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

# Ar create write off

> Ar create write off

### Request body

`CreateArWriteOffRequest`

<ParamField body="amount" type="string" required>
  Decimal amount as a string.
</ParamField>

<ParamField body="approved_by" type="string,null" />

<ParamField body="invoice_id" type="string" required />

<ParamField body="notes" type="string,null" />

<ParamField body="reason" type="string" required>
  One of `uncollectible`, `bankruptcy`, `customer_dispute`, `small_balance`,
  `account_closed`, `deceased`, `other`.
</ParamField>

### Responses

<ResponseField name="201" type="ArWriteOffResponse" />

<ResponseField name="400" type="ErrorBody" />

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url 'https://api.stateset.com/api/v1/ar/write-offs' \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
    "amount": "string",
    "approved_by": null,
    "invoice_id": "string",
    "notes": null,
    "reason": "string"
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "amount": "string",
    "created_at": "string",
    "customer_id": "string",
    "id": "string",
    "invoice_id": "string",
    "reason": "string",
    "reversed": true,
    "write_off_number": "string"
  }
  ```
</ResponseExample>
