npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

amazon-creators-api

v1.2.2

Published

Amazon Creators API NodeJS SDK

Downloads

362

Readme

Amazon Creators API Node.js SDK

https://github.com/ryanschiang/amazon-creators-api https://github.com/ryanschiang/amazon-creators-api/blob/main/LICENSE.txt https://github.com/ryanschiang/amazon-creators-api https://npmjs.com/package/amazon-creators-api

This is an unofficial TypeScript wrapper for the Amazon Creators API Node.js SDK.

This package implements a thin TypeScript wrapper around Amazon's JS runtime internals to add proper types to the Node.js SDK.

Prerequisites

  • Node.js version 18 or higher
  • Register for the Creators API

Installation

npm install amazon-creators-api

Usage

See the examples directory for usage examples.

Get Items

import {
  ApiClient,
  GetItemsRequestContent,
  GetItemsResource,
  TypedDefaultApi,
} from "amazon-creators-api";

// Initialize API client
const apiClient = new ApiClient();

// Add credential details
// You can find these in the Creators API dashboard: https://affiliate-program.amazon.com/creatorsapi
apiClient.credentialId = "<YOUR CREDENTIAL ID>";
apiClient.credentialSecret = "<YOUR CREDENTIAL SECRET>";
apiClient.version = "<YOUR CREDENTIAL VERSION>";

// Initialize typed API wrapper
const api = new TypedDefaultApi(apiClient);

/**
 * Sample function to demonstrate GetItems API usage
 */
async function getItems(): Promise<void> {
  /**
   * Add marketplace. For more details, refer: https://affiliate-program.amazon.com/creatorsapi/docs/en-us/api-reference/common-request-headers-and-parameters#marketplace-locale-reference
   */
  const marketplace = "<YOUR MARKETPLACE>"; // e.g. "www.amazon.com" for US marketplace

  // Create GetItems request
  // Enter your partner tag (store/tracking id)
  const partnerTag = "<YOUR PARTNER TAG>";

  // Choose item id(s) - ASINs to retrieve
  const itemIds = ["B0DLFMFBJW", "B0BFC7WQ6R", "B00ZV9RDKK"];

  const getItemsRequest = new GetItemsRequestContent(partnerTag, itemIds);

  /**
   * Choose resources you want from GetItemsResource enum
   * For more details, refer: https://affiliate-program.amazon.com/creatorsapi/docs/en-us/api-reference/operations/get-items#resources-parameter
   */
  const resources = [
    "images.primary.medium",
    "itemInfo.title",
    "itemInfo.features",
    "offersV2.listings.price",
    "offersV2.listings.availability",
    "offersV2.listings.condition",
    "offersV2.listings.merchantInfo",
  ].map((resource) => GetItemsResource.constructFromObject(resource));
  getItemsRequest.resources = resources;

  try {
    const response = await api.getItems(marketplace, getItemsRequest);
    console.log("API called successfully.");
    console.log("Complete Response:\n", JSON.stringify(response, null, 2));
  } catch (error) {
    console.log("Error calling Creators API!");
    console.log("Full Error Object:\n", JSON.stringify(error, null, 2));
  }

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

License

Licensed under the Apache License, Version 2.0. See the https://github.com/ryanschiang/amazon-creators-api/blob/main/LICENSE.txt file for details.

Original authorship belongs to Amazon.com, Inc. or its affiliates. See the https://github.com/ryanschiang/amazon-creators-api/blob/main/NOTICE.txt file for details.

Modifications copyright (c) 2026 Ryan Chiang.