---
title: "Upload a file for a debit memo"
method: POST
path: "/v1/debit-memos/{debitMemoKey}/files"
tags: ["Debit Memos"]
---

# Upload a file for a debit memo

`POST /v1/debit-memos/{debitMemoKey}/files`

**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. 

Uploads an externally generated PDF file for a debit memo that is in Draft or Posted status.

To use this operation, you must enable the Modify Debit Memo permission. See [Billing Permissions](https://docs.zuora.com?resourceId=platform-billing-roles) for more information.

This operation has the following restrictions:
- Only the PDF file format is supported.
- The maximum size of the PDF file to upload is 4 MB.
- A maximum of 50 PDF files can be uploaded for one debit memo.

## Path parameters

- `debitMemoKey` string, required

## Headers

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

## Response `200`

OK

- POSTUploadFileResponse
  - `fileId` string — The unique ID of the uploaded PDF file.
  - `success` boolean — Indicates whether the call succeeded.

## 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-service-production.skmtc.workers.dev/v1/apis/zuora/api-reference/revisions/d11e237f3e54/schema)
