New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

printful-sdk-js-v2

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

printful-sdk-js-v2

Printful SDK for Node.js / TypeScript. A wrapper for the Printful REST API (v2)

  • 2.0.0-beta
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

Printful SDK for TypeScript (Node.js)

NPM Version MIT license Project Status: WIP

📢 Printful API 2.0.0 is in beta [documentation]. This SDK is in development until the official 2.0.0 release (by 2025)

Printful SDK for Node.js. A basic TypeScript wrapper for the Printful REST API (v2). Guidelines and source endpoints can be found here: developers.printful.com/.

Getting started

Prerequisites

  1. Printful API Token (documentation)

Installation

# Npm
npm install printful-sdk-js-v2

# Yarn
yarn add printful-sdk-js-v2

# Pnpm
pnpm add printful-sdk-js-v2

Usage

⚠️ For security purposes, this is intended only for server-side use only

import { CountriesV2Api, Country } from 'printful-sdk-js-v2';
// const { CountriesV2Api, Country } = require('printful-sdk-js-v2'); // CommonJS

const apiKey = process.env.PRINTFUL_API_TOKEN || 'YOUR_PRINTFUL_API_TOKEN';

const countriesApi = new CountriesV2Api({ accessToken: apiKey });

(async () => {
  try {
    const countries: Country[] = await countriesApi.getCountries();
    console.log('List of countries:', countries);
  } catch (error) {
    console.error('Error fetching countries:', error);
  }
})();

API

For the full documentation, please see spencerlepine.github.io/printful-sdk-js-v2

Examples

To get started quickly, check out the JavaScript/TypeScript example code in the examples folder.

Contributing

We welcome contributions from the community! If you're interested in contributing to this project, please read the CONTRIBUTING.md file to get started.

Disclaimer

This SDK is a third-party library and is not officially endorsed or maintained by Printful. It is provided "as is" without warranty of any kind. For official information and guidelines on using the Printful API, please refer to the Printful Developer Documentation.

License

MIT

Keywords

FAQs

Package last updated on 04 Aug 2024

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc