# Coches.net Scraper y API: precios de coches de segunda mano (`scraperseurope/coches-net-spain`) Actor

Extrae anuncios de coches.net en España: precios al contado en EUR, marca, modelo, año, kilometraje, combustible y provincia. Búsquedas paginadas y exportación JSON, CSV o Excel para comparar el mercado de vehículos usados.

- **URL**: https://apify.com/scraperseurope/coches-net-spain.md
- **Developed by:** [Scrapers Europe](https://apify.com/scraperseurope) (community)
- **Categories:** E-commerce
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.00 / 1,000 listings

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/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

## Coches.net Scraper y API de coches de segunda mano en España

Obtén anuncios reales de coches.net con precio anunciado al contado en EUR, marca, modelo, año informado por la fuente, kilómetros, combustible, potencia y provincia. Útil para comparar precios, estudiar oferta de vehículos usados y seguir cambios del mercado. Exporta JSON, CSV o Excel y conecta el actor mediante la API de Apify.

### Ejemplo

```json
{"term":"bmw","maxItems":3}
```

Para varias búsquedas, usa `{"searchTerms":["bmw","audi"],"maxPages":2}`. `searchTerms` sustituye `term`. La búsqueda es textual: coches.net puede incluir vehículos relacionados; no es un filtro exacto de marca. Se mantiene el orden de relevancia de la fuente.

### Datos y límites

Cada fila incluye `product_id`, `listing_id`, `title`, `source_url`, `price`, `currency`, `make`, `model`, `model_year`, `mileage_km`, `power_hp`, `fuel`, `province`, `region`, `has_financing`, `includes_taxes`, `offer_type` e `image_url`, además de país, página, búsqueda y fecha de extracción.

El precio se valida contra la búsqueda al contado. `has_financing` indica que el anuncio ofrece financiación, no que el precio extraído sea una cuota. Los impuestos se reflejan según la fuente. No se infieren descuentos, disponibilidad, año de matriculación ni condiciones de financiación no publicadas en el listado. No se extraen teléfonos, nombres de particulares, matrículas ni datos de contacto.

No hay un tope fijo oculto de resultados o páginas. `maxItems` limita todas las búsquedas conjuntamente; `maxPages` limita cada búsqueda. El presupuesto temporal predeterminado es 240 segundos, ajustable hasta 7200. Los límites efectivos de coches.net y el gasto de Apify siguen aplicando. Las páginas se entregan progresivamente y se eliminan duplicados.

### Estados y precio

Los resultados vacíos comprobados generan `no_results`, sin filas de cobro. Un bloqueo no se presenta como búsqueda vacía. Si falla una página posterior, se conservan las filas ya entregadas y el resumen registra la interrupción. Consulta `RUN_SUMMARY` y `DIAGNOSTICS` para revisar el resultado. Las conexiones y los proxies se recuperan automáticamente; no necesitas cookies ni configuración técnica.

USD 0.004 por anuncio real y único entregado, más consumo de plataforma a cargo del usuario. No se cobran duplicados, diagnósticos ni errores. Este candidato permanece privado; la tarifa debe verificarse y activarse al autorizar su publicación.

Herramienta independiente, sin afiliación con coches.net. No garantiza todo el inventario, disponibilidad del vehículo ni actualización permanente de cada anuncio. Utiliza los datos conforme a las condiciones de la fuente y la normativa aplicable.

# Actor input Schema

## `term` (type: `string`):

Marca, modelo o texto que buscar en los anuncios de segunda mano de coches.net.

## `searchTerms` (type: `array`):

Sustituye la búsqueda individual. Los anuncios repetidos se entregan y cobran una sola vez.

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

Sin valor no hay un tope fijo de anuncios. El límite se aplica a todas las búsquedas.

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

Sin valor se continúa hasta el final de la fuente o el presupuesto de tiempo o gasto.

## `maxRuntimeSecs` (type: `integer`):

Se conservan los anuncios anteriores si una página posterior no está disponible.

## `requestTimeoutSecs` (type: `integer`):

Tiempo máximo de espera para una solicitud a la fuente.

## Actor input object example

```json
{
  "term": "bmw",
  "maxRuntimeSecs": 240,
  "requestTimeoutSecs": 30
}
```

# Actor output Schema

## `products` (type: `string`):

No description

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

No description

## `diagnostics` (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 = {
    "term": "bmw"
};

// Run the Actor and wait for it to finish
const run = await client.actor("scraperseurope/coches-net-spain").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 = { "term": "bmw" }

# Run the Actor and wait for it to finish
run = client.actor("scraperseurope/coches-net-spain").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 '{
  "term": "bmw"
}' |
apify call scraperseurope/coches-net-spain --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scraperseurope/coches-net-spain"
        }
    }
}
```

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/UCAMhod9gzTdklPfh/builds/EtGRcNKd1yTDKXDZO/openapi.json
