Creates one or more AP credit memos in bulk. Each credit memo's detail lines are either GL-account-based or item-based, determined by the vendor's entry type. For by-account vendors, every detail line requires glAccountId. For by-item vendors, every detail line requires either glAccountId or vendorItemNumber plus quantity. See the field-level notes on glAccountId, vendorItemNumber, quantity, and eachAmount for the exact requirements in each mode.
Security
The requesting user must have the following permission to create AP credit memos:
- Accounts Payable → AP Credit Memos → Create AP Credit Memos
Create and approve are separate permissions — this permission does not grant approval rights.
Identifies the R365 tenant the request applies to. Required on every request.
The credit memo number (business identifier).
The vendor identifier.
The header location identifier.
The document date (ISO 8601 calendar date, no time component).
The document amount.
Optional header-level comment.
The list of credit memo detail line items.
Optional GL account identifier. Required for GL-account rows and for by-account vendors.
Optional location identifier for this line. Falls back to the header location when omitted.
Optional vendor item number. Required for item rows on by-item vendors when glAccountId is not provided.
Optional quantity. Required for item rows on by-item vendors.
Optional unit price. Derived from totalAmount / quantity when omitted on item rows.
The line total amount.
Optional unit of measure identifier.
Optional line-level comment.
207 Multi-Status – per-item processing outcomes for the credit memos in the request. Inspect the per-item Status to identify successes and failures.
Per-item processing outcomes, one entry per credit memo in the original request (same order, matched by requestIndex).
Zero-based index of this item in creditMemos array of the original request.
The credit memo number echoed from the request, so callers can match the result back to the input.
Processing outcome for this item.
Identifier of the created credit memo. Populated when status is Succeeded.
Machine-readable error code. Populated when status is Failed (e.g. urn:r365:accounts-payable:credit-memo:create-failed).
Human-readable error description. Populated when status is Failed.
Bad Request — a parameter value is malformed, of the wrong type, or outside its allowed range.
Unauthorized — the bearer token is missing, invalid or expired, or is not valid for the specified tenant.
Forbidden — the caller lacks the permission required for this operation.
Not Found — the requested resource does not exist, or the supplied continuation token is unknown or has expired.
Conflict — the request conflicts with the current state of the resource and cannot be applied.
Unprocessable Entity — a required parameter is missing, or a supplied parameter value is invalid.
Too Many Requests — the caller has exceeded the rate limit; retry after a short delay.
Internal Server Error — an unexpected error occurred while processing the request.