[{"data":1,"prerenderedAt":1135},["ShallowReactive",2],{"navigation_docs_en":3,"-en-guides-data-connectors-ai-agents":445,"-en-guides-data-connectors-ai-agents-surround":1130},[4,30,72,132,260,436],{"title":5,"icon":6,"path":7,"stem":8,"children":9,"page":6},"Getting Started",false,"\u002Fen\u002Fgetting-started","en\u002F1.getting-started",[10,15,20,25],{"title":11,"path":12,"stem":13,"icon":14},"Introduction","\u002Fen\u002Fgetting-started\u002Fintroduction","en\u002F1.getting-started\u002F2.introduction","i-lucide-house",{"title":16,"path":17,"stem":18,"icon":19},"Quickstart","\u002Fen\u002Fgetting-started\u002Finstallation","en\u002F1.getting-started\u002F3.installation","i-lucide-download",{"title":21,"path":22,"stem":23,"icon":24},"Use Cases","\u002Fen\u002Fgetting-started\u002Fuse-cases","en\u002F1.getting-started\u002F4.use-cases","i-lucide-layers",{"title":26,"path":27,"stem":28,"icon":29},"Concepts","\u002Fen\u002Fgetting-started\u002Fconcepts","en\u002F1.getting-started\u002F5.concepts","i-lucide-book",{"title":26,"path":31,"stem":32,"children":33,"page":6},"\u002Fen\u002Fconcepts","en\u002F2.concepts",[34,38,43,48,53,58,63,68],{"title":35,"path":36,"stem":37,"icon":14},"Organization","\u002Fen\u002Fconcepts\u002Forganization","en\u002F2.concepts\u002F1.organization",{"title":39,"path":40,"stem":41,"icon":42},"Data Model","\u002Fen\u002Fconcepts\u002Fdata-model","en\u002F2.concepts\u002F2.data-model","i-lucide-database",{"title":44,"path":45,"stem":46,"icon":47},"Access Control","\u002Fen\u002Fconcepts\u002Faccess-permissions","en\u002F2.concepts\u002F3.access-permissions","i-lucide-user-key",{"title":49,"path":50,"stem":51,"icon":52},"Audit Logs","\u002Fen\u002Fconcepts\u002Faudit-logs","en\u002F2.concepts\u002F4.audit-logs","i-lucide-scroll-text",{"title":54,"path":55,"stem":56,"icon":57},"Introspection","\u002Fen\u002Fconcepts\u002Fintrospection","en\u002F2.concepts\u002F6.introspection","i-lucide-database-search",{"title":59,"path":60,"stem":61,"icon":62},"Query Engine","\u002Fen\u002Fconcepts\u002Fquery-engine","en\u002F2.concepts\u002F7.query-engine","i-lucide-workflow",{"title":64,"path":65,"stem":66,"icon":67},"AI","\u002Fen\u002Fconcepts\u002Fai","en\u002F2.concepts\u002F8.ai","i-lucide-sparkles",{"title":69,"path":70,"stem":71,"icon":42},"Caching","\u002Fen\u002Fconcepts\u002Fcaching","en\u002F2.concepts\u002F9.caching",{"title":73,"path":74,"stem":75,"children":76,"page":6},"Guides","\u002Fen\u002Fguides","en\u002F4.guides",[77,82,87,92,97,102,107,112],{"title":78,"path":79,"stem":80,"icon":81},"REST API Quickstart","\u002Fen\u002Fguides\u002Frest-api","en\u002F4.guides\u002F1.rest-api","i-lucide-plug",{"title":83,"path":84,"stem":85,"icon":86},"SDK Quickstart","\u002Fen\u002Fguides\u002Fsdk","en\u002F4.guides\u002F2.sdk","i-lucide-terminal",{"title":88,"path":89,"stem":90,"icon":91},"Configure SSO","\u002Fen\u002Fguides\u002Fconfigure-sso","en\u002F4.guides\u002F3.configure-sso","i-lucide-key-round",{"title":93,"path":94,"stem":95,"icon":96},"Configure MCP","\u002Fen\u002Fguides\u002Fmcp","en\u002F4.guides\u002F4.mcp","i-lucide-brain-cog",{"title":98,"path":99,"stem":100,"icon":101},"Customize Content Space","\u002Fen\u002Fguides\u002Fcustomize-content-space","en\u002F4.guides\u002F5.customize-content-space","i-lucide-columns-3-cog",{"title":103,"path":104,"stem":105,"icon":106},"Build an Application with AI Assistance","\u002Fen\u002Fguides\u002Fbuild-an-application","en\u002F4.guides\u002F6.build-an-application","i-lucide-route",{"title":108,"path":109,"stem":110,"icon":111},"Horizontal Scaling","\u002Fen\u002Fguides\u002Fhorizontal-scaling","en\u002F4.guides\u002F7.horizontal-scaling","i-lucide-network",{"title":113,"icon":114,"path":115,"stem":116,"children":117,"page":6},"Data Connectors","i-lucide-cable","\u002Fen\u002Fguides\u002Fdata-connectors","en\u002F4.guides\u002F8.data-connectors",[118,122,127],{"title":16,"path":119,"stem":120,"icon":121},"\u002Fen\u002Fguides\u002Fdata-connectors\u002Fquickstart","en\u002F4.guides\u002F8.data-connectors\u002F1.quickstart","i-lucide-rocket",{"title":123,"path":124,"stem":125,"icon":126},"Build a Stripe Connector","\u002Fen\u002Fguides\u002Fdata-connectors\u002Fstripe","en\u002F4.guides\u002F8.data-connectors\u002F2.stripe","i-lucide-hammer",{"title":128,"path":129,"stem":130,"icon":131},"Build with AI Agents","\u002Fen\u002Fguides\u002Fdata-connectors\u002Fai-agents","en\u002F4.guides\u002F8.data-connectors\u002F3.ai-agents","i-lucide-bot",{"title":133,"path":134,"stem":135,"children":136,"page":6},"Developer","\u002Fen\u002Fdeveloper","en\u002F5.developer",[137,191,215,220],{"title":138,"path":139,"stem":140,"children":141,"page":6},"Data Access","\u002Fen\u002Fdeveloper\u002Fapi","en\u002F5.developer\u002F1.api",[142,147,152,157,162,167,172,177,182,186],{"title":143,"path":144,"stem":145,"icon":146},"Overview","\u002Fen\u002Fdeveloper\u002Fapi\u002Foverview","en\u002F5.developer\u002F1.api\u002F1.overview","i-lucide-globe",{"title":148,"path":149,"stem":150,"icon":151},"Errors","\u002Fen\u002Fdeveloper\u002Fapi\u002Ferrors","en\u002F5.developer\u002F1.api\u002F10.errors","i-lucide-alert-triangle",{"title":153,"path":154,"stem":155,"icon":156},"Authentication","\u002Fen\u002Fdeveloper\u002Fapi\u002Fauthentication","en\u002F5.developer\u002F1.api\u002F2.authentication","i-lucide-lock",{"title":158,"path":159,"stem":160,"icon":161},"Reading Data","\u002Fen\u002Fdeveloper\u002Fapi\u002Freading-data","en\u002F5.developer\u002F1.api\u002F3.reading-data","i-lucide-book-open",{"title":163,"path":164,"stem":165,"icon":166},"Writing Data","\u002Fen\u002Fdeveloper\u002Fapi\u002Fwriting-data","en\u002F5.developer\u002F1.api\u002F4.writing-data","i-lucide-pencil",{"title":168,"path":169,"stem":170,"icon":171},"Filtering","\u002Fen\u002Fdeveloper\u002Fapi\u002Ffiltering","en\u002F5.developer\u002F1.api\u002F5.filtering","i-lucide-filter",{"title":173,"path":174,"stem":175,"icon":176},"Field Selection","\u002Fen\u002Fdeveloper\u002Fapi\u002Ffield-selection","en\u002F5.developer\u002F1.api\u002F6.field-selection","i-lucide-list-checks",{"title":178,"path":179,"stem":180,"icon":181},"Sorting & Pagination","\u002Fen\u002Fdeveloper\u002Fapi\u002Fsorting-pagination","en\u002F5.developer\u002F1.api\u002F7.sorting-pagination","i-lucide-arrow-up-down",{"title":183,"path":184,"stem":185,"icon":111},"Relational Data","\u002Fen\u002Fdeveloper\u002Fapi\u002Frelational-data","en\u002F5.developer\u002F1.api\u002F8.relational-data",{"title":187,"path":188,"stem":189,"icon":190},"Files & Assets","\u002Fen\u002Fdeveloper\u002Fapi\u002Ffiles","en\u002F5.developer\u002F1.api\u002F9.files","i-lucide-file-up",{"title":192,"path":193,"stem":194,"children":195,"page":6},"Client SDK","\u002Fen\u002Fdeveloper\u002Fsdk","en\u002F5.developer\u002F2.sdk",[196,200,205,210],{"title":197,"path":198,"stem":199,"icon":19},"Installation","\u002Fen\u002Fdeveloper\u002Fsdk\u002Finstallation","en\u002F5.developer\u002F2.sdk\u002F1.installation",{"title":201,"path":202,"stem":203,"icon":204},"Client Setup","\u002Fen\u002Fdeveloper\u002Fsdk\u002Fclient-setup","en\u002F5.developer\u002F2.sdk\u002F2.client-setup","i-lucide-settings",{"title":206,"path":207,"stem":208,"icon":209},"Type System","\u002Fen\u002Fdeveloper\u002Fsdk\u002Ftype-system","en\u002F5.developer\u002F2.sdk\u002F3.type-system","i-lucide-braces",{"title":211,"path":212,"stem":213,"icon":214},"Advanced","\u002Fen\u002Fdeveloper\u002Fsdk\u002Fadvanced","en\u002F5.developer\u002F2.sdk\u002F5.advanced","i-lucide-puzzle",{"title":216,"path":217,"stem":218,"icon":219},"Application Users","\u002Fen\u002Fdeveloper\u002Fapplication-users","en\u002F5.developer\u002F3.application-users","i-lucide-users",{"title":221,"path":222,"stem":223,"children":224,"icon":214},"Extensions","\u002Fen\u002Fdeveloper\u002Fextensions","en\u002F5.developer\u002F3.extensions\u002Findex",[225,226,231],{"title":143,"path":222,"stem":223,"icon":214},{"title":227,"path":228,"stem":229,"icon":230},"Install and Manage Extensions","\u002Fen\u002Fdeveloper\u002Fextensions\u002Finstall","en\u002F5.developer\u002F3.extensions\u002F1.install","i-lucide-package-plus",{"title":113,"path":232,"stem":233,"children":234,"icon":114},"\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors","en\u002F5.developer\u002F3.extensions\u002F2.data-connectors\u002Findex",[235,236,241,245,250,255],{"title":143,"path":232,"stem":233,"icon":114},{"title":237,"path":238,"stem":239,"icon":240},"How Data Connectors Run","\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fruntime","en\u002F5.developer\u002F3.extensions\u002F2.data-connectors\u002F2.runtime","i-lucide-cpu",{"title":242,"path":243,"stem":244,"icon":42},"Data Sources","\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fdata-sources","en\u002F5.developer\u002F3.extensions\u002F2.data-connectors\u002F3.data-sources",{"title":246,"path":247,"stem":248,"icon":249},"Map an External Data Source","\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fdata-source-mapping","en\u002F5.developer\u002F3.extensions\u002F2.data-connectors\u002F4.data-source-mapping","i-lucide-map",{"title":251,"path":252,"stem":253,"icon":254},"Handle Errors","\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ferrors","en\u002F5.developer\u002F3.extensions\u002F2.data-connectors\u002F5.errors","i-lucide-shield-alert",{"title":256,"path":257,"stem":258,"icon":259},"Test a Data Connector","\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting","en\u002F5.developer\u002F3.extensions\u002F2.data-connectors\u002F6.testing","i-lucide-flask-conical",{"title":261,"path":262,"stem":263,"children":264,"page":6},"Reference","\u002Fen\u002Freference","en\u002F6.reference",[265,269,274,279,295,299,304,340,369,374],{"title":266,"path":267,"stem":268,"icon":204},"Configuration","\u002Fen\u002Freference\u002Fenvironment-variables","en\u002F6.reference\u002F1.environment-variables",{"title":270,"path":271,"stem":272,"icon":273},"System Requirements","\u002Fen\u002Freference\u002Fsystem-requirements","en\u002F6.reference\u002F2.system-requirements","i-lucide-server",{"title":275,"path":276,"stem":277,"icon":278},"Licensing","\u002Fen\u002Freference\u002Flicensing","en\u002F6.reference\u002F3.licensing","i-lucide-gem",{"title":280,"path":281,"stem":282,"children":283,"icon":81},"Connectors","\u002Fen\u002Freference\u002Fconnectors","en\u002F6.reference\u002F4.connectors\u002Findex",[284,285,290],{"title":280,"path":281,"stem":282,"icon":81},{"title":286,"path":287,"stem":288,"icon":289},"PostgreSQL and Supabase","\u002Fen\u002Freference\u002Fconnectors\u002Fpostgresql-supabase","en\u002F6.reference\u002F4.connectors\u002F1.postgresql-supabase","i-simple-icons-postgresql",{"title":291,"path":292,"stem":293,"icon":294},"MySQL and MariaDB","\u002Fen\u002Freference\u002Fconnectors\u002Fmysql-mariadb","en\u002F6.reference\u002F4.connectors\u002F2.mysql-mariadb","i-simple-icons-mysql",{"title":296,"path":297,"stem":298,"icon":209},"Data Types Representation","\u002Fen\u002Freference\u002Fdata-types","en\u002F6.reference\u002F5.data-types",{"title":300,"path":301,"stem":302,"icon":303},"Permissions Reference","\u002Fen\u002Freference\u002Fpermissions","en\u002F6.reference\u002F6.permissions","i-lucide-shield",{"title":305,"path":306,"stem":307,"children":308,"page":6},"API Reference","\u002Fen\u002Freference\u002Fapi-reference","en\u002F6.reference\u002F7.api-reference",[309,313,318],{"title":310,"path":311,"stem":312,"icon":273},"System Endpoints","\u002Fen\u002Freference\u002Fapi-reference\u002Fsystem-endpoints","en\u002F6.reference\u002F7.api-reference\u002F1.system-endpoints",{"title":314,"path":315,"stem":316,"icon":317},"OpenAPI Spec","\u002Fen\u002Freference\u002Fapi-reference\u002Fopenapi-spec","en\u002F6.reference\u002F7.api-reference\u002F2.openapi-spec","i-lucide-file-code",{"title":319,"path":320,"stem":321,"children":322,"icon":324},"Schema Migration","\u002Fen\u002Freference\u002Fapi-reference\u002Fschema-migration","en\u002F6.reference\u002F7.api-reference\u002F3.schema-migration\u002Findex",[323,325,330,335],{"title":319,"path":320,"stem":321,"icon":324},"i-lucide-database-zap",{"title":326,"path":327,"stem":328,"icon":329},"Apply Migrations","\u002Fen\u002Freference\u002Fapi-reference\u002Fschema-migration\u002Fapply-migrations","en\u002F6.reference\u002F7.api-reference\u002F3.schema-migration\u002F1.apply-migrations","i-lucide-upload",{"title":331,"path":332,"stem":333,"icon":334},"Import Changes","\u002Fen\u002Freference\u002Fapi-reference\u002Fschema-migration\u002Fimport-changes","en\u002F6.reference\u002F7.api-reference\u002F3.schema-migration\u002F2.import-changes","i-lucide-refresh-cw",{"title":336,"path":337,"stem":338,"icon":339},"Operation Reference","\u002Fen\u002Freference\u002Fapi-reference\u002Fschema-migration\u002Foperation-reference","en\u002F6.reference\u002F7.api-reference\u002F3.schema-migration\u002F3.operation-reference","i-lucide-list-tree",{"title":341,"path":342,"stem":343,"children":344,"page":6},"Design Considerations","\u002Fen\u002Freference\u002Fdesign-considerations","en\u002F6.reference\u002F8.design-considerations",[345,349,354,359,364],{"title":143,"path":346,"stem":347,"icon":348},"\u002Fen\u002Freference\u002Fdesign-considerations\u002Foverview","en\u002F6.reference\u002F8.design-considerations\u002F1.overview","i-lucide-compass",{"title":350,"path":351,"stem":352,"icon":353},"Instance Configuration","\u002Fen\u002Freference\u002Fdesign-considerations\u002Finstance-configuration-related-problems","en\u002F6.reference\u002F8.design-considerations\u002F3.instance-configuration-related-problems","i-lucide-wrench",{"title":355,"path":356,"stem":357,"icon":358},"Overly Permissive Public Access","\u002Fen\u002Freference\u002Fdesign-considerations\u002Foverly-permissive","en\u002F6.reference\u002F8.design-considerations\u002F4.overly-permissive","i-lucide-shield-off",{"title":360,"path":361,"stem":362,"icon":363},"No Aggregates","\u002Fen\u002Freference\u002Fdesign-considerations\u002Fno-aggregates","en\u002F6.reference\u002F8.design-considerations\u002F5.no-aggregates","i-lucide-sigma",{"title":365,"path":366,"stem":367,"icon":368},"Cross-Data-Source Referential Integrity","\u002Fen\u002Freference\u002Fdesign-considerations\u002Fcross-data-source-referential-integrity","en\u002F6.reference\u002F8.design-considerations\u002F6.cross-data-source-referential-integrity","i-lucide-unlink",{"title":370,"path":371,"stem":372,"icon":373},"CLI","\u002Fen\u002Freference\u002Fcli","en\u002F6.reference\u002F9.cli","i-lucide-square-terminal",{"title":221,"path":375,"stem":376,"children":377,"page":6},"\u002Fen\u002Freference\u002Fextensions","en\u002F6.reference\u002F9.extensions",[378,383,386,405],{"title":379,"path":380,"stem":381,"icon":382},"Extension Config and Manifest","\u002Fen\u002Freference\u002Fextensions\u002Fmanifest","en\u002F6.reference\u002F9.extensions\u002F1.manifest","i-lucide-file-json",{"title":370,"path":384,"stem":385,"icon":86},"\u002Fen\u002Freference\u002Fextensions\u002Fcli","en\u002F6.reference\u002F9.extensions\u002F2.cli",{"title":387,"path":388,"stem":389,"children":390,"page":6},"Extension Kit","\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit","en\u002F6.reference\u002F9.extensions\u002F3.extension-kit",[391,395,400],{"title":392,"path":393,"stem":394,"icon":81},"Data Connector","\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit\u002Fdata-connector","en\u002F6.reference\u002F9.extensions\u002F3.extension-kit\u002F1.data-connector",{"title":396,"path":397,"stem":398,"icon":399},"Protocol","\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit\u002Fprotocol","en\u002F6.reference\u002F9.extensions\u002F3.extension-kit\u002F2.protocol","i-lucide-arrow-left-right",{"title":401,"path":402,"stem":403,"icon":404},"Schema Helpers","\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit\u002Fexperimental","en\u002F6.reference\u002F9.extensions\u002F3.extension-kit\u002F3.experimental","i-lucide-blocks",{"title":113,"path":406,"stem":407,"children":408,"page":6},"\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors",[409,413,417,421,426,431],{"title":410,"path":411,"stem":412,"icon":81},"Data Connector API","\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fapi","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors\u002F1.api",{"title":414,"path":415,"stem":416,"icon":176},"Operations and Operators","\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Foperations","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors\u002F2.operations",{"title":148,"path":418,"stem":419,"icon":420},"\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Ferrors","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors\u002F3.errors","i-lucide-triangle-alert",{"title":422,"path":423,"stem":424,"icon":425},"Runtime Limits","\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Flimits","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors\u002F4.limits","i-lucide-gauge",{"title":427,"path":428,"stem":429,"icon":430},"Limitations","\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Flimitations","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors\u002F5.limitations","i-lucide-ban",{"title":432,"path":433,"stem":434,"icon":435},"Network Permissions","\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fpermissions","en\u002F6.reference\u002F9.extensions\u002F4.data-connectors\u002F6.permissions","i-lucide-shield-check",{"title":437,"icon":121,"path":438,"stem":439,"children":440,"page":6},"Release Notes","\u002Fen\u002Frelease-notes","en\u002F7.release-notes",[441],{"title":442,"path":443,"stem":444,"icon":121},"Changelog","\u002Fen\u002Frelease-notes\u002Fchangelog","en\u002F7.release-notes\u002F1.changelog",{"id":446,"title":447,"body":448,"description":1123,"extension":1124,"links":1125,"meta":1126,"navigation":1127,"path":129,"seo":1128,"stem":130,"__hash__":1129},"docs_en\u002Fen\u002F4.guides\u002F8.data-connectors\u002F3.ai-agents.md","Build Data Connectors with AI Agents",{"type":449,"value":450,"toc":1114},"minimark",[451,454,458,462,481,484,488,491,559,566,569,698,702,705,722,725,729,732,1003,1007,1014,1086,1090],[452,453],"preview",{},[455,456,143],"h2",{"id":457},"overview",[459,460,461],"p",{},"A coding agent can build an extension end to end. Point it at these docs instead of its memory, and stay in the loop for the steps it can't check. Each entry type has its own workflow.",[459,463,464,465,469,470,475,476,480],{},"Data connectors are the only entry type today, so this page covers building a data connector extension. It exposes an ",[466,467,468],"strong",{},"external data source"," (the API, service, or database the connector reads and writes) as ",[471,472,474],"a",{"href":473},"\u002Fconcepts\u002Fdata-model#collections","collections"," in a Monospace ",[471,477,479],{"href":478},"\u002Fconcepts\u002Forganization#glossary","workspace",". The agent probes the external data source, writes the connector, and climbs the test ladder.",[459,482,483],{},"This page covers what to give the agent, a prompt to start from, the rules to hold it to, and what an agent can't verify alone.",[455,485,487],{"id":486},"give-the-agent-the-docs","Give the Agent the Docs",[459,489,490],{},"Every docs page has a markdown version, and the site publishes two index files for language models.",[492,493,494,507],"table",{},[495,496,497],"thead",{},[498,499,500,504],"tr",{},[501,502,503],"th",{},"URL",[501,505,506],{},"Contents",[508,509,510,522,532,546],"tbody",{},[498,511,512,519],{},[513,514,515],"td",{},[516,517,518],"code",{},"https:\u002F\u002Fdocs.monospace.io\u002Fllms.txt",[513,520,521],{},"Every page's title, description, and markdown URL",[498,523,524,529],{},[513,525,526],{},[516,527,528],{},"https:\u002F\u002Fdocs.monospace.io\u002Fllms-full.txt",[513,530,531],{},"The full text of every page in one file",[498,533,534,539],{},[513,535,536],{},[516,537,538],{},"https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002F\u003Cpage path>.md",[513,540,541,542,545],{},"One page as markdown (e.g., ",[516,543,544],{},"https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fruntime.md",")",[498,547,548,553],{},[513,549,550],{},[516,551,552],{},"https:\u002F\u002Fdocs.monospace.io\u002Fen\u002F\u003Cpage path>",[513,554,555,556,545],{},"One page as HTML (e.g., ",[516,557,558],{},"https:\u002F\u002Fdocs.monospace.io\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fruntime",[459,560,561,562,565],{},"Give the agent the markdown URLs of the extension pages rather than ",[516,563,564],{},"llms-full.txt",". The full file covers the whole platform, and most of it is unrelated to extensions.",[459,567,568],{},"Read these pages in this order. The agent needs the runtime model and the limitations before it writes code:",[492,570,571,581],{},[495,572,573],{},[498,574,575,578],{},[501,576,577],{},"Page",[501,579,580],{},"Why the agent needs it",[508,582,583,593,603,613,624,634,644,654,677],{},[498,584,585,590],{},[513,586,587],{},[471,588,237],{"href":589},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fruntime",[513,591,592],{},"The sandbox: one file, no Node APIs, configuration instead of environment variables",[498,594,595,600],{},[513,596,597],{},[471,598,113],{"href":599},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors",[513,601,602],{},"Live queries, the operations contract, and the Fit Check",[498,604,605,610],{},[513,606,607],{},[471,608,427],{"href":609},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Flimitations",[513,611,612],{},"What a connector can't do, and the workaround for each",[498,614,615,621],{},[513,616,617],{},[471,618,620],{"href":619},"\u002Fguides\u002Fdata-connectors\u002Fstripe","Build a Stripe Data Connector",[513,622,623],{},"The build, step by step",[498,625,626,631],{},[513,627,628],{},[471,629,246],{"href":630},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fdata-source-mapping",[513,632,633],{},"Probing, filters, paging, keys, and writes",[498,635,636,641],{},[513,637,638],{},[471,639,251],{"href":640},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ferrors",[513,642,643],{},"Which error class to throw for each failure of the external data source",[498,645,646,651],{},[513,647,648],{},[471,649,256],{"href":650},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting",[513,652,653],{},"The test ladder",[498,655,656,674],{},[513,657,658,661,662,661,665,661,668,661,671],{},[471,659,410],{"href":660},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fapi",", ",[471,663,414],{"href":664},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Foperations",[471,666,148],{"href":667},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Ferrors",[471,669,432],{"href":670},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fpermissions",[471,672,370],{"href":673},"\u002Freference\u002Fextensions\u002Fcli",[513,675,676],{},"Exact shapes, rules, and codes to check against",[498,678,679,692],{},[513,680,681,661,685,661,689],{},[471,682,684],{"href":683},"\u002Freference\u002Fextensions\u002Fextension-kit\u002Fdata-connector","Data Connector Module",[471,686,688],{"href":687},"\u002Freference\u002Fextensions\u002Fextension-kit\u002Fprotocol","Protocol Types",[471,690,401],{"href":691},"\u002Freference\u002Fextensions\u002Fextension-kit\u002Fexperimental",[513,693,694,695],{},"The declaration of every export of ",[516,696,697],{},"@monospace\u002Fextension-kit",[455,699,701],{"id":700},"start-with-a-prompt","Start with a Prompt",[459,703,704],{},"Copy this prompt, fill in the angle-bracket parts, and give it to your agent in the directory where the connector project goes. It points the agent at the docs, sets the safety defaults, and makes it stop at the checkpoints where you decide.",[706,707,708],"accordion",{},[709,710,712],"accordion-item",{"label":711},"prompt.txt",[713,714,720],"pre",{"className":715,"code":717,"filename":711,"language":718,"meta":719},[716],"language-text","Build a Monospace data connector extension for \u003CEXTERNAL DATA SOURCE, e.g. \"the Acme REST API at https:\u002F\u002Fapi.acme.example\">.\nExpose \u003CCOLLECTIONS, e.g. \"customers and invoices, with invoices -> customers\"> as collections.\nWrites: \u003C\"none, read-only\" | \"create and update on customers, behind an enableWrites option\">.\n\nRead these pages first, and trust them over anything you remember about Monospace. Re-read the\nrelevant page before each step:\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fruntime.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Flimitations.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fguides\u002Fdata-connectors\u002Fstripe.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Fdata-source-mapping.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ferrors.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fapi.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Foperations.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fpermissions.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fdata-connectors\u002Ferrors.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fcli.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit\u002Fdata-connector.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit\u002Fprotocol.md\n- https:\u002F\u002Fdocs.monospace.io\u002Fraw\u002Fen\u002Freference\u002Fextensions\u002Fextension-kit\u002Fexperimental.md\nThe index of all pages is https:\u002F\u002Fdocs.monospace.io\u002Fllms.txt.\n\nRules:\n- Run the Fit Check before building. If a limitation blocks what I asked for, stop and ask me.\n- Probe the live external data source before declaring anything. Every filter, sort, count and\n  paging option you declare must name a request to it that you ran. Don't trust the vendor's\n  docs alone.\n- Declare only what requests to the external data source can answer, and re-check every returned\n  item against the filter where its match is broader. Refuse the rest before any request to the\n  external data source when the request's shape decides it: QueryRejected for a valid request it\n  can't serve (including shapes Monospace composes: not, or), a plain Error for anything the\n  collection doesn't declare, anywhere in the filter. Monospace doesn't check the filters it\n  sends, so a permission rule's condition or a stale stored declaration can bring an undeclared\n  comparison: refuse it, never drop it. Exception: serve the relation and read-back\n  lookups Monospace sends undeclared on a key no declaration can carry (in on a one-field\n  boolean, bytes, json, geometry or unsupported key; equals on each field of a key with an\n  unsupported field). Never scan, and never truncate a page.\n- Bound every read. Monospace sends some reads without a limit (limit=-1, relation batches), so\n  refuse with QueryRejected once a read would fetch more than a budget you set.\n- Declare collections with the kit's builders: fields.all(), fieldsOf(...).pick(...),\n  paging.limit() and paging.offset(). A field is writable exactly when a data list names it.\n- Declare a query capability (insertReturning, updateReturning, deleteReturning, unique values\n  in the entry's engine.capabilities.query, applying to every collection of the entry) only for\n  writes whose answers carry the written items with every selected field. Updates always need\n  readMany to read their items back by stable ID. A collection with a write whose capability is\n  missing needs a primary or unique index. Without insertReturning, create.output lists the\n  stable-ID fields, create answers them, and readMany must read the created items by stable\n  ID. Without updateReturning, updates go through updateMany by stable ID, and no update's\n  data names a stable-ID field. Without deleteReturning, deletes go through deleteMany by\n  stable ID, after readMany reads the items by stable ID.\n- A keyed operation (readOne, updateOne, deleteOne) answers { record: \u003Citem> }, or\n  { record: null } when its key or guard misses, and then writes nothing. Never throw for a\n  miss, and never answer records. Type it with QueryResultFor\u003C'readOne'> (or its operation).\n  int64 values and keys arrive as strings.\n- Fixed hosts go in extension.config.json as net: permissions. Use preflight only for hosts\n  derived from configuration. Validate configuration in setup and throw InvalidConfiguration;\n  preflight may also throw InvalidConfiguration when the configuration it reads is invalid.\n- No Node APIs, no environment variables, no filesystem. Credentials come from the data source\n  configuration.\n- Use test-mode or sandbox credentials only. Default writes off for credentials that can reach\n  production data.\n- Keep secrets and personal data out of error messages: the message is the only text of an\n  error that can reach the caller. Never copy a response body or a query string into one.\n- Give every request to the external data source a timeout (AbortSignal.timeout), and read the\n  body inside the same try. Monospace sets no deadline on query, introspect or testConnection.\n- Map failures in one client: no answer, a timeout or a 5xx is ConnectionFailed, a 429 is\n  RateLimited, a rejected credential (401\u002F403) is AccessDenied. A missing required value, a\n  duplicate, or a missing reference is NullConstraintViolation, UniqueConstraintViolation or\n  ForeignKeyConstraintViolation; any other value the external data source refuses is\n  QueryRejected. Wrap a fetch rejection with { cause: error }, so a permission denial\n  stays one. Throw a plain Error only for a changed API (a body that isn't JSON, a wrong shape)\n  and for a request the declaration never offered. Compare error codes with ErrorCode, never\n  with hard-coded numbers.\n- Check every value before you return it: every selected field present, each value of its\n  declared type, null only on nullable fields, and integers within their type's range.\n- Writes aren't atomic. Read a keyed write's guard before writing, report how far a bulk write\n  got when it fails, and never retry a write that isn't safe to repeat.\n- If the external data source takes a credential, implement testConnection and test it with a\n  malformed, a wrong, and a valid credential. If you don't implement it, say so in your report.\n\nWork in this order, and stop to report at each checkpoint:\n1. Fit Check, probes, and a capability table (what you'll declare, and the request to the external\n   data source that answers each row). CHECKPOINT: show me the table and the limitations that apply.\n2. Project, configuration parser, client with error mapping, and the schema. Until reads exist,\n   make query throw QueryRejected. Typecheck, build, install, and request a data source\n   in a throwaway workspace. CHECKPOINT: when Monospace answers 7001, show me the required network\n   permissions before you resend them. Then create the data source before writing query code.\n3. Reads, then keyed operations, then writes, each with network-free unit tests (a fake fetch for\n   timeouts, 429s and bodies that aren't JSON) and artifact smoke checks: wire assertions for\n   every translated filter, no-request assertions for every shape-based refusal.\n4. The Engine smoke, one deliberate break per check, and a second full run. Send every Engine read\n   with Cache-Control: no-cache, so a cached result can't hide a connector failure.\n5. A README with the configuration, network access, the capability table, refusals, and gaps.\n\nWhen you finish, list every test rung you ran, every rung you skipped, and everything you could\nnot verify yourself.\n","text","",[516,721,717],{"__ignoreMap":719},[459,723,724],{},"The checkpoints matter more than the rules. The first one catches an external data source that doesn't fit before any code exists, and the second keeps network approval with you.",[455,726,728],{"id":727},"rules-for-the-agent","Rules for the Agent",[459,730,731],{},"Hold the agent to these rules. Each links to the page that owns the detail.",[492,733,734,744],{},[495,735,736],{},[498,737,738,741],{},[501,739,740],{},"Rule",[501,742,743],{},"What goes wrong without it",[508,745,746,761,773,804,834,856,873,904,919,951,979,992],{},[498,747,748,758],{},[513,749,750,753,754],{},[466,751,752],{},"Run the Fit Check first, and ask when a limitation blocks the request."," See ",[471,755,757],{"href":756},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors#fit-check","Fit Check",[513,759,760],{},"The agent builds around a required filter or an unwritable reference, and the user finds out in Studio",[498,762,763,770],{},[513,764,765,753,768],{},[466,766,767],{},"Probe the live external data source, and declare only what a request you ran answers.",[471,769,246],{"href":630},[513,771,772],{},"Declarations based on vendor docs fail at runtime. The Art Institute of Chicago API documents 10,000 search results, and refuses past 1,000",[498,774,775,798],{},[513,776,777,784,785,788,789,791,792,795,796],{},[466,778,779,780,783],{},"Put fixed hosts in the manifest. Use ",[516,781,782],{},"preflight"," only for hosts derived from configuration."," Validate the configuration in ",[516,786,787],{},"setup",". ",[516,790,782],{}," may throw ",[516,793,794],{},"InvalidConfiguration"," for the part it reads. See ",[471,797,432],{"href":670},[513,799,800,801,803],{},"A ",[516,802,782],{}," that declares fixed hosts hides the grant from the manifest",[498,805,806,820],{},[513,807,808,753,811,813,814],{},[466,809,810],{},"Write web-platform code only.",[471,812,237],{"href":589},". Need a Node.js-compatible API? ",[471,815,819],{"href":816,"rel":817},"https:\u002F\u002Ffeedback.monospace.io\u002Frequest?request=new",[818],"nofollow","Let us know",[513,821,822,825,826,829,830,833],{},[516,823,824],{},"node:*"," imports fail the build, and ",[516,827,828],{},"Deno.env"," or filesystem calls throw ",[516,831,832],{},"NotCapable"," at runtime",[498,835,836,849],{},[513,837,838,753,845],{},[466,839,840,841,844],{},"Run the linter, ",[516,842,843],{},"tsc"," and unit tests; the build doesn't typecheck.",[471,846,848],{"href":847},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting#_1-lint-typecheck-and-run-unit-tests","Lint, Typecheck, and Run Unit Tests",[513,850,851,852,855],{},"A green build ships a type error, or an error mapping that only a timeout or a ",[516,853,854],{},"429"," would exercise",[498,857,858,866],{},[513,859,860,753,863],{},[466,861,862],{},"Create a data source before writing query code, and check every relation in the workspace's OpenAPI document.",[471,864,256],{"href":865},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting#_5-run-an-engine-smoke",[513,867,868,869,872],{},"Engine checks declarations when a data source is created or reintrospected, not at build time or on the raw ",[516,870,871],{},"\u002Fsources\u002Fdata\u002Fintrospect"," endpoint. A reload doesn't refresh a data source's stored declarations either; reintrospect after changing them. It narrows a relation direction it can't serve with only a log warning",[498,874,875,901],{},[513,876,877,880,881,884,885,888,889,892,893,897,898],{},[466,878,879],{},"Serve or refuse: never scan, never truncate."," Refuse with ",[516,882,883],{},"QueryRejected"," (or a plain ",[516,886,887],{},"Error"," for what you didn't declare) as early as the connector can tell, fill the whole ",[516,890,891],{},"limit"," unless the matching items run out, and break sort ties with the ",[471,894,896],{"href":895},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Foperations#use-keys-and-the-stable-id","stable ID",". See ",[471,899,251],{"href":900},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ferrors#_4-refuse-requests-you-cant-serve",[513,902,903],{},"A short page reads as \"no more items\", and a scan burns the external data source's rate limit",[498,905,906,916],{},[513,907,908,911,912,897,914],{},[466,909,910],{},"Re-check every returned item against the filter"," when the external data source's match is broader than the declared operator (e.g., case-insensitive or substring), and keep fetching when the re-check drops items, so the page still fills its ",[516,913,891],{},[471,915,246],{"href":630},[513,917,918],{},"Callers get items that don't match their filter, or a short page that reads as the end of the data",[498,920,921,934],{},[513,922,923,753,930],{},[466,924,925,926,929],{},"Answer ",[516,927,928],{},"{ record: null }"," for a keyed miss, and check the guard before any write.",[471,931,933],{"href":932},"\u002Freference\u002Fextensions\u002Fdata-connectors\u002Fapi#keyed-operations","Keyed Operations",[513,935,936,937,939,940,943,944,947,948],{},"A guard miss still writes, or answers an item the guard excludes. A plain ",[516,938,887],{}," or a ",[516,941,942],{},"records"," answer fails the caller's request with ",[516,945,946],{},"500"," instead of ",[516,949,950],{},"404",[498,952,953,976],{},[513,954,955,965,966,969,970,973,974],{},[466,956,957,958,960,961,964],{},"Map errors in one client, use ",[516,959,794],{}," only for configuration and ",[516,962,963],{},"AccessDenied"," only for an account the external data source refuses"," (rejected credentials, a missing scope, or a resource it can't reach). Give every request a deadline, and wrap a ",[516,967,968],{},"fetch"," rejection with ",[516,971,972],{},"{ cause }",", so a permission denial stays one. See ",[471,975,251],{"href":640},[513,977,978],{},"Callers are told their configuration is invalid when the external data source is down, see an internal error, or wait on a request that never answers",[498,980,981,989],{},[513,982,983,753,986],{},[466,984,985],{},"Assert what goes on the wire, and make every check fail once.",[471,987,256],{"href":988},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting#assert-what-goes-on-the-wire",[513,990,991],{},"Checks pass against a fixture that ignores the parameter being tested",[498,993,994,1000],{},[513,995,996,999],{},[466,997,998],{},"Report honestly."," List skipped rungs, and exit non-zero from a run that skipped checks",[513,1001,1002],{},"\"All tests pass\" means only the rungs that ran",[455,1004,1006],{"id":1005},"know-what-the-agent-cant-verify-alone","Know What the Agent Can't Verify Alone",[459,1008,1009,1010,1013],{},"Some steps need a person, credentials, or an ",[466,1011,1012],{},"instance"," (a Monospace deployment) the agent can't reach. Plan for these before you start, and ask the agent to list them in its final report.",[492,1015,1016,1026],{},[495,1017,1018],{},[498,1019,1020,1023],{},[501,1021,1022],{},"Step",[501,1024,1025],{},"Why the agent needs you",[508,1027,1028,1040,1048,1059,1074],{},[498,1029,1030,1033],{},[513,1031,1032],{},"Approving network permissions",[513,1034,1035,1036,1039],{},"Deciding which hosts a data source may reach is your call. Review ",[516,1037,1038],{},"meta.permissions"," before the agent resends them. The grant must contain exactly the required hosts, ports and wildcards; reasons aren't compared",[498,1041,1042,1045],{},[513,1043,1044],{},"Credentials",[513,1046,1047],{},"The agent needs a test-mode or sandbox credential from you. Never give it production credentials",[498,1049,1050,1053],{},[513,1051,1052],{},"Installing into your instance",[513,1054,1055,1056],{},"The agent needs write access to the instance's install location, and a restart or automatic reloading. See ",[471,1057,227],{"href":1058},"\u002Fdeveloper\u002Fextensions\u002Finstall",[498,1060,1061,1064],{},[513,1062,1063],{},"Behavior that needs live traffic",[513,1065,1066,1067,1069,1070,1073],{},"Real rate limits and paging depth show up only against the real external data source, often only under load. The agent can test its ",[516,1068,854],{}," and ",[516,1071,1072],{},"5xx"," mapping alone with a stand-in that injects them",[498,1075,1076,1079],{},[513,1077,1078],{},"Studio",[513,1080,1081,1082],{},"Browsing, filtering, and editing in Studio, and judging whether each error message helps a user. No example automates it. See ",[471,1083,1085],{"href":1084},"\u002Fdeveloper\u002Fextensions\u002Fdata-connectors\u002Ftesting#_8-try-it-in-studio","Try It in Studio",[455,1087,1089],{"id":1088},"see-also","See Also",[1091,1092,1093,1099,1104,1109],"ul",{},[1094,1095,1096,1098],"li",{},[471,1097,620],{"href":619},": the Stripe connector, step by step",[1094,1100,1101,1103],{},[471,1102,256],{"href":650},": the ladder an agent climbs before it reports done",[1094,1105,1106,1108],{},[471,1107,427],{"href":609},": what a connector can't do, for the Fit Check",[1094,1110,1111,1113],{},[471,1112,237],{"href":589},": the sandbox the agent's code runs in",{"title":719,"searchDepth":1115,"depth":1115,"links":1116},2,[1117,1118,1119,1120,1121,1122],{"id":457,"depth":1115,"text":143},{"id":486,"depth":1115,"text":487},{"id":700,"depth":1115,"text":701},{"id":727,"depth":1115,"text":728},{"id":1005,"depth":1115,"text":1006},{"id":1088,"depth":1115,"text":1089},"Point a coding agent at the extension docs, give it a starter prompt, and know which steps still need you.","md",null,{},{"title":128,"icon":131},{"title":447,"description":1123},"yOSNObLB796BtfrxGPq2Rr3sD5Y2kbimR_2KqNDc8GM",[1131,1133],{"title":123,"path":124,"stem":125,"description":1132,"icon":126,"children":-1},"Build a Stripe test-mode data connector extension with customers, products and prices, from probing the API to writes and tests.",{"title":143,"path":144,"stem":145,"description":1134,"icon":146,"children":-1},"The Monospace API structure, endpoints, and response format.",1790840070610]