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

# RPC Reference

> Read Xpectrum state directly from Octra

Everything on Xpectrum is on-chain and publicly readable. You do not need an API key, an SDK, or the Xpectrum frontend to query a collection, a listing, or a provenance hash. This page covers the view calls you will reach for most.

## Endpoints

| Network | RPC                         | Explorer               |
| ------- | --------------------------- | ---------------------- |
| Mainnet | `https://octra.network/rpc` | `https://octrascan.io` |

Xpectrum runs on Octra mainnet.

## Calling a view function

View functions are read through `octra_callProgramView` with the contract address, method name, and an argument array:

```bash theme={"system"}
curl -X POST https://octra.network/rpc \
  -H "Content-Type: application/json" \
  -d '{
    "method": "octra_callProgramView",
    "params": ["<contract_address>", "get_contract_info", []],
    "id": 1
  }'
```

Many Xpectrum views return pipe-delimited strings (for example `get_token_info` returns `id|owner|creator|name|royalty_bps|minted_epoch|uri`). Split on `|` to parse.

## Collection (Xcollection / XpectrumGenesis)

| Method                 | Args            | Returns                             |
| ---------------------- | --------------- | ----------------------------------- |
| `get_contract_info`    | none            | `name\|symbol\|total_supply\|owner` |
| `owner_of`             | `token_id`      | owner address                       |
| `get_token_info`       | `token_id`      | pipe-delimited token detail         |
| `token_uri`            | `token_id`      | metadata URI                        |
| `royalty_of`           | `token_id`      | royalty bps                         |
| `get_current_phase`    | none            | active mint phase                   |
| `get_phase_info`       | `phase`         | phase config                        |
| `get_provenance_hash`  | none            | 64-char hash, or `""` if unset      |
| `get_holders_page`     | `offset, limit` | page of current holders             |
| `get_pending_proceeds` | `addr`          | claimable balance                   |

## Marketplace (Xmarket)

| Method                        | Args                 | Returns                                       |
| ----------------------------- | -------------------- | --------------------------------------------- |
| `get_market_info`             | none                 | market-level stats                            |
| `get_token_listing`           | `contract, token_id` | active listing for one token                  |
| `get_listings_for_collection` | `contract`           | active listings in a collection               |
| `get_listings_page`           | `offset, limit`      | paginated active listings                     |
| `get_offer`                   | `offer_id`           | offer detail, including `offer_is_collection` |
| `get_total_volume`            | none                 | lifetime settled volume                       |

## Verifying a collection

Reading `get_provenance_hash()` and recomputing it from the collection's published metadata is enough to confirm a frozen collection was not altered after mint. The [xpress](/developers/xpress) CLI automates this end to end (`xpress verify <collection_address>`). See [Provenance](/standards/provenance) for the algorithm.

<Note>
  All contract state is public. A non-empty `get_provenance_hash()` plus a matching recomputation plus `mutability == "frozen_by_provenance"` is the full trust basis. You verify it yourself; you do not take our word for it.
</Note>
