> For the complete documentation index, see [llms.txt](https://docs.xplorpay.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.xplorpay.com/api-reference/resources/visas-commercial-enhanced-data-program/level-3-error-code.md).

# Level 3 error code

Resolve Visa Commercial Enhanced Data Program Level 3 validation errors.

Use this reference to resolve Visa Commercial Enhanced Data Program (CEDP) Level 3 validation errors. It covers supported enhanced-data capabilities only.

{% hint style="warning" %}
These error codes are Visa Confidential and are not part of the Visa Rules. If this reference conflicts with Visa rules or specifications, use the Visa-controlled source and contact your Visa representative.
{% endhint %}

### Identify the record family

Use this table to identify where to begin investigating an error code.

<table data-search="true"><thead><tr><th valign="top">Code prefix</th><th valign="top">Start your investigation with</th></tr></thead><tbody><tr><td valign="top"><code>CS-xxxx</code></td><td valign="top">The TC05 clearing record and supporting enhanced-data fields.</td></tr><tr><td valign="top"><code>TC50-0xxx</code></td><td valign="top">Invoice structure and the PURCHA header or summary.</td></tr><tr><td valign="top"><code>TC50-1xxx</code> or <code>TC50-2xxx</code></td><td valign="top">PURCHL line details, calculations, sequence, and description quality.</td></tr></tbody></table>

### Error code

**What Visa is flagging** describes the validation failure. **First thing to check** gives a practical starting point. It does not replace Visa-controlled specifications.

#### CS codes: TC05 summary checks

Use this table to resolve errors in the TC05 clearing record and related summary fields.

<table><thead><tr><th valign="top">Code</th><th valign="top">Type</th><th valign="top">What Visa is flagging</th><th valign="top">First thing to check</th></tr></thead><tbody><tr><td valign="top"><code>CS-0001</code></td><td valign="top">Allowed value</td><td valign="top">Number of payment forms contains a value Visa does not allow.</td><td valign="top">Send blank, <code>1</code>–<code>9</code>, or <code>+</code>, as applicable.</td></tr><tr><td valign="top"><code>CS-0002</code></td><td valign="top">Allowed value</td><td valign="top">Purchase ID format contains an unsupported value.</td><td valign="top">Use blank, <code>0</code>, <code>1</code>, or <code>5</code>.</td></tr><tr><td valign="top"><code>CS-0003</code></td><td valign="top">Missing dependency</td><td valign="top">Purchase ID format indicates an ID should exist, but Purchase ID is empty.</td><td valign="top">Provide the Purchase ID. Use blank or <code>0</code> when no ID is supplied.</td></tr><tr><td valign="top"><code>CS-0004</code></td><td valign="top">Allowed value</td><td valign="top">Local Tax Included is not coded as included or not included.</td><td valign="top">Use <code>1</code> or <code>2</code>.</td></tr><tr><td valign="top"><code>CS-0005</code></td><td valign="top">Field dependency</td><td valign="top">A local tax amount was sent, but Local Tax Included does not indicate tax is included.</td><td valign="top">When Local Tax Amount is provided, set Local Tax Included to <code>1</code>.</td></tr><tr><td valign="top"><code>CS-0006</code></td><td valign="top">Field dependency</td><td valign="top">No local tax amount was sent, but Local Tax Included does not indicate tax is not included.</td><td valign="top">When Local Tax Amount is absent, set Local Tax Included to <code>2</code>.</td></tr><tr><td valign="top"><code>CS-0007</code></td><td valign="top">Must be zero</td><td valign="top">National Tax Amount is nonzero.</td><td valign="top">Set National Tax Amount to <code>0</code>.</td></tr><tr><td valign="top"><code>CS-0008</code></td><td valign="top">Must be zero</td><td valign="top">National Tax Included is nonzero.</td><td valign="top">Set National Tax Included to <code>0</code>.</td></tr><tr><td valign="top"><code>CS-0009</code></td><td valign="top">Missing field</td><td valign="top">Message ID is empty.</td><td valign="top">Populate Message ID.</td></tr><tr><td valign="top"><code>CS-0010</code></td><td valign="top">Format</td><td valign="top">Purchase time is not a valid 24-hour <code>HHMM</code> value.</td><td valign="top">Send a valid hour and minute in <code>HHMM</code> format.</td></tr><tr><td valign="top"><code>CS-0011</code></td><td valign="top">Amount reconciliation</td><td valign="top">Source Amount does not reconcile to line totals, taxes, invoice shipping, and invoice discount.</td><td valign="top">Recalculate all components. Confirm signs, rounding, and included lines.</td></tr><tr><td valign="top"><code>CS-0012</code></td><td valign="top">Amount reconciliation</td><td valign="top">Local Tax Amount does not equal the total submitted tax amounts.</td><td valign="top">Align the header tax amount with all tax details.</td></tr><tr><td valign="top"><code>CS-0089</code></td><td valign="top">Data quality pattern</td><td valign="top">Repeated single-item transactions prevent Visa from creating a unique digital receipt or invoice.</td><td valign="top">Send complete, transaction-specific line-item detail instead of repeated generic single items.</td></tr></tbody></table>

#### TC50-0000 series: invoice structure and header checks

Use this table to resolve invoice structure and PURCHA header errors.

<table><thead><tr><th valign="top">Code</th><th valign="top">Type</th><th valign="top">What Visa is flagging</th><th valign="top">First thing to check</th></tr></thead><tbody><tr><td valign="top"><code>TC50-0001</code></td><td valign="top">Missing record</td><td valign="top">The invoice header or summary record (<code>PURCHA</code>) is missing.</td><td valign="top">Include TC50 <code>PURCHA</code>.</td></tr><tr><td valign="top"><code>TC50-0002</code></td><td valign="top">Missing record</td><td valign="top">The invoice line-detail record (<code>PURCHL</code>) is missing.</td><td valign="top">Include TC50 <code>PURCHL</code> line items.</td></tr><tr><td valign="top"><code>TC50-0003</code></td><td valign="top">Record structure</td><td valign="top">More than one TC50 type was found where the structure does not allow it.</td><td valign="top">Review record construction. Remove the unintended TC50 type.</td></tr><tr><td valign="top"><code>TC50-0004</code></td><td valign="top">Duplicate record</td><td valign="top">A duplicate <code>PURCHA</code> header was found.</td><td valign="top">Send one intended <code>PURCHA</code> header.</td></tr><tr><td valign="top"><code>TC50-0005</code></td><td valign="top">Duplicate record</td><td valign="top">Duplicate <code>PURCHL</code> detail was found.</td><td valign="top">Remove unintended duplicate line-detail records.</td></tr><tr><td valign="top"><code>TC50-0006</code></td><td valign="top">Format</td><td valign="top">Destination postal or ZIP code does not match the destination country format.</td><td valign="top">Validate the postal code against the country code.</td></tr><tr><td valign="top"><code>TC50-0007</code></td><td valign="top">Code mapping</td><td valign="top">Destination Country Code is not a valid ISO country code.</td><td valign="top">Use a valid ISO country code.</td></tr><tr><td valign="top"><code>TC50-0009</code></td><td valign="top">Format</td><td valign="top"><code>PURCHA</code> Order Date is not a valid <code>YYMMDD</code> date.</td><td valign="top">Send a real calendar date in <code>YYMMDD</code> format.</td></tr><tr><td valign="top"><code>TC50-0010</code></td><td valign="top">Field dependency</td><td valign="top">Freight tax amount is nonzero although freight amount is <code>0</code>.</td><td valign="top">Set freight tax amount to <code>0</code> when freight amount is <code>0</code>.</td></tr><tr><td valign="top"><code>TC50-0011</code></td><td valign="top">Amount calculation</td><td valign="top">Freight tax amount does not equal freight amount multiplied by freight tax rate.</td><td valign="top">Recalculate freight tax. Review signs and rounding.</td></tr><tr><td valign="top"><code>TC50-0012</code></td><td valign="top">Field dependency</td><td valign="top">Freight tax rate is nonzero although freight amount is <code>0</code>.</td><td valign="top">Set freight tax rate to <code>0</code> when freight amount is <code>0</code>.</td></tr><tr><td valign="top"><code>TC50-0013</code></td><td valign="top">Cross-record mismatch</td><td valign="top"><code>PURCHA</code> Authorization Code is populated but differs from the TC05 Authorization Code.</td><td valign="top">Make the authorization codes match. Leave <code>PURCHA</code> blank when appropriate.</td></tr><tr><td valign="top"><code>TC50-0014</code></td><td valign="top">Allowed value</td><td valign="top">Invoice-level Discount Treatment Code is invalid.</td><td valign="top">Use <code>0</code>, <code>1</code>, or <code>2</code>.</td></tr><tr><td valign="top"><code>TC50-0015</code></td><td valign="top">Allowed value</td><td valign="top">Tax Treatment contains an unsupported value.</td><td valign="top">Use <code>0</code>, <code>1</code>, <code>2</code>, <code>3</code>, or <code>4</code>.</td></tr><tr><td valign="top"><code>TC50-0016</code></td><td valign="top">Allowed value</td><td valign="top">Discount Amount signage contains an unsupported value.</td><td valign="top">Use blank, <code>C</code>, or <code>D</code>.</td></tr><tr><td valign="top"><code>TC50-0017</code></td><td valign="top">Allowed value</td><td valign="top">Freight or Shipping Amount signage contains an unsupported value.</td><td valign="top">Use blank, <code>C</code>, or <code>D</code>.</td></tr><tr><td valign="top"><code>TC50-0018</code></td><td valign="top">Allowed value</td><td valign="top">Duty Amount signage contains an unsupported value.</td><td valign="top">Use blank, <code>C</code>, or <code>D</code>.</td></tr><tr><td valign="top"><code>TC50-0019</code></td><td valign="top">Allowed value</td><td valign="top">VAT or Tax Amount signage contains an unsupported value.</td><td valign="top">Use blank, <code>C</code>, or <code>D</code>.</td></tr></tbody></table>

#### TC50-1000 series: line-item structure and calculations

Use this table to resolve PURCHL line-item structure, calculation, and sequence errors.

<table><thead><tr><th valign="top">Code</th><th valign="top">Type</th><th valign="top">What Visa is flagging</th><th valign="top">First thing to check</th></tr></thead><tbody><tr><td valign="top"><code>TC50-1001</code></td><td valign="top">Missing field</td><td valign="top">Item Description is blank, null, or all zeros.</td><td valign="top">Provide a meaningful item description.</td></tr><tr><td valign="top"><code>TC50-1002</code></td><td valign="top">Missing field</td><td valign="top">Product Code is blank, null, or all zeros.</td><td valign="top">Provide a valid product code.</td></tr><tr><td valign="top"><code>TC50-1003</code></td><td valign="top">Missing field</td><td valign="top">Unit of Measure is blank, null, or all zeros.</td><td valign="top">Provide the applicable unit of measure.</td></tr><tr><td valign="top"><code>TC50-1004</code></td><td valign="top">Amount calculation</td><td valign="top">Line total does not equal unit cost × quantity minus line discount.</td><td valign="top">Recalculate each line total. Review signs and rounding.</td></tr><tr><td valign="top"><code>TC50-1005</code></td><td valign="top">Allowed value</td><td valign="top">Line-item Detail Indicator is invalid.</td><td valign="top">Use <code>0</code>, <code>1</code>, <code>2</code>, <code>3</code>, <code>4</code>, or <code>5</code>.</td></tr><tr><td valign="top"><code>TC50-1006</code></td><td valign="top">Record ending</td><td valign="top">Detail indicators do not follow Visa’s even or odd rule.</td><td valign="top">Use an even indicator for each nonfinal line. Use an odd indicator for the final line.</td></tr><tr><td valign="top"><code>TC50-1007</code></td><td valign="top">Allowed value</td><td valign="top">Line-item Discount Treatment Code is invalid.</td><td valign="top">Use <code>0</code>, <code>1</code>, or <code>2</code>.</td></tr><tr><td valign="top"><code>TC50-1011</code></td><td valign="top">Sequence</td><td valign="top">The line-item sequence does not progress correctly from the first line.</td><td valign="top">Renumber line items sequentially from the starting value.</td></tr></tbody></table>

#### TC50-2000 series: description quality

Use this table to improve PURCHL descriptions that do not identify purchased goods or services.

<table><thead><tr><th valign="top">Code</th><th valign="top">Type</th><th valign="top">What Visa is flagging</th><th valign="top">First thing to check</th></tr></thead><tbody><tr><td valign="top"><code>TC50-2001</code></td><td valign="top">Description quality</td><td valign="top">Line-item description is blank or effectively blank.</td><td valign="top">Provide a meaningful description of the purchase.</td></tr><tr><td valign="top"><code>TC50-2002</code></td><td valign="top">Description quality</td><td valign="top">Line-item description is the same as, or nearly the same as, the merchant name.</td><td valign="top">Describe the actual product or service.</td></tr><tr><td valign="top"><code>TC50-2003</code></td><td valign="top">Description quality</td><td valign="top">Line-item product code repeats the cardholder product ID.</td><td valign="top">Provide the item's product code.</td></tr><tr><td valign="top"><code>TC50-2004</code></td><td valign="top">Description quality</td><td valign="top">Line-item description is too generic to identify the purchase.</td><td valign="top">Use a specific product or service description.</td></tr><tr><td valign="top"><code>TC50-2005</code></td><td valign="top">Description quality</td><td valign="top">Line-item description contains only one character.</td><td valign="top">Provide a meaningful, multicharacter description.</td></tr><tr><td valign="top"><code>TC50-2006</code></td><td valign="top">Description quality</td><td valign="top">The entire line-item description is contained within the merchant name.</td><td valign="top">Describe the item or service independently.</td></tr><tr><td valign="top"><code>TC50-2007</code></td><td valign="top">Description quality</td><td valign="top">Descriptions are mostly generic, numeric, merchant-specific, or otherwise not descriptive.</td><td valign="top">Use clear, transaction-specific descriptions.</td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.xplorpay.com/api-reference/resources/visas-commercial-enhanced-data-program/level-3-error-code.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
