{"report":{"v":1,"package":"@secondlayer/mcp","version":"11.6.7","ranAt":"2026-11-16T11:37:39.235Z","install":{"ok":true,"bin":"mcp","integrity":"sha512-VwPuz5zTqdXdvtIeU1GTe9BP0M7KalMr7GOTa8NuKe7cy954igCInjS/8ooUnl7KVYb66jm6PoFhVfhpmHweZA==","deps":147,"scripts":["esbuild"],"bins":["mcp","secondlayer-mcp","mcp-http","secondlayer-mcp-http"],"license":"MIT","repository":"git+https://github.com/ryanwaits/secondlayer.git"},"start":{"ok":true,"ms":411,"serverName":"secondlayer","serverVersion":"11.6.7","protocol":"2025-06-18"},"tools":[{"name":"subgraphs_scaffold","description":"Generate a subgraph from observed print events when available; ABI token transfers or public functions only when the contract has never printed. Review the TypeScript, run subgraphs_test until ok: true with written >= 1, read skipped, then subgraphs_deploy. dryRun is DDL only.","params":["contractId","subgraphName"]},{"name":"subgraphs_list","description":"List all deployed subgraphs. Returns summary fields only; read rows with subgraphs_query.","params":[]},{"name":"subgraphs_status","description":"Get full details of a subgraph including schema, health (incl. health.emptyMapping when processed events wrote 0 rows), and table columns.","params":["name"]},{"name":"subgraphs_spec","description":"Fetch a subgraph's self-describing spec — the tables, columns, filters, and read URLs a consumer needs, without guessing. `agent` (default) returns the compact JSON schema built for tool use, `openapi` the OpenAPI document for the subgraph's read routes, `markdown` human-readable docs. Read it before writing queries against an unfamiliar subgraph.","params":["name","format"]},{"name":"subgraphs_query","description":"Query rows from a subgraph table (max 200 rows), reading the open /v1 surface — { rows, next_cursor, tip } envelope, cursor-paginated (no offset). Filters support operators: \"amount.gte\": \"1000\", \"sender.neq\": \"SP...\", \"name.like\": \"%token%\". Available operators: eq, neq, gt, gte, lt, lte, like. Every page with rows returns next_cursor (null only when empty): pass it back as `cursor` to read the next page. To TAIL new rows (no streaming over MCP), poll with cursor = next_cursor ?? the cursor you sent. Fetch one row by id with {\"_id\": \"<id>\"}. The same rows are readable over HTTP at GET /v1/subgraphs/<name>/<table>; hand that URL to third parties.","params":["name","table","filters","sort","order","limit","cursor","fields","count"]},{"name":"subgraphs_reindex","description":"Reindex a subgraph: drops and rebuilds the whole subgraph from its start block to chain tip. Takes no block range — use subgraphs_backfill to process a specific range. Returns an operationId — check subgraphs_status (health) or the REST operations endpoint to track progress to completion.","params":["name"]},{"name":"subgraphs_backfill","description":"Backfill a subgraph over a block range. Non-destructive forward fill (does not drop existing data) — unlike subgraphs_reindex, and the only data-fill path for BYO subgraphs (reindex is blocked there). Both blocks required. Returns an operationId — check subgraphs_status (health) or the REST operations endpoint to track progress.","params":["name","fromBlock","toBlock"]},{"name":"subgraphs_stop","description":"Cancel an in-flight reindex or backfill operation for a subgraph. Returns the stop request status; check subgraphs_status (health) or the REST operations endpoint to confirm it reaches a terminal state.","params":["name"]},{"name":"subgraphs_gaps","description":"List indexing gaps (missing block ranges) for a subgraph. Each gap reports start/end/size, reason, and detected/resolved timestamps. Feed an unresolved gap's range into subgraphs_backfill to fill it. Defaults to unresolved gaps.","params":["name","limit","offset","resolved"]},{"name":"subgraphs_operations","description":"Operation history for a subgraph (deploy/reindex/backfill/stop), newest first — status, block range, progress, and error. THIS IS THE VERIFY CALL: after subgraphs_deploy, subgraphs_reindex, subgraphs_backfill, or subgraphs_stop, poll it with the returned operationId until `status` is terminal (completed/failed/cancelled) before reporting success. Omit operationId for the recent history.","params":["name","operationId"]},{"name":"subgraphs_delete","description":"Delete a subgraph permanently.","params":["name"]},{"name":"subgraphs_deploy","description":"Deploy a subgraph from TypeScript code. Pass the full defineSubgraph() source — it will be bundled, validated, and deployed. Optional startBlock overrides the source definition for this deploy. dryRun validates schema/DDL only and does not run handlers — call subgraphs_test first and deploy only when it returns ok: true with written >= 1. Call subgraphs_reindex separately if you need a forced reindex.","params":["code","startBlock","dryRun"]},{"name":"subgraphs_test","description":"Prove a subgraph mapping writes rows against Index data before deploy. Pass full defineSubgraph() source plus a height range. Returns ok/written/tables; EMPTY_MAPPING means events matched but 0 rows were written — read hint for observed event.data keys and do not invent fields. subgraphs_deploy dryRun is DDL only; do not deploy until ok: true with written >= 1.","params":["code","fromHeight","toHeight","limit"]},{"name":"webhooks_list","description":"List all webhooks for the current account. Returns summary fields (no secrets).","params":[]},{"name":"webhooks_get","description":"Get full detail for a webhook (triggers, auth, retry config, circuit state).","params":["id"]},{"name":"webhooks_create","description":"Create a webhook that fires on raw chain events (set triggers). Returns `signingSecret` ONCE — forward it to the user so they can wire it into their receiver.","params":["name","triggers","url","format","authConfig"]},{"name":"webhooks_update","description":"Patch a webhook (name, url, authConfig, format, retry, timeout, concurrency).","params":["id","name","url","authConfig","format","maxRetries","timeoutMs","concurrency"]},{"name":"webhooks_delete","description":"Delete a webhook. Pending outbox rows are cascade-deleted.","params":["id"]},{"name":"webhooks_test","description":"Send a one-off test webhook to a webhook's URL (built for its format, SSRF-guarded). Logged as a delivery row. Returns {ok, statusCode, error, durationMs, deliveryId}.","params":["id"]},{"name":"webhooks_pause","description":"Pause a webhook: stops delivery attempts and stops queueing new ones. Nothing is deleted — resume picks the webhook back up from the tip. Verify with webhooks_get (status).","params":["id"]},{"name":"webhooks_resume","description":"Resume a paused webhook (also clears a tripped circuit breaker). Deliveries restart from the current tip — use webhooks_replay for the blocks missed while paused. Verify with webhooks_get (status).","params":["id"]},{"name":"webhooks_rotate_secret","description":"Rotate a webhook's signing secret. Returns the NEW `signingSecret` ONCE — forward it to the user; deliveries signed with the old secret stop verifying as soon as this returns, so the receiver must be updated.","params":["id"]},{"name":"webhooks_deliveries","description":"List recent delivery attempts for a webhook — status code, attempt count, error, duration, timestamps. THIS IS THE VERIFY CALL: after webhooks_create, webhooks_test, or webhooks_replay, read it to confirm the webhook actually landed (and to see the receiver's response when it didn't) instead of trusting the enqueue result.","params":["id"]},{"name":"webhooks_dead","description":"List a webhook's dead-letter queue — deliveries that exhausted their retries, with the outbox id, payload, and last error. Diagnose the receiver first (webhooks_get for the URL/auth, webhooks_test for a live probe), then requeue rows with webhooks_requeue.","params":["id"]},{"name":"webhooks_requeue","description":"Requeue ONE dead-lettered delivery for another attempt, by its outbox id from webhooks_dead. Fix the receiver first — a requeue against a still-broken endpoint just dies again. Verify with webhooks_deliveries.","params":["id","outboxId"]},{"name":"webhooks_replay","description":"Replay a block range for a webhook. Replays run at 10% of batch capacity — use sparingly. Pass `force` (a short idempotency suffix) to re-run a range that was already replayed.","params":["id","fromBlock","toBlock","force"]},{"name":"index_ft_transfers","description":"List decoded SIP-010 fungible-token transfers from Index. Reads are keyless.","params":["contractId","fromHeight","toHeight","cursor","limit","order","sender","recipient","assetIdentifier"]},{"name":"index_nft_transfers","description":"List decoded SIP-009 non-fungible-token transfers from Index. Reads are keyless.","params":["contractId","fromHeight","toHeight","cursor","limit","order","sender","recipient","assetIdentifier"]},{"name":"index_events","description":"List decoded chain events from the Index by event type. Use this for event types without a dedicated tool (stx_*, ft_mint/burn, nft_mint/burn, print), and for trait-scoped queries: set `trait` (e.g. sip-010) to match all contracts conforming to a standard — pair with contracts_find to discover traits. For ft/nft transfers without a trait prefer index_ft_transfers / index_nft_transfers.","params":["eventType","contractId","fromHeight","toHeight","cursor","limit","order","sender","recipient","assetIdentifier","trait","txContext"]},{"name":"index_contract_calls","description":"List decoded contract calls from the Index (function name, args, result). Set `trait` (e.g. sip-010) to match calls to all contracts conforming to a standard. Note: contract-call cursors are a SEPARATE keyspace from event cursors — they are not interchangeable.","params":["contractId","fromHeight","toHeight","cursor","limit","functionName","sender","trait"]},{"name":"index_blocks","description":"List decoded blocks from Index. Reads are keyless.","params":["fromHeight","toHeight","cursor","limit"]},{"name":"index_transactions","description":"List decoded transactions from Index. Filter by type, sender, or contract. Reads are keyless.","params":["contractId","fromHeight","toHeight","cursor","limit","type","sender"]},{"name":"index_print_schema","description":"Empirical per-topic print payload schemas for a contract, inferred from sampled on-chain events: each topic's fields with observed Clarity types, decoded TS types, subgraph column types, and presence rates. Use before writing print_event subgraph handlers to learn what's on e.data. Anonymous read.","params":["contractId"]},{"name":"index_discover","description":"Discover the Index vocabulary: every event type and its columns, allowed/equality filters, and required-non-null fields (and which types accept `trait`). Read this before building Index queries instead of guessing filters. Anonymous read.","params":[]},{"name":"batch_query","description":"Run up to 10 public /v1 reads in one round trip (POST /v1/batch). Each item keeps its own auth/quota/pay-per-call semantics; results return in order with per-item status. Paths must start with /v1/index, /v1/subgraphs, /v1/streams, or /v1/contracts.","params":["requests"]},{"name":"streams_tip","description":"Current canonical chain tip as Streams sees it: block height/hash, burn height, finalized_height, lag_seconds, and the oldest seekable height/cursor for this key's retention window. Call it before a cursor walk to know where the stream ends, and after an ingest to check lag.","params":[]},{"name":"streams_dumps","description":"List the Streams bulk parquet dumps manifest — coverage range, latest_finalized_cursor, and per-file metadata (block range, row count, size, sha256, signed URL). This is the cold backfill path for downloading all raw data; fetch the file URLs directly (e.g. with DuckDB). Requires the dumps base URL to be configured (SL_STREAMS_DUMPS_URL). For live reads use REST GET /v1/streams/events; for tip/lag use streams_tip.","params":[]},{"name":"contracts_find","description":"Discover deployed Stacks contracts conforming to a trait (e.g. \"sip-010\", \"sip-009\", \"sip-013\"). The discovery endpoint for \"which contracts implement X\". Reads are public.","params":["trait","conformance","include","limit","cursor"]},{"name":"contracts_get_abi","description":"Fetch a single deployed contract's ABI from the registry (prod-safe). Returns the contract's metadata + full ABI (functions, maps, variables, fungible/non-fungible tokens). Returns not_found if the contract isn't in the registry. Use it to inspect a contract before subgraphs_scaffold.","params":["contractId"]},{"name":"codegen_index_schema","description":"Generate an ORM schema for the Index tables (blocks, transactions, decoded_events, …) — the same output as `sl codegen index`. Returns the file contents as text; write it wherever your project keeps its schema. Use `tables` to emit only what you read.","params":["target","tables","schemaName","datasourceEnv"]},{"name":"instance_status","description":"Decoder health and empty-index diagnosis from GET /public/status. If state is empty-index, next tool is archive_bootstrap. Poll until index.decoders are ok before treating Index as ready — do not start decoders. Then archive_verify, then codegen_index_schema. Do not download parquet.","params":[]},{"name":"archive_verify","description":"Read-only, free compare of this instance against a signed archive (POST /v1/archive/verify). unanchored means pin a key or check the URL — not that the instance is fine. After bootstrap, poll instance_status until decoders ok, then this, then codegen_index_schema. Do not download parquet.","params":["against","fromBlock","toBlock","target"]},{"name":"archive_latest","description":"Signed pointer to the official archive tree (hosted). Needs SECONDLAYER_API_KEY (sk-sl_*), not INSTANCE_TOKEN. Use the returned origin as --against for archive_bootstrap. Do not download parquet.","params":["against"]},{"name":"archive_quote","description":"Price a hosted archive fetch (metered). Needs SECONDLAYER_API_KEY (sk-sl_*), not INSTANCE_TOKEN. Quote happens here; bootstrap/repair also quote inside the CLI. Do not download parquet.","params":["paths","flow"]},{"name":"credits_balance","description":"Archive credits balance at api.secondlayer.tools. Needs SECONDLAYER_API_KEY (sk-sl_*); INSTANCE_TOKEN is the instance.","params":[]},{"name":"archive_bootstrap","description":"Restore verified history into this instance (secondlayer bootstrap --against … --yes --json). Metered against the official archive; quote happens inside the CLI. After bootstrap, poll instance_status until decoders ok, then archive_verify, then codegen_index_schema. Do not download parquet.","params":["against","fromBlock","toBlock"]},{"name":"archive_repair","description":"Plan (default) or apply a repair of local chain data against a signed archive. Metered when apply fetches from the official archive. After apply, poll instance_status until decoders ok, then archive_verify. Do not download parquet.","params":["against","apply","fromBlock","toBlock"]}],"toolsHash":"c726fd389aab8fd7ab67a830218ca9effe0fbb2d85f109e2422556a947e6e24d","wrote":[],"callsAt":"2026-11-16T11:38:10.560Z","calls":[{"tool":"subgraphs_list","ok":false,"ms":23,"bytes":0,"error":"tool reported an error: {\"error\":{\"type\":\"error\",\"status\":0,\"message\":\"Cannot reach API at http://127.0.0.1:3800. Check your connection or try again.\"}}"},{"tool":"webhooks_list","ok":false,"ms":2,"bytes":0,"error":"tool reported an error: {\"error\":{\"type\":\"error\",\"status\":0,\"message\":\"Cannot reach API at http://127.0.0.1:3800. Check your connection or try again.\"}}"},{"tool":"instance_status","ok":false,"ms":1,"bytes":0,"error":"tool reported an error: {\"error\":{\"type\":\"error\",\"status\":0,\"message\":\"Cannot reach API at http://127.0.0.1:3800. Check your connection or try again.\"}}"}],"host":{"commit":"eaaffffaf52255d1b77dc4aacffdfaf353f0c12c","run":"https://github.com/itsHaddad/bragproof/actions/runs/43857070216"},"network":{"names":["registry.npmjs.org"],"conns":[],"callNames":[],"callConns":[]}},"summary":{"outcome":"started","needs":[],"contacts":[],"flags":[],"tools":47,"wrote":0,"callsTried":3,"callsAnswered":0,"callContacts":[]},"history":[{"package":"@secondlayer/mcp","version":"11.6.7","ranAt":"2026-11-16T11:37:39.235Z","outcome":"started","tools":47,"contacts":0,"flags":0,"serious":0,"toolsHash":"c726fd389aab8fd7ab67a830218ca9effe0fbb2d85f109e2422556a947e6e24d"},{"package":"@secondlayer/mcp","version":"11.6.6","ranAt":"2026-11-12T17:57:13.476Z","outcome":"started","tools":47,"contacts":0,"flags":0,"serious":0,"toolsHash":"c726fd389aab8fd7ab67a830218ca9effe0fbb2d85f109e2422556a947e6e24d"}],"page":"https://bragproof.smaverk.com/r/%40secondlayer/mcp"}