> ## Documentation Index
> Fetch the complete documentation index at: https://docs.uselim.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Journal Entries

> Create, list, filter, reverse, and manage journal entries.

# Journal Entries

Journal entries are the core of the ledger. Every financial event produces a double-entry record where total debits always equal total credits.

## List Entries

```bash theme={null}
lim journals list
```

### Filtering

```bash theme={null}
# By date range
lim journals list --from 2026-03-01 --to 2026-03-31

# By status
lim journals list --status draft

# By account
lim journals list --account 7100

# By memo text
lim journals list --search AWS

# Combine filters
lim journals list --from 2026-03-01 --status posted --account 4100
```

## Create an Entry Manually

For full control, specify debit and credit lines explicitly:

```bash theme={null}
lim journals create \
  --date 2026-03-15 \
  --memo "Equipment purchase" \
  --debit 1900:330000 \
  --debit 1410:30000 \
  --credit 1200:360000
```

<Warning>
  Total debits must equal total credits. The command will fail if they don't balance.
</Warning>

## Entry Status

| Status     | Description                                                           |
| ---------- | --------------------------------------------------------------------- |
| `draft`    | Created but not finalized. Can be edited or deleted.                  |
| `posted`   | Finalized. Included in all reports. Must be reversed, not deleted.    |
| `reversed` | Cancelled via a reversing entry. The original is preserved for audit. |

## Edit a Draft Entry

Fix mistakes in draft entries — date, memo, or journal lines.

```bash theme={null}
# Fix the date and memo
lim journals edit 42 --date 2026-03-20 --memo "Corrected memo"

# Replace the journal lines entirely
lim journals edit 42 \
  --debit 7101:120000 \
  --credit 1101:120000
```

<Warning>
  Only draft entries can be edited. Posted entries are immutable — reverse them and create a new entry instead.
</Warning>

## Reverse an Entry

Create an equal-and-opposite entry to cancel posted journals. Shows a preview and asks for confirmation.

```bash theme={null}
# Reverse a single entry
lim journals reverse --id 5

# Reverse multiple entries
lim journals reverse --id 1 --id 2 --id 3

# Reverse by filter
lim journals reverse --from 2026-03-01 --to 2026-03-31

# Preview only
lim journals reverse --id 5 --dry-run

# Skip confirmation (for scripting / AI agents)
lim journals reverse --id 5 --yes
```

<Tip>
  Reversals create a new entry linked to the original. The original entry is never deleted — this
  preserves the full audit trail.
</Tip>

<Warning>
  You must specify entry IDs or filter flags. `lim journals reverse` with no arguments will show an error.
</Warning>

## Delete Draft Entries

Remove draft entries that are no longer needed. Only `draft` entries can be deleted.

```bash theme={null}
# Delete specific entries
lim journals delete --id 10 --id 11

# Preview what would be deleted
lim journals delete --id 10 --id 11 --dry-run

# Skip confirmation
lim journals delete --id 10 --yes
```

<Warning>Only draft entries can be deleted. Posted entries must be reversed instead.</Warning>

## Update Tax Code

Update the tax code for journal lines matching a filter:

```bash theme={null}
lim journals update-tax-code \
  --from 2026-03-01 --to 2026-03-31 \
  --oldTaxCodeId <uuid> \
  --newTaxCodeId <uuid>
```

## View Entry Details

```bash theme={null}
lim journals show 42
# or
lim journals show 5d0f1a6e-8fd6-4f7f-9b7c-5c2d5b1a9c55
```

## Next Steps

<CardGroup cols={2}>
  <Card title="Natural Language" icon="message" href="/guides/natural-language">
    Let lim create entries from plain text.
  </Card>

  <Card title="Financial Reports" icon="chart-line" href="/guides/financial-reports">
    See how entries roll up into reports.
  </Card>
</CardGroup>
