Save this as .cursor/rules/blockdb.mdc in your project. Cursor loads it automatically.
---description: How to call the BlockDB on-chain data APIalwaysApply: false---# BlockDB APIWhen the user asks for Ethereum / EVM on-chain data (blocks, transactions, logs,transfers, swaps, pools, reserves, prices, TVL, yields), call the BlockDB REST API.## Hard rules- Base URL: `https://api.blockdb.io/v1`- Auth: every request sends `Authorization: Bearer ${BLOCKDB_API_KEY}` (read from env, never hardcode).- Method: `POST` with `Content-Type: application/json`. All filters go in the JSON body, not query params. (Exception: `GET /usage`.)- Response envelope: `{ "data": [...], "cursor": "<string|null>", "page_count": <number> }`.- Pagination: if `cursor` is non-null, resend the same body with that `cursor`. Stop when `cursor` is null.- Determinism: prefer `from_block` / `to_block` over timestamps.- Required: `chain_id` (Ethereum = 1). Never invent chain_id, exchange_id, pool_type_id, or addresses — resolve them from the docs.## Request template{ "chain_id": 1, "from_block": 19000000, "to_block": 19001000, "limit": 250, "cursor": null }## When unsureFetch the relevant page from https://docs.blockdb.io before generating a request:- Endpoint index: /api-reference/evm/overview- Enumerations (chain, exchange, pool type): /api-reference/enumerations/overview- Dataset → table mapping: /data-catalog/evm/dataset-index
For historical work, point Cursor at the free Parquet datasets instead of the API — no key, no rate limits:
import polars as pldf = pl.read_parquet("hf://datasets/blockdb/ethereum-dex-swaps/year=2024/")
The rule above is a trimmed version of LLM onboarding. Link the full page in long agent sessions for complete pagination and error-handling guidance.
Last modified on June 5, 2026
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"BlockDB Docs","description":"BlockDB documentation for institutional-grade blockchain data: catalog coverage, delivery options, verification, and API guides for EVM/SVM datasets.","colors":{"primary":"#323CE0","light":"#5A86FF","dark":"#5A86F0"},"logo":{"light":"https://mintcdn.com/blockdb/jY_NTBZTOTzgP7yE/logo/white.svg?fit=max\u0026auto=format\u0026n=jY_NTBZTOTzgP7yE\u0026q=85\u0026s=7073235be4b9377014f670b345c57f6f","dark":"https://mintcdn.com/blockdb/jY_NTBZTOTzgP7yE/logo/dark.svg?fit=max\u0026auto=format\u0026n=jY_NTBZTOTzgP7yE\u0026q=85\u0026s=b15eac1f01f9973b403b38a7a221bf94"},"favicon":"https://mintcdn.com/blockdb/gkh0Ba6oAwA86iCA/fav/fav-icon-256.png?fit=max\u0026auto=format\u0026n=gkh0Ba6oAwA86iCA\u0026q=85\u0026s=b9dd87c3e861221a2efc6541f1e90cda","api":{"mdx":{"auth":{"method":"bearer"},"server":"https://api.blockdb.io/v1/"}},"appearance":{"default":"dark"},"background":{"decoration":"gradient","color":{"dark":"#02071a"}},"navbar":{"links":[{"href":"mailto:support@blockdb.io","label":"Support"},{"href":"https://status.blockdb.io","label":"Status"},{"href":"/pricing/home","label":"Pricing"}],"primary":{"type":"button","label":"Get Free Data","href":"https://huggingface.co/collections/BlockDB/blockdb-full-evm-research-datasets-10-years"}},"footer":{"socials":{"github":"https://github.com/blockdb-io","linkedin":"https://linkedin.com/company/blockdb","youtube":"https://youtube.com/@Block_DB"}},"search":{"prompt":"Search datasets..."},"seo":{"metatags":{"description":"BlockDB delivers institutional-grade on-chain data for EVM networks: raw transactions, logs, contracts, token pricing, DeFi analytics, liquidity pools, and token transfers — with delivery SLAs, full data lineage, and REST API access.","keywords":"blockchain data API, EVM data, Ethereum data, on-chain data, token pricing API, DeFi analytics, smart contract data, liquidity pool data, token transfers, crypto data provider, historical blockchain data, web3 data, blockchain analytics","author":"BlockDB","robots":"index, follow","googlebot":"index, follow","google":"notranslate","google-site-verification":"-8hf3o9IZUm2tEkLEJm0sgd_QPAyPt8cgbUpn4ilwiE","theme-color":"#02071a","canonical":"https://docs.blockdb.io","format-detection":"telephone=no","referrer":"strict-origin-when-cross-origin","language":"en","og:image":"https://docs.blockdb.io/social-preview.png","og:locale":"en_US","twitter:card":"summary_large_image","twitter:image":"https://docs.blockdb.io/social-preview.png","twitter:image:alt":"BlockDB - Institutional Blockchain Data Catalog and API Reference"},"indexing":"navigable"},"fonts":{"family":"Plus Jakarta Sans"},"banner":{"content":"📊 New: Free research datasets — 10+ years of Ethereum token transfers, open to everyone. [Explore the free datasets →](/free-datasets/home)","dismissible":true},"errors":{"404":{"redirect":false,"title":"This page slipped off-chain","description":"We couldn't trace this **BlockDB** page. Check the URL, search for the dataset, or reach out to [support@blockdb.io](mailto:support@blockdb.io) and we'll point you to the right docs."}},"contextual":{"options":["chatgpt","claude","perplexity","cursor","mcp","add-mcp"],"display":"header"},"thumbnails":{},"interaction":{"drilldown":true},"metadata":{"timestamp":true},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"blockdb","hasAudioNarration":false,"actualSubdomain":"blockdb","customDomains":["docs.blockdb.io"],"gitSource":{"type":"github","owner":"blockdb-io","repo":"blockdb.public.docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true},"entitlements":{},"buildId":"6ac221d2281eafe8799f7c95","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"default","tag":"API Reference","count":69},{"language":"default","tag":"EVM Endpoints","count":47},{"language":"default","tag":"WSS Reference","count":41},{"language":"default","tag":"EVM Streams","count":36},{"language":"default","tag":"Data Catalog","count":34},{"language":"default","tag":"Overview","count":33},{"language":"default","tag":"EVM","count":24},{"language":"default","tag":"User Guide","count":16},{"language":"default","tag":"Primitives","count":15},{"language":"default","tag":"Entities","count":12}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":true},"customCss":[],"page":{"pagePath":"build-with-ai/cursor","slug":"/build-with-ai/cursor","pageMetadata":{"title":"Cursor","description":"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.","keywords":["Cursor rule API","Cursor blockchain","Cursor MCP BlockDB","AI coding on-chain data","Cursor AGENTS.md"],"icon":"laptop-code","href":"/build-with-ai/cursor"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,p:`p`,pre:`pre`,span:`span`,..._provideComponents(),...props.components},{CodeBlock,Heading,Tip}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Tip)_missingMdxReference(`Tip`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Drop the rule below into your project so Cursor writes correct BlockDB API calls — right auth, right body shape, right pagination.`}),`\n`,_jsx(Heading,{level:`2`,id:`add-the-rule`,children:`Add the rule`}),`\n`,_jsxs(_components.p,{children:[`Save this as `,_jsx(_components.code,{children:`.cursor/rules/blockdb.mdc`}),` in your project. Cursor loads it automatically.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`27`,language:`markdown`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`markdown`,children:_jsxs(_components.code,{language:`markdown`,numberOfLines:`27`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`---`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`description`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`How to call the BlockDB on-chain data API`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`alwaysApply`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`---`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-light-font-weight\":`bold`,\"--shiki-dark\":`#569CD6`,\"--shiki-dark-font-weight\":`bold`},children:`# BlockDB API`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`When the user asks for Ethereum / EVM on-chain data (blocks, transactions, logs,`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`transfers, swaps, pools, reserves, prices, TVL, yields), call the BlockDB REST API.`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-light-font-weight\":`bold`,\"--shiki-dark\":`#569CD6`,\"--shiki-dark-font-weight\":`bold`},children:`## Hard rules`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Base URL: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`https://api.blockdb.io/v1`\"})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Auth: every request sends `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`Authorization: Bearer ${BLOCKDB_API_KEY}`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (read from env, never hardcode).`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Method: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`POST`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` with `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`Content-Type: application/json`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`. All filters go in the JSON body, not query params. (Exception: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`GET /usage`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Response envelope: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:'`{ \"data\": [...], \"cursor\": \"\u003cstring|null>\", \"page_count\": \u003cnumber> }`'}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Pagination: if `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`cursor`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` is non-null, resend the same body with that `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`cursor`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`. Stop when `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`cursor`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` is null.`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Determinism: prefer `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`from_block`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` / `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`to_block`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` over timestamps.`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Required: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#CE9178`},children:\"`chain_id`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (Ethereum = 1). Never invent chain_id, exchange_id, pool_type_id, or addresses — resolve them from the docs.`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-light-font-weight\":`bold`,\"--shiki-dark\":`#569CD6`,\"--shiki-dark-font-weight\":`bold`},children:`## Request template`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{ \"chain_id\": 1, \"from_block\": 19000000, \"to_block\": 19001000, \"limit\": 250, \"cursor\": null }`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-light-font-weight\":`bold`,\"--shiki-dark\":`#569CD6`,\"--shiki-dark-font-weight\":`bold`},children:`## When unsure`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`Fetch the relevant page from https://docs.blockdb.io before generating a request:`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Endpoint index: /api-reference/evm/overview`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Enumerations (chain, exchange, pool type): /api-reference/enumerations/overview`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#6796E6`},children:`-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Dataset → table mapping: /data-catalog/evm/dataset-index`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`use-the-free-datasets-for-backtests`,children:`Use the free datasets for backtests`}),`\n`,_jsxs(_components.p,{children:[`For historical work, point Cursor at the `,_jsx(_components.a,{href:`/free-datasets/home`,children:`free Parquet datasets`}),` instead of the API — no key, no rate limits:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` polars `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`as`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` pl`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`df `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` pl.read_parquet(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"hf://datasets/blockdb/ethereum-dex-swaps/year=2024/\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})}),`\n`,_jsx(Tip,{children:_jsxs(_components.p,{children:[`The rule above is a trimmed version of `,_jsx(_components.a,{href:`/api-reference/overview/llm-onboarding`,children:`LLM onboarding`}),`. Link the full page in long agent sessions for complete pagination and error-handling guidance.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Cursor","description":"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.","keywords":["Cursor rule API","Cursor blockchain","Cursor MCP BlockDB","AI coding on-chain data","Cursor AGENTS.md"],"icon":"laptop-code","href":"/build-with-ai/cursor"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Add the rule","slug":"add-the-rule","depth":2,"children":[]},{"title":"Use the free datasets for backtests","slug":"use-the-free-datasets-for-backtests","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/blockdb/cea747a4392f2092/hubspot.js"],"subdomain":"blockdb","siteName":"BlockDB Docs","title":"Cursor - BlockDB Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-06-05T09:08:40.687Z","gitLastModified":"2026-06-05T09:07:06.000Z","originalFileLocation":"build-with-ai/cursor.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.\">\u003cmeta data-mint-head name=\"keywords\" content=\"blockchain data API, EVM data, Ethereum data, on-chain data, token pricing API, DeFi analytics, smart contract data, liquidity pool data, token transfers, crypto data provider, historical blockchain data, web3 data, blockchain analytics\">\u003cmeta data-mint-head name=\"application-name\" content=\"BlockDB Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"index, follow\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Cursor - BlockDB Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"BlockDB Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.blockdb.io/build-with-ai/cursor\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://docs.blockdb.io/social-preview.png\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Cursor - BlockDB Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://docs.blockdb.io/social-preview.png\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/blockdb/OJmX1QiZbwHoitmk/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"BlockDB Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#323CE0\">\u003cmeta data-mint-head name=\"og:locale\" content=\"en_US\">\u003cmeta data-mint-head name=\"author\" content=\"BlockDB\">\u003cmeta data-mint-head name=\"googlebot\" content=\"index, follow\">\u003cmeta data-mint-head name=\"google\" content=\"notranslate\">\u003cmeta data-mint-head name=\"google-site-verification\" content=\"-8hf3o9IZUm2tEkLEJm0sgd_QPAyPt8cgbUpn4ilwiE\">\u003cmeta data-mint-head name=\"theme-color\" content=\"#02071a\">\u003cmeta data-mint-head name=\"format-detection\" content=\"telephone=no\">\u003cmeta data-mint-head name=\"referrer\" content=\"strict-origin-when-cross-origin\">\u003cmeta data-mint-head name=\"language\" content=\"en\">\u003cmeta data-mint-head name=\"twitter:image:alt\" content=\"BlockDB - Institutional Blockchain Data Catalog and API Reference\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.blockdb.io/build-with-ai/cursor\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/build-with-ai/cursor.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.blockdb.io/#organization\",\"name\":\"BlockDB Docs\",\"url\":\"https://docs.blockdb.io\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/blockdb/jY_NTBZTOTzgP7yE/logo/white.svg?fit=max\u0026auto=format\u0026n=jY_NTBZTOTzgP7yE\u0026q=85\u0026s=7073235be4b9377014f670b345c57f6f\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.blockdb.io#website\",\"name\":\"BlockDB Docs\",\"url\":\"https://docs.blockdb.io\",\"publisher\":{\"@id\":\"https://docs.blockdb.io/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.blockdb.io/build-with-ai/cursor#webpage\",\"url\":\"https://docs.blockdb.io/build-with-ai/cursor\",\"name\":\"Cursor\",\"description\":\"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.\",\"dateModified\":\"2026-06-05T09:07:06.000Z\",\"isPartOf\":{\"@id\":\"https://docs.blockdb.io#website\"},\"breadcrumb\":{\"@id\":\"https://docs.blockdb.io/build-with-ai/cursor#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.blockdb.io/build-with-ai/cursor#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Build with AI\",\"item\":\"https://docs.blockdb.io/build-with-ai/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Cursor\",\"item\":\"https://docs.blockdb.io/build-with-ai/cursor\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.blockdb.io/build-with-ai/cursor#article\",\"headline\":\"Cursor\",\"name\":\"Cursor\",\"description\":\"Add a Cursor rule so the agent calls the BlockDB API correctly — auth, POST + JSON bodies, block ranges, and cursor pagination.\",\"url\":\"https://docs.blockdb.io/build-with-ai/cursor\",\"mainEntityOfPage\":{\"@id\":\"https://docs.blockdb.io/build-with-ai/cursor#webpage\"},\"image\":\"https://docs.blockdb.io/social-preview.png\",\"dateModified\":\"2026-06-05T09:07:06.000Z\",\"keywords\":\"Cursor rule API, Cursor blockchain, Cursor MCP BlockDB, AI coding on-chain data, Cursor AGENTS.md\",\"publisher\":{\"@id\":\"https://docs.blockdb.io/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.blockdb.io#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"BlockDB Docs\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"BlockDB Docs\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/build-with-ai/cursor.md","siteName":"BlockDB Docs","nav":{"global":null,"tabs":[{"tab":"Home","pages":[{"title":"Home","href":""}]},{"tab":"User Guide","pages":[{"title":"User Guide","href":"/user-guide/about-blockdb/what-is-blockdb"}]},{"tab":"Build with AI","groups":[{"group":"Build with AI","icon":"robot","pages":[{"title":"Build with AI","description":"Wire BlockDB into AI coding tools — a Cursor rule and a Claude skill, tuned to our API and free datasets, that query on-chain data in natural language.","icon":"robot","href":"/build-with-ai/overview"},{"title":"Cursor","icon":"laptop-code","href":"/build-with-ai/cursor"},{"title":"Claude Skill","description":"A ready-to-use Claude skill (SKILL.md) that turns Claude into a BlockDB query agent for Ethereum and EVM on-chain data.","icon":"sparkles","href":"/build-with-ai/claude-skills"}]}]},{"tab":"Data Catalog","pages":[{"title":"Data Catalog","href":"/data-catalog/overview/introduction"}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/overview/home"}]},{"tab":"WSS Reference","pages":[{"title":"WSS Reference","href":"/wss-reference/overview/introduction"}]},{"tab":"Troubleshooting","pages":[{"title":"Troubleshooting","href":"/troubleshooting/home"}]},{"tab":"Pricing","pages":[{"title":"Pricing","href":"/pricing/home"}]},{"tab":"Free Datasets","pages":[{"title":"Free Datasets","href":"/free-datasets/home"}]},{"tab":"Release Notes","pages":[{"title":"Release Notes","href":"/release-notes/home"}]}]},"basePath":"","title":"Cursor - BlockDB Docs","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":["10e4515597"],"chunks":["BannerMarkdown-DV3Oq1fY.js","dist-C-XZBk9h.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","clsx-D3Isdib3.js","html-void-elements-mCSPHezU.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js"]}