Skip to content
Discussion options

You must be logged in to vote

@wellington-vell you just need to do what Dosu told you.

import { defineConfig } from '@hey-api/openapi-ts';

export default defineConfig({
  input: 'src/source/health.json',
  output: {
    entryFile: false,
    path: './src/client',
  },
  plugins: [
    {
      name: '@hey-api/sdk',
      operations: {
        containerName: {
          name: 'orpc',
          casing: 'preserve',
        },
        strategy: 'byTags',
        nesting(operation) {
          // Parse your tag (e.g., "HealthV1") into ["Health", "v1"]
          const tag = operation.tags?.[0] || 'default';
          const versionMatch = tag.match(/^(.+?)(V\d+)$/i);

          if (versionMatch) {
            const [, baseName,

Replies: 2 comments 11 replies

Comment options

You must be logged in to vote
2 replies
@mrlubos
Comment options

@dosubot
Comment options

Comment options

You must be logged in to vote
9 replies
@mrlubos
Comment options

@wellington-vell
Comment options

@mrlubos
Comment options

Answer selected by wellington-vell
@wellington-vell
Comment options

@mrlubos
Comment options

@wellington-vell
Comment options

@mrlubos
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants