メインコンテンツへスキップ
POST

承認

Authorization
string
header
必須

Your API key, sent as Authorization: Bearer <key>.

ボディ

application/json

A field sent as null counts as not sent.

urls
string[]
必須

The pages to read: 1 to 100 public http or https URLs of at most 2,048 characters. A URL sent twice is read once. When ids is sent too, urls is used.

Required array length: 1 - 100 elements
Required string length: 1 - 2048
ids
string[]

Another name for urls.

Required array length: 1 - 100 elements
Required string length: 1 - 2048
text

Each page's text, up to 1,000,000 characters: its Markdown without link addresses, images and leftover HTML tags. A request that sends none of text, markdown and highlights gets text; once it sends markdown or highlights, text comes only when asked for.

markdown
boolean

true returns each page's Markdown as WEB_SCRAPE gives it, with its links and images.

highlights

The passages of each page that best answer query, in highlights with their highlightScores.

context

Also returns context, the pages read as one string for a prompt: the title, URL and text of each page.

extras
object

What else to return of each page.

livecrawlTimeout
integer
デフォルト:10000

How long to wait for the pages, in milliseconds. A page still being read then is answered with CRAWL_LIVECRAWL_TIMEOUT.

必須範囲: 1 <= x <= 90000
maxAgeHours
integer

The age of a cached read you accept, in hours. 0 reads the page now. Reads are cached for 7 days, so a larger value changes nothing beyond that; without this field a cached read up to 7 days old is used. Send it or livecrawl, not both.

必須範囲: 0 <= x <= 720
livecrawl
enum<string>

always reads the page now, like maxAgeHours: 0. The others take a cached read up to 7 days old. Send it or maxAgeHours, not both.

利用可能なオプション:
always,
fallback,
preferred,
auto
userIdentifier
string

Accepted and ignored.

country
string

The language and region the pages are requested for, a two-letter country code. Without it, a .kr address and domestic Coupang and Olive Young storefronts use KR and every other page uses US.

Pattern: ^[A-Za-z]{2}$
render
boolean

true reads each page in a browser after its script ran, even when a plain request already gets it. A page no browser can read is not read.

screenshot
boolean

true also returns screenshot and shown: each page as a person sees it in a 1366 x 900 browser, scrolled to the end. Implies render and often takes 20 to 60 seconds; raise livecrawlTimeout with it.

rawHtml
boolean

true also returns rawHtml, the HTML that was read.

contentHtml
boolean

true also returns contentHtml, the main content as HTML.

jsonLd
boolean

true also returns jsonLd, the page's schema.org JSON-LD blocks.

レスポンス

The answer for the URLs, also when some of them could not be read: those are in statuses.

requestId
string
必須
results
object[]
必須

The pages that were read, in the order the URLs were sent. A page that was not read is not here; see statuses.

statuses
object[]
必須

One entry per URL, in the order sent.

searchTime
integer
必須

How long the request took, in milliseconds.

context
string

With context.