# Bank Transaction

Use this type to set up a reusable *Bank Transaction* variable.

## Properties

| Type                      | See [Bank Transaction Types](https://developer.xero.com/documentation/api/types#BankTransactionTypes)                                                                                                                                                                                                                               |
| ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Contact                   | See [Contacts](https://developer.xero.com/documentation/api/contacts)                                                                                                                                                                                                                                                               |
| Lineitems                 | See [LineItems](https://developer.xero.com/documentation/api/banktransactions#LineItems). The LineItems element can contain any number of individual LineItem sub-elements.                                                                                                                                                         |
| BankAccount               | Bank account for transaction. See [BankAccount](https://developer.xero.com/documentation/api/banktransactions#BankAccount)                                                                                                                                                                                                          |
| IsReconciled              | Boolean to show if transaction is reconciled                                                                                                                                                                                                                                                                                        |
| Date                      | Date of transaction - YYYY-MM-DD                                                                                                                                                                                                                                                                                                    |
| Reference                 | Reference for the transaction. Only supported for SPEND and RECEIVE transactions.                                                                                                                                                                                                                                                   |
| CurrencyCode              | The currency that bank transaction has been raised in (see [Currencies](https://developer.xero.com/documentation/api/currencies)). Setting currency is only supported on overpayments.                                                                                                                                              |
| CurrencyRate              | Exchange rate to base currency when money is spent or received. e.g. 0.7500 Only used for bank transactions in non base currency. Setting currency is only supported on overpayments.                                                                                                                                               |
| Url                       | URL link to a source document - shown as "Go to App Name"                                                                                                                                                                                                                                                                           |
| Status                    | See [Bank Transaction Status Codes](https://developer.xero.com/documentation/api/types#BankTransactionStatuses)                                                                                                                                                                                                                     |
| LineAmountTypes           | See [Line Amount Types](https://developer.xero.com/documentation/api/types#LineAmountTypes)                                                                                                                                                                                                                                         |
| SubTotal                  | Total of bank transaction excluding taxes                                                                                                                                                                                                                                                                                           |
| TotalTax                  | Total tax on bank transaction                                                                                                                                                                                                                                                                                                       |
| Total                     | Total of bank transaction tax inclusive                                                                                                                                                                                                                                                                                             |
| BankTransactionID         | Xero generated unique identifier for bank transaction                                                                                                                                                                                                                                                                               |
| PrepaymentID              | Xero generated unique identifier for a [Prepayment](https://developer.xero.com/documentation/api/prepayments/). This will be returned on BankTransactions with a Type of SPEND-PREPAYMENT or RECEIVE-PREPAYMENT                                                                                                                     |
| OverpaymentID             | Xero generated unique identifier for an [Overpayment](https://developer.xero.com/documentation/api/overpayments/). This will be returned on BankTransactions with a Type of SPEND-OVERPAYMENT or RECEIVE-OVERPAYMENT                                                                                                                |
| UpdatedDateUTC            | Last modified date UTC format                                                                                                                                                                                                                                                                                                       |
| HasAttachments            | Boolean to indicate if a bank transaction has an attachment                                                                                                                                                                                                                                                                         |
| Elements for Line Items   |                                                                                                                                                                                                                                                                                                                                     |
| Description               | The description of the line item                                                                                                                                                                                                                                                                                                    |
| Quantity                  | LineItem Quantity                                                                                                                                                                                                                                                                                                                   |
| UnitAmount                | Lineitem unit amount. By default, unit amount will be rounded to two decimal places. You can opt in to use four decimal places by adding the querystring parameter unitdp=4 to your query. See the [Rounding in Xero](https://developer.xero.com/documentation/api-guides/rounding-in-xero/#unitamount) guide for more information. |
| AccountCode               | See [Accounts](https://developer.xero.com/documentation/api/accounts)                                                                                                                                                                                                                                                               |
| ItemCode                  | ItemCode can only be present when the Bank Transaction Type is SPEND or RECEIVE.                                                                                                                                                                                                                                                    |
| LineItemID                | The Xero generated identifier for a LineItem.                                                                                                                                                                                                                                                                                       |
| TaxType                   | Used as an override if the default Tax Code for the selected AccountCode is not correct - see [TaxTypes](https://developer.xero.com/documentation/api/types#TaxTypes).                                                                                                                                                              |
| LineAmount                | The total of the line including discount                                                                                                                                                                                                                                                                                            |
| Tracking                  | Optional Tracking Category - see [Tracking](https://developer.xero.com/documentation/api/tracking-categories). Any LineItem can have a maximum of 2 TrackingCategory elements.                                                                                                                                                      |
| Elements for Bank Account |                                                                                                                                                                                                                                                                                                                                     |
| Code                      | BankAccount code (this value may not always be present for a bank account)                                                                                                                                                                                                                                                          |
| AccountID                 | BankAccount identifier                                                                                                                                                                                                                                                                                                              |

## Links

[Xero Developer: Bank Transaction](https://developer.xero.com/documentation/api/banktransactions)


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.linx.software/reference/plugins/xero/content/banktransactions/bank-transaction.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
