# Hedera Topic API
> Read the Hedera Consensus Service (HCS) live from the public Hedera mirror node — no key. HCS is Hedera's signature feature: a decentralized, ordered, timestamped message log that powers audit trails, supply-chain tracking, oracles and tokenization registries — the layer that account- and token-readers miss entirely. Look up any topic for its memo, admin/submit-key control, auto-renew and deleted state; read a topic's most recent messages, decoded from base64 to text, each with its consensus sequence number, timestamp and the account that paid to submit it; or discover the topics that are actively receiving messages right now. The consensus-messaging layer for Hedera wallets, explorers, dApps and auditors. Live from the mirror node; short cache only.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/hederatopic-api/..."
```

## Pricing
- **Free** (Free) — 6,700 calls/Mo, 3 req/s
- **Starter** ($9/Mo) — 125,500 calls/Mo, 8 req/s
- **Pro** ($32/Mo) — 747,000 calls/Mo, 20 req/s
- **Business** ($91/Mo) — 4,705,000 calls/Mo, 50 req/s

## Endpoints

### HCS

#### `GET /v1/messages` — A topic's recent decoded messages

**Parameters:**
- `id` (query, optional, string) — Hedera topic id (0.0.x); omit for the demo topic Example: `0.0.368908`
- `limit` (query, optional, string) — Max messages (1-50) Example: `10`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hederatopic-api/v1/messages?id=0.0.368908&limit=10"
```

**Response:**
```json
{
    "data": {
        "note": "Most recent HCS messages on the topic (newest first), decoded from base64 to text where printable. Each has its consensus sequence number, timestamp and the account that paid to submit it.",
        "count": 10,
        "source": "Hedera mirror node",
        "messages": [
            {
                "message": "1781424220160 UkyatXFBPDSPqOXVgMZUzlRpgBpyfwfrxExgqRlcqHEGDTZMIxHDhzUWpiqTJvGnnnsVYqzNHrRkugjlSiYGqVUTdCQxtQgadumWVPwNyPUJbEVbUYfMmlfIvJJoEUFqTFGLuRdYTEWomhBLBNxlXlGZQEubRXzUuxDieZlkMAAHDQtmirLvRZirBKQXurcxjVgfPTBIUXEEenVSwyAZvmfEwdAJyViLSJNpYeZWFOUeEDKttI",
                "encoding": "utf8",
                "chunk_info": null,
                "size_bytes": 256,
                "hex_preview": null,
                "sequence_number": 22614984,
                "payer_account_id": "0.0.256009",
                "consensus_timestamp": "1781424220.839574000"
            },
            {
                "message": "1781424217624 UfDmswGqAxosZumgmiANUygUArmHtNiclHPeFCCZSrIoZDkiRpHiGCQYBcLdAtjojKyHzSjbngPIRyWVzZegEMxtZCeLgabFktxDcLAtqqCXOcBmpnZuIZZaBtGIafpFfGbCKZAENEdihJQwReixHsJUMSItzKnmZuajnYJMkDYZdmZLNdkieqFHdeBvPzIOWzZRmnyEMmOcDmiOeCduQoKDZMnPcHnbemqojsxWpdjEGyxnDc",
                "encoding": "utf8",
                "chunk_info": null,
                "size_bytes": 256,
                "hex_preview": null,
                "sequence_number": 22614983,
                "payer_account_id": "0.0.256009",
                "consensus_timestamp
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/recent` — Topics actively receiving messages right now

**Parameters:**
- `limit` (query, optional, string) — How many recent consensus submits to scan (1-50) Example: `15`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hederatopic-api/v1/recent?limit=15"
```

**Response:**
```json
{
    "data": {
        "note": "Topics that are actively receiving HCS messages right now, derived from the latest consensus-submit transactions. Use these ids with /v1/topic and /v1/messages.",
        "count": 6,
        "source": "Hedera mirror node",
        "topics": [
            {
                "topic_id": "0.0.368908",
                "last_payer": null,
                "submit_count_in_window": 8,
                "last_consensus_timestamp": "1781424220.839574000"
            },
            {
                "topic_id": "0.0.10528714",
                "last_payer": null,
                "submit_count_in_window": 3,
                "last_consensus_timestamp": "1781424193.401842358"
            },
            {
                "topic_id": "0.0.10387802",
                "last_payer": null,
                "submit_count_in_window": 1,
                "last_consensus_timestamp": "1781424222.460302000"
            },
            {
                "topic_id": "0.0.10387219",
                "last_payer": null,
                "submit_count_in_window": 1,
                "last_consensus_timestamp": "1781424212.604674281"
            },
            {
                "topic_id": "0.0.10584419",
                "last_payer": null,
                "submit_count_in_window": 1,
                "last_consensus_timestamp": "1781424194.839376000"
            },
            {
                "topic_id": "0.0.10490174",
                "last_payer": null,
                "submit_cou
…(truncated, see openapi.json for full schema)
```

#### `GET /v1/topic` — HCS topic metadata (omit id for the demo topic)

**Parameters:**
- `id` (query, optional, string) — Hedera topic id (0.0.x); omit for the demo topic Example: `0.0.368908`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hederatopic-api/v1/topic?id=0.0.368908"
```

**Response:**
```json
{
    "data": {
        "memo": "1629150079641 Mirror node created test topic",
        "note": "Hedera Consensus Service topic metadata. has_submit_key true means message submission is permissioned; admin key controls topic updates.",
        "source": "Hedera mirror node",
        "deleted": false,
        "topic_id": "0.0.368908",
        "has_admin_key": true,
        "has_submit_key": true,
        "auto_renew_period": 7776000,
        "created_timestamp": "1629150092.728366000",
        "auto_renew_account": null
    },
    "meta": {
        "timestamp": "2026-06-14T08:03:49.968Z",
        "request_id": "fa382e9b-4a1b-4b8e-859c-8febe872ed04"
    },
    "status": "ok",
    "message": "Topic retrieved successfully",
    "success": true
}
```

### Meta

#### `GET /v1/meta` — Service metadata & live sample

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hederatopic-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "sample": {
            "memo": "1629150079641 Mirror node created test topic",
            "topic": "0.0.368908"
        },
        "source": "public Hedera mirror node (mainnet-public.mirrornode.hedera.com), keyless",
        "service": "hederatopic-api",
        "endpoints": {
            "GET /v1/meta": "This document.",
            "GET /v1/topic": "HCS topic metadata (id=0.0.368908; omit for the demo topic).",
            "GET /v1/recent": "Topics actively receiving messages right now (limit).",
            "GET /v1/messages": "A topic's recent decoded messages (id, limit)."
        },
        "description": "Read the Hedera Consensus Service (HCS) live from the public mirror node: look up any topic's metadata (memo, admin/submit key, deleted state), read a topic's recent decoded messages with sequence/timestamp/payer, or discover topics actively receiving messages. The consensus-messaging layer for Hedera wallets, explorers and auditors. Live, short cache only.",
        "upstream_status": "ok"
    },
    "meta": {
        "timestamp": "2026-06-14T08:03:50.073Z",
        "request_id": "175387b4-fb9e-4857-ba06-304f60a1e3dd"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/hederatopic-api
OpenAPI spec: https://www.oanor.com/api/hederatopic-api/openapi.json
