Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with openapi generator #976

Open
benjaminfrancois opened this issue Sep 12, 2024 · 0 comments
Open

Problem with openapi generator #976

benjaminfrancois opened this issue Sep 12, 2024 · 0 comments

Comments

@benjaminfrancois
Copy link

Hello,

I'm using this library for the first time, and it works great!
However, I've generated TypeScript Axios services for the frontend using OpenAPI Generator, and all the responses are wrapped in the PaginatedDocumented interface. I would like to retrieve the actual interface that is correctly defined in the Swagger, but it seems to be nested within a secondary object.

"responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/PaginatedDocumented"
                    },
                    {
                      "properties": {
                        "data": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Organization"
                          }
                        },
                        "meta": {
                          "properties": {
                            "select": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "enum": [
                                  "id",
                                  "name",
                                  "siret",
                                  "archivedAt",
                                  "createdAt",
                                  "updatedAt"
                                ]
                              }
                            },

I use :

  @ApiOkPaginatedResponse(Organization, ORGANIZATION_PAGINATE_OPTIONS)
  @ApiPaginationQuery(ORGANIZATION_PAGINATE_OPTIONS)

Thank's !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant