# Xero: General Ledger

## Description

* Each record represents a journal line item. This ledger is used to create the balance sheet and profit and loss.

## Supported Data Sources

* <img src="https://fivetran.com/integrations/xero/resources/xero.svg" alt="" data-size="line"> Xero

## Columns

| Type    | Name                  | Description                                                                                                                                                                                                                                                                                                     |
| ------- | --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| STRING  | journal\_id           | Xero identifier for the journal entry                                                                                                                                                                                                                                                                           |
| STRING  | created\_date\_utc    | The created date of the journal entry                                                                                                                                                                                                                                                                           |
| DATE    | journal\_date         | The date the journal was posted                                                                                                                                                                                                                                                                                 |
| INTEGER | journal\_number       | Xero generated journal number                                                                                                                                                                                                                                                                                   |
| STRING  | reference             | The associated reference to the journal, if present.                                                                                                                                                                                                                                                            |
| STRING  | source\_id            | The identifier for the source transaction. This can be used to join to other Xero tables.                                                                                                                                                                                                                       |
| STRING  | source\_type          | The journal source type. This can be used to know which table to join to for additional information.                                                                                                                                                                                                            |
| STRING  | source\_relation      | The source where this data was pulled from. If you are making use of the `union_schemas` variable, this will be the source schema. If you are making use of the `union_databases` variable, this will be the source database. If you are not unioining together multiple sources, this will be an empty string. |
| STRING  | journal\_line\_id     | Xero identifier for the journal line.                                                                                                                                                                                                                                                                           |
| INTEGER | account\_code         | Customer defined alpha numeric account code e.g 200 or SALES                                                                                                                                                                                                                                                    |
| STRING  | account\_id           | The Xero identifier for the related account.                                                                                                                                                                                                                                                                    |
| STRING  | account\_name         | The name of the related account.                                                                                                                                                                                                                                                                                |
| STRING  | account\_type         | The type of the related account.                                                                                                                                                                                                                                                                                |
| INTEGER | description           | The description from the source transaction line item.                                                                                                                                                                                                                                                          |
| DECIMAL | gross\_amount         | Gross amount of journal line (NetAmount + TaxAmount).                                                                                                                                                                                                                                                           |
| DECIMAL | net\_amount           | Net amount of journal line. This will be a positive value for a debit and negative for a credit                                                                                                                                                                                                                 |
| DECIMAL | tax\_amount           | Total tax on a journal line                                                                                                                                                                                                                                                                                     |
| STRING  | tax\_name             | The name of the tax rate.                                                                                                                                                                                                                                                                                       |
| STRING  | tax\_type             | The type of the tax rate.                                                                                                                                                                                                                                                                                       |
| STRING  | account\_class        | The class of account, e.g. ASSET, EQUITY, EXPENSE, LIABILITY, REVENUE                                                                                                                                                                                                                                           |
| STRING  | invoice\_id           | Source ID where it can be joined to the invoice table.                                                                                                                                                                                                                                                          |
| STRING  | bank\_transaction\_id | Source ID where it can be joined to the bank transaction table.                                                                                                                                                                                                                                                 |
| STRING  | bank\_transfer\_id    | Source ID where it can be joined to the bank transfer table.                                                                                                                                                                                                                                                    |
| STRING  | manual\_journal\_id   | Source ID where it can be joined to the manual journal table.                                                                                                                                                                                                                                                   |
| STRING  | payment\_id           | Source ID where it can be joined to the payment table.                                                                                                                                                                                                                                                          |
| STRING  | credit\_note\_id      | Source ID where it can be joined to the credit note table.                                                                                                                                                                                                                                                      |
| STRING  | contact\_id           | ID of the associated contact, where relevant.                                                                                                                                                                                                                                                                   |
| STRING  | contact\_name         | Name of the associated contact, where relevant.                                                                                                                                                                                                                                                                 |


---

# 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://endash-guidance-docs.gitbook.io/cigro-data-templates/data-model-templates/xero-general-ledger.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.
