usebruno / bruno

Opensource IDE For Exploring and Testing Api's (lightweight alternative to postman/insomnia)
https://www.usebruno.com/
MIT License
26.98k stars 1.23k forks source link

"Open API Spec" doesn't appear to work #1986

Open DanaEpp opened 7 months ago

DanaEpp commented 7 months ago

Issue

I am trying to import a sample API spec doc (OAS 3.0.1) using the "Open API Spec" link in the UI.

image

The spec doc I am using can be found here.

While I can select it through the file explorer, it doesn't do anything. It doesn't load up, and I see no errors.

This is for Golden Edition v1.12.3.

DanaEpp commented 7 months ago

I've heard on Discord that the issue here is that the API spec import only supports YAML format currently, and not JSON.

So, this should be marked as a Feature Enhancement—a pretty major one, if you ask me—but still just an enhancement.

melroy89 commented 2 months ago

yup. I noticed that JSON isn't working, but YAML is. So this is a missing feature IMO.

NiklasBr commented 2 months ago

JSON isn't working, but YAML is

A hacky suggestion: According to spec a valid JSON file should also be valid YAML, so try to change the file extension to .yaml and open again.

melroy89 commented 2 months ago

Ahha no. Json isn't yaml. It's a totally different format.

NiklasBr commented 2 months ago

JSON is valid YAML

melroy89 commented 2 months ago

JSON is valid YAML

Ow... OK. Today I learned that json is mostly valid yaml.