API documentation

Endpoints

GET/client/:customerId/invoice/:invoiceId/stripe/download

Download Stripe PDF

This endpoint provides the PDF representation of the original Stripe Invoice. Authorization and the customer/invoice relationship are checked before returning the redirect.

Request
Build the URL with the parameters below and send the code in the Authorization header.
GEThttps://stripe-ix.betacode.tech/api/v1/client/:customerId/invoice/:invoiceId/stripe/download

Inputs and parameters

customerIdpathstring

Stripe Customer ID. Starts with cus_.

Required

invoiceIdpathstring

Stripe Invoice ID. Starts with in_.

Required

Request example

curl -L "https://stripe-ix.betacode.tech/api/v1/client/cus_Q1w2E3r4/invoice/in_1Q2w3E4r/stripe/download" \
  -H "Authorization: Bearer ixp_test_YOUR_ACCESS_CODE" \
  --output invoice-stripe.pdf
Response
On success, this endpoint returns HTTP 302 with the destination in the Location header.

Output example

HTTP/1.1 302 Found
Location: https://pay.stripe.com/invoice/acct_.../pdf
Cache-Control: no-store

Behavior

  • The response is HTTP 302 to the current invoice_pdf returned by Stripe.
  • The HTTP client must follow redirects; curl requires the -L option.
  • The API may return an error if Stripe has not made a PDF available for this Invoice.

Integration notes

  • The destination belongs to Stripe and may expire or change; download the file immediately.
  • The access code is only sent to the connector host, never to the Stripe destination URL.