Skip to content
Connect an agent
Billing

Download an invoice or receipt as a PDF

The PDF Stripe made for the invoice, as a file to save.

GET/user/billing/documents/{id}/pdf

TL;DR

QuestionAnswer
What does it do?Download an invoice or receipt as a PDF.
What does it take?id in the path.
What does it return?Status 200 with no body.
What can go wrong?400 the id is not shaped like an invoice id; 401 not signed in; 404 no such document for this account, or it has no pdf; 429 too many requests; 502 stripe could not supply the pdf; 503 billing is not set up on this server. Every failure uses the one error envelope.

What it does

The PDF Stripe made for the invoice, as a file to save. Only the address Stripe returned on this account's own invoice is fetched, and only if it is https on a Stripe host. Never cached. 404 for a document with no PDF.

Path parameters

FieldTypeRequiredDescription
idstringyesThe document id, as the list gave it.

Responses

StatusMeaningBody
200The PDF.none
400The id is not shaped like an invoice id.ErrorResponse
401Not signed in.ErrorResponse
404No such document for this account, or it has no PDF.ErrorResponse
429Too many requests.ErrorResponse
502Stripe could not supply the PDF.ErrorResponse
503Billing is not set up on this server.ErrorResponse

See also

DocWhy
API referenceEvery endpoint, and the error envelope
SchemasEvery request and response type
Tool referenceThe operations as callable tools