<!-- source: https://secondlayer.tools/docs/api-reference#list-transactions -->

## Full transaction documents

`GET /v1/index/transactions`

Transactions in canonical blocks, oldest first, with fee, nonce, post-conditions and payload detail decoded from the raw bytes. Filters combine with AND. The cursor is `<block_height>:<tx_index>`. `reorgs` covers every height on the page.

### Filters

| Name | Type | Description |
| --- | --- | --- |
| `type` | string | Transaction type as stored, e.g. `contract_call`, `token_transfer`, `smart_contract`, `coinbase`, `tenure_change`. Exact match. |
| `sender` | string | Sender principal. Exact match. |
| `contract_id` | string | Called or deployed contract. One principal. Exact match. |

### Range and paging

| Name | Type | Description |
| --- | --- | --- |
| `limit` | integer · 1 to 1000 | Page size; capped at 1000. |
| `cursor` | string | `<block_height>:<tx_index>` from a previous page's `next_cursor`. Resumes after it. |
| `from_cursor` | string | Same as `cursor`. Mutually exclusive with it and with `from_height`. |
| `from_height` | integer | First block height to read. Mutually exclusive with a cursor. With neither, the read starts one day behind the tip. |
| `to_height` | integer | Last block height to read, inclusive. |
| `fields` | string | Comma-separated columns to return, from `block_time`, `burn_block_height`, `tx_index`, `tx_type`, `sender`, `status`, `fee`, `nonce`, `sponsored`, `anchor_mode`, `post_condition_mode`, `post_conditions`, `contract_call`, `smart_contract`, `token_transfer`. `cursor`, `block_height` and `tx_id` always come back; an unknown name is refused. |

### Returns

A cursor envelope; `transactions` holds `Transaction` objects.

### Responses

- `200` Cursor-paginated envelope
- `400` A parameter, filter, cursor or body field was refused; `code` says which
- `401` This bind requires the instance token, and it was missing or wrong
- `429` Rate limited; retry after `Retry-After` seconds

### Example

```bash
curl https://api.secondlayer.tools/v1/index/transactions \
  -H "Authorization: Bearer $SECONDLAYER_API_KEY"
```

```json
{
  "transactions": [
    {
      "cursor": "9048502:1",
      "tx_id": "0x198d642edb1104a1757a8c353ad61231d0422ecb6ba83aa1ce45d05df44157e0",
      "block_height": 9048502,
      "block_time": "2026-09-23T13:14:42.000Z",
      "burn_block_height": 968276,
      "tx_index": 1,
      "tx_type": "contract_call",
      "sender": "SP15T1W26JTNS26VG17HM468KW7TQD3124KTYA9EJ",
      "status": "success",
      "fee": "3000",
      "nonce": "265",
      "sponsored": false,
      "anchor_mode": "any",
      "post_condition_mode": "deny",
      "post_conditions": [
        {
          "type": "ft",
          "principal": "SP15T1W26JTNS26VG17HM468KW7TQD3124KTYA9EJ",
          "asset_identifier": "SM3VDXK3WZZSA84XXFKAFAF15NNZX32CTSG82JFQ4.sbtc-token::sbtc-token",
          "condition_code": 1,
          "condition_code_name": "sent_eq",
          "amount": "300"
        }
      ],
      "contract_call": {
        "contract_id": "SM3VDXK3WZZSA84XXFKAFAF15NNZX32CTSG82JFQ4.sbtc-token",
        "function_name": "transfer",
        "function_args": [
          "300",
          "SP15T1W26JTNS26VG17HM468KW7TQD3124KTYA9EJ",
          "SPD3SCZDZ52X4ZX1878XWBFBJ29YRX0MFW9Z9W4V",
          null
        ],
        "function_args_hex": [
          "010000000000000000000000000000012c",
          "05164ba0f04696ab911b7009e3421913e1f5768c2224",
          "05161a3cb3edf945d27fa141d1de2deb9093ec74147f",
          "09"
        ],
        "result": true,
        "result_hex": "0x0703"
      }
    }
  ],
  "next_cursor": "7960000:42",
  "tip": {
    "block_height": 9048690,
    "finalized_height": 9048457,
    "lag_seconds": 4,
    "source_block_height": 9048692
  },
  "reorgs": [
    {
      "id": "3f16c2c5-9551-4ae9-adb0-923668e5c65e",
      "detected_at": "2026-09-15T15:39:38.129Z",
      "fork_point_height": 8996511,
      "old_index_block_hash": "0x45ba0195071488eda13afa66d8ce8612558a739f781be5a032d96332797c4174",
      "new_index_block_hash": "0xa686ff58e7c5ccb26c850a7eaffa7e7274fcbc081c706344eb6f1e1446023df0",
      "orphaned_range": {
        "from": "8996511:0",
        "to": "8996512:2701"
      },
      "new_canonical_tip": "8996511:0"
    }
  ]
}
```
