> For the complete documentation index, see [llms.txt](https://docs.artinals.com/artinals-protocol/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.artinals.com/artinals-protocol/market-module/data-structures/ledger-registry-ledgerregistry.md).

# Ledger Registry (LedgerRegistry)

A **mapping system** that tracks all trade ledgers.

Structure Definition

```
public struct LedgerRegistry has key {
    id: UID,                            // Unique identifier for the registry
    ledgers: Table<LedgerKey, ID>       // Mapping from (collection_id, currency_type) → TradeLedger ID
}

```

#### **Ledger Key**

A composite key struct that helps in uniquely identifying **trade ledgers**.

```
public struct LedgerKey has store, copy, drop {
    collection_id: ID,                  // NFT collection ID
    currency_type: TypeName             // Currency used for trading
}

```

#### **Purpose**

* Ensures each **NFT collection has a unique ledger** for its trading activity.
* Provides **quick lookups** for existing ledgers.
