Skip to main content

Documentation Index

Fetch the complete documentation index at: https://dev.puppetvendors.com/llms.txt

Use this file to discover all available pages before exploring further.

Overview

Vendor API keys let you authenticate with the PuppetVendors API programmatically. Each key is scoped to a single vendor account and can be restricted to specific permissions.

Key Prefixes

PrefixModeDescription
vk_liveLiveFull access to real data
vk_testTestFor development and testing

Available Scopes

Every API key must have at least one scope. Each scope grants access to a specific set of endpoints.
ScopeAccessEndpoints
orders:readRead orders, counts, timelineGET /orders, GET /orders/:id, GET /orders/counts, GET /orders/:id/timeline
orders:writeAdd order timeline commentsPOST /orders/:id/timeline
products:readRead products, countsGET /products, GET /products/:id, GET /products/counts
products:writeCreate, update, delete products, manage inventory and mediaPOST /products, PUT /products/:id, DELETE /products/:id, PATCH /products/:id/status, PATCH /products/:id/inventory, POST /products/media
fulfillments:readRead fulfillments, counts, stats, eventsGET /fulfillments, GET /fulfillments/counts, GET /fulfillments/stats, GET /fulfillments/events/:lineItemId
fulfillments:writeCreate and update fulfillments, manage eventsPOST /fulfillments, PUT /fulfillments/:id, POST /fulfillments/events/:lineItemId, POST /fulfillments/events/bulk
payouts:readRead payouts, transactions, pending items, summariesGET /payouts, GET /payouts/:id, GET /payouts/summary, GET /payouts/transactions, GET /payouts/pending
customers:readRead customer listGET /customers

Unscoped Endpoints

These endpoints work with any valid vendor token — no specific scope required on your API key:
GroupEndpoints
DiscountsList, create, update, delete discounts
ProfileGET/PUT /vendors/me/profile, GET/PUT /vendors/me/address
SettingsAccount, profile settings, shipping rates, warehouses, team members
IntegrationsShippo, ShipStation, PayPal, Stripe configuration
DocumentsInvoice, packing slip, shipping label generation
ShopFeature flags and product configuration

How Scopes Work

When you create an API key, you choose which scopes to include. The API rejects requests that require a scope your key doesn’t have with 403 Forbidden.

Read vs Write

  • :read scopes grant access to GET endpoints — listing, viewing, and exporting data
  • :write scopes grant access to POST, PUT, PATCH, and DELETE endpoints — creating, updating, and deleting data
Write scopes do not automatically include read access. If you need both, add both scopes (e.g., products:read and products:write).

Managing API Keys

ActionEndpointDescription
List keysGET /settings/public-api/keysSee all your API keys (tokens are masked)
Create keyPOST /settings/public-api/keysCreate a new key — token shown once
Rotate keyPOST /settings/public-api/keys/:keyId/rotateGenerate a new token, old one is invalidated
Delete keyDELETE /settings/public-api/keys/:keyIdPermanently revoke a key
When you create or rotate a key, the plaintext token is returned exactly once. Store it securely — you cannot retrieve it later.

Quick Start Example

# 1. Authenticate with your vendor API key
curl -X POST https://staging-api.puppetvendors.com/authenticate \
  -H "Content-Type: application/json" \
  -d '{"apiKey": "vk_live_abc123..."}'

# Response: {"success": true, "data": {"token": "eyJ...", "expiresIn": 86400}}

# 2. Use the JWT token for subsequent requests
curl -X GET "https://staging-api.puppetvendors.com/orders?first=10" \
  -H "x-access-token: eyJ..."