Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs-alpha.pepay.io/llms.txt

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

Overview

Use these methods to fetch product details and offer options (shipping, retailer variations, etc.) for checkout.

Authentication

Requires x-commerce-api-key.

Request

Retrieve a product

const product = await pepay.commerce.products.retrieve('prod_123');

Get offers for a product

const offers = await pepay.commerce.products.offers('prod_123', { mode: 'checkout' });

Response

Example product response (truncated):
{
  "success": true,
  "data": {
    "productId": "B000NPYY04",
    "title": "Wireless Headphones",
    "price": 129.99,
    "image": "https://images.example.com/product.png"
  }
}

Errors

  • 401 missing/invalid commerce API key
  • 404 product not found

Examples

  • Fetch offers immediately before checkout to avoid stale pricing/shipping expectations. Next: Checkout