> ## Documentation Index
> Fetch the complete documentation index at: /llms.txt
> Use this file to discover all available pages before exploring further.

# Void Invoice

> Void an unpaid invoice by expiring it immediately.

### Authentication

Requires `X-API-KEY` header.

### Path Parameters

**id** `uuid` *required*

The unique identifier of the invoice to void.

### Details

This endpoint instantly expires an invoice. If the invoice has already been paid, it returns a `422` error with the code `invoice_already_paid`.

### Response

Returns the updated invoice object with `is_expired` set to `true`.

```json 200 (success)
{
  "id": "a1b2c3d4-5678-90ab-cdef-1234567890ab",
  "invoice_number": "INV-123456",
  "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",
  "checkout_url": "https://app.playto.so/pay/...",
  "redirect_url": "https://acme.com/thanks",
  "is_paid": false,
  "is_expired": true,
  "paid_at": null,
  "expires_at": "2026-06-04T12:00:00Z",
  "source": "api",
  "payment_method_configuration": null,
  "created_at": "2026-06-03T12:00:00Z"
}
```

```json 422 (invoice already paid)
{
  "error": {
    "type": "invalid_request_error",
    "code": "invoice_already_paid",
    "message": "A paid invoice cannot be voided."
  }
}
```
