---
title: "Get batch results"
method: GET
path: "/batch/{batch_id}/results"
tags: ["Batch"]
---

# Get batch results

`GET /batch/{batch_id}/results`

Page through a finished batch's results as JSON instead of downloading the NDJSON files.

## Path parameters

- `batch_id` string, required — ID of the batch to retrieve or cancel.

## Query parameters

- `limit` integer — Records per page. Defaults to 25. A page can close early so its payload stays under ~8 MB; rely on next_cursor rather than counting records.
- `cursor` string — next_cursor from the previous page.

## Response `200`

One page of result records. Keep paging with `next_cursor` while `has_more` is true.

- object
  - `data` BatchResultRecord[] — Result records on this page.
    - union — One page outcome from a finished batch.
      - object — A page the batch fetched successfully.
        - `url` string, required — URL as submitted, or as discovered by the crawl.
        - `itemId` string — Caller-supplied identifier echoed from submission.
        - `meta` object — Caller-supplied metadata echoed from submission.
        - `status` 'ok', required — The page was scraped.
        - `http_status` integer, nullable, required — HTTP status of the final response, when known.
        - `final_url` string, required — URL the content was read from, after redirects.
        - `markdown` string — Page content as Markdown. Present on markdown batches.
        - `html` string — Raw page HTML. Present on html batches.
        - `metadata` PageMetadata, required — Metadata extracted from the scraped page HTML.
          - `sourceUrl` string, required — Original URL requested by the caller.
          - `finalUrl` string, required — Final URL scraped after redirects or scraper fallback, when known. Falls back to sourceUrl when unavailable.
          - `title` string — Best title extracted from the page.
          - `description` string — Best description extracted from standard, Open Graph, or Twitter metadata.
          - `language` string — Language extracted from html lang or language meta tags.
          - `keywords` string[] — Keywords extracted from the page's keywords meta tag.
          - `canonicalUrl` string — Resolved canonical URL, when present.
          - `author` string — Author metadata, when present.
          - `siteName` string — Site or application name from page metadata.
          - `image` string — Primary resolved preview image from Open Graph, Twitter, or image metadata.
          - `favicon` string — Resolved favicon URL, when present.
          - `publishedTime` string — Published timestamp/date from page metadata, when present.
          - `modifiedTime` string — Modified timestamp/date from page metadata, when present.
          - `robots` string — Robots meta directive, when present.
          - `openGraph` object — Open Graph metadata with the og: prefix removed and keys camel-cased.
          - `twitter` object — Twitter card metadata with the twitter: prefix removed and keys camel-cased.
          - `alternates` PageMetadataAlternate[] — Resolved alternate links from link rel=alternate tags.
            - `href` string, required — Resolved alternate URL.
            - `hreflang` string — Language or locale for the alternate URL, when present.
            - `type` string — Alternate resource MIME type, when present.
            - `title` string — Alternate resource title, when present.
          - `jsonLd` object[] — JSON-LD structured data blocks parsed from the page.
          - `additionalMeta` object — Additional non-social meta tags not promoted to top-level metadata fields.
        - `ocr_pages` integer — PDF pages of this document recovered by OCR (pdf.ocr=true). Each recovered page bills 1 credit on top of the page base credit; absent when no OCR ran.
      - object — A page the batch could not fetch.
        - `url` string, required — URL as submitted, or as discovered by the crawl.
        - `itemId` string — Caller-supplied identifier echoed from submission.
        - `meta` object — Caller-supplied metadata echoed from submission.
        - `status` 'error', required — The page could not be scraped.
        - `error_code` string, required — Why the page failed.
        - `message` string, required — Human-readable failure detail.
  - `has_more` boolean — Whether another page is available.
  - `next_cursor` string, nullable — Cursor for the next page.
  - `key_metadata` KeyMetadata — Metadata about the API key used for the request. Included in every response whenever a valid API key is provided, even when the response status is not 200.
    - `credits_consumed` integer, required — The number of credits consumed by this request.
    - `credits_remaining` integer, required — The number of credits remaining for your organization after this request.

## Other responses

- `400` — Bad request
- `401` — Unauthorized
- `404` — Not found
- `409` — Batch has not finished yet (error_code BATCH_NOT_COMPLETED).

---

[API](https://skmtc.net/context/apis/context-dev.md) · [All operations](https://skmtc.net/context/apis/context-dev/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/context/context-dev/versions/3c6a01ba967f/schema)
