EditalMD
EditalMD collects the public purchases of Brazil from the national procurement portal (PNCP).
Use it to find tenders, check their deadlines and prices, and read the tender documents as Markdown.
Original files are free at GET /api/documento/{id}/original. PDFs open inline; other formats download.
Processed content and requirement analysis use the paid document access.
Connect
- MCP server (preferred):
https://editalmd.com/mcp?checkout=site. Transport: Streamable HTTP. Every MCP tool is free, within its free limits: no payment. Search and records need no key. - HTTP API: base URL
https://editalmd.com. Each MCP tool calls one route of this API. - If the MCP tools are not available, call the HTTP routes with
curlor with your fetch tool. - Discovery:
GET https://editalmd.com/api/lists the routes, prices and limits.https://editalmd.com/llms-full.txthas the full reference.
MCP tools
| Tool | HTTP | Use it to | Cost |
|---|---|---|---|
consulta_cadastro |
GET /api/consulta/cadastro/{cnpj} |
Read basic company data without contacts or live analysis. | Free, no allowance consumed |
consulta_endereco |
GET /api/consulta/endereco/{cep} |
Read up to 20 addresses and 20 companies of a CEP. | Free, no allowance consumed |
buscar_licitacao |
GET /api/busca |
Find purchases by term (q) and state (uf). Set abertas to keep only open proposals. |
Free |
compra |
GET /api/compra/{id} |
Read a purchase: object, agency, value, dates and its documents. | Free |
prazos |
GET /api/compra/{id} |
Read the proposal deadline and the estimated last day to challenge (Lei 14.133, art. 164). | Free |
quem_fornece |
GET /api/compra/{id}/cnaes |
See which activities (CNAE) usually win purchases like this one. | Free |
abertas_do_ramo |
GET /api/compra/{id}/abertas |
List open tenders of the same line of business from the last 7 days. | Free |
precos_homologados |
GET /api/precos |
Get the winning price of a similar item: count, median and range. | Free summary |
atas_vigentes |
GET /api/atas |
Find valid price-registration minutes and see if they accept adhesion. | Free |
planos_de_compras |
GET /api/planos |
See what agencies plan to buy before the tender opens. | Free |
exemplos |
GET /api/exemplos |
Get five processed sample documents. | Free |
documento |
GET /api/documento/{id} |
Read the title, type and page count of a document. | Free |
estado_geracao |
GET /api/documento/{id}/geracao |
Read the progress of a document and its page count. | Free |
edital_markdown |
GET /api/documento/{id}/markdown |
Read the document as Markdown with source and hash. Send acesso_codigo. |
With access |
habilitacao |
POST /api/documento/{id}/habilitacao |
List the qualification requirements with literal excerpts. | With access |
documento_dossie |
GET /api/documento/{id}/dossie |
Read items, requirements, deadlines and obligations with page evidence. | With access |
criar_dono |
POST /api/dono |
Create the owner token edm_… for alerts and watches. You see it one time only. |
Free |
criar_alerta |
POST /api/alertas |
Create an alert for new tenders by terms and state. | First one free |
alerta_por_cnpj |
POST /api/alertas |
Create alerts from the activities of a company (CNPJ). | First one free |
alertas_compras |
GET /api/alertas/{id}/compras |
Read the tenders that matched an alert. | Free |
vigiar_compra |
POST /api/vigias |
Watch one purchase for a new document, suspension, new deadline or new value. | First one free |
vigia_eventos |
GET /api/vigias/{id}/eventos |
Read the changes of a watched purchase. | Free |
Rules
- Start with the free tools: search, purchase record, deadlines, suppliers and prices.
- Processed content needs access: one of the five samples (
exemplos), the free evaluation below, or anacesso_codigothat the person bought on the site or the HTTP API. - An
acesso_codigois private. Keep it and send it to the reading tools. With it, you open the document again at no cost. - On the HTTP API, if
POST /api/documento/{id}/geracaoreturns HTTP 202, wait for the time inRetry-After. Then readestado_geracao(GET). Do not send the POST again to check the progress. - Alerts and watches need the owner token. Create it once with
criar_donoand keep it secret. Send it as headerAuthorization: Bearer edm_…(HTTP request or MCP connection header). - If an MCP tool answers
free_limit, tell the user that the free limit for that action is used up. Never pay by yourself. On the HTTP API, a paid route returns HTTP 402: show the price and https://editalmd.com/pricing to the user. The person buys on the site. Then send the same call again with the person's prepaid credit token in the headerX-Credito: cred_…, with the sameidempotenciavalue. - Keep tokens (
cred_…,edm_…,whsec_…) and access codes secret. Do not write them in files, logs or answers unless the user asks you to save them. - The challenge deadline is an estimate: 3 business days before the session, with national holidays only. Tell the user to confirm it in the tender document.
- A missing or partial dossier does not mean that the tender has no requirements. Read its coverage fields.
- Lists return up to 20 items per page. Follow the next-page links. Do not scrape HTML pages.
- If you get HTTP 429 or 503, wait for the time in
Retry-Afterand try once more.
Free evaluation for agents
An agent can test the document service without payment: one sponsored premium document and up to 100 basic
reads, up to 50 pages each, for a limited time. The guide is https://editalmd.com/avaliacao.md.
The tools are avaliacao_cotas, avaliacao_premium and avaliacao_basico.
Paid features (site and HTTP API)
- The person buys on the site: https://editalmd.com/pricing shows the plans and the prepaid credit, with the
prices. Pay as you go has no monthly fee. Basic includes 1,000 units for R$ 97 (
pro-paginas). Professional includes 10,000 for R$ 797 (profissional-paginas). Enterprise includes 100,000 for R$ 5,997 (empresarial-paginas). Each paid plan includes requirements, deadlines, obligations, company-document comparison and processed reading. Card subscriptions renew monthly only after explicit consent. Pix, USDC and balance purchases last 30 days without renewal. Unused units expire at the end of the period. Each document can have up to 200 pages. Original PDFs remain free. - The allowance uses 1 unit per page, 25 per price report, 5 per alert and 3 per tender watch.
The first alert and watch remain free. Human services and API access packages are separate.
GET /api/plansreturnsaccount.active.usagewith total, used and remaining units. A signed-in person opens a report withPOST /api/precos/detalheand CSRF protection. The server uses allowance before prepaid credit. Reopening the same report in the period uses no more units. GET /api/pricingandestado_geracaoread the prices and the quote. They do not charge.- The HTTP API also supports CNPJ and address lookup purchases without an account through x402 v1 or v2.
The paying wallet owns the package. Its
mmw_…credential comes from/api/auth/wallet/agent/startand/api/auth/wallet/agent/token. The MCP connection above never charges. - A prepaid credit gives a
cred_…token one time only. The same token works in EditalMD, Radar CNPJ and PontoFato.
Examples
# Tenders for school uniforms in São Paulo state (free)
curl -s 'https://editalmd.com/api/busca?q=uniforme%20escolar&uf=SP'
# Purchase record with deadlines and documents (free)
curl -s https://editalmd.com/api/compra/28870493
# Winning price summary of a similar item (free)
curl -s 'https://editalmd.com/api/precos?q=papel%20A4'
Limits
-
Read procurement news. Use the free feed. Cite the article date and original sources.
-
The source is PNCP. A purchase in the data can be closed already: read
prazosbefore you act. -
The Markdown comes from the original files. Automatic review has quality indicators but does not certify that the text is identical to the original.
-
Terms: https://editalmd.com/termos. Privacy: https://editalmd.com/privacidade. Contact: contato@editalmd.com.
