kenyipp / selling-partner-api-sdk

A fully typed TypeScript and Node.js SDK library for Amazon Selling Partner API

Home Page:https://npm.im/@scaleleap/selling-partner-api-sdk

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Selling Partner API for Node.js

NPM License GitHub Workflow Status Codecov Snyk Semantic Release FOSSA Status


  • A fully typed TypeScript and Node.js SDK package for Amazon Selling Partner API
  • Uses models from API model's repo to generate classes automatically
  • Picks up changes and releases daily when/if models have drifted
  • Based on Axios and uses aws4-axios interceptor to automatically sign the requests
  • Can optionally assume roles via STS, and refresh STS credentials on schedule

Download & Installation

npm i -s @scaleleap/selling-partner-api-sdk

Getting Started

Prerequisites

A few things to get started:

Basic Usage

The general format applies to any Selling Partner API request:

import { SellersApiClient } from '@scaleleap/selling-partner-api-sdk'

const client = new SellersApiClient({
  accessToken: 'Atza|...',

  // Or use `amazonMarketplaces.CA.sellingPartner.region.endpoint`
  // from `@scaleleap/amazon-marketplaces` package
  basePath: 'https://sellingpartnerapi-na.amazon.com',

  // Or use `amazonMarketplaces.CA.sellingPartner.region.awsRegion`
  // from `@scaleleap/amazon-marketplaces` package
  region: 'us-east-1',
})

const marketplaceParticipations = await client.getMarketplaceParticipations()

See the full list of exported classes and types: src/api-models/index.ts.

See @scaleleap/amazon-marketplaces docs for a database of constants about Amazon Marketplaces.

Documentation

Contributing

This repository uses Conventional Commit style commit messages.

Authors or Acknowledgments

License

This project is licensed under the MIT License.

FOSSA Status

About

A fully typed TypeScript and Node.js SDK library for Amazon Selling Partner API

https://npm.im/@scaleleap/selling-partner-api-sdk

License:MIT License


Languages

Language:TypeScript 100.0%Language:JavaScript 0.0%Language:Shell 0.0%