# Audit trail and actions

Source: https://developer.avalara.com/transaction-reconciliation/xdu6381588622829/

# Audit trail and actions

This section describes adjustment reason codes, audit log structure, and error handling behavior used during reconciliation workflows.

## Adjustment reason codes

When adjusting transactions, use the appropriate `adjustmentReason` enum value.

Reason Code

When to Use

`SourcingIssue`

Address/location correction

`ReconciledWithGeneralLedger`

GL reconciliation adjustment

`ExemptCertApplied`

Exemption applied after the fact

`PriceAdjusted`

Amount correction

`ProductReturned`

Return processing

`Other`

Other (specify in description)

## Audit log entry format

Each AI-initiated action creates an audit entry with the following structure:

Field

Description

**`action`**

"`AdjustTransaction`" | "`CreateTransaction`" | "`VoidTransaction`"

**`transactionCode`**

Document code

`**companyCode**`

Company identifier

`**timestamp**`

ISO 8601 format

`**initiatedBy**`

"AI Reconciliation Assistant"

**`approvedBy`**

User email who approved

`**reason**`

Human-readable explanation

`**previousValues**`

Before state (for adjustments)

`**newValues**`

After state

## Error handling

The following table describes common error codes and how the AI responds.

Error Code

Meaning

AI Response

1100

`CannotModifyLockedTransaction`

Alert user that the transaction is locked for filing; suggest amended return

1715/1716

Rate Limit Exceeded

Implement exponential backoff; queue requests

309

`InvalidAddress`

Present address correction options

303

`DocumentCodeConflict`

Transaction already exists; offer to adjust instead