JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q57008F
  • License MIT

Export apigateway docs.

Package Exports

  • apigateway-export-tool

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (apigateway-export-tool) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

apigateway-export-tool

Usage CLI

Usage: apigateway-export-tool [options]

Options:
  -V, --version            output the version number
  -p, --path [path]        path (default: "D:\\Projects\\npm\\apigateway-export")
  -t, --exportType [type]  exportType (default: "swagger")
  -i, --restApiId <id>     restApiId
  -e, --extensions [ext]   extensions (default: "postman")
  -s, --stageName [stage]  stageName (default: "prod")
  -h, --help               output usage information

Commands:
  list [options]
npx apigateway-export-tool list
npx apigateway-export-tool -i 123123 -stageName prod

Usage Nodejs

const { getExportAndSave, getRestApis, setAwsConfig } = require("apigateway-export-tool");
setAwsConfig({ region: "us-east-1" });

(async function() {
  const params = {
    exportType, // String ("oas30", "swagger")
    restApiId, // String
    stageName, // String
    parameters: {
      extensions // String ("postman", "integrations", "integrations", "authorizers")
    }
  };
  const filePath = "./";
  const apis = await getRestApis(); 
  const file = await getExportAndSave(params, filePath); //save the file in path.
  const file = await getExportAndSave(params); // just returning the file.
})();