Skip to main content

Gov Archive

This guide shows you how to search government records about a business using Gov Archive. You can query permits, violations, filings, licenses, and other regulatory records from 7,000+ federal, state, and municipal datasets — through an AI assistant, a custom agent, or directly via API.

Prerequisites

  • An Enigma account
  • An active subscription to the Max plan or an Enterprise plan

That's all you need to get started with an AI assistant such as Claude, ChatGPT, or Gemini CLI. Custom agents and direct API access require an Enigma API key, available in the Console settings menu.

How to Search Government Records with an AI Assistant

If Enigma is already connected to your AI assistant, Gov Archive is available immediately through the search_gov_archive tool. No additional setup is required.

If you haven't connected Enigma yet, setup takes about a minute. For Claude, the steps are:

  1. In Claude, open Settings > Connectors > Add custom connector
  2. Enter Enigma as the name and https://mcp.enigma.com/http as the Remote MCP Server URL
  3. Click Connect and log in with your Enigma credentials

For other platforms, follow the setup guide: ChatGPT | Cursor | MS Copilot | VS Code | Claude Code | Gemini CLI

Once connected, ask your AI to search government records for a specific business:

Search government records for "Tacombi" and summarize any
permits, violations, or regulatory filings.
What government licenses does ABC Trucking LLC hold in Texas?
Are there any OSHA violations or environmental compliance issues?

Your AI calls search_gov_archive, interprets the results, and presents a summary with source citations. To go deeper in the same conversation, combine Gov Archive with other Enigma tools — use search_business for financial data, search_negative_news for adverse media, or search_kyb for identity verification.

How to Build a Custom Agent with Gov Archive

If you want to integrate Gov Archive into an automated workflow, connect to Enigma's MCP server from any agent framework. This requires an Enigma API key (available in the Console settings menu). Here is an example using the OpenAI Agents SDK:

import asyncio
from agents import Agent, Runner
from agents.mcp import MCPServerStreamableHttp

async def main():
async with MCPServerStreamableHttp(
params={
"url": "https://mcp.enigma.com/http-key",
"headers": {"x-api-key": "your_api_key"}
}
) as server:
await server.connect()

agent = Agent(
name="Due Diligence Agent",
instructions=(
"You are a compliance research agent. "
"Use search_gov_archive to find government records about businesses. "
"Cite the source agency, dataset, and date for every finding."
),
mcp_servers=[server]
)

result = await Runner.run(
starting_agent=agent,
input="Search government records for ABC Trucking LLC in Texas. "
"Look for any permits, violations, or liens."
)
print(result.final_output)

asyncio.run(main())

To adapt this for LangChain, CrewAI, or AutoGen, see the AI agent frameworks guide.

How to Call Gov Archive Directly via API

If you want to call Gov Archive without an agent framework, send a JSON-RPC request to the MCP HTTP endpoint:

curl --request POST 'https://mcp.enigma.com/http-key' \
--header 'x-api-key: <YOUR_API_KEY>' \
--header 'Content-Type: application/json' \
--data '{
"jsonrpc": "2.0",
"id": "1",
"method": "tools/call",
"params": {
"name": "search_gov_archive",
"arguments": {
"query": "ABC Trucking LLC Texas",
"page": 1,
"historical_data": false
}
}
}'

Parameters:

ParameterTypeDefaultDescription
querystringSearch string applied across business name and address fields
pageinteger1Page number for pagination (each page returns ~250-300 records)
historical_databooleanfalseInclude historical or archived records

How to Read the Response

The direct API returns a JSON-RPC response. The results are in result.content[0].text, which is a JSON string you need to parse:

{
"jsonrpc": "2.0",
"id": "1",
"result": {
"content": [
{
"type": "text",
"text": "{\"hits\": [...]}"
}
]
}
}

Each hit in the parsed hits array contains two objects:

dataset_info — metadata about the source:

  • dataset_title — human-readable name (e.g., "Business Licenses", "Food Inspections")
  • dataset_organization — the publishing government agency (e.g., "City of San Francisco")
  • last_updated_at — Unix timestamp of the dataset's most recent update

matched_row_info — the matched record:

  • business_name — primary business name as it appears in the government record
  • business_name_2 — secondary or alternate business name, when available
  • street_address, city, state, zip_code — location fields
  • phone_number — when available in the source record
  • row_details — the full record with all dataset-specific fields (JSON object)
tip

The row_details field contains the complete original government record. Its structure varies by dataset type — a health inspection record includes violation descriptions and inspection dates, while a UCC lien record includes secured party details and filing numbers.

note

When using Gov Archive through an AI assistant or agent framework, the response parsing is handled automatically — you only need to work with the raw JSON-RPC structure when calling the API directly.

Available Record Types

CategoryExamples
Business registrationsSecretary of State filings, DBA registrations
Permits and licensesLiquor, cannabis, professional licenses, business permits
Health and safetyFood safety inspections, health code violations, building code violations
Court filings and liensUCC liens, bankruptcy filings, active litigation
Environmental complianceEPA records, Clean Air Tracking System, brownfield/site remediation
Workplace safetyOSHA violations, citations, worker fatality records
Government contractsUSA Spending data, vendor payment records
Financial incentivesState economic incentive programs, tax credits

Rate Limits

PlanDaily LimitMonthly Limit
Pro500 calls6,000 calls
Max500 calls6,000 calls
EnterpriseConfigurableConfigurable

For full details across all Enigma tools, see Rate Limits.

Next Steps