Maranhão Open Data MCP for AI. Query public records & state data via SQL
Works with every AI agent you already use
…and any MCP-compatible client








Connect to your AI in seconds.
Maranhão Open Data connects your AI agent directly to the state's government transparency portal. It lets you discover, inspect metadata, and query public datasets from Maranhão, Brazil—all via structured commands like `search_packages` or complex SQL execution using `search_datastore_sql`.
This is for anyone who needs reliable, real-time access to official public records.
What your AI can do
Get package
Retrieves the metadata for an entire dataset package, giving you details on its scope and contents.
Get resource
Fetches detailed metadata about a specific resource within a dataset (e.g., checking if it's a CSV file or API endpoint).
List packages
Returns a complete list of every available public data package hosted on the portal.
The agent uses list_packages or search_packages to retrieve a list of all topics and packages available on the portal.
You call get_package to get detailed information about an entire dataset package, including its scope and owners.
The tool uses get_resource to retrieve the metadata for a particular file or API endpoint within a dataset.
For quick filtering on existing rows, run search_datastore to query data based on simple criteria.
You use search_datastore_sql to run raw SQL against the data store. This handles deep analysis that basic searching can't achieve.
Ask an AI about this
Waiting for input…
Maranhão Open Data MCP Server: 6 Tools for Data Query & Retrieval
These six tools allow your AI client to perform everything from listing available datasets to executing deep, customized SQL queries against the Maranhão data store.
Make your AI actually useful.
Add this MCP to Claude, Cursor, or Windsurf and your AI stops guessing. It gets real tools to look things up, take action, and handle the stuff you keep doing by hand.
Start using Maranhão Open Data on VinkiusGet Package
Retrieves the metadata for an entire dataset package, giving you details on its scope and contents.
Get Resource
Fetches detailed metadata about a specific resource within a dataset (e.g., checking...
List Packages
Returns a complete list of every available public data package hosted on the portal.
Search Datastore Sql
Runs complex SQL queries against the data store. This is used when you need to join...
Search Datastore
Executes basic searches for records within an existing resource in the DataStore...
Search Packages
Filters and searches for specific packages by topic, name, or keyword across all available datasets.
Security and governance baked right in.
Pick your AI client below to get set up. Just create a Vinkius account, subscribe, and you're instantly up and running. We handle the entire backend infrastructure, delivering out-of-the-box support for HTTPS Streamable, SSE, and OAuth2—zero messy routing required.
Choose How to Get Started
Build a custom MCP for your own tools, or connect a ready-made integration from our catalog.
Build Your Own
Turn any API into an MCP. Import a spec, define Agent Skills, or deploy with MCPFusion.
- Import from OpenAPI, Swagger, or YAML specs
- Create Agent Skills with progressive disclosure
- Deploy to edge with MCPFusion framework
- Built in DLP, auth, and compliance on every call
- Real time usage dashboard and cost metering
- Publish to catalog or keep private
Make Your AI Do More
Start with Maranhão Open Data, then connect any of our 5,100+ other servers whenever your AI needs more. One click, no limits.
- Use this MCP plus 5,100+ others, all in one place
- Add new capabilities to your AI anytime you want
- Every connection is secured and compliant automatically
- Track usage and costs across all your servers
- Works with Claude, ChatGPT, Cursor, and more
- New servers added to the catalog every week
Independent Platform Disclaimer: Vinkius is an independent platform and is not affiliated with, endorsed by, sponsored by, verified by, or otherwise authorized by Maranhão Open Data. All third-party trademarks, logos, and brand names are the property of their respective owners. Their use on this website is strictly for informational purposes to identify service compatibility and interoperability.
VINKIUS INFRASTRUCTURE
Cloud Hosted
Managed infra
V8 Isolated
Sandboxed per request
Zero-Trust Proxy
No stored credentials
DLP Enforced
Policy on every call
GDPR Compliant
EU data residency
Token Compression
~60% cost reduction
Works with Claude, ChatGPT, Cursor, and more
The Model Context Protocol standardizes how applications expose capabilities to LLMs. Instead of operating in isolation, your AI gains direct access to external platforms, live data, and real-world actions through secure, standardized connections.
This connection provides 6 powerful capabilities that interface natively with Claude, ChatGPT, Cursor, and other compatible AI platforms. No middleware. No custom integration required.
Sifting through government websites shouldn't feel like archaeology.
Today, finding a specific piece of public data means clicking through multiple state departmental portals. You find the 'Contracts' section on Page A, download an Excel sheet that only shows 50 rows, and then you have to manually cross-reference those IDs in the 'Spending Indicators' tab on Page B. It takes hours just to compile a basic timeline.
With this MCP server, your agent runs `search_packages` first, confirming all relevant data sources are visible. Then, instead of downloading files, you ask for the combined view using `search_datastore_sql`. You get an instant, structured table with exactly what you need—no manual clicking, no messy spreadsheets.
Maranhão Open Data MCP Server: run complex SQL queries from chat.
Before this server, running a query that combined data across multiple tables (e.g., 'Give me all contractors who received funds for health projects in Q1') required you to contact an IT department or write boilerplate code just to establish the database connection and permissions.
Now, you simply provide the SQL logic. The agent executes `search_datastore_sql` directly against the live government data store. It's immediate, it's auditable, and it removes the bottleneck of manual data plumbing.
What your AI can actually do with this
Listen up. The Maranhão Open Data MCP Server hooks your AI agent straight into the state government's public transparency portal. Forget clicking through endless web forms or manually downloading zip files; you just talk to your agent, and it handles all the API calls needed to pull real-time data from Maranhão, Brazil.
When you use this server, your agent interacts with structured tools, giving you deep analytical access without needing external scripts. It's built for anyone who needs reliable, official records right now.
Discovering What’s Available
If you don't know what data exists, you start by mapping the landscape. You can run list_packages to get a complete rundown of every single public dataset package hosted on that portal. Need something specific? Use search_packages—you just punch in a topic or keyword, and your agent filters through the massive catalog to show only relevant packages.
This is how you narrow down what’s out there.
Inspecting Data Sources and Metadata
You've found a promising package, but you need to know exactly what it contains before you commit to querying it. You call get_package for detailed metadata on the whole dataset; this tells you about its overall scope and who owns it. If that package has multiple files or endpoints—maybe a CSV dump alongside an API feed—you use get_resource to inspect the specific structure of that particular file or endpoint, letting you know if it's ready for queries.
Searching Within DataTables
Once you have identified a resource, you can start pulling data. For basic filtering on existing rows within a table, your agent runs search_datastore. This is the quick and dirty way to filter records based on simple criteria—like finding all entries from a specific year or department.
But what if that doesn't cut it? If you need complex analysis, like joining tables together or applying advanced filters across multiple columns (say, tracking every contract over $50,000 and filed in the last quarter), you gotta use search_datastore_sql. This function lets your agent run raw SQL queries directly against the data store.
It handles deep analysis that simple filtering just can't touch.
The whole process flows like this: first, you list packages to see everything; then, you search or filter using keywords via search_packages; next, you nail down the details of a package with get_package and check specific file structures with get_resource; finally, you either use search_datastore for simple pulls or hit it hard with raw SQL in search_datastore_sql to get exactly what you need.
It's a complete data pipeline, built right into your agent.
019e38bc-342a-707f-9689-67f7bdd547e4 Here's how it actually works
The bottom line is: you get to treat government data like it's in a standard SQL database, without needing an intermediate API wrapper or manual web portal steps.
First, prompt your agent with what you need (e.g., 'Show me all health-related datasets'). The agent uses search_packages to narrow the scope.
Next, if you need specific data points, tell the agent to run an SQL query using search_datastore_sql, providing the necessary SELECT statement and table/resource name.
The system executes the call against the live Maranhão Open Data infrastructure. You get back a structured, paginated result set that your AI client can read immediately.
Who is this actually for?
This server is for professionals who deal with public policy and structured information. Think researchers who can't afford to spend days manually cross-referencing government websites, or investigative journalists needing quick access to contract data. If your job involves turning raw state documents into actionable reports, this is the tool you need.
You run search_datastore_sql queries directly on datasets (e.g., finding all spending records in a given fiscal year) instead of building complex ETL pipelines.
You use list_packages to find relevant public contract data, and then call get_resource repeatedly to pull specific supporting documents for an article.
You combine search_packages (to find 'health' packages) with get_package (to verify data scope) and then run SQL queries to track trends in social indicators over time.
What Changes When You Connect
Deep analysis happens when you use search_datastore_sql. This lets you run complex join queries on government tables, which is impossible with simple front-end searching.
You save time finding datasets. Instead of manually browsing the portal, running a search via search_packages filters hundreds of records down to the specific topic (like 'finance') you need.
The agent handles metadata checks for you. You don't have to guess if data is a PDF or a CSV; calling get_resource tells you exactly what format it is before you try to use it.
You get full transparency on the source. By using list_packages, you can quickly verify the scope of available records—from social indicators to public contracts—in one command.
It works across modalities. This server lets your agent handle structured data (via SQL) and unstructured metadata (via package/resource tools), all in the same chat session.
See it in action
Tracking public spending over time
A researcher needs to see how state spending on education changed between 2018 and 2023. They don't want to download five separate CSV files. Instead, they prompt their agent: 'Run a query joining the Spending and Year tables for column X.' The agent uses search_datastore_sql to execute the complex join and returns a single, clean table.
Verifying dataset availability
A journalist wants to write about public health initiatives but isn't sure what data exists. They run 'List all packages related to medicine.' The agent uses search_packages and returns a list like 'Leitos Hospitalares' and 'Vacinação COVID-19', immediately showing the scope of available info.
Checking for specific contract details
A policy analyst wants to find all public contracts over $50,000 awarded in Q4. They use search_datastore_sql with a precise WHERE clause on the ContractValue column. This bypasses manual searching and pulls exactly the records they need for their report.
Understanding data limitations
A developer needs to know if a dataset contains both demographic data and API endpoints. They use get_package first, which returns all metadata. Then they call get_resource on the relevant resource ID to confirm it's not just a static PDF but an active endpoint.
The honest tradeoffs
Treating everything like simple search
Asking the agent: 'What is all the data about health?' and expecting a list of facts. This fails because 'health' is too broad for basic searching.
You must use search_packages first to narrow down the category (e.g., search for 'saúde'). Once you have the package, you use get_package or run SQL on a specific resource.
Trying to filter complex relationships
Attempting to ask the agent to compare data across two different datasets (e.g., 'Compare education spending vs health spending'). Simple search tools can't join tables.
You need search_datastore_sql. You must provide a query that explicitly joins the necessary tables or resources together in one statement.
Ignoring resource type
Assuming a dataset is always CSV, and trying to process it as a flat file when it's actually an API endpoint. The job fails with formatting errors.
Always run get_resource first. This confirms the data format (CSV, JSON, etc.) and tells you which tool—simple search or SQL—to use next.
When It Fits, When It Doesn't
Use this MCP Server if your core task is querying structured public records from government portals, especially those requiring complex joins or specific metadata checks. If your goal is simple data retrieval based on a known key (e.g., 'get record ID 123'), search_datastore might suffice. However, if you need to combine multiple fields, compare trends over time, or verify the source structure, you must use search_datastore_sql. Do not use this server if your data lives in a proprietary system that isn't exposed through CKAN/SQL interfaces. The key is: If it can be queried with SQL on the Maranhão Open Data Portal, this server handles it.
Questions you might have
How do I find all available datasets on the Maranhão Open Data portal? +
Use list_packages. This tool gives you a complete manifest of every dataset package hosted. If that list is too long, try running search_packages with keywords like 'education' or 'finance'.
Is `search_datastore_sql` the right way to query data? +
Yes, search_datastore_sql is necessary for complex queries involving multiple tables (joins) or specific filtering criteria that simple searches cannot handle. It lets you write raw SQL.
What if I need metadata on a specific file? +
You use get_resource. This tool takes the resource ID and checks its type—whether it's CSV, PDF, or an API endpoint—before you try to process it.
Can I check if a package exists before querying? +
You can use get_package. This retrieves the full metadata for a dataset package. It's useful for verifying scope and ownership details before attempting a query.
What happens if I run many searches using `list_packages` or `search_datastore`? +
You might hit rate limits, especially during large data pulls. The system recommends entering your Maranhão API Key to increase your allowed query volume and keep performance stable for intensive analysis.
How do I know what columns are available before using `search_datastore`? +
You must use get_package first. This tool pulls the full metadata, which details all associated resources and lists their column names (the schema). You need that structure to write a successful query.
Besides CSV files, what other data types can I inspect using `get_resource`? +
The server handles more than just flat files. get_resource retrieves metadata for various endpoints—this includes links to API documents and PDF records—so you know exactly how to access the original source material.
If I get an error when running a query with `search_datastore_sql`, what should I check? +
First, verify your SQL syntax; that's the most common issue. Second, confirm column names and data types using get_package metadata before you execute complex queries.
How do I find datasets about a specific topic like 'education'? +
You can use the search_packages tool with a query string. For example, searching for 'educação' will return all related datasets available on the portal.
Can I query the actual content of a CSV file without downloading it? +
Yes! If the resource is in the DataStore, use search_datastore with the Resource ID to search through the rows directly.
Is it possible to perform complex filtering using SQL? +
Absolutely. Use the search_datastore_sql tool to execute standard SQL queries against any resource stored in the portal's DataStore.
We've already built the connector for Maranhão Open Data. Just plug in your AI agents and start using Vinkius.
No hosting. No infrastructure. No complex setup.
All 6 tools are live and waiting.
You're up and running in seconds.
Vinkius gives your AI agents access to the full catalog of app connectors, all fully managed, secure, and enterprise-ready. One subscription, every tool you need.
Built, hosted, and secured by Vinkius. You just connect and go.