[GH-ISSUE #4850] [bug]: Import from Open API not load all requests #1823

Closed
opened 2026-03-16 21:55:11 +03:00 by kerem · 3 comments
Owner

Originally created by @zabojpetr on GitHub (Mar 6, 2025).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4850

Originally assigned to: @anwarulislam on GitHub.

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

When I upload open api from grafana, there are missing some requests - for example dashboard/db for creating dashboard.

grafana_api-merged.json

Steps to reproduce

  1. Import/Export
  2. Import from OpenAPI
  3. Import from file
  4. Choose file
  5. Import

Environment

Production

Version

Cloud

Originally created by @zabojpetr on GitHub (Mar 6, 2025). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4850 Originally assigned to: @anwarulislam on GitHub. ### Is there an existing issue for this? - [x] I have searched the existing issues ### Current behavior When I upload open api from grafana, there are missing some requests - for example dashboard/db for creating dashboard. [grafana_api-merged.json](https://github.com/user-attachments/files/19109674/grafana_api-merged.json) ### Steps to reproduce 1. Import/Export 2. Import from OpenAPI 3. Import from file 4. Choose file 5. Import ### Environment Production ### Version Cloud
kerem 2026-03-16 21:55:11 +03:00
Author
Owner

@jamesgeorge007 commented on GitHub (Apr 11, 2025):

Hi, the OpenAPI importer had a few improvements recently. Could you see if there are persisting inconsistencies in the latest release?

<!-- gh-comment-id:2796107460 --> @jamesgeorge007 commented on GitHub (Apr 11, 2025): Hi, the OpenAPI importer had a few improvements recently. Could you see if there are persisting inconsistencies in the latest release?
Author
Owner

@zabojpetr commented on GitHub (Apr 11, 2025):

Hi,

it look like methods are imported now, but they have odd names. For names are used operationId. Wouldn't it be better to use summary? But I don't know the openapi well so maybe it is not good idea, I don't know.

Example:

Image

"/dashboards/db": {
      "post": {
        "description": "Creates a new dashboard or updates an existing dashboard.\nNote: This endpoint is not intended for creating folders, use `POST /api/folders` for that.",
        "tags": [
          "dashboards"
        ],
        "summary": "Create / Update dashboard",
        "operationId": "postDashboard",
        "parameters": [
          {
            "name": "Body",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/SaveDashboardCommand"
            }
          }
        ],
        "responses": {
          "200": {
            "$ref": "#/responses/postDashboardResponse"
          },
          "400": {
            "$ref": "#/responses/badRequestError"
          },
          "401": {
            "$ref": "#/responses/unauthorisedError"
          },
          "403": {
            "$ref": "#/responses/forbiddenError"
          },
          "404": {
            "$ref": "#/responses/notFoundError"
          },
          "412": {
            "$ref": "#/responses/preconditionFailedError"
          },
          "422": {
            "$ref": "#/responses/unprocessableEntityError"
          },
          "500": {
            "$ref": "#/responses/internalServerError"
          }
        }
      }
    },
<!-- gh-comment-id:2796141019 --> @zabojpetr commented on GitHub (Apr 11, 2025): Hi, it look like methods are imported now, but they have odd names. For names are used operationId. Wouldn't it be better to use summary? But I don't know the openapi well so maybe it is not good idea, I don't know. Example: ![Image](https://github.com/user-attachments/assets/811fd929-8e3f-4c26-b0b4-4fb104625516) ```json "/dashboards/db": { "post": { "description": "Creates a new dashboard or updates an existing dashboard.\nNote: This endpoint is not intended for creating folders, use `POST /api/folders` for that.", "tags": [ "dashboards" ], "summary": "Create / Update dashboard", "operationId": "postDashboard", "parameters": [ { "name": "Body", "in": "body", "required": true, "schema": { "$ref": "#/definitions/SaveDashboardCommand" } } ], "responses": { "200": { "$ref": "#/responses/postDashboardResponse" }, "400": { "$ref": "#/responses/badRequestError" }, "401": { "$ref": "#/responses/unauthorisedError" }, "403": { "$ref": "#/responses/forbiddenError" }, "404": { "$ref": "#/responses/notFoundError" }, "412": { "$ref": "#/responses/preconditionFailedError" }, "422": { "$ref": "#/responses/unprocessableEntityError" }, "500": { "$ref": "#/responses/internalServerError" } } } }, ```
Author
Owner

@jamesgeorge007 commented on GitHub (Apr 11, 2025):

Thanks for the feedback. The existing implementation prefers the operationId field due to its uniqueness and predictability while creating requests with suitable fallbacks.

github.com/hoppscotch/hoppscotch@80b63545f1/packages/hoppscotch-common/src/helpers/import-export/import/openapi.ts (L807)

Again, this has scope for improvement from a UX standpoint that can be evaluated and revisited, and I'd appreciate opening a new issue to track the same. Closing this issue since the original concern is addressed.

<!-- gh-comment-id:2796197210 --> @jamesgeorge007 commented on GitHub (Apr 11, 2025): Thanks for the feedback. The existing implementation prefers the `operationId` field due to its uniqueness and predictability while creating requests with suitable fallbacks. https://github.com/hoppscotch/hoppscotch/blob/80b63545f14b43067ba290ab6bf15e3d8438f966/packages/hoppscotch-common/src/helpers/import-export/import/openapi.ts#L807 Again, this has scope for improvement from a UX standpoint that can be evaluated and revisited, and I'd appreciate opening a new issue to track the same. Closing this issue since the original concern is addressed.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#1823
No description provided.