For Agents
Contrie is built for a machine caller: single-page extraction and reading, returning JSON with fields to make a keep/retry decision on — not a browsing agent. A request does not crawl a site, search the open web, or drive a multi-step browser session.
Machine-Readable Surfaces
| Path | What it is |
|---|---|
| /llms.txt | Plain-text summary of the API and service, for models that read it directly |
| /openapi.json | Full OpenAPI spec for the REST endpoints — generate a typed client from this |
| /agent-onboarding/SKILL.md | Setup and the same decision procedure below, in a format agent frameworks that load skills can consume directly |
| /mcp | Hosted MCP server — nine tools, no HTTP client code needed: contrie_extract, contrie_read, contrie_search, contrie_verify, contrie_watch, contrie_changes, contrie_monitors, contrie_unwatch and contrie_account |
Decision Procedure
- Reading vs. structured data: use
format: "markdown"(or thecontrie_readMCP tool) when you just need to read a page. Useschemawhen downstream code depends on the exact shape; use free-textextractotherwise. - Check the acceptance evidence: require
success: true. For structured output that already meansvalid: trueandqualityScore ≥ 70; they are not a second gate. Inspectvalid,schemaValid,requestedFieldsandgroundingCoverage. These are local structure and text-support checks; verify field meaning, attribution and freshness before a consequential action. Acceptance requires at least half of all returned values (nulls excluded) to be found in the page text; booleans and strings under 3 characters are never found, so an answer made mostly of yes/no values or one- or two-letter codes is refused. Ask for such a value as the text the page shows (“the stock status as shown”). Above that floor, choose the bar each job needs and readgroundingFieldsfor the values that matter. - Retry once, narrower: on a lower
qualityScore, retry a single time with a more specificextractprompt rather than repeating the same call. - Refused, read why before you retry: a refusal (
success: false) carries no values and nogroundingFields. Readmetadata.requestedFields.missingandmetadata.groundingCoverageandmetadata.completeness. Acceptance requires more than 30% of the fields in the answer to be populated (completeness above 0.3), so an answer at or below that share is refused: request fewer fields. Otherwise retry once with nullable fields or values asked for as the page writes them. - Low grounding on an accepted answer, inspect before you retry: don't discard the whole result, and don't assume an unmatched value is wrong — it is unconfirmed, and a page that presents a value differently can fail the check. Read
metadata.groundingFields, find the entries withgrounded: false, and retry with a narrowerextractnaming only thosepaths. When a human needs to check the agent's work, theexcerpton each entry is the audit trail — it's the page text the check matched against, not just a verdict. - RENDER_REQUIRED isn't retryable as-is: the available page could not support this request. Check the source and its limits first. Eligible requests may use Contrie's rendering options; authorized callers can also supply captured HTML through /api/v1/extract. A login wall or unsupported source may still be refused.
- Check credits and capacity: call
contrie_accountbefore new work, then inspect the extraction'smetadata.credits. The account check reserves no capacity. Unused monthly credits alone do not guarantee availability. - One page per call: no crawling, no open-web search, no multi-step browsing — call once per URL you already have.
For one consistent first job, use the product name and price quickstart or the matching Track a price recipe. Inspect its name, offer price, currency, source time and support before automating repeat checks.
Worked Example: Retrying on Low Grounding
A product page extraction comes back with qualityScore: 78 but grounding: 0.67 — a third of the checkable values have no text support. Instead of retrying the whole request, check groundingFields for the failing path:
[
{
"path": "$.price",
"value": "$49.99 (was $69.99)",
"grounded": false
},
{
"path": "$.name",
"value": "Trail Runner Jacket",
"grounded": true,
"excerpt": "…lightweight trail runner jacket, packable, water-resistant shell…"
}
]Only $.price failed — the returned value may combine a sale price and a strikethrough price into one string that never appears verbatim on the page. Retry with a narrower extract targeting just that field ("the current price only, as a plain number") instead of re-running the full extraction.
Full Reference
For the complete parameter and response contract, see Scrape, Extract, Streaming, and Error Codes.