# Spain Public Tenders Scraper (PLACSP) (`flets_sv/licitaciones-placsp`) Actor

Scrape Spanish public procurement tenders from PLACSP: buyer, CPV code, budget, deadline and region. Get new tenders daily as JSON for B2B lead generation.

- **URL**: https://apify.com/flets_sv/licitaciones-placsp.md
- **Developed by:** [FlEtsv](https://apify.com/flets_sv) (community)
- **Categories:** Lead generation, Business
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 85.7% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

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)

Get Spanish public procurement tenders from the official PLACSP feed as clean JSON, CSV or Excel: contracting authority, CPV codes, budget, status, deadline and region. Filter by CPV, province, amount and deadline, and receive only the tenders you have not seen yet. *Versión en español más abajo.*

***

### Use cases

- Find Spanish public tenders (PLACSP) by CPV code, region and amount before competitors do
- Lead generation for companies selling to the public sector
- Daily tender alerts and market analysis of public procurement
- Feed tender data into a CRM or an AI assistant

### English

#### What does Spain Public Tenders Scraper do?

It reads the official ATOM feed of the **Plataforma de Contratacion del Sector Publico (PLACSP)**, the Spanish government's public procurement platform, and returns one record per tender. No browser, no proxies, no API key: the data comes straight from the official syndication feed.

Use cases:

- **B2B lead generation:** find which public bodies are about to buy what you sell (construction, IT, cleaning, consulting, medical supplies).
- **Bid management:** a daily list of new tenders matching your CPV codes and region, with the deadline for submitting offers.
- **Market intelligence:** analyse budgets and buyers by CPV code, province or autonomous community.
- **Alerts:** schedule the Actor daily with `soloNuevas` to push only new tenders to Slack, email or your CRM.
- **AI agents:** feed tenders to an LLM; the optional AI summary scores how well each tender fits your company profile.

#### Input

All fields are optional. An empty input `{}` returns the 20 most recent open tenders in under a minute.

| Field | Description |
|---|---|
| `cpv` | List of CPV code prefixes (e.g. `72` for IT services, `45` for construction). |
| `provincias` / `comunidades` | Filter by province or autonomous community. |
| `importeMin` / `importeMax` | Budget range in EUR, excluding VAT. |
| `estados` | Tender status (`PUB` published, `EV` evaluation, `ADJ` awarded, `RES` resolved, `ANUL` cancelled). |
| `plazoDesde` / `plazoHasta` | Submission deadline window. |
| `soloAbiertas` | Only tenders still open for offers (default `true`). |
| `soloNuevas` | Emit only tenders not seen in previous runs (default `false`). |
| `maxResultados`, `maxPaginas` | Limits (defaults `20` and `1`). |
| `resumenIA`, `perfilEmpresa` | Optional AI summary and company-fit score. |

Example input:

```json
{
  "cpv": ["72"],
  "provincias": ["Madrid"],
  "importeMin": 50000,
  "soloNuevas": true,
  "maxResultados": 50
}
```

#### Output

Real items from a run with `{}`:

```json
{
  "id": "4051",
  "titulo": "Zonas de aparcamiento en C Pedro el Junco y Escuela de Música",
  "organoContratacion": "Alcaldía del Ayuntamiento de Astorga",
  "cpv": ["45233250", "45233330"],
  "importeSinIva": 140811.93,
  "estado": "PUB",
  "plazoPresentacion": "2026-11-19T23:59:00",
  "provincia": "León",
  "nuts": "ES413",
  "url": "https://contrataciondelestado.es/wps/poc?uri=deeplink:detalle_licitacion&idEvl=5oXLJe4NMn%2FCfVQHDepjGQ%3D%3D",
  "fechaActualizacion": "2026-10-30T19:23:30.227+01:00",
  "fuente": "Plataforma de Contratacion del Sector Publico (contrataciondelestado.es)",
  "urlOficial": "https://contrataciondelestado.es/wps/poc?uri=deeplink:detalle_licitacion&idEvl=5oXLJe4NMn%2FCfVQHDepjGQ%3D%3D"
}
```

Field names are in Spanish because the source is Spanish: `titulo` (title), `organoContratacion` (contracting authority), `importeSinIva` (budget excl. VAT), `plazoPresentacion` (offer deadline).

#### Pricing (pay per event)

You pay only for what is delivered. No monthly fee.

| Event | Price | Per 1,000 |
|---|---|---|
| Tender published (`resultado`) | $0.002 | $2.00 |
| AI summary and fit score (`resumen-ia`, optional) | $0.005 | $5.00 |

Set a maximum spend per run and the Actor stops when it is reached, keeping what it already saved.

#### Integrations (Make, Zapier, Google Sheets)

- **Make**: add the Apify module "Run an Actor" (Actor `Flets_sv/licitaciones-placsp`), paste the input JSON, chain "Get Dataset Items" and map the fields to Google Sheets, Slack, Airtable or your CRM.
- **Zapier**: the Apify app offers "Run Actor" and "Fetch Dataset Items". Add a Schedule trigger and send each row to Gmail, Slack or Notion.
- **Google Sheets**: enable the official Google Sheets integration in the Actor's Integrations tab to append every run to a sheet, or call `https://api.apify.com/v2/acts/Flets_sv~licitaciones-placsp/run-sync-get-dataset-items?format=csv` with POST and your input from Apps Script (`UrlFetchApp`).
- **API and webhooks**: start the Actor from the REST API, use Schedules for recurring runs and add a webhook to notify your system when a run finishes.

Input to paste into Make or Zapier:

```json
{"urlFeed":"https://contrataciondelestado.es/sindicacion/sindicacion_643/licitacionesPerfilesContratanteCompleto3.atom","cpv":["45"],"provincias":["Madrid"],"comunidades":["Comunidad de Madrid"],"importeMin":50000,"importeMax":5000000,"estados":["PUB","EV"],"plazoDesde":"2026-01-01","plazoHasta":"2026-12-31","maxResultados":5,"maxPaginas":1,"perfilEmpresa":"Empresa de servicios de tecnologia e informacion con experiencia en administracion publica."}
```

#### FAQ

**Is it legal to scrape PLACSP?** The Actor does not scrape web pages: it reads the official public syndication (ATOM) feed that the platform publishes for reuse. Public sector information in Spain is reusable under Law 37/2007 (transposing the EU Open Data Directive). Each record carries `fuente` and `urlOficial` so you can cite the origin. This is not legal advice.

**Does it include personal data?** Tenders are institutional records. If you reuse any personal data that appears in them, you are responsible for GDPR compliance.

**How fresh is the data?** It reflects the PLACSP feed, updated by the platform several times a day. Schedule the Actor hourly or daily.

**Can I get the tender documents (pliegos)?** No. You get the metadata and the official link `urlOficial` to the announcement.

**Why did I get fewer results than expected?** Filters are cumulative and `soloAbiertas` is on by default. Increase `maxPaginas` to read deeper into the feed.

#### Integrations

- **API:** `POST https://api.apify.com/v2/acts/flets_sv~licitaciones-placsp/runs` or the official clients for JavaScript and Python.
- **Make, Zapier, n8n, Google Sheets:** use the Apify modules; trigger on schedule and send new tenders to your CRM.
- **MCP / AI agents:** call it from Claude, ChatGPT or any MCP client through the Apify MCP server (`https://mcp.apify.com`).
- **Schedules and webhooks:** daily run + webhook on success for alerts.

```python
from apify_client import ApifyClient
client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("flets_sv/licitaciones-placsp").call(run_input={"cpv": ["72"], "soloNuevas": True})
for t in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(t["titulo"], t["importeSinIva"], t["plazoPresentacion"])
```

#### Data source and license

Plataforma de Contratacion del Sector Publico (contrataciondelestado.es), Spanish Ministry of Finance. Reuse under Law 37/2007; always cite the source. This Actor is independent and is not affiliated with or endorsed by the Spanish government.

***

### Español

#### ¿Qué hace?

Lee el feed ATOM oficial de la **Plataforma de Contratación del Sector Público (PLACSP)** y devuelve un registro por licitación: órgano de contratación, CPV, importe sin IVA, estado, plazo de presentación, provincia y enlace oficial. Sin navegador, sin proxies y sin claves.

Casos de uso: captar clientes B2B que venden al sector público, avisos diarios de licitaciones nuevas por CPV y provincia, análisis de mercado y alertas en Slack, email o CRM.

#### Input

Todos los campos son opcionales. Con `{}` devuelve las 20 licitaciones abiertas más recientes en menos de un minuto. Filtros: `cpv`, `provincias`, `comunidades`, `importeMin`, `importeMax`, `estados`, `plazoDesde`, `plazoHasta`, `soloAbiertas`, `soloNuevas` (solo lo que no viste en ejecuciones anteriores), `maxResultados`, `maxPaginas`, y `resumenIA` con `perfilEmpresa` para un resumen y una puntuación de encaje con IA.

#### Output

Ver el ejemplo real en la sección inglesa. Los nombres de campo están en español.

#### Precios (pago por evento)

| Evento | Precio | Por 1.000 |
|---|---|---|
| Licitación publicada (`resultado`) | 0,002 $ | 2,00 $ |
| Resumen con IA y encaje (`resumen-ia`, opcional) | 0,005 $ | 5,00 $ |

Solo pagas lo que se entrega. Puedes fijar un gasto máximo por ejecución.

#### Integraciones (Make, Zapier, Google Sheets)

- **Make**: añade el módulo de Apify «Run an Actor» (Actor `Flets_sv/licitaciones-placsp`), pega el input JSON y encadena «Get Dataset Items»; después mapea los campos a Google Sheets, Slack, Airtable o tu CRM.
- **Zapier**: la app de Apify ofrece «Run Actor» y «Fetch Dataset Items». Ponle un disparador de horario y envía cada fila a Gmail, Slack o Notion.
- **Google Sheets**: en la pestaña Integrations del Actor activa la integración oficial con Google Sheets para añadir cada ejecución a una hoja, o llama desde Apps Script (`UrlFetchApp`) a `https://api.apify.com/v2/acts/Flets_sv~licitaciones-placsp/run-sync-get-dataset-items?format=csv` con POST y tu input.
- **API y webhooks**: lanza el Actor por API REST, programa ejecuciones (Schedules) y avisa a tu sistema con un webhook al terminar.

Ejemplo de input para pegar en Make o Zapier:

```json
{"urlFeed":"https://contrataciondelestado.es/sindicacion/sindicacion_643/licitacionesPerfilesContratanteCompleto3.atom","cpv":["45"],"provincias":["Madrid"],"comunidades":["Comunidad de Madrid"],"importeMin":50000,"importeMax":5000000,"estados":["PUB","EV"],"plazoDesde":"2026-01-01","plazoHasta":"2026-12-31","maxResultados":5,"maxPaginas":1,"perfilEmpresa":"Empresa de servicios de tecnologia e informacion con experiencia en administracion publica."}
```

#### Preguntas frecuentes

**¿Es legal?** El Actor no hace scraping de páginas: lee el feed público de sindicación que la plataforma ofrece para su reutilización. La información del sector público es reutilizable según la Ley 37/2007. Cada registro incluye `fuente` y `urlOficial` para citar el origen. No es asesoramiento jurídico.

**¿Incluye los pliegos?** No: incluye los metadatos y el enlace oficial al anuncio.

**¿Cada cuánto se actualiza?** Con el feed de PLACSP, varias veces al día. Programa el Actor cada hora o cada día con `soloNuevas`.

#### Integración

API de Apify, Make, Zapier, n8n, Google Sheets, webhooks y agentes de IA mediante el servidor MCP de Apify (`https://mcp.apify.com`).

#### Fuente y licencia

Plataforma de Contratación del Sector Público (contrataciondelestado.es). Reutilización según la Ley 37/2007; cita siempre la fuente. Este Actor es independiente y no está afiliado al Gobierno de España.

### Ejemplos de uso / Usage examples

#### Example output (real run, 2026-11-05)

First rows returned by a real run of this Actor on 2026-11-05 (shortened columns, values truncated):

| id | titulo | organoContratacion | importeSinIva | estado | plazoPresentacion |
|---|---|---|---|---|---|
| 2536/2026 | Servicio integral de telefonía, internet y comunicaciones. | Pleno del Ayuntamiento de Viveiro | 270000 | PUB | 2026-12-03T23:59:00 |
| 2026_028_SE_PASA | Contratación del servicio de telefonía móvil y de acceso... | Gerencia de la Fundación Universidad de Valladolid | 28080 | PUB | 2026-11-18T23:59:00 |
| S-04071-2026 | Evolución y soporte a la herramienta SIGO de Gestión TI (... | Compras de la Corporación de Radio y Televisión Española... | 55745 | EV | 2026-10-21T14:00:00 |

#### Copy-paste inputs

**1. Madrid IT tenders over 50k EUR**

```json
{
  "cpv": [
    "72"
  ],
  "provincias": [
    "Madrid"
  ],
  "importeMin": 50000,
  "soloNuevas": true,
  "maxResultados": 50
}
```

**2. Open tenders in Catalonia or Andalusia**

```json
{
  "comunidades": [
    "Cataluña",
    "Andalucía"
  ],
  "soloAbiertas": true,
  "maxResultados": 100
}
```

#### Call it from your code (Apify API)

```bash
curl -X POST "https://api.apify.com/v2/acts/Flets_sv~licitaciones-placsp/run-sync-get-dataset-items?token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"cpv": ["72"], "provincias": ["Madrid"], "importeMin": 50000, "soloNuevas": true, "maxResultados": 50}'
```

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_API_TOKEN")
run = client.actor("Flets_sv/licitaciones-placsp").call(run_input={"cpv": ["72"], "provincias": ["Madrid"], "importeMin": 50000, "soloNuevas": true, "maxResultados": 50})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)
```

No code? Use the Apify modules for **Make** and **Zapier** (run the Actor, then fetch dataset items), or the **Google Sheets** integration in the Actor's Integrations tab to append each run to a sheet.

### Related Actors / Actores relacionados

Public tenders and grants family by Flets_sv / Familia de licitaciones y ayudas:

- [Spain grants and subsidies (BDNS)](https://apify.com/flets_sv/subvenciones-bdns-espana): ayudas y subvenciones de España.
- [EU tenders (TED)](https://apify.com/flets_sv/ted-eu-tenders): above-threshold tenders of all EU countries.
- [UK public tenders](https://apify.com/flets_sv/uk-public-tenders): Find a Tender and Contracts Finder.
- [France tenders (BOAMP)](https://apify.com/flets_sv/boamp-france-tenders): French marchés publics.
- [Australia government contracts (AusTender)](https://apify.com/flets_sv/austender-australia-contracts): federal contracts awarded.

# Actor input Schema

## `urlFeed` (type: `string`):

Direccion publica del feed de licitaciones.

## `cpv` (type: `array`):

Prefijos de CPV que deben coincidir con algun codigo de la licitacion.

## `provincias` (type: `array`):

Nombres de provincia que deben coincidir con la ubicacion de la licitacion.

## `comunidades` (type: `array`):

Nombres de comunidad autonoma derivados del codigo NUTS de la licitacion.

## `importeMin` (type: `number`):

Importe sin IVA minimo en euros. Se excluyen las licitaciones sin importe.

## `importeMax` (type: `number`):

Importe sin IVA maximo en euros. Se excluyen las licitaciones sin importe.

## `estados` (type: `array`):

Estados de la licitacion que se admiten.

## `plazoDesde` (type: `string`):

Fecha minima de presentacion en formato ISO (AAAA-MM-DD).

## `plazoHasta` (type: `string`):

Fecha maxima de presentacion en formato ISO (AAAA-MM-DD).

## `maxResultados` (type: `integer`):

Numero maximo de licitaciones que se recuperaran.

## `soloAbiertas` (type: `boolean`):

Si se activa, se descartan las licitaciones ya cerradas.

## `soloNuevas` (type: `boolean`):

Si se activa, solo se emiten las licitaciones nuevas o modificadas desde la ultima ejecucion.

## `diasRetencion` (type: `integer`):

Numero de dias que se conservan los identificadores vistos antes de podarlos.

## `maxPaginas` (type: `integer`):

Numero maximo de paginas del feed que se descargaran.

## `pausaMs` (type: `integer`):

Milisegundos de espera entre peticiones a la fuente.

## `resumenIA` (type: `boolean`):

Anade un resumen y un encaje 0-100 a cada licitacion. Desactivado por defecto.

## `perfilEmpresa` (type: `string`):

Descripcion libre de la empresa para calcular el encaje de cada licitacion.

## `gatewayUrl` (type: `string`):

URL base del gateway de IA; por defecto GATEWAY_URL del entorno.

## `gatewayApiKey` (type: `string`):

Clave de API del gateway de IA. Campo secreto: solo por input, nunca en el repo.

## Actor input object example

```json
{
  "urlFeed": "https://contrataciondelestado.es/sindicacion/sindicacion_643/licitacionesPerfilesContratanteCompleto3.atom",
  "cpv": [
    "45"
  ],
  "provincias": [
    "Madrid"
  ],
  "comunidades": [
    "Comunidad de Madrid"
  ],
  "importeMin": 50000,
  "importeMax": 5000000,
  "estados": [
    "PUB",
    "EV"
  ],
  "plazoDesde": "2026-01-01",
  "plazoHasta": "2026-12-31",
  "maxResultados": 5,
  "soloAbiertas": true,
  "soloNuevas": false,
  "diasRetencion": 90,
  "maxPaginas": 1,
  "pausaMs": 500,
  "resumenIA": false,
  "perfilEmpresa": "Empresa de servicios de tecnologia e informacion con experiencia en administracion publica.",
  "gatewayUrl": "",
  "gatewayApiKey": ""
}
```

# Actor output Schema

## `licitaciones` (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 = {
    "urlFeed": "https://contrataciondelestado.es/sindicacion/sindicacion_643/licitacionesPerfilesContratanteCompleto3.atom",
    "cpv": [
        "45"
    ],
    "provincias": [
        "Madrid"
    ],
    "comunidades": [
        "Comunidad de Madrid"
    ],
    "importeMin": 50000,
    "importeMax": 5000000,
    "estados": [
        "PUB",
        "EV"
    ],
    "plazoDesde": "2026-01-01",
    "plazoHasta": "2026-12-31",
    "maxResultados": 5,
    "maxPaginas": 1,
    "perfilEmpresa": "Empresa de servicios de tecnologia e informacion con experiencia en administracion publica.",
    "gatewayUrl": "",
    "gatewayApiKey": ""
};

// Run the Actor and wait for it to finish
const run = await client.actor("flets_sv/licitaciones-placsp").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 = {
    "urlFeed": "https://contrataciondelestado.es/sindicacion/sindicacion_643/licitacionesPerfilesContratanteCompleto3.atom",
    "cpv": ["45"],
    "provincias": ["Madrid"],
    "comunidades": ["Comunidad de Madrid"],
    "importeMin": 50000,
    "importeMax": 5000000,
    "estados": [
        "PUB",
        "EV",
    ],
    "plazoDesde": "2026-01-01",
    "plazoHasta": "2026-12-31",
    "maxResultados": 5,
    "maxPaginas": 1,
    "perfilEmpresa": "Empresa de servicios de tecnologia e informacion con experiencia en administracion publica.",
    "gatewayUrl": "",
    "gatewayApiKey": "",
}

# Run the Actor and wait for it to finish
run = client.actor("flets_sv/licitaciones-placsp").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 '{
  "urlFeed": "https://contrataciondelestado.es/sindicacion/sindicacion_643/licitacionesPerfilesContratanteCompleto3.atom",
  "cpv": [
    "45"
  ],
  "provincias": [
    "Madrid"
  ],
  "comunidades": [
    "Comunidad de Madrid"
  ],
  "importeMin": 50000,
  "importeMax": 5000000,
  "estados": [
    "PUB",
    "EV"
  ],
  "plazoDesde": "2026-01-01",
  "plazoHasta": "2026-12-31",
  "maxResultados": 5,
  "maxPaginas": 1,
  "perfilEmpresa": "Empresa de servicios de tecnologia e informacion con experiencia en administracion publica.",
  "gatewayUrl": "",
  "gatewayApiKey": ""
}' |
apify call flets_sv/licitaciones-placsp --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,flets_sv/licitaciones-placsp"
        }
    }
}
```

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/wSnw9gwqfueePEYPJ/builds/nyIiijHMaTsxATODJ/openapi.json
