Skip to content

SamVerschueren/aws-swagger-import

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aws-swagger-import Build Status

AWS swagger importer

Install

$ npm install --save aws-swagger-import

Usage

const awsSwaggerImport = require('aws-swagger-import');

awsSwaggerImport('swagger.json', {name: 'foo', awsProfile: 'aws-profile'}).then(() => {
	// done
});

API

awsSwagger(file, [options])

file

Type: string

JSON swagger definition file.

options

name

Required
Type: string

Name of the API Gateway to import to.

alias

Type: string

Alias or version of the lambda functions that should be invoked by the gateway.

accountId

Type: string

AWS Account ID that will be used in the swagger definition file when linking lambda functions.

awsProfile

Type: string

AWS Profile. The user related to the profile should have admin access to API Gateway.

awsRegion

Type: string
Default: us-west-1

AWS region.

awsFilename

Type: string
Default: ~/.aws/credentials

Filename to use when loading credentials.

Related

License

MIT © Sam Verschueren