# DBA Scraper: Denmark Marketplace Listings (`reventadata/dba-scraper`) Actor

Scrape DBA.dk, the Danish second-hand marketplace, by search term. Title, price in DKK, location with coordinates, posting time, seller type, shipping and buy-now flags, brand and photos. Unofficial.

- **URL**: https://apify.com/reventadata/dba-scraper.md
- **Developed by:** [reventadata](https://apify.com/reventadata) (community)
- **Categories:** E-commerce, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 results

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

## DBA Scraper: Denmark's Classifieds Marketplace

> **Unofficial.** This Actor is not affiliated with, authorised by, endorsed by, or in any
> way officially connected to DBA (dba.dk) or Vend Marketplaces ApS / Vend Marketplaces ASA.
> "DBA" and "Den Blå Avis" are trademarks of their respective owners and are used here only to describe
> what this tool reads. It reads the same public data a browser does.

DBA Scraper extracts structured listing data from dba.dk, Denmark's largest second-hand marketplace (Den Blå Avis, Markedspladsen).

### What does it do?

- Searches DBA marketplace listings by keyword query (`searchQueries`).
- Extracts title, price in DKK, locality, coordinates, seller type (private vs dealer), shop/dealer name, brand, shipping and buy-now flags, labels, image URLs, and posting timestamps.
- Filters by price range (`minPrice` / `maxPrice`) directly on the site.

Cars and mobility verticals are out of scope for this Actor.

### Why use it?

- **Clean structured data:** asking price, currency, latitude/longitude, and seller classification are parsed into clean dataset columns.
- **Site-side price filters:** `minPrice` and `maxPrice` are applied by the site, so only matching listings are fetched.
- **Public data only:** extracts public listing metadata. Private sellers remain anonymous on DBA; rows contain business names only for registered dealers and shops.

### How to use it

1. Add search terms to `searchQueries` (e.g. `["iphone"]`).
2. Optionally specify price filters (`minPrice`, `maxPrice`) in DKK.
3. Configure `maxItems` and `maxPages` (up to the site ceiling of 50 pages / ~2,650 items per query).
4. Run the Actor and export dataset results to JSON, CSV, or Excel.

#### Input

| Field | Type | Description |
|---|---|---|
| `searchQueries` | array | List of search queries or keywords to search on dba.dk. Required. |
| `maxItems` | integer | Maximum number of items/records to push to the dataset. Default 100, prefill 10. |
| `maxPages` | integer | Maximum number of pagination pages to scrape per keyword (ceiling is 50 pages). Default 50, prefill 1. |
| `minPrice` | integer | Minimum asking price in DKK (maps to `price_from`). |
| `maxPrice` | integer | Maximum asking price in DKK (maps to `price_to`). |
| `requireKeywordMatch` | boolean | Default true: drops ads whose visible fields (title, brand) do not contain the query. |
| `shippingOnly` | boolean | Default false: only keeps listings that offer shipping (`shipping_exists` flag). |
| `proxyConfiguration` | object | Optional proxy settings. Direct connection works cleanly by default. |

#### Sample Input

```json
{
    "searchQueries": ["iphone"],
    "maxPrice": 5000,
    "maxItems": 10,
    "maxPages": 1
}
```

#### Output

Every row in the dataset contains:

- `id`: unique DBA listing ID
- `title`: listing heading
- `url`: canonical URL on dba.dk
- `price`: asking price in DKK (or null; 0 for give-away listings)
- `currency`: DKK
- `location`: town or city name
- `postedAt`: ISO 8601 UTC timestamp
- `latitude` / `longitude`: geolocation coordinates
- `imageUrls`: list of image links
- `organisationName`: business name for dealers; null for private sellers
- `sellerType`: 'private' or 'dealer'
- `shippingAvailable`: boolean
- `buyNow`: boolean
- `labels`: site badge labels (e.g. `Privat`, `Fiks færdig`)
- `brand`: brand name if provided
- `tradeType`: ad type as the site words it (e.g. `Til salg`)
- `matchedKeyword`: keyword query that returned this item
- `scrapedAt`: ISO 8601 UTC timestamp of extraction

#### Sample Output

One row from a real platform run on 2026-11-11 (search `iphone`; `imageUrls` shortened to 2 items):

```json
{
  "id": "26648537",
  "title": "iPhone 17 256GB i sort",
  "url": "https://www.dba.dk/recommerce/forsale/item/26648537",
  "price": 6000,
  "currency": "DKK",
  "location": "Ribe",
  "postedAt": "2026-11-11T02:28:20+00:00",
  "latitude": 55.30372,
  "longitude": 8.7771,
  "imageUrls": [
    "https://images.dbastatic.dk/dynamic/default/item/26648537/81ae94dd-f90e-42ac-95e2-f3718a605bbe"
  ],
  "organisationName": null,
  "sellerType": "private",
  "shippingAvailable": false,
  "buyNow": false,
  "labels": [
    "Privat"
  ],
  "brand": "Apple",
  "tradeType": "Til salg",
  "matchedKeyword": "iphone",
  "scrapedAt": "2026-11-11T06:38:41.843853+00:00"
}
```

### Pricing

The current price is on the Actor's Pricing tab.

### Privacy & Compliance

This Actor reads only publicly accessible search results and returns the public data they show. It sends no login. DBA terms ask for express permission for automated access; you are responsible for how you use the data and for complying with the site's terms and applicable law.

# Actor input Schema

## `searchQueries` (type: `array`):

List of search queries or keywords to search on dba.dk (Markedspladsen). Required.

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

Maximum number of items/records to push to the dataset across all queries.

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

Maximum number of pagination pages to scrape per keyword (ceiling is 50 pages / ~2,650 items).

## `minPrice` (type: `integer`):

Filter by minimum asking price in DKK (maps to price_from).

## `maxPrice` (type: `integer`):

Filter by maximum asking price in DKK (maps to price_to).

## `requireKeywordMatch` (type: `boolean`):

When true, drops ads whose visible fields (title, brand) do not contain the query.

## `shippingOnly` (type: `boolean`):

When true, only keeps listings that offer shipping (shipping_exists flag).

## `proxyConfiguration` (type: `object`):

Proxy settings for the Actor. Configure Apify Proxy or custom proxies if needed (direct works cleanly by default).

## Actor input object example

```json
{
  "searchQueries": [
    "iphone"
  ],
  "maxItems": 10,
  "maxPages": 1,
  "requireKeywordMatch": true,
  "shippingOnly": false,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `dataset` (type: `string`):

Items scraped from the target website.

# 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 = {
    "searchQueries": [
        "iphone"
    ],
    "maxItems": 10,
    "maxPages": 1
};

// Run the Actor and wait for it to finish
const run = await client.actor("reventadata/dba-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 = {
    "searchQueries": ["iphone"],
    "maxItems": 10,
    "maxPages": 1,
}

# Run the Actor and wait for it to finish
run = client.actor("reventadata/dba-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 '{
  "searchQueries": [
    "iphone"
  ],
  "maxItems": 10,
  "maxPages": 1
}' |
apify call reventadata/dba-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,reventadata/dba-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/ndxtbsfSDBQwsrnjr/builds/mvtpewoiAEcDLKLZk/openapi.json
