Skip to content

Cannot successfully run queries through SmartAPI editor or registration page #187

@colleenXu

Description

@colleenXu

This is not urgent.

For CTD API (just registered https://smart-api.info/registry?q=0212611d1c670f9107baf00b77f0889a), when I "try an example" query, I get TypeError: NetworkError when attempting to fetch resource. This also happens if I copy the SmartAPI yaml into the Editor.

However, the uptime-checking with those same example values seems to be successful. I can run the same query successfully in Postman, the browser, and through BTE (testing on a local instance). With the browser, I get prompted to download the response as a file.

I'm wondering if this is related to the setup of the SmartAPI Editor/UI (references: swagger-api/swagger-editor#1861 and swagger-api/swagger-ui#5750).

Other notes I took
  • I think the CTD API is returning responses as files and Postman is unpacking / displaying those files. I therefore tried to represent this in the endpoint spec using this OpenAPI reference and these links on media-types.
  • I don't know whether this behavior can be changed by providing different headers in the request
  • I notice response-headers that I'm not used to (see screenshot below). I'm not sure how to add them to the endpoint spec, and whether that will help.
    Screen Shot 2023-03-13 at 10 22 59 PM

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions