Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@netlify/open-api
Advanced tools
This repository contains Netlify's API definition in the Open API format, formerly known as Swagger.
It's still a work in progress and we welcome feedback and contributions.
We use go-swagger to validate our spec against the 2.0 spec of Open API.
We currently depend on version 0.12.0 of the swagger toolchain. You can download the binary for your platform from this release page:
https://github.com/go-swagger/go-swagger/releases/tag/0.12.0
You can run this command to validate the spec:
make validate
Currently, we're generating client code for Go, but we're planning on releasing libraries in any language that can generate code from the spec.
You can use this command to generate the Go client:
make generate
You may first want to edit swagger.yml to add your field or endpoint definitions.
Swagger's JS client can dynamically create a client from a spec either from a URL or spec object.
See swagger-js
<script src='browser/swagger-client.js' type='text/javascript'></script>
<script>
var swaggerClient = new SwaggerClient('https://open-api.netlify.com/swagger.json');
</script>
You can also consume the swagger spec as an npm module:
$ npm install @netlify/open-api
# or
$ yarn add @netlify/open-api
import spec from '@netlify/open-api' // import the spec object into your project
The module also ships a copy of the original yml
spec file at @netlify/open-api/swagger.yml
.
Go to https://open-api.netlify.com to explore the spec definitions using Open-Api's UI.
MIT. See LICENSE for more details.
FAQs
Netlify's open-api definition as a module
The npm package @netlify/open-api receives a total of 67,742 weekly downloads. As such, @netlify/open-api popularity was classified as popular.
We found that @netlify/open-api demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 16 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.