Socket
Socket
Sign inDemoInstall

oas-resolver

Package Overview
Dependencies
22
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    oas-resolver

Resolve external $refs in OpenAPI (swagger) 2.0 / 3.x definitions


Version published
Weekly downloads
1.3M
increased by1.07%
Maintainers
1
Install size
1.35 MB
Created
Weekly downloads
 

Readme

Source

oas-resolver

Usage

const yaml = require('yaml');
const input = yaml.parse(str);
const source = url; // or filename
resolver.resolve(input,source,options)
.then(function(options){
  fs.writeFileSync(outputFile,yaml.stringify(options.openapi),'utf8');
})
.catch(function(ex){
  // ...
});

See here for complete documentation of the options object.

Keywords

FAQs

Last updated on 07 Jul 2021

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc