# Spain Public Auctions (BOE) — Judicial & Tax Auction Feed (`jdepablos/spain-boe-auctions`) Actor

Live Spanish public auctions from the official portal (subastas.boe.es): judicial and tax auctions with auction value, appraisal, minimum bid, deposit, ISO dates and full asset details — address, cadastral reference, charges, possession status. Built for real-estate investors and AI agents.

- **URL**: https://apify.com/jdepablos/spain-boe-auctions.md
- **Developed by:** [Juan de Pablos](https://apify.com/jdepablos) (community)
- **Categories:** Real estate, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.00 / 1,000 auctions

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Spain Public Auctions (BOE) — Judicial & Tax Auctions as Clean JSON

**Every public auction in Spain, structured.** Live feed from the official Spanish auction portal (subastas.boe.es): judicial foreclosures, tax-agency and administrative auctions — with the numbers and the asset data investors actually need, one JSON record per auction.

The official portal is a search form with no API. This Actor turns it into data: **"give me every open auction in Madrid with its auction value, minimum bid, deposit, address, cadastral reference and charges."**

### What you get per auction

```json
{
  "id": "SUB-JA-2025-246146",
  "type": "JUDICIAL EN VÍA DE APREMIO",
  "startsAt": "2025-04-18T18:00:00+02:00",
  "endsAt": "2026-07-05T12:27:24+02:00",
  "claimedAmountEur": 6953.30,
  "auctionValueEur": 325095.43,
  "appraisalValueEur": 325095.43,
  "minBidEur": null,
  "bidIncrementEur": 6501.90,
  "depositEur": 16254.77,
  "boeAnnouncement": "BOE-B-2025-13955",
  "url": "https://subastas.boe.es/detalleSubasta.php?idSub=SUB-JA-2025-246146",
  "assets": [
    {
      "description": "VIVIENDA SITA EN C/DEL BARCO Nº27 4ºB MADRID 28004 57 M",
      "cadastralRef": "28108000205725",
      "address": "C/BARCO Nº27 4ºB",
      "postalCode": "28004",
      "city": "MADRID",
      "province": "Madrid",
      "possessionStatus": "No consta",
      "visitable": "No",
      "charges": "SIN CARGAS",
      "registryInfo": "FINCA 2213 REGISTRO DE LA PROPIEDAD Nº27 MADRID"
    }
  ]
}
```

### Market comparison built in (v0.2)

Real-estate auctions are enriched with **live market stats for the asset's own city** (source: fotocasa listings):

```json
"marketComparison": {
  "source": "fotocasa",
  "zoneSlug": "getafe",
  "sampleSize": 31,
  "medianAskingEur": 299000,
  "medianPerM2Eur": 3333,
  "assetSurfaceM2": 75,
  "estMarketValueEur": 249975,
  "estDiscountPct": 34.2
}
```

`estDiscountPct` is the number every auction investor computes by hand: auction value vs what the zone actually asks per m². Note: zone stats come from a first-page sample of asking prices — treat them as a screening signal, then verify. Disable with `compareMarket: false`.

### Why investors use it

- **The spread is visible**: auction value vs appraisal vs minimum bid — the discount math is one subtraction away.
- **Cadastral reference included**: join against Catastro data, comparables or your own models.
- **Charges and possession status**: the two fields that turn a "bargain" into a money pit — surfaced, not buried in a PDF.
- **ISO dates**: bidding deadlines you can sort, filter and alert on.
- **Official source**: the State's own auction portal, every record with its BOE announcement id.

### Use cases

- **Real-estate investors**: daily sweep of open auctions in your provinces, filtered by value band.
- **Proptech / data teams**: structured feed to enrich with Catastro, idealista comps or your AVM.
- **Lawyers / insolvency pros**: track auctions tied to specific proceedings.
- **AI agents**: "find me flats at auction in Madrid under 200k ending this month" — one tool call.

### Input

| Field | Description |
|---|---|
| `status` | `EJ` in progress (default) · `PU` upcoming · `CO` concluded |
| `provinces` | Names or INE codes: `["Madrid", "08"]` — empty for all of Spain |
| `maxAuctions` | Cap per run (default 50) |
| `includeAssets` | Fetch per-auction asset details (default true) |
| `minAuctionValue` / `maxAuctionValue` | Value band filter (EUR) |

### Use with AI agents (MCP)

This Actor is exposed as a tool on the [Apify MCP Server](https://mcp.apify.com):

```json
{
  "mcpServers": {
    "spain-boe-auctions": {
      "url": "https://mcp.apify.com?tools=jdepablos/spain-boe-auctions",
      "headers": { "Authorization": "Bearer <APIFY_TOKEN>" }
    }
  }
}
```

Pairs well with [Spanish Company Feed (BORME)](https://apify.com/jdepablos/borme-company-feed) — same official-source discipline, company events instead of auctions.

### Pricing

Pay per event: **one flat fee per auction returned**, asset details included. Failed fetches are never charged.

### FAQ

**How fresh is the data?** It is scraped live from the official portal at run time — auctions open and close daily; run it on a schedule for monitoring.

**Vehicles and other assets too?** Yes — the portal covers real estate, vehicles and other seized assets. Asset fields adapt (plate/brand/model for vehicles).

**Why is `minBidEur` sometimes null?** "Sin puja mínima" — the auction has no minimum bid, which is exactly the kind you may care about.

### More data tools by this developer

- [eBay Sold Price Appraiser — real market value from confirmed sales](https://apify.com/jdepablos/ebay-sold-price-appraiser)
- [Second-hand Deal Scanner ES — Vinted/Wallapop/Milanuncios deals vs eBay sold](https://apify.com/jdepablos/second-hand-deal-scanner-es)
- [Spanish Company Feed (BORME) — daily registry acts as JSON](https://apify.com/jdepablos/borme-company-feed)
- [Trademark Watch (TMview) — new filings & opposition deadlines](https://apify.com/jdepablos/trademark-watch-tmview)

# Actor input Schema

## `status` (type: `string`):

EJ = in progress (bidding open), PU = upcoming, CO = concluded.

## `provinces` (type: `array`):

Spanish province names or two-digit INE codes, e.g. \["Madrid", "Barcelona"] or \["28", "08"]. Empty = all of Spain.

## `maxAuctions` (type: `integer`):

Stop after this many auctions.

## `includeAssets` (type: `boolean`):

Fetch the assets tab per auction: description, address, cadastral reference, charges, possession status (one extra request per auction).

## `minAuctionValue` (type: `integer`):

Skip auctions below this value.

## `maxAuctionValue` (type: `integer`):

Skip auctions above this value.

## `compareMarket` (type: `boolean`):

Enrich real-estate auctions with zone market stats from fotocasa (median asking price, EUR/m2) and estimated discount vs market. One extra request per distinct city.

## Actor input object example

```json
{
  "status": "EJ",
  "provinces": [
    "Madrid"
  ],
  "maxAuctions": 50,
  "includeAssets": true,
  "compareMarket": true
}
```

# 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 = {
    "provinces": [
        "Madrid"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("jdepablos/spain-boe-auctions").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 = { "provinces": ["Madrid"] }

# Run the Actor and wait for it to finish
run = client.actor("jdepablos/spain-boe-auctions").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "provinces": [
    "Madrid"
  ]
}' |
apify call jdepablos/spain-boe-auctions --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=jdepablos/spain-boe-auctions",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/a2QnLQOfcRgsnhsRe/builds/IaOYfawVIfxD5z58x/openapi.json
