Get subscription payment details

Returns one subscription payment by ID — a single charge in a subscription billing cycle, including its payment and invoice status, billing reason, payment method, and Stripe references. To list every payment on a subscription, use the list endpoint with subscriptionId.

GET/v1/subscription-payments/:subscriptionPaymentId

Authorization

api_key_auth
AuthorizationBearer <token>

API key authentication. Use "Bearer YOUR_API_KEY" format.

In: header

Path Parameters

subscriptionPaymentIdstringrequired

The ID of the subscription payment to retrieve. Use the list subscription payments endpoint first if you need to discover an ID — filter by subscriptionId to see every payment on one subscription.

^[0-9a-fA-F]{24}$

Query Parameters

livemodestring

Set to false to return test-mode records created while a page was in test mode. Defaults to the mode of the API key. Test API keys can only read test data.

truefalse

Returns

Subscription payment retrieved successfully

    • idstring

      Unique identifier for the subscription payment

    • subscriptionId?string

      ID of the subscription this payment belongs to

    • customerId?string

      ID of the customer

    • pageId?string

      ID of the page the subscription was bought on. A sale made through your store carries an ID that is not a checkout page in the API.

    • storeId?string

      ID of the store it was sold in. Absent for a sale made outside a store. Match this to find everything a store sold.

    • productId?string

      ID of the product

    • sellerId?string

      ID of the seller

    • transactionIds?string[]

      IDs of the transactions associated with this payment

    • customerEmail?string

      Email of the customer at time of payment

    • customerName?string

      Name of the customer at time of payment

    • productTitle?string

      Title of the product at time of payment

    • pageSlug?string

      Slug of the page at time of payment

    • currency?string

      ISO 4217 currency code (lowercase)

    • amountnumber

      Amount in the smallest unit of the currency

    • amountUsd?number

      Amount converted to USD (smallest unit)

    • What this payment added to cover the processing fee, when the customer chose to at checkout. Already inside amount.

    • livemode?boolean

      true for live charges, false for test mode

    • paymentStatus?string
      succeededpendingfailedincomplete
    • invoiceStatus?string
      draftopenpaiduncollectiblevoid
    • paid?boolean
    • refunded?boolean
    • partiallyRefunded?boolean
    • billingReason?string
      manualsubscription_createsubscription_cyclesubscription_thresholdsubscription_updateupcoming
    • stripeSubscriptionId?string
    • stripePaymentId?string
    • stripePaymentIntentId?string
    • stripeInvoiceId?string
    • stripeInvoicePdf?string
    • stripeRefundInvoicePdf?string
    • createdAtstring

      date-time

    • updatedAtstring

      date-time

Bad request - Invalid request parameters

  • statusstring

    Indicates the request failed.

    error
  • typestring

    Machine-readable error category.

  • messagestring

    Human-readable error message.

  • Optional validation details for invalid requests.

Unauthorized - Missing or invalid API key

  • statusstring

    Indicates the request failed.

    error
  • typestring

    Machine-readable error category.

  • messagestring

    Human-readable error message.

  • Optional validation details for invalid requests.

Forbidden - Insufficient permissions or validation error

  • statusstring

    Indicates the request failed.

    error
  • typestring

    Machine-readable error category.

  • messagestring

    Human-readable error message.

  • Optional validation details for invalid requests.

Subscription payment not found

  • statusstring

    Indicates the request failed.

    error
  • typestring

    Machine-readable error category.

  • messagestring

    Human-readable error message.

  • Optional validation details for invalid requests.

Rate Limit Exceeded - Please try again later.

  • messagestring

    Human-readable error message.

Internal server error

  • statusstring

    Indicates the request failed.

    error
  • typestring

    Machine-readable error category.

  • messagestring

    Human-readable error message.

  • Optional validation details for invalid requests.

import { createCheckoutPageClient } from '@checkoutpage/sdk';const checkoutpage = createCheckoutPageClient({  apiKey: process.env.CHECKOUTPAGE_API_KEY!,});const response = await checkoutpage.subscriptionPayments.get('6812fe6e9f39b6760576f01c');
{
  "data": {
    "id": "507f1f77bcf86cd799439011",
    "subscriptionId": "65f4a1c2e4a9f3d2b1c0a9e8",
    "customerId": "65f4a1c2e4a9f3d2b1c0a9e8",
    "pageId": "65f4a1c2e4a9f3d2b1c0a9e8",
    "storeId": "string",
    "productId": "65f4a1c2e4a9f3d2b1c0a9e8",
    "sellerId": "65f4a1c2e4a9f3d2b1c0a9e8",
    "transactionIds": [
      "65f4a1c2e4a9f3d2b1c0a9e8"
    ],
    "customerEmail": "string",
    "customerName": "string",
    "productTitle": "string",
    "pageSlug": "string",
    "currency": "usd",
    "amount": 0,
    "amountUsd": 0,
    "processingFeeContribution": {
      "name": "string",
      "amount": 0
    },
    "livemode": true,
    "paymentStatus": "succeeded",
    "invoiceStatus": "draft",
    "paid": true,
    "refunded": true,
    "partiallyRefunded": true,
    "billingReason": "manual",
    "paymentMethod": {
      "gateway": "stripe",
      "method": "string",
      "wallet": "string",
      "mode": "default",
      "brand": "string",
      "last4": "string",
      "country": "string",
      "expMonth": 0,
      "expYear": 0,
      "funding": "string"
    },
    "stripeSubscriptionId": "string",
    "stripePaymentId": "string",
    "stripePaymentIntentId": "string",
    "stripeInvoiceId": "string",
    "stripeInvoicePdf": "string",
    "stripeRefundInvoicePdf": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z"
  }
}
{
  "status": "error",
  "type": "ValidationError",
  "message": "Bad request - Invalid body: Field 'email' must be a valid email address",
  "errors": [
    {
      "param": "email",
      "message": "must be a valid email address"
    }
  ]
}
{
  "status": "error",
  "type": "error",
  "message": "Missing or invalid API key"
}
{
  "status": "error",
  "type": "error",
  "message": "Insufficient permissions requires: BOOKINGS_WRITE"
}
{
  "status": "error",
  "type": "error",
  "message": "Subscription payment not found"
}
{
  "message": "API key rate limit exceeded. Please try again later."
}
{
  "status": "error",
  "type": "error",
  "message": "Internal server error"
}