# PNCP Tenders Monitor – Brazil Government Tenders & Alerts (`cairolabs/pncp-tenders-monitor`) Actor

PNCP tenders monitor for Brazil government procurement: find public tenders (licitações, pregão eletrônico, dispensa, concorrência) via PNCP's official API. Keyword, state (UF), modality, value and agency CNPJ filters. Daily 'only new' bid alerts. Pay per tender.

- **URL**: https://apify.com/cairolabs/pncp-tenders-monitor.md
- **Developed by:** [Cairo Labs](https://apify.com/cairolabs) (community)
- **Categories:** Business, Lead generation, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$8.00 / 1,000 tender returneds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

**PNCP tenders monitor** for **Brazil government tenders (licitações)**: find open public tenders – pregão eletrônico, dispensa, concorrência – published on **PNCP (Portal Nacional de Contratações Públicas)**, the official mandatory procurement portal under Lei 14.133/2021. It uses PNCP's **official public consultation API** – no login, no captcha, no browser – and can send **daily tender alerts with only new bids**.

### What does this PNCP tenders monitor do?

- 🟢 **"Open" mode**: only tenders still receiving proposals (deadline in the future) – the ones you can actually bid on.
- 📅 **"Published" mode**: everything published on PNCP in the last N days (`daysBack`).
- 🔔 **Only-new tender alerts**: schedule it daily; it remembers what it returned and you **pay only for fresh tenders**.
- 🔍 Accent/case-insensitive **keywords** (`computador` matches `COMPUTADOR`, `veiculos` matches `veículos`) + **exclude terms**.
- 📍 Filters: **state (UF)**, **modality**, **estimated value range (BRL)**, **agency CNPJ**, date window.
- 🔗 Direct **PNCP edital link** + original bidding-system link, normalized English field names.
- 🛡️ Polite rate limiting (2 req/s by default), retries with backoff on 429/5xx, partial results never lost.

### Who is it for?

B2G sales prospecting, bid alerts to Slack/email via Apify webhooks, n8n, Make or Zapier, procurement (licitação) consultancies, and market intelligence on Brazilian government demand.

### How to monitor Brazilian public tenders (step by step)

1. Choose `mode`: `open` (receiving bids now) or `published` (last N days).
2. Add your `keywords` and optional filters: states (UF), modalities, min/max value, agency CNPJ.
3. Click **Start** and check the results in the dataset (export to JSON, CSV, Excel).
4. For daily alerts, create an **Apify Schedule** with `onlyNew: true` and attach a webhook or integration.

### Input example (JSON)

```json
{ "mode": "open", "keywords": ["software", "notebook"], "excludeKeywords": ["merenda"], "states": ["SP", "MG"], "modalities": [6, 8], "minValue": 50000, "onlyNew": true, "maxItems": 500 }
```

**Modality codes:** 6 Pregão Eletrônico · 8 Dispensa · 4 Concorrência Eletrônica · 7 Pregão Presencial · 9 Inexigibilidade · 12 Credenciamento · 1 Leilão Eletrônico (default: `[6, 8]`).

| Field | Default | Notes |
|---|---|---|
| `mode` | `open` | `open` or `published` |
| `daysAhead` | 30 | Open mode: proposal deadline up to N days ahead (1–365) |
| `daysBack` | 3 | Published mode: last N days (1–365) |
| `onlyNew` / `stateKey` | `false` / `default` | Use different `stateKey` names for independent monitors |
| `maxItems` | 500 | Hard cost cap |
| `maxPagesPerQuery` | 20 | 50 items per page |
| `requestsPerSecond` / `maxRetries` | 2 / 3 | Max 5 req/s, max 6 retries |

Unknown UF codes fail the run before any API call.

### Output example (real sample)

```json
{
  "pncpId": "43052497000102-1-000433/2026",
  "object": "Contratação de serviços de locação de solução tecnológica para controle ...",
  "agency": "DEPARTAMENTO DE ESTRADAS DE RODAGEM", "agencyCnpj": "43052497000102", "sphere": "Estadual",
  "state": "SP", "city": "São Paulo", "modality": "Pregão - Eletrônico", "estimatedValueBRL": 899265.6,
  "proposalOpenAt": "...", "proposalCloseAt": "2026-10-27T10:00:00", "status": "Divulgada no PNCP",
  "pncpUrl": "https://pncp.gov.br/app/editais/43052497000102/2026/433", "sourceSystemUrl": "..."
}
```

Other fields: `additionalInfo`, `unit`, `ibgeCityCode`, `modalityCode`, `disputeMode`, `legalBasis`, `priceRegistration`, `awardedValueBRL`, `purchaseNumber`, `process`, `year`, `publishedAt`, `updatedAt`, `scrapedAt`.
Some agencies mark the estimated value as confidential → `0` or `null`. Dates are Brasília time. Run counters are saved to the `STATS` key-value record.

### How much does it cost? (Pricing)

- **$0.008 per tender returned** ($8 / 1,000 tenders), pay per event.
- Already-seen tenders in only-new mode are **free**.
- Use `maxItems` as a hard cost cap.

### FAQ

#### What is PNCP?

PNCP (Portal Nacional de Contratações Públicas) is Brazil's official national portal where federal, state and municipal agencies must publish their public tenders under Lei 14.133/2021.

#### Is it legal to use PNCP data?

Yes – PNCP data is public by law (Lei 14.133/2021 & Lei de Acesso à Informação) and served through an official open API.

#### How do I get daily tender alerts?

Create an Apify Schedule with `onlyNew: true` and attach a webhook or integration (Slack, email, n8n, Make, Zapier).

#### Can I search in English?

Filters match the original Portuguese tender text, so use Portuguese keywords (e.g. `computador`, `veiculos`). Accents and case are ignored. Output field names are in English.

#### Can I bid through this actor?

No. It finds tenders and gives you the PNCP edital link and the original bidding-system link where you submit proposals.

### Related actors

- [Brazil Company Due Diligence Report by CNPJ (KYB)](https://apify.com/cairolabs/brazil-company-due-diligence) – Receita data + CEIS/CNEP sanctions + PNCP public contracts + risk level, $0.10 per report.

***

### 🇧🇷 Monitor de Licitações PNCP – alertas de editais e pregões

Encontre **licitações abertas** (pregão eletrônico, dispensa, concorrência) publicadas no **PNCP – Portal Nacional de Contratações Públicas** e receba **alertas diários só com editais novos**.

- Filtros por **palavra-chave** (ignora acentos/maiúsculas), termos excluídos, **UF**, modalidade, **faixa de valor** e **CNPJ do órgão**.
- Modo "abertas": só editais ainda recebendo propostas.
- Agende diariamente com "somente novas" e **pague só pelo que é novo** (US$ 0,008 por edital — US$ 8 por 1.000).
- Link direto do edital no PNCP; exporte para Excel/CSV ou envie para Slack, e-mail, n8n, Make, Zapier.

Ideal para empresas que vendem para o governo, consultorias de licitação e inteligência comercial B2G.

*Actor comunitário não oficial; sem vínculo com o PNCP ou o Governo Federal.*

# Actor input Schema

## `mode` (type: `string`):

'open' = tenders still accepting proposals; 'published' = everything published in the date window.

## `keywords` (type: `array`):

Accent/case-insensitive match on the tender object, e.g. 'software', 'veiculos'. Empty = all.

## `excludeKeywords` (type: `array`):

Drop tenders containing any of these terms.

## `states` (type: `array`):

Two-letter UF codes (case-insensitive). Empty = all Brazil. Valid: AC, AL, AP, AM, BA, CE, DF, ES, GO, MA, MT, MS, MG, PA, PB, PR, PE, PI, RJ, RN, RS, RO, RR, SC, SP, SE, TO. Unknown codes fail the run before any API call.

## `modalities` (type: `array`):

PNCP codes: 6 Pregão Eletrônico, 8 Dispensa, 4 Concorrência Eletrônica, 7 Pregão Presencial, 9 Inexigibilidade, 12 Credenciamento, 1 Leilão Eletrônico.

## `minValue` (type: `integer`):

Tenders without a value are excluded when set.

## `maxValue` (type: `integer`):

Max estimated value (BRL).

## `agencyCnpj` (type: `string`):

Only tenders from this government body.

## `daysBack` (type: `integer`):

Days back (published mode).

## `daysAhead` (type: `integer`):

Proposal deadline up to N days ahead (open mode).

## `onlyNew` (type: `boolean`):

Remembers returned tenders in a named key-value store; scheduled runs return only fresh ones (and you only pay for those).

## `stateKey` (type: `string`):

Use different names for independent monitors.

## `maxItems` (type: `integer`):

Cost cap.

## `maxPagesPerQuery` (type: `integer`):

Max pages per query (50 items/page).

## `requestsPerSecond` (type: `integer`):

Polite rate limit for the public API.

## `maxRetries` (type: `integer`):

Retries.

## Actor input object example

```json
{
  "mode": "open",
  "keywords": [
    "software",
    "computador",
    "notebook"
  ],
  "states": [
    "SP"
  ],
  "modalities": [
    6,
    8
  ],
  "daysBack": 3,
  "daysAhead": 30,
  "onlyNew": false,
  "stateKey": "default",
  "maxItems": 20,
  "maxPagesPerQuery": 10,
  "requestsPerSecond": 2,
  "maxRetries": 3
}
```

# Actor output Schema

## `overview` (type: `string`):

One row per PNCP tender matching the filters: object, agency, state, city, modality, estimated value, proposal dates, status and PNCP link.

## `results` (type: `string`):

All dataset items with every field.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "keywords": [
        "software",
        "computador",
        "notebook"
    ],
    "states": [
        "SP"
    ],
    "modalities": [
        6,
        8
    ],
    "maxItems": 20,
    "maxPagesPerQuery": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("cairolabs/pncp-tenders-monitor").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "keywords": [
        "software",
        "computador",
        "notebook",
    ],
    "states": ["SP"],
    "modalities": [
        6,
        8,
    ],
    "maxItems": 20,
    "maxPagesPerQuery": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("cairolabs/pncp-tenders-monitor").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "keywords": [
    "software",
    "computador",
    "notebook"
  ],
  "states": [
    "SP"
  ],
  "modalities": [
    6,
    8
  ],
  "maxItems": 20,
  "maxPagesPerQuery": 10
}' |
apify call cairolabs/pncp-tenders-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,cairolabs/pncp-tenders-monitor"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/XNjTr3hmctCBRg6UO/builds/54dNbaaPpMtaxrdZo/openapi.json
