curl https://api.playto.so/v1/invoices/c3d4e5f6-a7b8-9012-cdef-123456789012/ \
-H "X-API-KEY: sk_live_your_api_key_here"
{
"id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
"invoice_number": "INV-20240501-C3D4E5",
"reference_id": "booking_88213",
"title": "Website Redesign - Phase 1",
"description": "Wireframes and initial mockups.",
"amount": 120000,
"currency": "USD",
"customer_name": "Jane Smith",
"customer_email": "jane@acme.com",
"customer_phone": "+1 555 000 1234",
"checkout_url": "https://app.playto.so/pay/checkout?paymentLinkId=c3d4e5f6-a7b8-9012-cdef-123456789012",
"redirect_url": "https://yoursite.com/thank-you",
"is_paid": false,
"is_expired": false,
"paid_at": null,
"expires_at": "2027-12-31T23:59:59Z",
"payment_method_configuration": null,
"created_at": "2024-05-01T10:00:00Z"
}
{
"error": {
"type": "not_found_error",
"code": "resource_not_found",
"message": "Invoice not found."
}
}
Invoices
Retrieve Invoice
Fetch details for a single invoice by its ID.
GET
/
invoices
/
{id}
/
curl https://api.playto.so/v1/invoices/c3d4e5f6-a7b8-9012-cdef-123456789012/ \
-H "X-API-KEY: sk_live_your_api_key_here"
{
"id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
"invoice_number": "INV-20240501-C3D4E5",
"reference_id": "booking_88213",
"title": "Website Redesign - Phase 1",
"description": "Wireframes and initial mockups.",
"amount": 120000,
"currency": "USD",
"customer_name": "Jane Smith",
"customer_email": "jane@acme.com",
"customer_phone": "+1 555 000 1234",
"checkout_url": "https://app.playto.so/pay/checkout?paymentLinkId=c3d4e5f6-a7b8-9012-cdef-123456789012",
"redirect_url": "https://yoursite.com/thank-you",
"is_paid": false,
"is_expired": false,
"paid_at": null,
"expires_at": "2027-12-31T23:59:59Z",
"payment_method_configuration": null,
"created_at": "2024-05-01T10:00:00Z"
}
{
"error": {
"type": "not_found_error",
"code": "resource_not_found",
"message": "Invoice not found."
}
}
Authentication
RequiresX-API-KEY header.
Path Parameters
Response
Your own id for this invoice, as you sent it when you created the invoice.
null if none was set.Whether the invoice has passed its expiry date. It turns
true once the calendar day of expires_at has ended (India Standard Time).The saved payment method setting, for example
{"enabled": ["card"]}. null means the usual methods. See Payment Methods.curl https://api.playto.so/v1/invoices/c3d4e5f6-a7b8-9012-cdef-123456789012/ \
-H "X-API-KEY: sk_live_your_api_key_here"
{
"id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
"invoice_number": "INV-20240501-C3D4E5",
"reference_id": "booking_88213",
"title": "Website Redesign - Phase 1",
"description": "Wireframes and initial mockups.",
"amount": 120000,
"currency": "USD",
"customer_name": "Jane Smith",
"customer_email": "jane@acme.com",
"customer_phone": "+1 555 000 1234",
"checkout_url": "https://app.playto.so/pay/checkout?paymentLinkId=c3d4e5f6-a7b8-9012-cdef-123456789012",
"redirect_url": "https://yoursite.com/thank-you",
"is_paid": false,
"is_expired": false,
"paid_at": null,
"expires_at": "2027-12-31T23:59:59Z",
"payment_method_configuration": null,
"created_at": "2024-05-01T10:00:00Z"
}
{
"error": {
"type": "not_found_error",
"code": "resource_not_found",
"message": "Invoice not found."
}
}
