openapi-directory icon indicating copy to clipboard operation
openapi-directory copied to clipboard

Add "NetBox API" API

Open bcftv opened this issue 4 years ago • 1 comments
trafficstars

Format: OpenAPI 3.0 Official: YES Url: https://demo.netbox.dev/api/?format=json Name: NetBox API Category: enterprise Logo:

bcftv avatar Oct 07 '21 17:10 bcftv

Many thanks for the contribution. Please could you provide a link to the actual machine-readable API definition, in either OpenAPI or one of the other supported formats (RAML, API Blueprint, Postman etc)? Without this unfortunately we cannot add the API to the directory.

MikeRalphson avatar Aug 26 '22 09:08 MikeRalphson

@bcftv - Closing due to inactivity - but please feel free to reopen the issue if necessary.

MikeRalphson avatar Mar 04 '23 14:03 MikeRalphson

Apologies - I missed the notifications on this. I don't seem to be able to re-open it. Do you want a new issue?

Here's the OpenAPI JSON: https://demo.netbox.dev/api/docs/?format=openapi

And here's the browsable link: https://demo.netbox.dev/api/docs/

bcftv avatar Mar 06 '23 12:03 bcftv

@bcftv - It looks like your API definition did not fully validate. Please mention (@) MikeRalphson to discuss. Here is the log output:

MikeRalphson avatar Mar 06 '23 12:03 MikeRalphson

[email protected] check node --no-warnings --insecure-http-parser ./node_modules/@Mermade/api-registry/registry.js check --host undefined https://demo.netbox.dev/api/docs/?format=openapi

https://demo.netbox.dev/api/docs/?format=openapi Ffetch failed Saving metadata... Exiting with 1

MikeRalphson avatar Mar 06 '23 12:03 MikeRalphson

The endpoint seems very slow, hence I think our fetch is timing out.

MikeRalphson avatar Mar 06 '23 12:03 MikeRalphson

The endpoint seems very slow, hence I think our fetch is timing out.

Yes - it seems pretty laggy for me too. I'm afraid that I don't have any control over where it's hosted.

I logged a feature request for them to host it somewhere that is not dependent on their demo server: (https://github.com/netbox-community/netbox/issues/11911)

bcftv avatar Mar 06 '23 12:03 bcftv

Looks like they addressed this previously and added some server-side caching but the docs are generated on demand so they can't generate a static file.

If you can't adjust the timeout then I guess this is not going to be possible.

bcftv avatar Mar 06 '23 12:03 bcftv

I'll have a look, thanks for your efforts!

MikeRalphson avatar Mar 06 '23 13:03 MikeRalphson

API added, many thanks for the contribution! The API will be live on the website after the next CI run.

MikeRalphson avatar Mar 21 '23 13:03 MikeRalphson