---
title: "Extract values, parameters in a JSON body"
method: POST
path: "/v1/clusters/{id}/extract"
tags: ["clusters"]
---

# Extract values, parameters in a JSON body

`POST /v1/clusters/{id}/extract`

## Request

- Base URL: `https://api.publicwww.com`
- URL: `https://api.publicwww.com/v1/clusters/{id}/extract`
- Auth: HTTP bearer

Pulls values out of the page source of the sites in the cluster, part by part: domains [offset, offset+limit). Call again with offset = next_offset until it is null. Costs extraction points: a site found in the index costs as many points as values found, 0.1 if none; when the day's points run out the call stops early (stopped: extract_quota_exceeded). format=csv gives one row per site with X-Next-Offset and X-Points-Left headers.

## Path parameters

- `id` integer, required

## Request body

- ExtractRequest
  - `presets` string[]
  - `regex` string[]
  - `offset` integer
  - `limit` integer
  - `skip_empty` boolean
  - `format` 'json' | 'xml' | 'csv'

## Response `200`

Extracted values.

- ExtractResponse
  - `cluster` integer, required
  - `name` string
  - `size` integer
  - `offset` integer, required
  - `scanned` integer, required: Domains gone through in this call.
  - `in_index` integer
  - `with_matches` integer
  - `next_offset` integer, nullable, required: Pass as offset to continue; null when the cluster is done.
  - `regex` string[], required: Expressions applied, presets resolved, one column each.
  - `points_used` number, required
  - `points_left` integer, required
  - `stopped` 'extract_quota_exceeded' | 'time_limit'
  - `rows` object[], required
    - `domain` string, required
    - `values` array[], required: One list per expression.
      - string[]
    - `matches` integer, required

## Other responses

- `400`: The request cannot be served as asked: missing_query, unknown_format, unknown_column, format_not_available, per_page_too_large, page_too_deep, invalid_json.
- `401`: missing_key - no Authorization: Bearer header; invalid_key - the token does not name an account.
- `403`: No paid plan (plan_required).
- `404`: No such cluster on this account (cluster_not_found).
- `429`: Too many requests, or the daily search or extraction allowance is used up.

---

[API](https://skmtc.dev/publicwww/apis/publicwww-search-api.md) · [All operations](https://skmtc.dev/publicwww/apis/publicwww-search-api/llms.txt) · [OpenAPI document](https://skmtc.dev/publicwww/apis/publicwww-search-api/revisions/79d49d819de3?raw)
