# Blockscout — List output roots.

List Blockscout Optimism output roots via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Blockscout, pass parameters such as Set, and retrieve structured data including reported output-root value, L2 output index, associated L2 block number, associated L1 block number, and associated L1 transaction hash for output-root browsers, and cross-layer navigation.

Documentation: https://openany.si/blockscout/blockscout-list-output-roots/ac7de07c-bc0f-4a82-842d-c1b4425b6461/
API ID: ac7de07c-bc0f-4a82-842d-c1b4425b6461
Provider: blockscout
Contract revision: 4
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/blockscout/{chain_id}/api/v2/optimism/output-roots
Page update time: 2026-12-03T02:49:21.318Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0 / call
The published contract currently has no usage charge. Authentication and service limits still apply.
Price source: OpenAny public API contract.
Contract update time: 2026-12-03T02:49:20.830Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "fixed",
  "priceMicroUsd": "0",
  "rounding": null,
  "unit": "call",
  "unitQuantity": null
}
```

## Usage and limits
## Blockscout Optimism Output Roots API

Provide chain\_id to optimism/output-roots. items contains output\_root, l2\_output\_index and layer-specific references. Continue with the exposed index and optional items\_count of at least 1.

## What You Can Build

- **Output-root browsers**: Display roots with their output indexes.
- **Cross-layer navigation**: Retain separate L1 and L2 references.

## Documented Response Fields

| Field | Meaning |
| --- | --- |
| `items[].output_root` | Reported output-root value |
| `items[].l2_output_index` | L2 output index |
| `items[].l2_block_number` | Associated L2 block number |
| `items[].l1_block_number` | Associated L1 block number |
| `items[].l1_transaction_hash` | Associated L1 transaction hash |

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Blockscout — List output roots. request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {
        "chain_id": {
          "type": "string",
          "description": "The ID of the blockchain"
        }
      },
      "required": [
        "chain_id"
      ]
    },
    "query": {
      "type": "object",
      "properties": {
        "items_count": {
          "type": "integer",
          "description": "Number of items per page",
          "minimum": 1
        },
        "index": {
          "type": "integer",
          "description": "Item index for paging"
        }
      }
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "items": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "l1_block_number": {
            "type": "integer"
          },
          "l1_timestamp": {
            "type": "string"
          },
          "l1_transaction_hash": {
            "type": "string"
          },
          "l2_block_number": {
            "type": "integer"
          },
          "l2_output_index": {
            "type": "integer"
          },
          "output_root": {
            "type": "string"
          }
        }
      }
    },
    "next_page_params": {
      "type": "object",
      "properties": {
        "index": {
          "type": "integer"
        }
      }
    }
  }
}
```

## Request example
Scenario: Schema template · Schema template (not executed)
```bash
curl \
  'https://api.openany.si/v1/agent-apis/blockscout/%3Cchain_id%3E/api/v2/optimism/output-roots' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Response illustration only. Placeholder values and unknown business fields are not recorded API results. Replace request placeholders before use.
Response template · not a real response · Documented HTTP 200
```json
{
  "items": [
    {
      "l1_block_number": 0,
      "l1_timestamp": "<l1_timestamp>",
      "l1_transaction_hash": "<l1_transaction_hash>",
      "l2_block_number": 0,
      "l2_output_index": 0,
      "output_root": "<output_root>"
    }
  ],
  "next_page_params": {
    "index": 8829
  }
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Common questions
### Is output_root the same as an L2 block hash?
They identify different values. Preserve the output root and block references separately.

### Does this endpoint verify a state proof?
It retrieves output-root records. Independent proof verification is a separate operation.

### Can I use page as a continuation input?
This implementation exposes index and items_count, not page.

### Does a listed output root imply finality?
A root record does not by itself establish the finality of its associated state or transaction.

### Which API key should I use?
Use your OpenAny API key as Bearer authentication on the documented OpenAny route.

### Where can I check the current request price?
Check the pricing area for the selected implementation. Follow its billing unit and any request-dependent rules before sending the request.

## Available implementations
- blockscout: https://openany.si/blockscout/blockscout-list-output-roots/ac7de07c-bc0f-4a82-842d-c1b4425b6461/

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
