Tollkit Extraction API
The Extraction API from Tollkit — 3 operation(s) for extraction.
The Extraction API from Tollkit — 3 operation(s) for extraction.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/tollkit-dev:tollkit-dev-extraction-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Tollkit Dev Extraction API
version: 0.39.0
contact:
email: hello@tollkit.dev
x-guidance: 'Give POST /extract the URL of ONE product page and it returns schema.org/Product JSON — name, brand, sku, price, currency, availability, images, variants. The page is rendered in a real headless browser and the store''s own schema.org data is read before anything is inferred, so JavaScript-built pages work and sku/variants come from the source. Every response carries a `provenance` object saying which fields the merchant declared and which the model inferred, so you can tell a published price from a read one. Use POST /extract/batch when you have more than one URL: up to 5 for one flat payment and one round trip, which is the usual case when comparing a product across stores. GET /preview is free and returns a real extraction of a fixed sample page, so you can judge output quality before spending anything. Failed extractions are never charged. A URL that redirects to what looks like a different page is refused free rather than answered with the wrong product; pass allow_redirect to override. Cached answers say so and carry the original render timestamp.'
description: 'Operations tagged Extraction across 2 of this provider''s published API definitions: tollkit-dev-api-openapi.json, tollkit-dev-extract-openapi.json. Each path carries the servers of the definition it was published in.'
servers:
- url: https://extract.tollkit.dev
tags:
- name: Extraction
paths:
/extract:
post:
operationId: extractProduct
summary: Extract structured Product data from one product page URL
description: 'Product details from one product page URL: price, currency, stock, name, brand, SKU/GTIN, images and variants as schema.org/Product JSON, with which fields the store itself published. $0.01 per call; a page it cannot read is not charged.'
tags:
- Extraction
x-payment-info:
price:
mode: fixed
currency: USD
amount: '0.010000'
protocols:
- x402: {}
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- url
properties:
url:
type: string
format: uri
description: Absolute https:// URL of ONE product page. Not a search or category page, not a login-gated page, and not a private address.
allow_redirect:
type: boolean
default: false
description: By default a URL that redirects to what looks like a different page (a discontinued item bouncing to its category listing) is refused free of charge rather than answered with the wrong product.
responses:
'200':
description: Successful response
content:
application/json:
schema:
$schema: https://json-schema.org/draft/2020-12/schema
type: object
description: schema.org/Product extracted from the rendered page. Fields the page does not state come back null rather than guessed.
required:
- product
- page
properties:
product:
type: object
properties:
name:
type:
- string
- 'null'
description:
type:
- string
- 'null'
brand:
type:
- string
- 'null'
sku:
type:
- string
- 'null'
price:
type:
- number
- 'null'
description: Numeric, no symbol or separators.
currency:
type:
- string
- 'null'
description: ISO 4217. Null whenever price is null.
availability:
type: string
enum:
- in_stock
- out_of_stock
- preorder
- unknown
images:
type: array
items:
type: string
description: Up to 5 absolute URLs copied from the page. Never invented.
variants:
type: array
items:
type: object
properties:
name:
type: string
values:
type: array
items:
type: string
url:
type: string
page:
type: object
properties:
url:
type: string
finalUrl:
type: string
title:
type:
- string
- 'null'
status:
type: integer
fetchedAt:
type: string
description: ISO timestamp of the RENDER, not of this call. Older than now on a cached result.
render_ms:
type: integer
cached:
type: boolean
description: True when re-served from a recent render. Still a paid call, and the data is as old as cache_age_seconds says.
cache_age_seconds:
type: integer
provenance:
type: object
description: Where each field came from. `declared` fields match what the merchant published in schema.org JSON-LD or Open Graph tags — their own number, the one they stand behind. `inferred` fields were read off the page by a model and deserve less trust. Fields that came back null appear in neither list. Use this to decide which values you can act on directly and which are worth a second look.
properties:
source:
type: string
enum:
- json-ld
- meta
- json-ld+meta
- none
declared:
type: array
items:
type: string
inferred:
type: array
items:
type: string
redirect:
type: object
description: Present only when the browser landed somewhere other than the requested URL.
properties:
requested:
type: string
final:
type: string
'400':
description: 'Bad input: a missing or malformed field, or a URL that is not public. Not charged.'
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'402':
description: Payment Required. The PAYMENT-REQUIRED header carries the x402 v2 quote (price, asset, network, payTo) for each network accepted. Pay and retry with PAYMENT-SIGNATURE.
'422':
description: Valid input the tool could not answer, e.g. an empty page, a token with no pool, an unknown ticker. Not charged.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'429':
description: Too many requests from this caller; retry after a short wait. Not charged.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'502':
description: An upstream source (the page, a chain RPC, a public data API) failed or timed out. Not charged; safe to retry.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'503':
description: The tool is temporarily unavailable on this deployment. Not charged.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
servers:
- url: https://extract.tollkit.dev
/extract/batch:
post:
operationId: extractProducts
summary: Extract up to 5 product pages in one call and one payment
description: The same product extraction for up to 5 product pages in one call and one payment, for price comparison across stores. $0.04 flat; if every URL fails you are not charged.
tags:
- Extraction
x-payment-info:
price:
mode: fixed
currency: USD
amount: '0.040000'
protocols:
- x402: {}
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- urls
properties:
urls:
type: array
maxItems: 5
items:
type: string
format: uri
description: Up to 5 absolute https:// product page URLs. Duplicates are removed and not billed twice.
allow_redirect:
type: boolean
default: false
responses:
'200':
description: Successful response
content:
application/json:
schema:
$schema: https://json-schema.org/draft/2020-12/schema
type: object
description: 'One entry per URL, in the order given. BILLING: flat price for the whole batch, so a batch where only some URLs succeed is charged in full. A batch where NO url succeeds returns 502 and is not charged.'
required:
- requested
- succeeded
- failed
- results
properties:
requested:
type: integer
succeeded:
type: integer
failed:
type: integer
billing:
type: string
description: The billing rule, restated per response.
results:
type: array
items:
type: object
required:
- url
- ok
properties:
url:
type: string
ok:
type: boolean
product:
type:
- object
- 'null'
description: As POST /extract. Present when ok.
page:
type:
- object
- 'null'
provenance:
type:
- object
- 'null'
description: 'Per-URL: which fields the merchant declared vs the model inferred.'
cached:
type: boolean
cache_age_seconds:
type: integer
error:
type: string
description: Present when ok is false.
message:
type: string
'400':
description: 'Bad input: a missing or malformed field, or a URL that is not public. Not charged.'
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'402':
description: Payment Required. The PAYMENT-REQUIRED header carries the x402 v2 quote (price, asset, network, payTo) for each network accepted. Pay and retry with PAYMENT-SIGNATURE.
'422':
description: Valid input the tool could not answer, e.g. an empty page, a token with no pool, an unknown ticker. Not charged.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'429':
description: Too many requests from this caller; retry after a short wait. Not charged.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'502':
description: An upstream source (the page, a chain RPC, a public data API) failed or timed out. Not charged; safe to retry.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
'503':
description: The tool is temporarily unavailable on this deployment. Not charged.
content:
application/json:
schema:
type: object
required:
- error
- message
- charged
properties:
error:
type: string
description: Machine-readable code, e.g. invalid_url, no_pool, page_fetch_failed.
message:
type: string
description: Plain-English reason, ending in "Nothing was charged."
charged:
type: boolean
const: false
servers:
- url: https://extract.tollkit.dev
/preview:
get:
operationId: previewExtract
summary: Free. A real extraction of one fixed sample page
tags:
- Extraction
security: []
responses:
'200':
description: The same shape POST /extract returns, free.
content:
application/json:
schema:
$schema: https://json-schema.org/draft/2020-12/schema
type: object
description: schema.org/Product extracted from the rendered page. Fields the page does not state come back null rather than guessed.
required:
- product
- page
properties:
product:
type: object
properties:
name:
type:
- string
- 'null'
description:
type:
- string
- 'null'
brand:
type:
- string
- 'null'
sku:
type:
- string
- 'null'
price:
type:
- number
- 'null'
description: Numeric, no symbol or separators.
currency:
type:
- string
- 'null'
description: ISO 4217. Null whenever price is null.
availability:
type: string
enum:
- in_stock
- out_of_stock
- preorder
- unknown
images:
type: array
items:
type: string
description: Up to 5 absolute URLs copied from the page. Never invented.
variants:
type: array
items:
type: object
properties:
name:
type: string
values:
type: array
items:
type: string
url:
type: string
page:
type: object
properties:
url:
type: string
finalUrl:
type: string
title:
type:
- string
- 'null'
status:
type: integer
fetchedAt:
type: string
description: ISO timestamp of the RENDER, not of this call. Older than now on a cached result.
render_ms:
type: integer
cached:
type: boolean
description: True when re-served from a recent render. Still a paid call, and the data is as old as cache_age_seconds says.
cache_age_seconds:
type: integer
provenance:
type: object
description: Where each field came from. `declared` fields match what the merchant published in schema.org JSON-LD or Open Graph tags — their own number, the one they stand behind. `inferred` fields were read off the page by a model and deserve less trust. Fields that came back null appear in neither list. Use this to decide which values you can act on directly and which are worth a second look.
properties:
source:
type: string
enum:
- json-ld
- meta
- json-ld+meta
- none
declared:
type: array
items:
type: string
inferred:
type: array
items:
type: string
redirect:
type: object
description: Present only when the browser landed somewhere other than the requested URL.
properties:
requested:
type: string
final:
type: string
servers:
- url: https://extract.tollkit.dev
x-refined-from:
- tollkit-dev-api-openapi.json
- tollkit-dev-extract-openapi.json