---
title: "Write off a credit memo"
method: PUT
path: "/v1/credit-memos/{creditMemoId}/write-off"
tags: ["Credit Memos"]
---

# Write off a credit memo

`PUT /v1/credit-memos/{creditMemoId}/write-off`

## Request

- Base URL: `https://rest.test.zuora.com`
- URL: `https://rest.test.zuora.com/v1/credit-memos/{creditMemoId}/write-off`
- Auth: HTTP bearer

**Note:** This operation is only available if you have [Invoice Settlement](https://docs.zuora.com?resourceId=billing-invoice-settlement) enabled. The Invoice Settlement feature is generally available as of Zuora Billing Release 296 (March 2021). This feature includes Unapplied Payments, Credit and Debit Memo, and Invoice Item Settlement. If you want to enable Invoice Settlement, see [Invoice Settlement Enablement and Checklist Guide](https://docs.zuora.com?resourceId=billing-invoice-settlement-migration-checklist-and-guide) for more information. 

Write off a fully unapplied credit memo. When writing off a credit memo, a debit memo is automatically created, and then the credit memo to be written off is fully applied to the debit memo.

Note that this operation only supports writing off credit memos that are fully unapplied. Credit memos that are not fully unapplied cannot be written off by this operation.

## Path parameters

- `creditMemoId` string, required

## Headers

- `Accept-Encoding` string
- `Content-Encoding` string
- `Zuora-Track-Id` string
- `Zuora-Entity-Ids` string
- `Zuora-Org-Ids` string
- `Zuora-Version` string

## Request body

- PUTCreditMemoWriteOff: Container for custom fields of a Debit Memo object.
  - `comment` string: Comments about the debit memo.
  - `memoDate` string, date: The creation date of the debit memo and the effective date of the credit memo. Credit memos are applied to the corresponding debit memos on `memoDate`. By default, `memoDate` is set to the current date.
  - `reasonCode` string: A code identifying the reason for the transaction. The value must be an existing reason code or empty. The default value is `Write-off`.

## Response `200`

OK

- PUTCreditMemoWriteOffResponseType
  - `debitMemo` object: Container for the credit memo that is automatically created.
    - `id` string: The unique ID of the created debit memo.
  - `success` boolean: Returns `true` if the request was processed successfully.

## Other responses

- `500`: Internal Server Error
- `4XX`: Request Errors

---

[API](https://skmtc.dev/zuora/apis/api-reference.md) · [All operations](https://skmtc.dev/zuora/apis/api-reference/llms.txt) · [OpenAPI document](https://skmtc.dev/zuora/apis/api-reference/revisions/2deecb0dd041?raw)
