swagger-typescript-api icon indicating copy to clipboard operation
swagger-typescript-api copied to clipboard

Group routes by first tag with delimiter

Open jannis6023 opened this issue 8 months ago • 0 comments

I group my API Routes in the swagger by naming my tags by the "category" - e.g. routes starting with /tenants/:tenantId/users/:userId has tag /tenants/users as it is affecting users in tenants. I found that sta currently supports the "split by first tag", but this would make swagger typescript api more advanced and more seeming like APIs generated by e.g. OpenAPI or Stripe.

I guess it would be easy if you specify a delimiter in the command, e.g. /. Then grouping "underneath". So just a new child object containing the endpoints.

Then you could use the request from the example above via api.tenants.users.getUser(...).

jannis6023 avatar Mar 30 '25 13:03 jannis6023