# Spain Public Tenders Scraper – PLACSP Licitaciones (`fluyeporlaweb/spain-public-tenders-scraper`) Actor

Scrape Spain's public tenders (PLACSP, Plataforma de Contratación del Sector Público): budget, CPV, deadline, buyer, status. Filter by keyword, CPV, region.

- **URL**: https://apify.com/fluyeporlaweb/spain-public-tenders-scraper.md
- **Developed by:** [Pablo Navarro](https://apify.com/fluyeporlaweb) (community)
- **Categories:** Lead generation, Automation, AI
- **Stats:** 2 total users, 1 monthly users, 33.3% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 tenders

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

## Spain Public Tenders Scraper – PLACSP Licitaciones

**Spain public tenders scraper** (*licitaciones públicas*) built on the official open-data ATOM feed of the **Plataforma de Contratación del Sector Público (PLACSP)**. It turns the complex CODICE XML into flat JSON: title, buyer, budget, CPV codes, submission deadline, status and a link to the tender. No login, no browser, no proxies.

### What does it do?

- Reads the newest tender updates, newest first, and follows the feed's pagination.
- Filters by **keywords**, **CPV prefix**, **status** (open, awarded…), **region/city** and **minimum budget**.
- Keeps one record per tender (its latest update).
- Excludes contact phones and emails. It returns only tender data.

### Use cases

- **Tender alerts for SMEs and freelancers**: get new open tenders in your CPV codes every morning.
- **Bid consultants and agencies**: build lead lists of public opportunities.
- **Market intelligence**: see which public bodies buy what, and for how much.
- **AI agents**: let an LLM triage and summarise tenders for you.
- **Telegram and X bots**: post new tenders by sector or region.

### Input

| Field | Description |
|---|---|
| `keywords` | Keep tenders whose title contains any keyword (Spanish). Example: software, limpieza, consultoría |
| `cpvPrefixes` | Keep tenders with a CPV code starting with any prefix. Example: 72 (IT services), 45 (construction), 79 (business services) |
| `statuses` | PRE (prior notice), PUB (open), EV (evaluation), ADJ (awarded), RES (resolved), ANUL (cancelled). Example: PUB |
| `regions` | Text contained in region, city or NUTS code. Example: Madrid, ES51 |
| `minBudgetEur` | Example: 50000 |
| `maxPages` | Each page holds about 70 latest updates, newest first. Example: 10 |
| `maxItems` | 0 = no limit. Example: 200 |

Example input:

```json
{
  "maxPages": 3,
  "statuses": [
    "PUB"
  ],
  "maxItems": 25
}
```

### Output

Real output (first items of a run on 26 Oct 2026):

```json
[
  {
    "id": "CS/99/1126059886/26/AM",
    "title": "Acuerdo marco con un único proveedor para el suministro de gases medicinales y otros gases con destino a los centros dependientes del Servicio Extremeño de Salud.",
    "status": "Open (published)",
    "statusCode": "PUB",
    "contractType": "Supplies",
    "contractingBody": "Dirección General de Planificación Económica",
    "city": "Mérida",
    "nuts": "ES43",
    "region": "Extremadura",
    "budgetWithoutTaxEur": 16453046.85,
    "budgetWithTaxEur": 17833875.17,
    "estimatedValueEur": 19743656.22,
    "cpv": [
      "24100000",
      "24111300",
      "24112200",
      "24111900",
      "24113000",
      "24111500",
      "24112100",
      "24111800"
    ],
    "deadline": "2026-11-23 23:59:00",
    "updatedAt": "2026-10-25T19:51:07.199+01:00",
    "url": "https://contrataciondelestado.es/wps/poc?uri=deeplink:detalle_licitacion&idEvl=Nygmf3UkegrXOjazN1Dw9Q%3D%3D"
  },
  {
    "id": "5/2026",
    "title": "Pavimentación de varias callejas en Peroblasco",
    "status": "Open (published)",
    "statusCode": "PUB",
    "contractType": "Works",
    "contractingBody": "Alcaldía del Ayuntamiento de Munilla",
    "city": "Munilla",
    "nuts": "ES230",
    "region": "La Rioja",
    "budgetWithoutTaxEur": 41322.31,
    "budgetWithTaxEur": 50000.0,
    "estimatedValueEur": 41322.31,
    "cpv": [
      "45233252",
      "45232410",
      "45232150"
    ],
    "deadline": "2026-11-06 23:59:00",
    "updatedAt": "2026-10-25T19:41:52.817+01:00",
    "url": "https://contrataciondelestado.es/wps/poc?uri=deeplink:detalle_licitacion&idEvl=5a%2FQilm%2BBmc2wEhQbcAqug%3D%3D"
  }
]
```

Export the results as JSON, CSV or Excel, read them through the API, or send them to Google Sheets, Make, Zapier, n8n or webhooks. You can also run this Actor from AI agents through the Apify MCP server.

### Pricing

Pay per event: **$3.00 per 1,000 tenders** plus $0.00005 per run start. There is no extra platform usage charge.

### FAQ

**Which tenders are included?** All tenders published in PLACSP's profiles (*perfiles del contratante*). Some regions publish on their own platforms too.

**How far back can I go?** Each page holds about 70 updates. Raise `maxPages` to go further back.

**Are prices with VAT?** Both are given: `budgetWithoutTaxEur` and `budgetWithTaxEur`.

**Do I need a login or API key?** No. It uses the source's public API; you only need an Apify account.

**Can AI agents use it?** Yes. Call it through the Apify API, or from Claude, Cursor or any MCP client via the Apify MCP server.

### Data source and license

Source: [PLACSP open data](https://contrataciondelestado.es/wps/portal/DatosAbiertos) (Ministerio de Hacienda), reused under the [Ministry's reuse conditions](https://www.hacienda.gob.es/es-ES/Paginas/AvisoLegal.aspx): "Las presentes condiciones generales permiten la reutilización de los documentos sometidos a ellas para fines comerciales y no comerciales." Under those conditions you must cite the source and must not alter the content or its meaning.

This Actor is not affiliated with or endorsed by the data source. You are responsible for using the data in line with the source's license and terms.

# Actor input Schema

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

Keep tenders whose title contains any keyword (Spanish). Example: software, limpieza, consultoría

## `cpvPrefixes` (type: `array`):

Keep tenders with a CPV code starting with any prefix. Example: 72 (IT services), 45 (construction), 79 (business services)

## `statuses` (type: `array`):

PRE (prior notice), PUB (open), EV (evaluation), ADJ (awarded), RES (resolved), ANUL (cancelled). Example: PUB

## `regions` (type: `array`):

Text contained in region, city or NUTS code. Example: Madrid, ES51

## `minBudgetEur` (type: `integer`):

Example: 50000

## `maxPages` (type: `integer`):

Each page holds about 70 latest updates, newest first. Example: 10

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

Default 50 (fast run). 0 = no limit. Example: 200

## Actor input object example

```json
{
  "keywords": [
    "servicio"
  ],
  "maxPages": 3,
  "maxItems": 50
}
```

# Actor output Schema

## `items` (type: `string`):

No description

## `summary` (type: `string`):

No description

# 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": [
        "servicio"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("fluyeporlaweb/spain-public-tenders-scraper").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": ["servicio"] }

# Run the Actor and wait for it to finish
run = client.actor("fluyeporlaweb/spain-public-tenders-scraper").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": [
    "servicio"
  ]
}' |
apify call fluyeporlaweb/spain-public-tenders-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,fluyeporlaweb/spain-public-tenders-scraper"
        }
    }
}
```

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/MpfDhLufhOyf1dMUb/builds/6jwRDxEqTH7GJ8CYZ/openapi.json
