New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

aws-api-gateway-javascript-client

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

aws-api-gateway-javascript-client

This is a simple Axios wrapper for AWS Api Gateway client. It simplifies the process of signing each request using Signature V4. In order to use the app import it to your project.

latest
npmnpm
Version
0.1.1
Version published
Maintainers
1
Created
Source

This is a simple Axios wrapper for AWS Api Gateway client. It simplifies the process of signing each request using Signature V4. In order to use the app import it to your project.

import ApiGatewayJsClient from 'aws-api-gateway-javascript-client'

Then initiate the constructor

const api = new ApiGatewayJsClient({
  invokeUrl: 'https://apidomainexample.com',
  accessKey: 'Example Access Key',
  secretKey: 'Example Secret Key',
  region: 'eu-west-2',
  headers: {
    host: 'example.host.com'
  }
});

You can now start making requests using the instance. All the access

Example post request

api.post('/sample-path', {
  url: 'hello world'
}).then((response) => {
  console.log(response);
}).catch((error) => {
  console.log(error);
});

Example get request

api.get('/sample-path', {
  params: {
  	foo: 'bar'
  }
}).then((response) => {
  console.log(response);
}).catch((error) => {
  console.log(error);
});

FAQs

Package last updated on 03 Jul 2018

Did you know?

Socket

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