@hunt-labs/bytekit-mcp 0.3.28 → 0.3.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +151 -47
- package/dist/docs-bundle/docs-bundle.json +10 -10
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -10,7 +10,29 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
10
10
|
|
|
11
11
|
## [Unreleased]
|
|
12
12
|
|
|
13
|
-
## [0.3.
|
|
13
|
+
## [0.3.30] - 2026-12-03
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
|
|
17
|
+
- Reworded two earlier entries of this changelog (#5335, #4515) so they no longer name an
|
|
18
|
+
internal-only request field (#6215). This changes no tool, schema or transport.
|
|
19
|
+
|
|
20
|
+
## [0.3.29] - 2026-12-03 [REMOVED FROM REGISTRY]
|
|
21
|
+
|
|
22
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
23
|
+
|
|
24
|
+
### Changed
|
|
25
|
+
|
|
26
|
+
- Refreshed the bundled documentation snapshot after the TypeScript SDK reference dropped
|
|
27
|
+
`client.account.apiKeys` (#6217) and the errors guide stopped naming dashboard billing endpoints.
|
|
28
|
+
This refresh itself changes no tool, schema or transport.
|
|
29
|
+
- Refreshed the bundled documentation snapshot after bulk requests began refusing, per item, hosts
|
|
30
|
+
our proxy provider does not allow (`proxy_refused`, #6227). This refresh itself changes no tool,
|
|
31
|
+
schema or transport.
|
|
32
|
+
|
|
33
|
+
## [0.3.28] - 2026-12-01 [REMOVED FROM REGISTRY]
|
|
34
|
+
|
|
35
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
14
36
|
|
|
15
37
|
### Changed
|
|
16
38
|
|
|
@@ -22,7 +44,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
22
44
|
requested and the page is too large to convert. The generated `ScrapeEnvelopeErrorCode` union
|
|
23
45
|
gains `content_too_large`; no tool, schema or transport changes.
|
|
24
46
|
|
|
25
|
-
## [0.3.27] - 2026-12-01
|
|
47
|
+
## [0.3.27] - 2026-12-01 [REMOVED FROM REGISTRY]
|
|
48
|
+
|
|
49
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
26
50
|
|
|
27
51
|
### Changed
|
|
28
52
|
|
|
@@ -30,7 +54,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
30
54
|
`credits_used` (#6088): the schema extraction guide now lists both in its Response table and says
|
|
31
55
|
where the credit charge is reported. This refresh itself changes no tool, schema or transport.
|
|
32
56
|
|
|
33
|
-
## [0.3.26] - 2026-11-27
|
|
57
|
+
## [0.3.26] - 2026-11-27 [REMOVED FROM REGISTRY]
|
|
58
|
+
|
|
59
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
34
60
|
|
|
35
61
|
### Changed
|
|
36
62
|
|
|
@@ -38,7 +64,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
38
64
|
(#5777): the scraping guide now says which paths the 1000 to 90000 range applies to, and
|
|
39
65
|
`/v1/scrape` defaults to 90000. This refresh itself changes no tool, schema or transport.
|
|
40
66
|
|
|
41
|
-
## [0.3.25] - 2026-11-23
|
|
67
|
+
## [0.3.25] - 2026-11-23 [REMOVED FROM REGISTRY]
|
|
68
|
+
|
|
69
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
42
70
|
|
|
43
71
|
### Changed
|
|
44
72
|
|
|
@@ -47,7 +75,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
47
75
|
blocking or never finishes loading reaches a final `blocked` or `timeout` within about 6 minutes
|
|
48
76
|
of starting work. This refresh itself changes no tool, schema or transport.
|
|
49
77
|
|
|
50
|
-
## [0.3.24] - 2026-11-12
|
|
78
|
+
## [0.3.24] - 2026-11-12 [REMOVED FROM REGISTRY]
|
|
79
|
+
|
|
80
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
51
81
|
|
|
52
82
|
### Changed
|
|
53
83
|
|
|
@@ -60,7 +90,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
60
90
|
rendered in a browser renders in a phone-sized window with a desktop (Windows) browser identity.
|
|
61
91
|
This refresh itself changes no tool, schema or transport.
|
|
62
92
|
|
|
63
|
-
## [0.3.23] - 2026-11-04
|
|
93
|
+
## [0.3.23] - 2026-11-04 [REMOVED FROM REGISTRY]
|
|
94
|
+
|
|
95
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
64
96
|
|
|
65
97
|
### Changed
|
|
66
98
|
|
|
@@ -73,7 +105,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
73
105
|
other value as a 422 `validation_error`. The server has no screenshot tool parameter for it, so no
|
|
74
106
|
tool, schema or transport changes.
|
|
75
107
|
|
|
76
|
-
## [0.3.22] - 2026-10-27
|
|
108
|
+
## [0.3.22] - 2026-10-27 [REMOVED FROM REGISTRY]
|
|
109
|
+
|
|
110
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
77
111
|
|
|
78
112
|
### Added
|
|
79
113
|
|
|
@@ -90,7 +124,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
90
124
|
`get_result`. Description text only; no input schema change. The bundled documentation snapshot
|
|
91
125
|
carries the same wording.
|
|
92
126
|
|
|
93
|
-
## [0.3.21] - 2026-10-24
|
|
127
|
+
## [0.3.21] - 2026-10-24 [REMOVED FROM REGISTRY]
|
|
128
|
+
|
|
129
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
94
130
|
|
|
95
131
|
### Security
|
|
96
132
|
|
|
@@ -106,7 +142,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
106
142
|
`str | Unset` and `X | None` replace `Union[Unset, str]` and `Optional[X]`. The `get_doc` and
|
|
107
143
|
`search_docs` tools serve the new text; no tool, schema or transport change.
|
|
108
144
|
|
|
109
|
-
## [0.3.20] - 2026-10-23
|
|
145
|
+
## [0.3.20] - 2026-10-23 [REMOVED FROM REGISTRY]
|
|
146
|
+
|
|
147
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
110
148
|
|
|
111
149
|
### Security
|
|
112
150
|
|
|
@@ -117,7 +155,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
117
155
|
The SDK bump also fixes three advisories in SDK code ByteKit does not use (GHSA-22jm-h49p-29qw,
|
|
118
156
|
GHSA-rvq5-wwqv-78pq, GHSA-6prh-2h8m-c8cw). No tool, schema or transport change.
|
|
119
157
|
|
|
120
|
-
## [0.3.19] - 2026-10-15
|
|
158
|
+
## [0.3.19] - 2026-10-15 [REMOVED FROM REGISTRY]
|
|
159
|
+
|
|
160
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
121
161
|
|
|
122
162
|
### Changed
|
|
123
163
|
|
|
@@ -126,7 +166,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
126
166
|
"page was fetched, but extraction failed" row. The `get_doc` and `search_docs` tools serve the
|
|
127
167
|
new text; no tool, schema or transport change.
|
|
128
168
|
|
|
129
|
-
## [0.3.18] - 2026-10-02
|
|
169
|
+
## [0.3.18] - 2026-10-02 [REMOVED FROM REGISTRY]
|
|
170
|
+
|
|
171
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
130
172
|
|
|
131
173
|
### Changed
|
|
132
174
|
|
|
@@ -155,8 +197,8 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
155
197
|
- The bundled documentation snapshot's Scraping guide now has an Options section covering every
|
|
156
198
|
public `POST /v1/scrape` option, with two worked curl examples (#5333). The `get_doc` and
|
|
157
199
|
`search_docs` tools serve the new text; no tool, schema or transport change.
|
|
158
|
-
- The bundled documentation snapshot's `POST /v1/scrape` API reference no longer lists
|
|
159
|
-
internal-only
|
|
200
|
+
- The bundled documentation snapshot's `POST /v1/scrape` API reference no longer lists an
|
|
201
|
+
internal-only request field (#5335); any property the OpenAPI spec marks
|
|
160
202
|
`x-internal: true` is now left out of the API reference. The `get_doc` and `search_docs` tools
|
|
161
203
|
serve the new text; no tool, schema or transport change.
|
|
162
204
|
- The bundled documentation snapshot's `guides/errors` page now describes HTTP `500 internal_error`
|
|
@@ -288,7 +330,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
288
330
|
`cookies` (#5434). The `get_doc` and `search_docs` tools serve the new text; no tool, schema or
|
|
289
331
|
transport change.
|
|
290
332
|
|
|
291
|
-
## [0.3.17] - 2026-10-02
|
|
333
|
+
## [0.3.17] - 2026-10-02 [REMOVED FROM REGISTRY]
|
|
334
|
+
|
|
335
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
292
336
|
|
|
293
337
|
### Changed
|
|
294
338
|
|
|
@@ -310,7 +354,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
310
354
|
shape (#5072). The `get_doc` and `search_docs` tools serve the new text; no tool, schema or
|
|
311
355
|
transport change.
|
|
312
356
|
|
|
313
|
-
## [0.3.16] - 2026-10-01
|
|
357
|
+
## [0.3.16] - 2026-10-01 [REMOVED FROM REGISTRY]
|
|
358
|
+
|
|
359
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
314
360
|
|
|
315
361
|
### Changed
|
|
316
362
|
|
|
@@ -326,7 +372,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
326
372
|
100-credit grant unchanged (#4959). No behavior change in the package: bundled content only,
|
|
327
373
|
no tool, schema or transport change.
|
|
328
374
|
|
|
329
|
-
## [0.3.15] - 2026-09-30
|
|
375
|
+
## [0.3.15] - 2026-09-30 [REMOVED FROM REGISTRY]
|
|
376
|
+
|
|
377
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
330
378
|
|
|
331
379
|
### Fixed
|
|
332
380
|
|
|
@@ -346,7 +394,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
346
394
|
`bytekit-sdk` (PyPI), and the npm package named `bytekit` is not ByteKit's (#5004). The `get_doc`
|
|
347
395
|
and `search_docs` tools serve the new text; no tool, schema or transport change.
|
|
348
396
|
|
|
349
|
-
## [0.3.14] - 2026-09-29
|
|
397
|
+
## [0.3.14] - 2026-09-29 [REMOVED FROM REGISTRY]
|
|
398
|
+
|
|
399
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
350
400
|
|
|
351
401
|
### Changed
|
|
352
402
|
|
|
@@ -361,7 +411,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
361
411
|
billable requests are refused with `402 quota_exceeded` while any is owed (#4960). No behavior
|
|
362
412
|
change: bundled content only, no tool, schema or transport change.
|
|
363
413
|
|
|
364
|
-
## [0.3.13] - 2026-09-24
|
|
414
|
+
## [0.3.13] - 2026-09-24 [REMOVED FROM REGISTRY]
|
|
415
|
+
|
|
416
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
365
417
|
|
|
366
418
|
### Changed
|
|
367
419
|
|
|
@@ -370,7 +422,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
370
422
|
upstream wire bytes with no endpoint factor instead of "exactly like `/v1/scrape`" (#4865). No
|
|
371
423
|
behavior change: bundled content only, no tool, schema or transport change.
|
|
372
424
|
|
|
373
|
-
## [0.3.12] - 2026-09-23
|
|
425
|
+
## [0.3.12] - 2026-09-23 [REMOVED FROM REGISTRY]
|
|
426
|
+
|
|
427
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
374
428
|
|
|
375
429
|
### Changed
|
|
376
430
|
|
|
@@ -378,7 +432,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
378
432
|
gained the required boolean `onboarding_completed` (#4780). Additive, patch-level: bundled
|
|
379
433
|
content only, no tool, schema or transport change.
|
|
380
434
|
|
|
381
|
-
## [0.3.11] - 2026-09-21
|
|
435
|
+
## [0.3.11] - 2026-09-21 [REMOVED FROM REGISTRY]
|
|
436
|
+
|
|
437
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
382
438
|
|
|
383
439
|
### Changed
|
|
384
440
|
|
|
@@ -387,7 +443,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
387
443
|
optional `X-Fetch-ID` header on their `422` responses (#4732). Bundled content only: no tool,
|
|
388
444
|
schema or transport change.
|
|
389
445
|
|
|
390
|
-
## [0.3.10] - 2026-09-21
|
|
446
|
+
## [0.3.10] - 2026-09-21 [REMOVED FROM REGISTRY]
|
|
447
|
+
|
|
448
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
391
449
|
|
|
392
450
|
### Changed
|
|
393
451
|
|
|
@@ -397,7 +455,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
397
455
|
`getfetch` and `postfetch` pages name the new condition. Bundled content only: no tool, schema
|
|
398
456
|
or transport change.
|
|
399
457
|
|
|
400
|
-
## [0.3.9] - 2026-09-18
|
|
458
|
+
## [0.3.9] - 2026-09-18 [REMOVED FROM REGISTRY]
|
|
459
|
+
|
|
460
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
401
461
|
|
|
402
462
|
### Changed
|
|
403
463
|
|
|
@@ -414,7 +474,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
414
474
|
window into release history; it now says release history isn't bundled at all and points to
|
|
415
475
|
the public changelog page instead.
|
|
416
476
|
|
|
417
|
-
## [0.3.8] - 2026-09-17
|
|
477
|
+
## [0.3.8] - 2026-09-17 [REMOVED FROM REGISTRY]
|
|
478
|
+
|
|
479
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
418
480
|
|
|
419
481
|
### Changed
|
|
420
482
|
|
|
@@ -424,7 +486,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
424
486
|
`changelog` page, and the page's truncation notice reports its new full size. Bundled content
|
|
425
487
|
only: no tool, schema or transport change.
|
|
426
488
|
|
|
427
|
-
## [0.3.7] - 2026-09-14
|
|
489
|
+
## [0.3.7] - 2026-09-14 [REMOVED FROM REGISTRY]
|
|
490
|
+
|
|
491
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
428
492
|
|
|
429
493
|
### Added
|
|
430
494
|
|
|
@@ -477,9 +541,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
477
541
|
page.
|
|
478
542
|
- Refreshed the bundled documentation snapshot after the generated `sdk/python/scrape` reference
|
|
479
543
|
stopped listing request fields the OpenAPI spec marks `x-internal: true` (#4515): that page
|
|
480
|
-
loses
|
|
481
|
-
spec and in the generated model, and the API reference page for `POST /v1/scrape` still
|
|
482
|
-
it. This refresh itself changes no tool, schema or transport.
|
|
544
|
+
loses the bullet for an internal-only request field. The field remained a live internal control in
|
|
545
|
+
the spec and in the generated model, and the API reference page for `POST /v1/scrape` still
|
|
546
|
+
listed it. This refresh itself changes no tool, schema or transport.
|
|
483
547
|
- The MCP server changelog entry for #4515 is past the cut, so a client reading the bundled
|
|
484
548
|
`changelog` page does not see it; the only other bundled bytes that move are in that page's
|
|
485
549
|
truncation notice, which reports the full size of the page it truncates.
|
|
@@ -492,7 +556,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
492
556
|
- The TypeScript SDK changelog entry for #4508 is inside the bundled body of the `changelog`
|
|
493
557
|
page.
|
|
494
558
|
|
|
495
|
-
## [0.3.6] - 2026-09-12
|
|
559
|
+
## [0.3.6] - 2026-09-12 [REMOVED FROM REGISTRY]
|
|
560
|
+
|
|
561
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
496
562
|
|
|
497
563
|
### Changed
|
|
498
564
|
|
|
@@ -513,7 +579,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
513
579
|
spec included; only the implementation detail is gone. No tool, schema or runtime
|
|
514
580
|
behavior in this package changed.
|
|
515
581
|
|
|
516
|
-
## [0.3.5] - 2026-09-06
|
|
582
|
+
## [0.3.5] - 2026-09-06 [REMOVED FROM REGISTRY]
|
|
583
|
+
|
|
584
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
517
585
|
|
|
518
586
|
### Changed
|
|
519
587
|
|
|
@@ -557,7 +625,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
557
625
|
for #4132, which qualifies that third case as an internal deploy-skew safeguard no API request
|
|
558
626
|
can reach. Bundled content only: no tool, schema or transport change.
|
|
559
627
|
|
|
560
|
-
## [0.3.4] - 2026-09-04
|
|
628
|
+
## [0.3.4] - 2026-09-04 [REMOVED FROM REGISTRY]
|
|
629
|
+
|
|
630
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
561
631
|
|
|
562
632
|
### Changed
|
|
563
633
|
|
|
@@ -567,7 +637,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
567
637
|
omitted on a cache hit, which replays stored bytes and runs no tier. No tool, argument or
|
|
568
638
|
output shape changed.
|
|
569
639
|
|
|
570
|
-
## [0.3.3] - 2026-09-03
|
|
640
|
+
## [0.3.3] - 2026-09-03 [REMOVED FROM REGISTRY]
|
|
641
|
+
|
|
642
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
571
643
|
|
|
572
644
|
### Changed
|
|
573
645
|
|
|
@@ -604,7 +676,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
604
676
|
TypeScript SDK section's own older history, so slightly less of an older entry is visible than
|
|
605
677
|
before. The page count stays at 108 and no tool, argument, or response shape changes.
|
|
606
678
|
|
|
607
|
-
## [0.3.2] - 2026-08-31
|
|
679
|
+
## [0.3.2] - 2026-08-31 [REMOVED FROM REGISTRY]
|
|
680
|
+
|
|
681
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
608
682
|
|
|
609
683
|
### Changed
|
|
610
684
|
|
|
@@ -615,7 +689,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
615
689
|
**not** in the bundle — the notice's byte count is the whole delta. The page count stays at 108
|
|
616
690
|
and no tool, argument, or response shape changes.
|
|
617
691
|
|
|
618
|
-
## [0.3.1] - 2026-08-25
|
|
692
|
+
## [0.3.1] - 2026-08-25 [REMOVED FROM REGISTRY]
|
|
693
|
+
|
|
694
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
619
695
|
|
|
620
696
|
### Changed
|
|
621
697
|
|
|
@@ -637,7 +713,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
637
713
|
full-text search never sees them. Read the whole changelog at
|
|
638
714
|
https://bytekit.com/docs/changelog. Bundled content only: no tool, schema or transport change.
|
|
639
715
|
|
|
640
|
-
## [0.3.0] - 2026-08-20
|
|
716
|
+
## [0.3.0] - 2026-08-20 [REMOVED FROM REGISTRY]
|
|
717
|
+
|
|
718
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
641
719
|
|
|
642
720
|
### Removed
|
|
643
721
|
|
|
@@ -661,7 +739,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
661
739
|
it, but full-text search now reaches only the releases above the cut. The docs site keeps the
|
|
662
740
|
whole changelog.
|
|
663
741
|
|
|
664
|
-
## [0.2.8] - 2026-08-19
|
|
742
|
+
## [0.2.8] - 2026-08-19 [REMOVED FROM REGISTRY]
|
|
743
|
+
|
|
744
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
665
745
|
|
|
666
746
|
### Changed
|
|
667
747
|
|
|
@@ -674,7 +754,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
674
754
|
server itself: the MCP tools do not call the capture endpoints whose responses now carry the
|
|
675
755
|
node.
|
|
676
756
|
|
|
677
|
-
## [0.2.7] - 2026-08-18
|
|
757
|
+
## [0.2.7] - 2026-08-18 [REMOVED FROM REGISTRY]
|
|
758
|
+
|
|
759
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
678
760
|
|
|
679
761
|
### Changed
|
|
680
762
|
|
|
@@ -687,7 +769,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
687
769
|
release is a regeneration of the checked-in contract only, with no behavior change in the server
|
|
688
770
|
itself.
|
|
689
771
|
|
|
690
|
-
## [0.2.6] - 2026-08-12
|
|
772
|
+
## [0.2.6] - 2026-08-12 [REMOVED FROM REGISTRY]
|
|
773
|
+
|
|
774
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
691
775
|
|
|
692
776
|
### Changed
|
|
693
777
|
|
|
@@ -749,7 +833,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
749
833
|
failures render through one error path. `--help`, the missing-key message, and the
|
|
750
834
|
existing `--timeout-ms abc` / `--timeout-ms=-5` errors are unchanged. (#2952)
|
|
751
835
|
|
|
752
|
-
## [0.2.5] - 2026-08-11
|
|
836
|
+
## [0.2.5] - 2026-08-11 [REMOVED FROM REGISTRY]
|
|
837
|
+
|
|
838
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
753
839
|
|
|
754
840
|
### Added
|
|
755
841
|
|
|
@@ -760,13 +846,17 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
760
846
|
client's single header-construction site — it does not ride along with `Authorization`
|
|
761
847
|
and is not affected by the in-process gateway dispatch path (issue #1182). (#2907)
|
|
762
848
|
|
|
763
|
-
## [0.2.4] - 2026-08-10
|
|
849
|
+
## [0.2.4] - 2026-08-10 [REMOVED FROM REGISTRY]
|
|
850
|
+
|
|
851
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
764
852
|
|
|
765
853
|
### Changed
|
|
766
854
|
|
|
767
855
|
- Version-alignment release after the 2026-08-10 publish rescue: the published 0.2.3 artifact was built from the `main` promotion HEAD, which already contained every change documented under the 0.2.3 heading — but that commit postdates the one that introduced the 0.2.3 version string, so the `check-release-drift` gate (#2680) correctly reported shipped drift on every subsequent CI run (#2829). 0.2.4 realigns manifest ↔ registry ↔ version-introducing commit. **No consumer-visible change relative to the published 0.2.3.**
|
|
768
856
|
|
|
769
|
-
## [0.2.3] - 2026-08-07
|
|
857
|
+
## [0.2.3] - 2026-08-07 [REMOVED FROM REGISTRY]
|
|
858
|
+
|
|
859
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
770
860
|
|
|
771
861
|
### Added
|
|
772
862
|
|
|
@@ -872,7 +962,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
872
962
|
`(Screenshot ID: ss_…)` handle line is unchanged, and a genuine request-validation 422
|
|
873
963
|
still renders exactly as it did. (#2679)
|
|
874
964
|
|
|
875
|
-
## [0.2.2] - 2026-07-29
|
|
965
|
+
## [0.2.2] - 2026-07-29 [REMOVED FROM REGISTRY]
|
|
966
|
+
|
|
967
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
876
968
|
|
|
877
969
|
### Fixed
|
|
878
970
|
|
|
@@ -927,7 +1019,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
927
1019
|
keys (#2643). Content only — no tool surface, schema, or runtime behavior changed.
|
|
928
1020
|
(#2640, #2643)
|
|
929
1021
|
|
|
930
|
-
## [0.2.1] - 2026-07-24
|
|
1022
|
+
## [0.2.1] - 2026-07-24 [REMOVED FROM REGISTRY]
|
|
1023
|
+
|
|
1024
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
931
1025
|
|
|
932
1026
|
### Fixed
|
|
933
1027
|
|
|
@@ -956,7 +1050,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
956
1050
|
the caller never reads. The `120000` default is deliberately well above the server-side
|
|
957
1051
|
screenshot ceiling so it never truncates a legitimate billable operation. (#2568)
|
|
958
1052
|
|
|
959
|
-
## [0.2.0] - 2026-07-21
|
|
1053
|
+
## [0.2.0] - 2026-07-21 [REMOVED FROM REGISTRY]
|
|
1054
|
+
|
|
1055
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
960
1056
|
|
|
961
1057
|
### Removed (**BREAKING**)
|
|
962
1058
|
|
|
@@ -990,7 +1086,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
990
1086
|
regenerated: 96 pages, now including the TypeScript SDK `usage` and
|
|
991
1087
|
`webhooks` reference pages and dropping removed content. (#2469)
|
|
992
1088
|
|
|
993
|
-
## [0.1.3] - 2026-07-16
|
|
1089
|
+
## [0.1.3] - 2026-07-16 [REMOVED FROM REGISTRY]
|
|
1090
|
+
|
|
1091
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
994
1092
|
|
|
995
1093
|
### Changed (**BREAKING**)
|
|
996
1094
|
|
|
@@ -1009,7 +1107,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
1009
1107
|
correct `@hunt-labs/bytekit-sdk` install/import name instead of the dead
|
|
1010
1108
|
`@bytekit/sdk` scope. (#2449)
|
|
1011
1109
|
|
|
1012
|
-
## [0.1.2] - 2026-07-15
|
|
1110
|
+
## [0.1.2] - 2026-07-15 [REMOVED FROM REGISTRY]
|
|
1111
|
+
|
|
1112
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
1013
1113
|
|
|
1014
1114
|
### Fixed
|
|
1015
1115
|
|
|
@@ -1025,7 +1125,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
1025
1125
|
- Compiled test code and fixtures are excluded from the published tarball — only
|
|
1026
1126
|
runtime `dist/**` (plus `README.md`, `LICENSE`, and now `CHANGELOG.md`) ships (#2419).
|
|
1027
1127
|
|
|
1028
|
-
## [0.1.1] - 2026-07 [DEPRECATED]
|
|
1128
|
+
## [0.1.1] - 2026-07 [DEPRECATED] [REMOVED FROM REGISTRY]
|
|
1129
|
+
|
|
1130
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
1029
1131
|
|
|
1030
1132
|
### Note
|
|
1031
1133
|
|
|
@@ -1033,7 +1135,9 @@ today, see [README.md](./README.md), which remains the authoritative usage guide
|
|
|
1033
1135
|
(camelCase fields the API no longer returned) and included compiled test code in
|
|
1034
1136
|
the tarball. Upgrade to 0.1.2 or later.
|
|
1035
1137
|
|
|
1036
|
-
## [0.1.0] - 2026-07
|
|
1138
|
+
## [0.1.0] - 2026-07 [REMOVED FROM REGISTRY]
|
|
1139
|
+
|
|
1140
|
+
> **Removed from npm.** Install 0.3.30 or later.
|
|
1037
1141
|
|
|
1038
1142
|
### Added
|
|
1039
1143
|
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"api/bulk/createbulk": {
|
|
23
23
|
"title": "Create mixed bulk job",
|
|
24
24
|
"section": "API Reference",
|
|
25
|
-
"body": "# Create mixed bulk job\n\nEnqueues screenshots or scrapes in a single batch.\nProvide `urls` (simple list) or `items` (per-item config), not both.\nWebhook deliveries include `X-ByteKit-Event: bulk.completed` so\nreceivers can dispatch on the header without parsing the body shape.\nThe body follows `BulkCompletedWebhook`: at most 500 complete items and\n1 MiB, followed by cursor recovery through the existing mixed-item route\nwhenever `recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 4 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 32 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's richer per-item override\nbudget), which reaches 28.7 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 4 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**POST** `/v1/bulk`\n\n## Request Body\n\n- `urls`\n- `items`\n- `items.url`\n- `items.type`\n- `items.device`\n- `items.format`\n- `items.quality`\n- `items.full_page`\n- `items.block_ads`\n- `items.block_cookie_banners`\n- `items.scroll`\n- `items.include_html`\n- `items.country`\n- `items.language`\n- `items.dark_mode`\n- `items.formats`\n- `items.formats.type`\n- `items.formats.schema`\n- `items.formats.model`\n- `items.formats.prompt`\n- `items.wait_until`\n- `items.wait_for_selector`\n- `items.delay_ms`\n- `items.viewport`\n- `items.viewport.width`\n- `items.viewport.height`\n- `items.duration`\n- `items.scenario`\n- `items.metadata`\n- `defaults`\n- `defaults.type`\n- `defaults.device`\n- `defaults.format`\n- `defaults.quality`\n- `defaults.full_page`\n- `defaults.block_ads`\n- `defaults.block_cookie_banners`\n- `defaults.scroll`\n- `defaults.include_html`\n- `defaults.country`\n- `defaults.language`\n- `defaults.dark_mode`\n- `defaults.formats`\n- `defaults.formats.type`\n- `defaults.formats.schema`\n- `defaults.formats.model`\n- `defaults.formats.prompt`\n- `defaults.wait_until`\n- `defaults.wait_for_selector`\n- `defaults.delay_ms`\n- `defaults.viewport`\n- `defaults.viewport.width`\n- `defaults.viewport.height`\n- `defaults.device_scale_factor`\n- `webhook_url` (required)\n- `webhook_secret`\n- `metadata`\n\n## Responses\n\n### 202 — Bulk job accepted.\n- `id`\n- `status`\n- `total`\n- `completed`\n- `failed`\n- `created_at`\n- `completed_at`\n- `total_credits_charged`\n- `total_billed_bytes`\n- `estimated_credits`\n- `webhook_url`\n\n### 400 — Bad request. When a `url` (or item URL) fails strict validation the\nerror code is `invalid_url` and the `details` object contains:\n- `field` — the request field that failed (e.g. `\"url\"`)\n- `url` — the rejected value\n- `reason` — one of: `scheme_missing`, `scheme_unsupported`,\n `scheme_separator_typo`, `host_empty`, `host_invalid`,\n `host_blocked_private`, `host_blocked_loopback`, `host_too_long`,\n `host_unicode_not_punycode`, `userinfo_present`, `url_too_long`,\n `control_chars`, `not_a_url`\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 401 — Unauthorized. The request carried no valid credential, and no work was\nperformed. The unified `Error` envelope carries one of the codes below\nin `error.code`; match on the code, never on the prose.\n\n- `invalid_api_key` — a bearer API key was presented and rejected:\n unknown, revoked, expired or malformed. The bearer-only operations\n (`/v1/webhook-deliveries*` among them) also return it when no\n `Authorization` header is sent. `GET /v1/account` is the exception\n to \"malformed\": it returns `invalid_api_key` only for a key that\n starts `sk_test_` or `sk_live_` and is unknown, revoked or expired.\n- `unauthorized` — the `Authorization` header is absent or malformed on\n an operation that also accepts a dashboard session (the dual-auth and\n billing operations). `GET /v1/account` also returns it, for no\n `Authorization` header and for any bearer value that does not start\n `sk_test_` or `sk_live_` (that value is checked as a dashboard\n session token).\n\nNot retryable as-is: supply a valid API key first.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 402 — Payment required. The account cannot fund this request, and no work was\nperformed. The unified `Error` envelope carries one of the billing codes\nbelow in `error.code`; match on the code, never on the prose.\n\n- `quota_exceeded` — the enforced balance for this request's meter\n cannot fund it. Capture endpoints (`/v1/scrape`, `/v1/fetch`,\n `/v1/screenshots`, `/v1/sitemap` and the bulk siblings) meter\n bandwidth: they reject when the balance cannot fund the request's\n byte reservation, and `error.details.required_bytes` and\n `error.details.available_bytes` report the bytes the request reserves\n and the bytes available. `/v1/search` meters credits.\n- `spending_cap_reached` — the request would push overage spend past the\n account's configured cap. Only reachable on a custom overage-enabled\n plan; standard plans stop at `quota_exceeded`.\n- `billing_entitlement_impaired` — the paid subscription is in a payment\n impairment (e.g. `past_due`). `error.message` names the reason.\n- `billing_entitlement_expired` — the paid subscription entitlement\n period has ended, or its dunning grace period has run out.\n\nNot retryable as-is: settle the balance, raise the cap, or restore the\nsubscription first. This response carries no `X-Quota-*` headers — they\ntravel with the 2xx responses of the operations that emit them.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 403 —
|
|
25
|
+
"body": "# Create mixed bulk job\n\nEnqueues screenshots or scrapes in a single batch.\nProvide `urls` (simple list) or `items` (per-item config), not both.\nWebhook deliveries include `X-ByteKit-Event: bulk.completed` so\nreceivers can dispatch on the header without parsing the body shape.\nThe body follows `BulkCompletedWebhook`: at most 500 complete items and\n1 MiB, followed by cursor recovery through the existing mixed-item route\nwhenever `recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 4 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 32 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's richer per-item override\nbudget), which reaches 28.7 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 4 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**POST** `/v1/bulk`\n\n## Request Body\n\n- `urls`\n- `items`\n- `items.url`\n- `items.type`\n- `items.device`\n- `items.format`\n- `items.quality`\n- `items.full_page`\n- `items.block_ads`\n- `items.block_cookie_banners`\n- `items.scroll`\n- `items.include_html`\n- `items.country`\n- `items.language`\n- `items.dark_mode`\n- `items.formats`\n- `items.formats.type`\n- `items.formats.schema`\n- `items.formats.model`\n- `items.formats.prompt`\n- `items.wait_until`\n- `items.wait_for_selector`\n- `items.delay_ms`\n- `items.viewport`\n- `items.viewport.width`\n- `items.viewport.height`\n- `items.duration`\n- `items.scenario`\n- `items.metadata`\n- `defaults`\n- `defaults.type`\n- `defaults.device`\n- `defaults.format`\n- `defaults.quality`\n- `defaults.full_page`\n- `defaults.block_ads`\n- `defaults.block_cookie_banners`\n- `defaults.scroll`\n- `defaults.include_html`\n- `defaults.country`\n- `defaults.language`\n- `defaults.dark_mode`\n- `defaults.formats`\n- `defaults.formats.type`\n- `defaults.formats.schema`\n- `defaults.formats.model`\n- `defaults.formats.prompt`\n- `defaults.wait_until`\n- `defaults.wait_for_selector`\n- `defaults.delay_ms`\n- `defaults.viewport`\n- `defaults.viewport.width`\n- `defaults.viewport.height`\n- `defaults.device_scale_factor`\n- `webhook_url` (required)\n- `webhook_secret`\n- `metadata`\n\n## Responses\n\n### 202 — Bulk job accepted.\n- `id`\n- `status`\n- `total`\n- `completed`\n- `failed`\n- `created_at`\n- `completed_at`\n- `total_credits_charged`\n- `total_billed_bytes`\n- `estimated_credits`\n- `webhook_url`\n- `rejected`\n- `rejected.index`\n- `rejected.url`\n- `rejected.code`\n- `rejected.message`\n\n### 400 — Bad request. When a `url` (or item URL) fails strict validation the\nerror code is `invalid_url` and the `details` object contains:\n- `field` — the request field that failed (e.g. `\"url\"`)\n- `url` — the rejected value\n- `reason` — one of: `scheme_missing`, `scheme_unsupported`,\n `scheme_separator_typo`, `host_empty`, `host_invalid`,\n `host_blocked_private`, `host_blocked_loopback`, `host_too_long`,\n `host_unicode_not_punycode`, `userinfo_present`, `url_too_long`,\n `control_chars`, `not_a_url`\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 401 — Unauthorized. The request carried no valid credential, and no work was\nperformed. The unified `Error` envelope carries one of the codes below\nin `error.code`; match on the code, never on the prose.\n\n- `invalid_api_key` — a bearer API key was presented and rejected:\n unknown, revoked, expired or malformed. The bearer-only operations\n (`/v1/webhook-deliveries*` among them) also return it when no\n `Authorization` header is sent. `GET /v1/account` is the exception\n to \"malformed\": it returns `invalid_api_key` only for a key that\n starts `sk_test_` or `sk_live_` and is unknown, revoked or expired.\n- `unauthorized` — the `Authorization` header is absent or malformed on\n an operation that also accepts a dashboard session (the dual-auth and\n billing operations). `GET /v1/account` also returns it, for no\n `Authorization` header and for any bearer value that does not start\n `sk_test_` or `sk_live_` (that value is checked as a dashboard\n session token).\n\nNot retryable as-is: supply a valid API key first.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 402 — Payment required. The account cannot fund this request, and no work was\nperformed. The unified `Error` envelope carries one of the billing codes\nbelow in `error.code`; match on the code, never on the prose.\n\n- `quota_exceeded` — the enforced balance for this request's meter\n cannot fund it. Capture endpoints (`/v1/scrape`, `/v1/fetch`,\n `/v1/screenshots`, `/v1/sitemap` and the bulk siblings) meter\n bandwidth: they reject when the balance cannot fund the request's\n byte reservation, and `error.details.required_bytes` and\n `error.details.available_bytes` report the bytes the request reserves\n and the bytes available. `/v1/search` meters credits.\n- `spending_cap_reached` — the request would push overage spend past the\n account's configured cap. Only reachable on a custom overage-enabled\n plan; standard plans stop at `quota_exceeded`.\n- `billing_entitlement_impaired` — the paid subscription is in a payment\n impairment (e.g. `past_due`). `error.message` names the reason.\n- `billing_entitlement_expired` — the paid subscription entitlement\n period has ended, or its dunning grace period has run out.\n\nNot retryable as-is: settle the balance, raise the cap, or restore the\nsubscription first. This response carries no `X-Quota-*` headers — they\ntravel with the 2xx responses of the operations that emit them.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 403 — Either of two bodies.\n\nOne or more URLs in the request are on ByteKit's blocklist. The whole request is\nrejected before anything is queued or billed. This body is NOT the unified `Error`\nenvelope: it carries no `status`, `http_status` or `failed_at`. `blocked` lists every\noffending URL with the rule that matched (`domain`, `tld`, `port` or `path`) and the\ncode that rule maps to (`host_forbidden` for the first three, `path_forbidden` for\n`path`).\n\n`proxy_refused`: every item in the batch was refused because our proxy provider does not allow\nrequests to its host. This is the unified `Error` envelope, and `details.rejected` lists\neach item as `{ index, url, code, message }`. Nothing is queued or billed. When only some\nitems are refused the batch is accepted with `202` and those items are listed in\n`rejected`.\n- `error`\n- `error.code`\n- `error.message`\n- `blocked`\n- `blocked.url`\n- `blocked.rule_type`\n- `blocked.error_code`\n- `status`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 422 — Validation error. `bulk_too_large` is returned when the item count\nexceeds the account plan's `max_bulk_size` cap (also surfaced as\n`max_bulk_size` on `GET /v1/account`). `validation_error` is\nreturned when the request body contains an unrecognized key\nanywhere in the top-level object, an `items[]` entry, or\n`defaults` — all three reject unknown keys with a 422\n`validation_error` whose `details` message names the offending\nkey, instead of silently discarding it. The two nested objects\ndo not accept the same field set: `device_scale_factor` is\n`defaults`-only (rejected per item), and `duration`/`scenario`\nare `items[]`-only (rejected under `defaults`). `metadata` is\nvalid both at the top level of the body and per item, but is\nrejected with this same 422 if placed under `defaults`. A\n`viewport` outside width 360 to 2544 or height 1 to 1297, under\n`defaults` or on an item, is a 422 `validation_error` too.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`"
|
|
26
26
|
},
|
|
27
27
|
"api/bulk/deletebulk": {
|
|
28
28
|
"title": "Cancel a bulk job",
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
"api/fetch-bulk/createfetchbulk": {
|
|
63
63
|
"title": "Bulk fetch URLs",
|
|
64
64
|
"section": "API Reference",
|
|
65
|
-
"body": "# Bulk fetch URLs\n\nEnqueues multiple URLs for HTTP fetching. Results delivered via webhook.\nDoes not support options that require page rendering (wait_for_selector, etc.).\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/fetch/bulk/{id}` whenever\n`recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 2 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 20 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's per-item override budget),\nwhich reaches 16.8 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 2 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**POST** `/v1/fetch/bulk`\n\n## Request Body\n\n- `urls` (required)\n- `urls.url`\n- `urls.country`\n- `urls.cache_ttl`\n- `defaults`\n- `defaults.country`\n- `defaults.cache_ttl`\n- `webhook_url` (required)\n- `webhook_secret`\n- `metadata`\n\n## Responses\n\n### 202 — Fetch bulk job accepted.\n- `id`\n- `status`\n- `total`\n- `completed`\n- `failed`\n- `created_at`\n- `completed_at`\n- `total_credits_charged`\n- `total_billed_bytes`\n- `estimated_credits`\n- `webhook_url`\n\n### 400 — Bad request. When a `url` (or item URL) fails strict validation the\nerror code is `invalid_url` and the `details` object contains:\n- `field` — the request field that failed (e.g. `\"url\"`)\n- `url` — the rejected value\n- `reason` — one of: `scheme_missing`, `scheme_unsupported`,\n `scheme_separator_typo`, `host_empty`, `host_invalid`,\n `host_blocked_private`, `host_blocked_loopback`, `host_too_long`,\n `host_unicode_not_punycode`, `userinfo_present`, `url_too_long`,\n `control_chars`, `not_a_url`\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 401 — Unauthorized. The request carried no valid credential, and no work was\nperformed. The unified `Error` envelope carries one of the codes below\nin `error.code`; match on the code, never on the prose.\n\n- `invalid_api_key` — a bearer API key was presented and rejected:\n unknown, revoked, expired or malformed. The bearer-only operations\n (`/v1/webhook-deliveries*` among them) also return it when no\n `Authorization` header is sent. `GET /v1/account` is the exception\n to \"malformed\": it returns `invalid_api_key` only for a key that\n starts `sk_test_` or `sk_live_` and is unknown, revoked or expired.\n- `unauthorized` — the `Authorization` header is absent or malformed on\n an operation that also accepts a dashboard session (the dual-auth and\n billing operations). `GET /v1/account` also returns it, for no\n `Authorization` header and for any bearer value that does not start\n `sk_test_` or `sk_live_` (that value is checked as a dashboard\n session token).\n\nNot retryable as-is: supply a valid API key first.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 402 — Payment required. The account cannot fund this request, and no work was\nperformed. The unified `Error` envelope carries one of the billing codes\nbelow in `error.code`; match on the code, never on the prose.\n\n- `quota_exceeded` — the enforced balance for this request's meter\n cannot fund it. Capture endpoints (`/v1/scrape`, `/v1/fetch`,\n `/v1/screenshots`, `/v1/sitemap` and the bulk siblings) meter\n bandwidth: they reject when the balance cannot fund the request's\n byte reservation, and `error.details.required_bytes` and\n `error.details.available_bytes` report the bytes the request reserves\n and the bytes available. `/v1/search` meters credits.\n- `spending_cap_reached` — the request would push overage spend past the\n account's configured cap. Only reachable on a custom overage-enabled\n plan; standard plans stop at `quota_exceeded`.\n- `billing_entitlement_impaired` — the paid subscription is in a payment\n impairment (e.g. `past_due`). `error.message` names the reason.\n- `billing_entitlement_expired` — the paid subscription entitlement\n period has ended, or its dunning grace period has run out.\n\nNot retryable as-is: settle the balance, raise the cap, or restore the\nsubscription first. This response carries no `X-Quota-*` headers — they\ntravel with the 2xx responses of the operations that emit them.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 403 —
|
|
65
|
+
"body": "# Bulk fetch URLs\n\nEnqueues multiple URLs for HTTP fetching. Results delivered via webhook.\nDoes not support options that require page rendering (wait_for_selector, etc.).\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/fetch/bulk/{id}` whenever\n`recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 2 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 20 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's per-item override budget),\nwhich reaches 16.8 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 2 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**POST** `/v1/fetch/bulk`\n\n## Request Body\n\n- `urls` (required)\n- `urls.url`\n- `urls.country`\n- `urls.cache_ttl`\n- `defaults`\n- `defaults.country`\n- `defaults.cache_ttl`\n- `webhook_url` (required)\n- `webhook_secret`\n- `metadata`\n\n## Responses\n\n### 202 — Fetch bulk job accepted.\n- `id`\n- `status`\n- `total`\n- `completed`\n- `failed`\n- `created_at`\n- `completed_at`\n- `total_credits_charged`\n- `total_billed_bytes`\n- `estimated_credits`\n- `webhook_url`\n- `rejected`\n- `rejected.index`\n- `rejected.url`\n- `rejected.code`\n- `rejected.message`\n\n### 400 — Bad request. When a `url` (or item URL) fails strict validation the\nerror code is `invalid_url` and the `details` object contains:\n- `field` — the request field that failed (e.g. `\"url\"`)\n- `url` — the rejected value\n- `reason` — one of: `scheme_missing`, `scheme_unsupported`,\n `scheme_separator_typo`, `host_empty`, `host_invalid`,\n `host_blocked_private`, `host_blocked_loopback`, `host_too_long`,\n `host_unicode_not_punycode`, `userinfo_present`, `url_too_long`,\n `control_chars`, `not_a_url`\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 401 — Unauthorized. The request carried no valid credential, and no work was\nperformed. The unified `Error` envelope carries one of the codes below\nin `error.code`; match on the code, never on the prose.\n\n- `invalid_api_key` — a bearer API key was presented and rejected:\n unknown, revoked, expired or malformed. The bearer-only operations\n (`/v1/webhook-deliveries*` among them) also return it when no\n `Authorization` header is sent. `GET /v1/account` is the exception\n to \"malformed\": it returns `invalid_api_key` only for a key that\n starts `sk_test_` or `sk_live_` and is unknown, revoked or expired.\n- `unauthorized` — the `Authorization` header is absent or malformed on\n an operation that also accepts a dashboard session (the dual-auth and\n billing operations). `GET /v1/account` also returns it, for no\n `Authorization` header and for any bearer value that does not start\n `sk_test_` or `sk_live_` (that value is checked as a dashboard\n session token).\n\nNot retryable as-is: supply a valid API key first.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 402 — Payment required. The account cannot fund this request, and no work was\nperformed. The unified `Error` envelope carries one of the billing codes\nbelow in `error.code`; match on the code, never on the prose.\n\n- `quota_exceeded` — the enforced balance for this request's meter\n cannot fund it. Capture endpoints (`/v1/scrape`, `/v1/fetch`,\n `/v1/screenshots`, `/v1/sitemap` and the bulk siblings) meter\n bandwidth: they reject when the balance cannot fund the request's\n byte reservation, and `error.details.required_bytes` and\n `error.details.available_bytes` report the bytes the request reserves\n and the bytes available. `/v1/search` meters credits.\n- `spending_cap_reached` — the request would push overage spend past the\n account's configured cap. Only reachable on a custom overage-enabled\n plan; standard plans stop at `quota_exceeded`.\n- `billing_entitlement_impaired` — the paid subscription is in a payment\n impairment (e.g. `past_due`). `error.message` names the reason.\n- `billing_entitlement_expired` — the paid subscription entitlement\n period has ended, or its dunning grace period has run out.\n\nNot retryable as-is: settle the balance, raise the cap, or restore the\nsubscription first. This response carries no `X-Quota-*` headers — they\ntravel with the 2xx responses of the operations that emit them.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 403 — Either of two bodies.\n\nOne or more URLs in the request are on ByteKit's blocklist. The whole request is\nrejected before anything is queued or billed. This body is NOT the unified `Error`\nenvelope: it carries no `status`, `http_status` or `failed_at`. `blocked` lists every\noffending URL with the rule that matched (`domain`, `tld`, `port` or `path`) and the\ncode that rule maps to (`host_forbidden` for the first three, `path_forbidden` for\n`path`).\n\n`proxy_refused`: every item in the batch was refused because our proxy provider does not allow\nrequests to its host. This is the unified `Error` envelope, and `details.rejected` lists\neach item as `{ index, url, code, message }`. Nothing is queued or billed. When only some\nitems are refused the batch is accepted with `202` and those items are listed in\n`rejected`.\n- `error`\n- `error.code`\n- `error.message`\n- `blocked`\n- `blocked.url`\n- `blocked.rule_type`\n- `blocked.error_code`\n- `status`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 422 — Validation error. `bulk_too_large` is returned when the item count\nexceeds the account plan's `max_bulk_size` cap (also surfaced as\n`max_bulk_size` on `GET /v1/account`).\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`"
|
|
66
66
|
},
|
|
67
67
|
"api/fetch-bulk/getfetchbulk": {
|
|
68
68
|
"title": "Get fetch bulk job status",
|
|
@@ -157,7 +157,7 @@
|
|
|
157
157
|
"api/scrape-bulk/createscrapebulk": {
|
|
158
158
|
"title": "Bulk scrape URLs",
|
|
159
159
|
"section": "API Reference",
|
|
160
|
-
"body": "# Bulk scrape URLs\n\nEnqueues multiple URLs for scraping. Results delivered via webhook.\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/scrape/bulk/{id}` whenever\n`recovery_required` is true.\n\n**Unknown keys.** An unknown key on an `items[]` entry, or at the top level of\nthe body, is rejected with `422 validation_error`. An unknown key inside\n`defaults` is not: it is dropped without a warning and the request is accepted\nwith `202`. The exception is `cookies` and `headers`, on an item or in `defaults`: they\nanswer `400 validation_error`.\n\n**POST** `/v1/scrape/bulk`\n\n## Request Body\n\n- `urls`\n- `items`\n- `items.url`\n- `items.formats`\n- `items.formats.type`\n- `items.formats.schema`\n- `items.formats.model`\n- `items.formats.prompt`\n- `items.country`\n- `items.delay_ms`\n- `items.timeout_ms`\n- `items.metadata`\n- `items.clean_markdown`\n- `items.custom`\n- `defaults`\n- `defaults.formats`\n- `defaults.formats.type`\n- `defaults.formats.schema`\n- `defaults.formats.model`\n- `defaults.formats.prompt`\n- `defaults.country`\n- `defaults.delay_ms`\n- `defaults.timeout_ms`\n- `defaults.clean_markdown`\n- `webhook_url` (required)\n- `webhook_secret`\n- `metadata`\n- `custom`\n\n## Responses\n\n### 202 — Bulk scrape job accepted.\n- `id`\n- `status`\n- `total`\n- `completed`\n- `failed`\n- `created_at`\n- `completed_at`\n- `total_credits_charged`\n- `total_billed_bytes`\n- `estimated_credits`\n- `webhook_url`\n- `rejected`\n- `rejected.index`\n- `rejected.url`\n- `rejected.code`\n- `rejected.message`\n\n### 400 — Bad request. When a `url` (or item URL) fails strict validation the\nerror code is `invalid_url` and the `details` object contains:\n- `field` — the request field that failed (e.g. `\"url\"`)\n- `url` — the rejected value\n- `reason` — one of: `scheme_missing`, `scheme_unsupported`,\n `scheme_separator_typo`, `host_empty`, `host_invalid`,\n `host_blocked_private`, `host_blocked_loopback`, `host_too_long`,\n `host_unicode_not_punycode`, `userinfo_present`, `url_too_long`,\n `control_chars`, `not_a_url`\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 401 — Unauthorized. The request carried no valid credential, and no work was\nperformed. The unified `Error` envelope carries one of the codes below\nin `error.code`; match on the code, never on the prose.\n\n- `invalid_api_key` — a bearer API key was presented and rejected:\n unknown, revoked, expired or malformed. The bearer-only operations\n (`/v1/webhook-deliveries*` among them) also return it when no\n `Authorization` header is sent. `GET /v1/account` is the exception\n to \"malformed\": it returns `invalid_api_key` only for a key that\n starts `sk_test_` or `sk_live_` and is unknown, revoked or expired.\n- `unauthorized` — the `Authorization` header is absent or malformed on\n an operation that also accepts a dashboard session (the dual-auth and\n billing operations). `GET /v1/account` also returns it, for no\n `Authorization` header and for any bearer value that does not start\n `sk_test_` or `sk_live_` (that value is checked as a dashboard\n session token).\n\nNot retryable as-is: supply a valid API key first.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 402 — Payment required. The account cannot fund this request, and no work was\nperformed. The unified `Error` envelope carries one of the billing codes\nbelow in `error.code`; match on the code, never on the prose.\n\n- `quota_exceeded` — the enforced balance for this request's meter\n cannot fund it. Capture endpoints (`/v1/scrape`, `/v1/fetch`,\n `/v1/screenshots`, `/v1/sitemap` and the bulk siblings) meter\n bandwidth: they reject when the balance cannot fund the request's\n byte reservation, and `error.details.required_bytes` and\n `error.details.available_bytes` report the bytes the request reserves\n and the bytes available. `/v1/search` meters credits.\n- `spending_cap_reached` — the request would push overage spend past the\n account's configured cap. Only reachable on a custom overage-enabled\n plan; standard plans stop at `quota_exceeded`.\n- `billing_entitlement_impaired` — the paid subscription is in a payment\n impairment (e.g. `past_due`). `error.message` names the reason.\n- `billing_entitlement_expired` — the paid subscription entitlement\n period has ended, or its dunning grace period has run out.\n\nNot retryable as-is: settle the balance, raise the cap, or restore the\nsubscription first. This response carries no `X-Quota-*` headers — they\ntravel with the 2xx responses of the operations that emit them.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 403 —
|
|
160
|
+
"body": "# Bulk scrape URLs\n\nEnqueues multiple URLs for scraping. Results delivered via webhook.\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/scrape/bulk/{id}` whenever\n`recovery_required` is true.\n\n**Unknown keys.** An unknown key on an `items[]` entry, or at the top level of\nthe body, is rejected with `422 validation_error`. An unknown key inside\n`defaults` is not: it is dropped without a warning and the request is accepted\nwith `202`. The exception is `cookies` and `headers`, on an item or in `defaults`: they\nanswer `400 validation_error`.\n\n**POST** `/v1/scrape/bulk`\n\n## Request Body\n\n- `urls`\n- `items`\n- `items.url`\n- `items.formats`\n- `items.formats.type`\n- `items.formats.schema`\n- `items.formats.model`\n- `items.formats.prompt`\n- `items.country`\n- `items.delay_ms`\n- `items.timeout_ms`\n- `items.metadata`\n- `items.clean_markdown`\n- `items.custom`\n- `defaults`\n- `defaults.formats`\n- `defaults.formats.type`\n- `defaults.formats.schema`\n- `defaults.formats.model`\n- `defaults.formats.prompt`\n- `defaults.country`\n- `defaults.delay_ms`\n- `defaults.timeout_ms`\n- `defaults.clean_markdown`\n- `webhook_url` (required)\n- `webhook_secret`\n- `metadata`\n- `custom`\n\n## Responses\n\n### 202 — Bulk scrape job accepted.\n- `id`\n- `status`\n- `total`\n- `completed`\n- `failed`\n- `created_at`\n- `completed_at`\n- `total_credits_charged`\n- `total_billed_bytes`\n- `estimated_credits`\n- `webhook_url`\n- `rejected`\n- `rejected.index`\n- `rejected.url`\n- `rejected.code`\n- `rejected.message`\n\n### 400 — Bad request. When a `url` (or item URL) fails strict validation the\nerror code is `invalid_url` and the `details` object contains:\n- `field` — the request field that failed (e.g. `\"url\"`)\n- `url` — the rejected value\n- `reason` — one of: `scheme_missing`, `scheme_unsupported`,\n `scheme_separator_typo`, `host_empty`, `host_invalid`,\n `host_blocked_private`, `host_blocked_loopback`, `host_too_long`,\n `host_unicode_not_punycode`, `userinfo_present`, `url_too_long`,\n `control_chars`, `not_a_url`\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 401 — Unauthorized. The request carried no valid credential, and no work was\nperformed. The unified `Error` envelope carries one of the codes below\nin `error.code`; match on the code, never on the prose.\n\n- `invalid_api_key` — a bearer API key was presented and rejected:\n unknown, revoked, expired or malformed. The bearer-only operations\n (`/v1/webhook-deliveries*` among them) also return it when no\n `Authorization` header is sent. `GET /v1/account` is the exception\n to \"malformed\": it returns `invalid_api_key` only for a key that\n starts `sk_test_` or `sk_live_` and is unknown, revoked or expired.\n- `unauthorized` — the `Authorization` header is absent or malformed on\n an operation that also accepts a dashboard session (the dual-auth and\n billing operations). `GET /v1/account` also returns it, for no\n `Authorization` header and for any bearer value that does not start\n `sk_test_` or `sk_live_` (that value is checked as a dashboard\n session token).\n\nNot retryable as-is: supply a valid API key first.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 402 — Payment required. The account cannot fund this request, and no work was\nperformed. The unified `Error` envelope carries one of the billing codes\nbelow in `error.code`; match on the code, never on the prose.\n\n- `quota_exceeded` — the enforced balance for this request's meter\n cannot fund it. Capture endpoints (`/v1/scrape`, `/v1/fetch`,\n `/v1/screenshots`, `/v1/sitemap` and the bulk siblings) meter\n bandwidth: they reject when the balance cannot fund the request's\n byte reservation, and `error.details.required_bytes` and\n `error.details.available_bytes` report the bytes the request reserves\n and the bytes available. `/v1/search` meters credits.\n- `spending_cap_reached` — the request would push overage spend past the\n account's configured cap. Only reachable on a custom overage-enabled\n plan; standard plans stop at `quota_exceeded`.\n- `billing_entitlement_impaired` — the paid subscription is in a payment\n impairment (e.g. `past_due`). `error.message` names the reason.\n- `billing_entitlement_expired` — the paid subscription entitlement\n period has ended, or its dunning grace period has run out.\n\nNot retryable as-is: settle the balance, raise the cap, or restore the\nsubscription first. This response carries no `X-Quota-*` headers — they\ntravel with the 2xx responses of the operations that emit them.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 403 — Either of two bodies.\n\nOne or more URLs in the request are on ByteKit's blocklist. The whole request is\nrejected before anything is queued or billed. This body is NOT the unified `Error`\nenvelope: it carries no `status`, `http_status` or `failed_at`. `blocked` lists every\noffending URL with the rule that matched (`domain`, `tld`, `port` or `path`) and the\ncode that rule maps to (`host_forbidden` for the first three, `path_forbidden` for\n`path`).\n\n`proxy_refused`: every item in the batch was refused because our proxy provider does not allow\nrequests to its host (if any of them was refused for a `.pdf` path, the answer is `415`\ninstead). This is the unified `Error` envelope, and `details.rejected` lists each item as\n`{ index, url, code, message }`. Nothing is queued or billed. When only some items are\nrefused the batch is accepted with `202` and those items are listed in `rejected`.\n- `error`\n- `error.code`\n- `error.message`\n- `blocked`\n- `blocked.url`\n- `blocked.rule_type`\n- `blocked.error_code`\n- `status`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 415 — `unsupported_content_type`: every item in the batch was refused, at least one of them because\nits URL path ends in `.pdf` (the path, lowercased; the query string and fragment are not\nlooked at). Nothing is queued or billed. `details.rejected` lists each item as\n`{ index, url, code, message }`. When only some items are refused the batch is accepted\nwith `202` and those items are listed in `rejected` instead.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`\n\n### 422 — Validation error. `bulk_too_large` is returned when the count of\naccepted items exceeds the account plan's `max_bulk_size` cap (also\nsurfaced as `max_bulk_size` on `GET /v1/account`). Items listed\nin `rejected` do not count.\n- `status`\n- `error`\n- `error.code`\n- `error.message`\n- `error.http_status`\n- `error.failed_at`\n- `error.details`"
|
|
161
161
|
},
|
|
162
162
|
"api/scrape-bulk/getscrapebulk": {
|
|
163
163
|
"title": "Get scrape bulk job status",
|
|
@@ -347,7 +347,7 @@
|
|
|
347
347
|
"guides/bulk": {
|
|
348
348
|
"title": "Bulk",
|
|
349
349
|
"section": "Guides",
|
|
350
|
-
"body": "# Bulk\n\nSubmit many URLs in one request — which of the three bulk APIs to use, how results arrive, how to cancel a job, what it costs, and the limits.\n\nByteKit has three bulk APIs. Each takes a list of URLs in one request, answers `202` with a job id, and does the work in the background.\nYou get the results by webhook when the job completes, and you can also read them by polling. A job that is cancelled or failed sends no webhook, so poll it.\n\n## Which bulk API to use\n\n| You want | Use | Entries are |\n| ------------------------------------------------------- | ---------------------- | ------------------------------------------------------------ |\n| Screenshots, or screenshots and scrapes in one job | `POST /v1/bulk` | `urls`, or `items` that each choose `screenshot` or `scrape` |\n| Scrapes only, as `raw`, `markdown`, `links` or `images` | `POST /v1/scrape/bulk` | `urls`, or `items` with per-URL options |\n| The raw response from each URL | `POST /v1/fetch/bulk` | `urls`, as strings or small objects |\n\nThe three do not share one field set. For example, `clean_markdown` is accepted on `/v1/scrape/bulk` and\nrejected on `/v1/bulk` with a `422`, and `wait_until` is accepted on `/v1/bulk` and rejected on a\n`/v1/scrape/bulk` item with a `422`. The API Reference lists the fields of each:\n[Bulk](https://bytekit.com/docs/api/bulk/createbulk), [Scrape bulk](https://bytekit.com/docs/api/scrape-bulk/createscrapebulk) and\n[Fetch bulk](https://bytekit.com/docs/api/fetch-bulk/createfetchbulk).\n\n`/v1/fetch/bulk` does not render pages. A `cookies` or `headers` field in its body, in `defaults`, or in a `urls` object returns\n`400 validation_error` with the message `cookies is no longer accepted: caller-supplied cookies and headers were removed from the capture API. Every capture presents ByteKit's own identity to the target site.` (the message for `headers` is the same with `headers` in place of the leading `cookies`; for a `urls` object it starts with `Item 0: `, using the object's position). No bulk route accepts `cookies` or `headers`, so there is no other route to send them to. A `wait_for_selector`, `delay_ms` or `wait_until` field in the same three places returns `400 validation_error` with the message `Use /v1/bulk for browser-backed options.`, with the same `Item 0: ` prefix, because `/v1/bulk` accepts all three. Naming a scrape format such as `markdown` as `format` is also a `400`. For\nMarkdown, links or images from a batch, use `/v1/scrape/bulk`.\n\n## Submit a job\n\nAll three create routes require `webhook_url`, an `https://` URL. An `http://` URL is rejected with\n`400 invalid_url` and the reason `scheme_unsupported`. Set `webhook_secret` to have the deliveries signed;\nsee the [Webhooks guide](https://bytekit.com/docs/guides/webhooks) for verification.\n\n### Mixed screenshots and scrapes\n\n```bash\ncurl -i -X POST https://api.bytekit.com/v1/bulk \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"items\": [\n {\"url\": \"https://example.com/?page=bulk-guide-1\", \"type\": \"screenshot\"},\n {\"url\": \"https://example.com/?page=bulk-guide-1\", \"type\": \"scrape\", \"formats\": [\"markdown\"]}\n ],\n \"webhook_url\": \"https://hooks.example.com/bytekit\"\n }'\n```\n\n```json\n{\n \"id\": \"bulk_01a125a61d9777909cff22879e7d0165\",\n \"status\": \"processing\",\n \"total\": 2,\n \"completed\": 0,\n \"failed\": 0,\n \"total_credits_charged\": 0,\n \"total_billed_bytes\": null,\n \"estimated_credits\": 2.5,\n \"webhook_url\": \"https://hooks.example.com/bytekit\",\n \"created_at\": \"2026-10-10T11:50:05.984Z\",\n \"completed_at\": null\n}\n```\n\n> This request was run for real and returned `202`.\n\nKeep the `id`: it is how you read and cancel the job. `total_billed_bytes` is `null` here because nothing has completed yet.\n\n### Scrapes only\n\n```bash\ncurl -i -X POST https://api.bytekit.com/v1/scrape/bulk \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"urls\": [\"https://example.com/?page=bulk-guide-2\"],\n \"defaults\": {\"formats\": [\"markdown\"]},\n \"webhook_url\": \"https://hooks.example.com/bytekit\"\n }'\n```\n\n> This request was run for real and returned `202`, with the same job envelope as above.\n\n### Raw fetches\n\n```bash\ncurl -i -X POST https://api.bytekit.com/v1/fetch/bulk \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"urls\": [\"https://example.com/?page=bulk-guide-3\"],\n \"webhook_url\": \"https://hooks.example.com/bytekit\"\n }'\n```\n\n> This request was run for real and returned `202`, with the same job envelope as above.\n\n### `urls` or `items`\n\nOn `/v1/bulk` and `/v1/scrape/bulk`, send `urls` or `items`, not both. A request with both returns\n`422 validation_error` (`Provide either urls or items, not both.`), and a request with neither returns\n`422 validation_error` (`Either urls or items must be provided.`).\n\n- `urls` is a plain list of URLs. Each one takes the values in `defaults`.\n- `items` is a list of objects, each with a `url` and its own options. An option on an item wins over the\n same option in `defaults`.\n- On `/v1/bulk`, an entry that names no `type` is a screenshot unless `defaults.type` says `scrape`. A bare\n `urls` list on `/v1/bulk` therefore produces screenshots, and with `\"defaults\": {\"type\": \"scrape\"}` it\n produces scrapes. Both were run for real.\n- `/v1/fetch/bulk` has no `items`. It takes `urls`, as strings or as objects with `url`, `country` and\n `cache_ttl`, and a body with `items` and no `urls` returns `422 validation_error`.\n\n## Get the results\n\n### By webhook\n\nWhen the job reaches `completed`, ByteKit sends a `POST` to your `webhook_url` with the header `X-ByteKit-Event: bulk.completed`, so you can dispatch on the header without reading the body. A job that ends `cancelled` or `failed` gets no webhook, so poll it. The\n[Scraping guide](https://bytekit.com/docs/guides/scraping#webhook-event-header) lists the other event types.\n\nThe body is bounded: it carries at most 500 complete items and 1 MiB of JSON. These are its fields, from\nthe API Reference (this page shows no captured delivery):\n\n| Field | Meaning |\n| ------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `bulk_id` | The job id |\n| `status` | `completed` |\n| `total`, `completed`, `failed` | Counts for the whole job |\n| `total_billed_bytes` | Bandwidth billed for the job, in bytes, or `null` when it cannot be reported in full |\n| `total_credits_charged` | Deprecated: read `total_billed_bytes` instead |\n| `webhook_url` | The `webhook_url` the job was created with |\n| `items` | Complete item records, up to 500. Each has an `id`, a `type` and a `status` (`success`, `completed`, `failed` or `cancelled`), and may carry `error_code` and `error_message` |\n| `recovery_api` | `fetch`, `scrape` or `mixed`: which API created the job |\n| `recovery_url` | The path to read the rest of the results from |\n| `manifest_item_count` | How many items this body carries |\n| `manifest_items_complete` | `true` when every item that reached a final status is in `items` |\n| `manifest_artifacts_complete` | `true` when every included completed item has a usable result reference |\n| `manifest_complete` | `true` when both of the above are `true` |\n| `recovery_required` | The inverse of `manifest_complete` |\n\nWhen `recovery_required` is `true`, the body does not hold the whole job. Read the rest from\n`recovery_url` with cursors: request it, then repeat the request with `?cursor=` set to the `next_cursor`\nyou were given, until `has_more` is `false`. `recovery_url` depends on the API that created the job:\n\n| Created with | `recovery_url` |\n| ---------------------- | --------------------------- |\n| `POST /v1/bulk` | `/v1/bulk/{id}/screenshots` |\n| `POST /v1/scrape/bulk` | `/v1/scrape/bulk/{id}` |\n| `POST /v1/fetch/bulk` | `/v1/fetch/bulk/{id}` |\n\nA delivery can arrive more than once or late. Use `bulk_id` together with each item `id` to process an item\nonce.\n\n### By polling\n\nEach API has `GET` routes for its own jobs. The job routes (`GET /v1/bulk/{id}`,\n`GET /v1/scrape/bulk/{id}` and `GET /v1/fetch/bulk/{id}`) answer `202` while the job is `processing` and `200` once it is `completed`, `failed` or `cancelled`. `GET /v1/bulk/{id}/screenshots` answers `200` whatever the job's status; an item that\nhas not completed shows `null` in `billing`.\n\n| Created with | Job status | Items |\n| ---------------------- | -------------------------- | --------------------------------------------------------- |\n| `POST /v1/bulk` | `GET /v1/bulk/{id}` | `GET /v1/bulk/{id}/screenshots`, whatever the item `type` |\n| `POST /v1/scrape/bulk` | `GET /v1/scrape/bulk/{id}` | the same response, in `items` |\n| `POST /v1/fetch/bulk` | `GET /v1/fetch/bulk/{id}` | the same response, in `items` |\n\n`GET /v1/bulk/{id}/screenshots` lists the items of a mixed job and is not limited to screenshots; each item\nhas a `type` of `screenshot` or `scrape`. Unless the job is cancelled, its `status` is `processing` until every item has completed or failed, and `completed` after. A `completed` job can have a non-zero `failed`; read `failed` to tell. The other values are `failed` and `cancelled`.\n\n```bash\ncurl -i https://api.bytekit.com/v1/bulk/bulk_01a125a61d9777909cff22879e7d0165 \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\"\n```\n\n```json\n{\n \"id\": \"bulk_01a125a61d9777909cff22879e7d0165\",\n \"status\": \"completed\",\n \"total\": 2,\n \"completed\": 2,\n \"failed\": 0,\n \"total_credits_charged\": 0,\n \"total_billed_bytes\": 1002,\n \"estimated_credits\": null,\n \"webhook_url\": \"https://hooks.example.com/bytekit\",\n \"created_at\": \"2026-10-10T11:50:05.951Z\",\n \"completed_at\": \"2026-10-10T11:50:16.313Z\"\n}\n```\n\n> This request was run for real and returned `200`. Called while the job was still running, it returned `202`.\n\nThe items of that job:\n\n```bash\ncurl -i https://api.bytekit.com/v1/bulk/bulk_01a125a61d9777909cff22879e7d0165/screenshots \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\"\n```\n\n```json\n{\n \"bulk_id\": \"bulk_01a125a61d9777909cff22879e7d0165\",\n \"items\": [\n {\n \"type\": \"screenshot\",\n \"id\": \"ss_01a125a61d9d744299721fb4b915b626\",\n \"status\": \"completed\",\n \"url\": \"https://example.com/?page=bulk-guide-1\",\n \"image_url\": \"https://…\",\n \"billing\": { \"raw_bytes\": 334, \"multiplier\": 1.5, \"billed_bytes\": 501 },\n \"error_code\": null\n },\n {\n \"type\": \"scrape\",\n \"id\": \"sc_01a125a61d9973569644148e9697b8ba\",\n \"status\": \"completed\",\n \"url\": \"https://example.com/?page=bulk-guide-1\",\n \"content_url\": \"https://…\",\n \"markdown_url\": \"https://…\",\n \"billing\": { \"raw_bytes\": 334, \"multiplier\": 1.5, \"billed_bytes\": 501 },\n \"error_code\": null\n }\n ],\n \"total\": 2,\n \"next_cursor\": null,\n \"has_more\": false,\n \"job_counters\": { \"total\": 2, \"completed\": 2, \"failed\": 0 }\n}\n```\n\n> This request was run for real and returned `200`. Links are shortened, and other fields, such as\n> `page_title`, `artifacts` and `created_at`, are left out.\n\nThe item routes take `limit`, `cursor` and `status` (`pending`, `processing`, `completed`, `failed` or\n`cancelled`). `limit` runs from 1 to 500; its default is 100 on `/v1/bulk/{id}/screenshots` and 500 on the\nother two. Pass the `next_cursor` of one page as `cursor` of the next while `has_more` is `true`, and reuse\nthe same `status` filter for the whole walk.\n\nDownload links in the item lists are signed and expire. `content_url`, `markdown_url` and `image_url` on\n`/v1/bulk/{id}/screenshots` and `content_url` on `/v1/fetch/bulk/{id}` are valid for 600 seconds; read the\njob again for a fresh link. On `/v1/scrape/bulk/{id}`, a `raw` or `markdown` result up to 10 MiB is returned\ninline, and a larger one is replaced by a signed link valid for 24 hours.\n\nRead a job through the routes of the API that created it. Another API's routes can answer `200` with\nsomething else: in a run for real, `GET /v1/fetch/bulk/{id}` on a `POST /v1/bulk` job returned `200` with an\nempty `items` list.\n\n### Listing jobs\n\n`GET /v1/bulk` lists your bulk jobs, most recent first, whichever API created them. It takes `status`\n(`processing`, `completed`, `failed` or `cancelled`), `limit` (1 to 100, default 25) and `cursor`. Follow\n`next_cursor` while `has_more` is `true`. Each entry is the job envelope without `items`.\n\n```bash\ncurl -i \"https://api.bytekit.com/v1/bulk?limit=2\" \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\"\n```\n\n> This request was run for real and returned `200` with `data`, `next_cursor` and `has_more`.\n\n### Checking bulk concurrency\n\n`GET /v1/bulk/concurrency` returns `{ active, limit }`: how many of your account's bulk concurrency slots\nare in use, and your plan's maximum concurrency. Compare the two to see whether your jobs are held at the\ncap. `active` is `null` when the count cannot be read right now; it is not zero. A slot whose release never\narrived drops out of the count after 5 minutes.\n\n## Cancel a job\n\n`DELETE /v1/bulk/{id}` cancels a job that is still running. It takes the id from any of the three create\nroutes. `/v1/scrape/bulk/{id}` and `/v1/fetch/bulk/{id}` have no `DELETE`; they answer `404`.\n\nCancelling drains the items that are still waiting to start and refunds the quota held for exactly those.\nItems that already completed or are in progress are not refunded by the cancel. A failed item adds nothing to `total_billed_bytes`, and on `GET /v1/bulk/{id}/screenshots` it shows `null` in `billing`. Repeating a `DELETE` is safe: on a job that is already `completed`, `failed` or `cancelled` it retu\n\n---\n[Truncated to the 16384-byte per-page limit — this page is 22715 bytes in full. The text cut here is not searchable either: search_docs matches only the part kept above. Read all of it at https://bytekit.com/docs/guides/bulk]"
|
|
350
|
+
"body": "# Bulk\n\nSubmit many URLs in one request — which of the three bulk APIs to use, how results arrive, how to cancel a job, what it costs, and the limits.\n\nByteKit has three bulk APIs. Each takes a list of URLs in one request, answers `202` with a job id, and does the work in the background.\nYou get the results by webhook when the job completes, and you can also read them by polling. A job that is cancelled or failed sends no webhook, so poll it.\n\n## Which bulk API to use\n\n| You want | Use | Entries are |\n| ------------------------------------------------------- | ---------------------- | ------------------------------------------------------------ |\n| Screenshots, or screenshots and scrapes in one job | `POST /v1/bulk` | `urls`, or `items` that each choose `screenshot` or `scrape` |\n| Scrapes only, as `raw`, `markdown`, `links` or `images` | `POST /v1/scrape/bulk` | `urls`, or `items` with per-URL options |\n| The raw response from each URL | `POST /v1/fetch/bulk` | `urls`, as strings or small objects |\n\nThe three do not share one field set. For example, `clean_markdown` is accepted on `/v1/scrape/bulk` and\nrejected on `/v1/bulk` with a `422`, and `wait_until` is accepted on `/v1/bulk` and rejected on a\n`/v1/scrape/bulk` item with a `422`. The API Reference lists the fields of each:\n[Bulk](https://bytekit.com/docs/api/bulk/createbulk), [Scrape bulk](https://bytekit.com/docs/api/scrape-bulk/createscrapebulk) and\n[Fetch bulk](https://bytekit.com/docs/api/fetch-bulk/createfetchbulk).\n\n`/v1/fetch/bulk` does not render pages. A `cookies` or `headers` field in its body, in `defaults`, or in a `urls` object returns\n`400 validation_error` with the message `cookies is no longer accepted: caller-supplied cookies and headers were removed from the capture API. Every capture presents ByteKit's own identity to the target site.` (the message for `headers` is the same with `headers` in place of the leading `cookies`; for a `urls` object it starts with `Item 0: `, using the object's position). No bulk route accepts `cookies` or `headers`, so there is no other route to send them to. A `wait_for_selector`, `delay_ms` or `wait_until` field in the same three places returns `400 validation_error` with the message `Use /v1/bulk for browser-backed options.`, with the same `Item 0: ` prefix, because `/v1/bulk` accepts all three. Naming a scrape format such as `markdown` as `format` is also a `400`. For\nMarkdown, links or images from a batch, use `/v1/scrape/bulk`.\n\n## Submit a job\n\nAll three create routes require `webhook_url`, an `https://` URL. An `http://` URL is rejected with\n`400 invalid_url` and the reason `scheme_unsupported`. Set `webhook_secret` to have the deliveries signed;\nsee the [Webhooks guide](https://bytekit.com/docs/guides/webhooks) for verification.\n\n### Mixed screenshots and scrapes\n\n```bash\ncurl -i -X POST https://api.bytekit.com/v1/bulk \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"items\": [\n {\"url\": \"https://example.com/?page=bulk-guide-1\", \"type\": \"screenshot\"},\n {\"url\": \"https://example.com/?page=bulk-guide-1\", \"type\": \"scrape\", \"formats\": [\"markdown\"]}\n ],\n \"webhook_url\": \"https://hooks.example.com/bytekit\"\n }'\n```\n\n```json\n{\n \"id\": \"bulk_01a125a61d9777909cff22879e7d0165\",\n \"status\": \"processing\",\n \"total\": 2,\n \"completed\": 0,\n \"failed\": 0,\n \"total_credits_charged\": 0,\n \"total_billed_bytes\": null,\n \"estimated_credits\": 2.5,\n \"webhook_url\": \"https://hooks.example.com/bytekit\",\n \"created_at\": \"2026-10-10T11:50:05.984Z\",\n \"completed_at\": null\n}\n```\n\n> This request was run for real and returned `202`.\n\nKeep the `id`: it is how you read and cancel the job. `total_billed_bytes` is `null` here because nothing has completed yet.\n\n### Scrapes only\n\n```bash\ncurl -i -X POST https://api.bytekit.com/v1/scrape/bulk \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"urls\": [\"https://example.com/?page=bulk-guide-2\"],\n \"defaults\": {\"formats\": [\"markdown\"]},\n \"webhook_url\": \"https://hooks.example.com/bytekit\"\n }'\n```\n\n> This request was run for real and returned `202`, with the same job envelope as above.\n\n### Raw fetches\n\n```bash\ncurl -i -X POST https://api.bytekit.com/v1/fetch/bulk \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"urls\": [\"https://example.com/?page=bulk-guide-3\"],\n \"webhook_url\": \"https://hooks.example.com/bytekit\"\n }'\n```\n\n> This request was run for real and returned `202`, with the same job envelope as above.\n\n### `urls` or `items`\n\nOn `/v1/bulk` and `/v1/scrape/bulk`, send `urls` or `items`, not both. A request with both returns\n`422 validation_error` (`Provide either urls or items, not both.`), and a request with neither returns\n`422 validation_error` (`Either urls or items must be provided.`).\n\n- `urls` is a plain list of URLs. Each one takes the values in `defaults`.\n- `items` is a list of objects, each with a `url` and its own options. An option on an item wins over the\n same option in `defaults`.\n- On `/v1/bulk`, an entry that names no `type` is a screenshot unless `defaults.type` says `scrape`. A bare\n `urls` list on `/v1/bulk` therefore produces screenshots, and with `\"defaults\": {\"type\": \"scrape\"}` it\n produces scrapes. Both were run for real.\n- `/v1/fetch/bulk` has no `items`. It takes `urls`, as strings or as objects with `url`, `country` and\n `cache_ttl`, and a body with `items` and no `urls` returns `422 validation_error`.\n\n### Hosts our proxy provider refuses\n\nOur proxy provider does not allow requests to some hosts. An entry for such a host is not queued: the\n`202` body lists it under `rejected` as `{ index, url, code, message }` with the code\n`proxy_refused`, it is not counted in `total`, and nothing is billed for it. The other entries run as\nusual. When every entry is refused for this reason, no job is created and the request returns\n`403 proxy_refused`, with the same list in `error.details.rejected`.\n\n## Get the results\n\n### By webhook\n\nWhen the job reaches `completed`, ByteKit sends a `POST` to your `webhook_url` with the header `X-ByteKit-Event: bulk.completed`, so you can dispatch on the header without reading the body. A job that ends `cancelled` or `failed` gets no webhook, so poll it. The\n[Scraping guide](https://bytekit.com/docs/guides/scraping#webhook-event-header) lists the other event types.\n\nThe body is bounded: it carries at most 500 complete items and 1 MiB of JSON. These are its fields, from\nthe API Reference (this page shows no captured delivery):\n\n| Field | Meaning |\n| ------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `bulk_id` | The job id |\n| `status` | `completed` |\n| `total`, `completed`, `failed` | Counts for the whole job |\n| `total_billed_bytes` | Bandwidth billed for the job, in bytes, or `null` when it cannot be reported in full |\n| `total_credits_charged` | Deprecated: read `total_billed_bytes` instead |\n| `webhook_url` | The `webhook_url` the job was created with |\n| `items` | Complete item records, up to 500. Each has an `id`, a `type` and a `status` (`success`, `completed`, `failed` or `cancelled`), and may carry `error_code` and `error_message` |\n| `recovery_api` | `fetch`, `scrape` or `mixed`: which API created the job |\n| `recovery_url` | The path to read the rest of the results from |\n| `manifest_item_count` | How many items this body carries |\n| `manifest_items_complete` | `true` when every item that reached a final status is in `items` |\n| `manifest_artifacts_complete` | `true` when every included completed item has a usable result reference |\n| `manifest_complete` | `true` when both of the above are `true` |\n| `recovery_required` | The inverse of `manifest_complete` |\n\nWhen `recovery_required` is `true`, the body does not hold the whole job. Read the rest from\n`recovery_url` with cursors: request it, then repeat the request with `?cursor=` set to the `next_cursor`\nyou were given, until `has_more` is `false`. `recovery_url` depends on the API that created the job:\n\n| Created with | `recovery_url` |\n| ---------------------- | --------------------------- |\n| `POST /v1/bulk` | `/v1/bulk/{id}/screenshots` |\n| `POST /v1/scrape/bulk` | `/v1/scrape/bulk/{id}` |\n| `POST /v1/fetch/bulk` | `/v1/fetch/bulk/{id}` |\n\nA delivery can arrive more than once or late. Use `bulk_id` together with each item `id` to process an item\nonce.\n\n### By polling\n\nEach API has `GET` routes for its own jobs. The job routes (`GET /v1/bulk/{id}`,\n`GET /v1/scrape/bulk/{id}` and `GET /v1/fetch/bulk/{id}`) answer `202` while the job is `processing` and `200` once it is `completed`, `failed` or `cancelled`. `GET /v1/bulk/{id}/screenshots` answers `200` whatever the job's status; an item that\nhas not completed shows `null` in `billing`.\n\n| Created with | Job status | Items |\n| ---------------------- | -------------------------- | --------------------------------------------------------- |\n| `POST /v1/bulk` | `GET /v1/bulk/{id}` | `GET /v1/bulk/{id}/screenshots`, whatever the item `type` |\n| `POST /v1/scrape/bulk` | `GET /v1/scrape/bulk/{id}` | the same response, in `items` |\n| `POST /v1/fetch/bulk` | `GET /v1/fetch/bulk/{id}` | the same response, in `items` |\n\n`GET /v1/bulk/{id}/screenshots` lists the items of a mixed job and is not limited to screenshots; each item\nhas a `type` of `screenshot` or `scrape`. Unless the job is cancelled, its `status` is `processing` until every item has completed or failed, and `completed` after. A `completed` job can have a non-zero `failed`; read `failed` to tell. The other values are `failed` and `cancelled`.\n\n```bash\ncurl -i https://api.bytekit.com/v1/bulk/bulk_01a125a61d9777909cff22879e7d0165 \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\"\n```\n\n```json\n{\n \"id\": \"bulk_01a125a61d9777909cff22879e7d0165\",\n \"status\": \"completed\",\n \"total\": 2,\n \"completed\": 2,\n \"failed\": 0,\n \"total_credits_charged\": 0,\n \"total_billed_bytes\": 1002,\n \"estimated_credits\": null,\n \"webhook_url\": \"https://hooks.example.com/bytekit\",\n \"created_at\": \"2026-10-10T11:50:05.951Z\",\n \"completed_at\": \"2026-10-10T11:50:16.313Z\"\n}\n```\n\n> This request was run for real and returned `200`. Called while the job was still running, it returned `202`.\n\nThe items of that job:\n\n```bash\ncurl -i https://api.bytekit.com/v1/bulk/bulk_01a125a61d9777909cff22879e7d0165/screenshots \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\"\n```\n\n```json\n{\n \"bulk_id\": \"bulk_01a125a61d9777909cff22879e7d0165\",\n \"items\": [\n {\n \"type\": \"screenshot\",\n \"id\": \"ss_01a125a61d9d744299721fb4b915b626\",\n \"status\": \"completed\",\n \"url\": \"https://example.com/?page=bulk-guide-1\",\n \"image_url\": \"https://…\",\n \"billing\": { \"raw_bytes\": 334, \"multiplier\": 1.5, \"billed_bytes\": 501 },\n \"error_code\": null\n },\n {\n \"type\": \"scrape\",\n \"id\": \"sc_01a125a61d9973569644148e9697b8ba\",\n \"status\": \"completed\",\n \"url\": \"https://example.com/?page=bulk-guide-1\",\n \"content_url\": \"https://…\",\n \"markdown_url\": \"https://…\",\n \"billing\": { \"raw_bytes\": 334, \"multiplier\": 1.5, \"billed_bytes\": 501 },\n \"error_code\": null\n }\n ],\n \"total\": 2,\n \"next_cursor\": null,\n \"has_more\": false,\n \"job_counters\": { \"total\": 2, \"completed\": 2, \"failed\": 0 }\n}\n```\n\n> This request was run for real and returned `200`. Links are shortened, and other fields, such as\n> `page_title`, `artifacts` and `created_at`, are left out.\n\nThe item routes take `limit`, `cursor` and `status` (`pending`, `processing`, `completed`, `failed` or\n`cancelled`). `limit` runs from 1 to 500; its default is 100 on `/v1/bulk/{id}/screenshots` and 500 on the\nother two. Pass the `next_cursor` of one page as `cursor` of the next while `has_more` is `true`, and reuse\nthe same `status` filter for the whole walk.\n\nDownload links in the item lists are signed and expire. `content_url`, `markdown_url` and `image_url` on\n`/v1/bulk/{id}/screenshots` and `content_url` on `/v1/fetch/bulk/{id}` are valid for 600 seconds; read the\njob again for a fresh link. On `/v1/scrape/bulk/{id}`, a `raw` or `markdown` result up to 10 MiB is returned\ninline, and a larger one is replaced by a signed link valid for 24 hours.\n\nRead a job through the routes of the API that created it. Another API's routes can answer `200` with\nsomething else: in a run for real, `GET /v1/fetch/bulk/{id}` on a `POST /v1/bulk` job returned `200` with an\nempty `items` list.\n\n### Listing jobs\n\n`GET /v1/bulk` lists your bulk jobs, most recent first, whichever API created them. It takes `status`\n(`processing`, `completed`, `failed` or `cancelled`), `limit` (1 to 100, default 25) and `cursor`. Follow\n`next_cursor` while `has_more` is `true`. Each entry is the job envelope without `items`.\n\n```bash\ncurl -i \"https://api.bytekit.com/v1/bulk?limit=2\" \\\n -H \"Authorization: Bearer sk_live_YOUR_KEY_HERE\"\n```\n\n> This request was run for real and returned `200` with `data`, `next_cursor` and `has_more`.\n\n### Checking bulk concurrency\n\n`GET /v1/bulk/concurrency` returns `{ active, limit }`: how many of your account's bulk concurrency slots\nare in use, and your plan's maximum concurrency. Compare the two to see whether your jobs are held at the\ncap. `active` is `null` when the count cannot be read right now; it is not zero. A slot whose release never\narrived drops out of the count after 5 minutes.\n\n## Cancel a job\n\n`DELETE /v1/bulk/{id}` cancels a job that is still running. It takes the id from any of the three create\nroutes. `\n\n---\n[Truncated to the 16384-byte per-page limit — this page is 23560 bytes in full. The text cut here is not searchable either: search_docs matches only the part kept above. Read all of it at https://bytekit.com/docs/guides/bulk]"
|
|
351
351
|
},
|
|
352
352
|
"guides/choosing-an-endpoint": {
|
|
353
353
|
"title": "Choosing an endpoint",
|
|
@@ -357,7 +357,7 @@
|
|
|
357
357
|
"guides/errors": {
|
|
358
358
|
"title": "Errors",
|
|
359
359
|
"section": "Guides",
|
|
360
|
-
"body": "# Errors\n\nByteKit error response shape, common error codes, and retry guidance.\n\nAll errors from the ByteKit API follow a consistent envelope shape so you can handle them\nprogrammatically.\n\n## Error response shape\n\nEvery `4xx`/`5xx` response across the API uses one unified envelope. `status` is\nalways the literal string `\"failed\"`, so you can branch on the response body alone.\n\n```json\n{\n \"status\": \"failed\",\n \"error\": {\n \"code\": \"rate_limited\",\n \"message\": \"Rate limit exceeded. Allowed 5 requests per second.\",\n \"http_status\": 429,\n \"failed_at\": \"2026-08-27T12:17:46.234Z\"\n }\n}\n```\n\nThe number in a `rate_limited` message is your own plan's per-second limit — the same value the `X-RateLimit-Limit` response header carries.\n\n| Field | Description |\n| ------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |\n| `status` | Always `\"failed\"` on an error response — the top-level discriminator |\n| `error.code` | Machine-readable string identifier |\n| `error.message` | Human-readable explanation |\n| `error.http_status` | Mirrors the HTTP response status (useful for logged or replayed bodies) |\n| `error.failed_at` | ISO-8601 UTC timestamp of when the error was produced |\n| `error.details` | Optional object with additional context (e.g. which field failed validation). Absent — not `{}` — when the error carries no context |\n\n## Common error codes\n\n| HTTP status | Code | Meaning |\n| ----------- | -------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `400` | `invalid_url` | A supplied URL (including `webhook_url`) is malformed or uses an unsupported scheme |\n| `400` | `validation_error` | Field errors on `/v1/search`, `POST /v1/billing/checkout` and `PUT`/`DELETE /v1/billing/payment-methods/{id}`, plus rejections that run before schema validation on any endpoint: a removed field such as `cookies` or `headers` on a capture endpoint, or a `/v1/fetch` or `/v1/fetch/bulk` request asking for an option only `/v1/scrape` or `/v1/bulk` serves |\n| `401` | `unauthorized` | Missing or malformed `Authorization` header |\n| `401` | `invalid_api_key` | API key is present but not valid |\n| `402` | `quota_exceeded` | The [balance](https://bytekit.com/docs/billing#terms) cannot fund this request. Capture endpoints reject when it cannot fund the request's byte reservation, and `error.details.required_bytes` and `error.details.available_bytes` give the bytes the request reserves and the bytes available; `/v1/search` meters credits and rejects when its credit balance is used up |\n| `402` | `spending_cap_reached` | A credit-metered request would push overage spend past the account's cap. Only reachable on a custom plan with an overage agreement — standard plans have no automatic overage and stop at `quota_exceeded` |\n| `402` | `billing_entitlement_impaired` | The paid subscription is in a payment impairment (e.g. `past_due`); `error.message` names the reason |\n| `402` | `billing_entitlement_expired` | The paid subscription's entitlement period has ended, or its dunning grace period has run out |\n| `403` | `forbidden` | Key is valid but lacks permission for this action |\n| `422` | `validation_error` | Malformed JSON, or a request field failed validation, everywhere the `400` row above does not name |\n| `422` | `content_too_large` | The page is too large to convert to markdown: over the size cap, or past the conversion deadline. On `/v1/scrape` this answers a request that asks for `markdown` (an `async` request fails with the same code on its error envelope); `/v1/schema` answers it too. The request is charged nothing, and on `/v1/scrape` the other requested formats are not returned either |\n| `422` | `blocked`, `upstream_error`, `timeout` | `/v1/fetch` only: the fetch ran and the target could not be read (bot protection refused every attempt, or another exhausted-retries failure such as an unresolvable host), or it ran out of its time limit before the page could be fetched (`timeout`). This is a result about the URL, not an outage of this API, and it is charged nothing. `upstream_error` can also come from a relay fault on our side, so the code alone does not prove the target is at fault. The `X-Fetch-ID` response header, when present, names the failed request's row in Logs |\n| `429` | `rate_limited` | Too many requests per second; back off and retry |\n| `429` | `concurrency_limit` | Too many simultaneous in-flight requests; back off and retry |\n| `500` | `internal_error` | A ByteKit-side failure (for example, failing to enqueue a job or to persist a result, or an unexpected server error), not a problem with the target site. A target-site failure is a result instead: a `200` response with a `failed` scrape envelope on `/v1/scrape` (its `error.code` can itself be `internal_error`), or the `422` `blocked` / `upstream_error` row above on `/v1/fetch` |\n\n## Webhook URLs Must Use HTTPS\n\nAll webhook URLs submitted to the ByteKit API must use HTTPS. Plain HTTP URLs (e.g. `http://example.com/webhook`) are rejected with a `400` `invalid_url` error.\n\n**Why HTTPS only?** Webhook payloads may contain sensitive data (API keys, session tokens, scrape results). HTTPS encryption protects this data in transit.\n\n**Request with an invalid webhook URL:**\n\n```json\n{\n \"webhook_url\": \"http://example.com/webhook\"\n}\n```\n\n**Response (HTTP 400)** — the same unified envelope as every other error; `error.details` names the offending field and reason:\n\n```json\n{\n \"status\": \"failed\",\n \"error\": {\n \"code\": \"invalid_url\",\n \"message\": \"url is not a valid HTTP(S) URL: scheme_unsupported\",\n \"http_status\": 400,\n \"failed_at\": \"2026-08-27T12:16:29.033Z\",\n \"details\": {\n \"url\": \"http://example.com/webhook\",\n \"field\": \"webhook_url\",\n \"reason\": \"scheme_unsupported\"\n }\n }\n}\n```\n\n**Working example:**\n\n```json\n{\n \"webhook_url\": \"https://example.com/webhook\"\n}\n```\n\nThis applies to all endpoints that accept a `webhook_url` parameter: `/v1/scrape` (async), `/v1/scrape/bulk`, `/v1/fetch/bulk`, `/v1/bulk`, `/v1/monitors`, and `/v1/sitemap`.\n\n## Retry guidance\n\nNot all errors are retryable. Use this table to decide:\n\n| Code | Retry? | Guidance |\n| ---------------------------------- | ------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `invalid_url` | No | Fix the URL before retrying |\n| `validation_error` | No | Fix the request body before retrying |\n| `unauthorized` / `invalid_api_key` | No | Check your API key |\n| `quota_exceeded` | No | Retrying the same request cannot succeed while the balance is short. Compare `error.details.required_bytes` with `error.details.available_bytes`: add balance (upgrade your plan or top up), or send a smaller request. On `/v1/search`, upgrade your plan or wait for the credit reset |\n| `spending_cap_reached` | No | The overage cap is account-level and has no self-service control — [contact support](https://bytekit.com/docs/billing/spending) to raise it, or upgrade the plan |\n| `billing_entitlement_impaired` | No | Settle the outstanding invoice — retrying cannot succeed while the subscription is impaired \n\n---\n[Truncated to the 16384-byte per-page limit — this page is 19291 bytes in full. The text cut here is not searchable either: search_docs matches only the part kept above. Read all of it at https://bytekit.com/docs/guides/errors]"
|
|
360
|
+
"body": "# Errors\n\nByteKit error response shape, common error codes, and retry guidance.\n\nAll errors from the ByteKit API follow a consistent envelope shape so you can handle them\nprogrammatically.\n\n## Error response shape\n\nEvery `4xx`/`5xx` response across the API uses one unified envelope. `status` is\nalways the literal string `\"failed\"`, so you can branch on the response body alone.\n\n```json\n{\n \"status\": \"failed\",\n \"error\": {\n \"code\": \"rate_limited\",\n \"message\": \"Rate limit exceeded. Allowed 5 requests per second.\",\n \"http_status\": 429,\n \"failed_at\": \"2026-08-27T12:17:46.234Z\"\n }\n}\n```\n\nThe number in a `rate_limited` message is your own plan's per-second limit — the same value the `X-RateLimit-Limit` response header carries.\n\n| Field | Description |\n| ------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |\n| `status` | Always `\"failed\"` on an error response — the top-level discriminator |\n| `error.code` | Machine-readable string identifier |\n| `error.message` | Human-readable explanation |\n| `error.http_status` | Mirrors the HTTP response status (useful for logged or replayed bodies) |\n| `error.failed_at` | ISO-8601 UTC timestamp of when the error was produced |\n| `error.details` | Optional object with additional context (e.g. which field failed validation). Absent — not `{}` — when the error carries no context |\n\n## Common error codes\n\n| HTTP status | Code | Meaning |\n| ----------- | -------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `400` | `invalid_url` | A supplied URL (including `webhook_url`) is malformed or uses an unsupported scheme |\n| `400` | `validation_error` | Field errors on `/v1/search`, plus rejections that run before schema validation on any endpoint: a removed field such as `cookies` or `headers` on a capture endpoint, or a `/v1/fetch` or `/v1/fetch/bulk` request asking for an option only `/v1/scrape` or `/v1/bulk` serves |\n| `401` | `unauthorized` | Missing or malformed `Authorization` header |\n| `401` | `invalid_api_key` | API key is present but not valid |\n| `402` | `quota_exceeded` | The [balance](https://bytekit.com/docs/billing#terms) cannot fund this request. Capture endpoints reject when it cannot fund the request's byte reservation, and `error.details.required_bytes` and `error.details.available_bytes` give the bytes the request reserves and the bytes available; `/v1/search` meters credits and rejects when its credit balance is used up |\n| `402` | `spending_cap_reached` | A credit-metered request would push overage spend past the account's cap. Only reachable on a custom plan with an overage agreement — standard plans have no automatic overage and stop at `quota_exceeded` |\n| `402` | `billing_entitlement_impaired` | The paid subscription is in a payment impairment (e.g. `past_due`); `error.message` names the reason |\n| `402` | `billing_entitlement_expired` | The paid subscription's entitlement period has ended, or its dunning grace period has run out |\n| `403` | `forbidden` | Key is valid but lacks permission for this action |\n| `422` | `validation_error` | Malformed JSON, or a request field failed validation, everywhere the `400` row above does not name |\n| `422` | `content_too_large` | The page is too large to convert to markdown: over the size cap, or past the conversion deadline. On `/v1/scrape` this answers a request that asks for `markdown` (an `async` request fails with the same code on its error envelope); `/v1/schema` answers it too. The request is charged nothing, and on `/v1/scrape` the other requested formats are not returned either |\n| `422` | `blocked`, `upstream_error`, `timeout` | `/v1/fetch` only: the fetch ran and the target could not be read (bot protection refused every attempt, or another exhausted-retries failure such as an unresolvable host), or it ran out of its time limit before the page could be fetched (`timeout`). This is a result about the URL, not an outage of this API, and it is charged nothing. `upstream_error` can also come from a relay fault on our side, so the code alone does not prove the target is at fault. The `X-Fetch-ID` response header, when present, names the failed request's row in Logs |\n| `429` | `rate_limited` | Too many requests per second; back off and retry |\n| `429` | `concurrency_limit` | Too many simultaneous in-flight requests; back off and retry |\n| `500` | `internal_error` | A ByteKit-side failure (for example, failing to enqueue a job or to persist a result, or an unexpected server error), not a problem with the target site. A target-site failure is a result instead: a `200` response with a `failed` scrape envelope on `/v1/scrape` (its `error.code` can itself be `internal_error`), or the `422` `blocked` / `upstream_error` row above on `/v1/fetch` |\n\n## Webhook URLs Must Use HTTPS\n\nAll webhook URLs submitted to the ByteKit API must use HTTPS. Plain HTTP URLs (e.g. `http://example.com/webhook`) are rejected with a `400` `invalid_url` error.\n\n**Why HTTPS only?** Webhook payloads may contain sensitive data (API keys, session tokens, scrape results). HTTPS encryption protects this data in transit.\n\n**Request with an invalid webhook URL:**\n\n```json\n{\n \"webhook_url\": \"http://example.com/webhook\"\n}\n```\n\n**Response (HTTP 400)** — the same unified envelope as every other error; `error.details` names the offending field and reason:\n\n```json\n{\n \"status\": \"failed\",\n \"error\": {\n \"code\": \"invalid_url\",\n \"message\": \"url is not a valid HTTP(S) URL: scheme_unsupported\",\n \"http_status\": 400,\n \"failed_at\": \"2026-08-27T12:16:29.033Z\",\n \"details\": {\n \"url\": \"http://example.com/webhook\",\n \"field\": \"webhook_url\",\n \"reason\": \"scheme_unsupported\"\n }\n }\n}\n```\n\n**Working example:**\n\n```json\n{\n \"webhook_url\": \"https://example.com/webhook\"\n}\n```\n\nThis applies to all endpoints that accept a `webhook_url` parameter: `/v1/scrape` (async), `/v1/scrape/bulk`, `/v1/fetch/bulk`, `/v1/bulk`, `/v1/monitors`, and `/v1/sitemap`.\n\n## Retry guidance\n\nNot all errors are retryable. Use this table to decide:\n\n| Code | Retry? | Guidance |\n| ---------------------------------- | ------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `invalid_url` | No | Fix the URL before retrying |\n| `validation_error` | No | Fix the request body before retrying |\n| `unauthorized` / `invalid_api_key` | No | Check your API key |\n| `quota_exceeded` | No | Retrying the same request cannot succeed while the balance is short. Compare `error.details.required_bytes` with `error.details.available_bytes`: add balance (upgrade your plan or top up), or send a smaller request. On `/v1/search`, upgrade your plan or wait for the credit reset |\n| `spending_cap_reached` | No | The overage cap is account-level and has no self-service control — [contact support](https://bytekit.com/docs/billing/spending) to raise it, or upgrade the plan |\n| `billing_entitlement_impaired` | No | Settle the outstanding invoice — retrying cannot succeed while the subscription is impaired \n\n---\n[Truncated to the 16384-byte per-page limit — this page is 19291 bytes in full. The text cut here is not searchable either: search_docs matches only the part kept above. Read all of it at https://bytekit.com/docs/guides/errors]"
|
|
361
361
|
},
|
|
362
362
|
"guides/fetch": {
|
|
363
363
|
"title": "Fetch",
|
|
@@ -457,7 +457,7 @@
|
|
|
457
457
|
"sdk/python/bulk": {
|
|
458
458
|
"title": "Bulk",
|
|
459
459
|
"section": "SDK Reference",
|
|
460
|
-
"body": "# Bulk\n\nFunctions for interacting with the `bulk` API resource. Each operation ships in four forms — `sync` / `sync_detailed` and their `async` counterparts.\n\n## Create Bulk\n\nCreate mixed bulk job\n\nEnqueues screenshots or scrapes in a single batch.\nProvide `urls` (simple list) or `items` (per-item config), not both.\nWebhook deliveries include `X-ByteKit-Event: bulk.completed` so\nreceivers can dispatch on the header without parsing the body shape.\nThe body follows `BulkCompletedWebhook`: at most 500 complete items and\n1 MiB, followed by cursor recovery through the existing mixed-item route\nwhenever `recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 4 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 32 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's richer per-item override\nbudget), which reaches 28.7 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 4 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**Parameters**\n\n- `body (CreateBulkBody): Provide `urls` (simple list) OR `items` (per-item config), not`\n- `both. `type` selects the capture kind per entry — only`\n- ``screenshot` and `scrape` are accepted (`recording` is`\n- `deactivated). Behaviour fields may be set per item or via`\n- ``defaults`; a per-item value overrides the matching default.`\n- `This includes `type`: an entry with no `type` of its own`\n- `inherits `defaults.type`, falling back to `screenshot` only`\n- `when neither is set.`\n- `The top-level object, each `items[]` entry, and `defaults``\n- `each reject unrecognized keys with a 422 `validation_error``\n- `(the offending key name appears in the error's `details``\n- `message text) rather than silently discarding them.`\n- ``items[]` and `defaults` do not share one field set`\n- ``device_scale_factor` is accepted only under `defaults` (a`\n- `per-item value 422s), and `duration`/`scenario` are accepted`\n- `only per item (a `defaults` value 422s). `metadata` is`\n- `different from those three: it is valid both at the top`\n- `level of the body and per item, but rejected with a 422 if`\n- `placed under `defaults`. See the `422` response below.`\n- `webhook_url` — `str` — Webhook endpoint URL (HTTPS only; http:// rejected with 400 invalid_url, reason scheme_unsupported)\n- `urls` — `list[str] | Unset` — Simple URL list. Provide urls OR items, not both.\n- `items` — `list[CreateBulkBodyItemsItem] | Unset` — Per-item configs. Provide urls OR items, not both.\n- `defaults` — `CreateBulkBodyDefaults | Unset` — Default behaviour applied to every entry unless the item overrides it.\n- `webhook_secret` — `str | Unset` — HMAC secret used to sign webhook deliveries. Each delivery carries `X-Webhook- Timestamp` and `X-Webhook-Signature` (`sha256=` + the hex HMAC-SHA256 of `timestamp.body`). See https://bytekit.com/docs/guides/webhooks for verification code.\n- `metadata` — `Metadata | Unset` — Arbitrary key-value metadata. Max 4096 bytes when JSON-serialized.\n\n**Call styles**\n\n```python\nsync_detailed(client=client, body=body) -> Response[CreateBulkResponse202 | CreateBulkResponse403 | Error]\nsync(client=client, body=body) -> CreateBulkResponse202 | CreateBulkResponse403 | Error | None\nawait asyncio_detailed(client=client, body=body) -> Response[CreateBulkResponse202 | CreateBulkResponse403 | Error]\nawait asyncio(client=client, body=body) -> CreateBulkResponse202 | CreateBulkResponse403 | Error | None\n```\n\n## Delete Bulk\n\nCancel a bulk job\n\nCancels an in-flight bulk job: drains its still-queued (pending) child jobs and refunds the quota\nheld for exactly those drained children. Children already completed, failed, or in progress are\nuntouched and keep their charge. Idempotent — cancelling an already-terminal job (completed, failed,\nor cancelled) is a no-op that returns 200 with the job's real, unchanged status and refunds nothing.\n\n**Parameters**\n\n- `id (str)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client) -> Response[DeleteBulkResponse200 | Error]\nsync(id=id, client=client) -> DeleteBulkResponse200 | Error | None\nawait asyncio_detailed(id=id, client=client) -> Response[DeleteBulkResponse200 | Error]\nawait asyncio(id=id, client=client) -> DeleteBulkResponse200 | Error | None\n```\n\n## Get Bulk\n\nGet bulk job status\n\nReturns the job envelope. Items are listed by `GET /v1/bulk/\\{id\\}/screenshots`.\n\n**Cancelled by the platform.** When the account can no longer spend (its bandwidth\nbalance is exhausted, or the account is deleted) while items are still pending, ByteKit\ncancels the job itself. It then reads `status: cancelled` even though you never called\n`DELETE /v1/bulk/\\{id\\}`, and the cancellation sends no webhook.\n\n**Job ids from other create routes.** The job is looked up by account only, so the id\nof a job created by `POST /v1/scrape/bulk` or `POST /v1/fetch/bulk` is found here too, not\na `404`, with that job's envelope. An id from another account answers `404`.\n\n**Parameters**\n\n- `id (str)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client) -> Response[Error | GetBulkResponse200 | GetBulkResponse202]\nsync(id=id, client=client) -> Error | GetBulkResponse200 | GetBulkResponse202 | None\nawait asyncio_detailed(id=id, client=client) -> Response[Error | GetBulkResponse200 | GetBulkResponse202]\nawait asyncio(id=id, client=client) -> Error | GetBulkResponse200 | GetBulkResponse202 | None\n```\n\n## List Bulk Screenshots\n\nList bulk job items\n\nReturns the bulk job's items, discriminated by `type`.\n\n**Downloading item artifacts.** For a `completed` item with a storage key,\n`image_url` (`type: screenshot`) and both `content_url` and `markdown_url`\n(`type: scrape`) are **pre-signed** URLs, minted fresh on every read of\nthis endpoint and valid for **600 seconds (10 minutes)** —\nthe same signing lifetime as `content_url` on `GET /v1/fetch/bulk/\\{id\\}`.\nDownload inside that window, or re-poll this endpoint for a fresh\nsignature.\n\n**When no signature is minted.** Three cases mint none: an item that is not\n`completed`, a `completed` item with no storage key, and a `completed` item\nwhose object could not be signed — during an object-storage outage, for\ninstance. In all three the item's stored value is returned unchanged: `null`\nwhile nothing has been stored, and otherwise a **private, unsigned**\nobject-storage URL that answers `401`. These fields are neither nulled nor\nflagged in that case, so treat an artifact URL as usable only once you have\ndownloaded it, and re-poll for a fresh signature otherwise.\n`artifact_warnings` and its `artifact_unavailable` code describe the sibling\n`artifacts` object on `type: scrape` items only — they say nothing about\n`image_url`, `content_url`, or `markdown_url`.\n\n**Parameters**\n\n- `id (str)`\n- `cursor (str | Unset)`\n- `limit (int | Unset)`\n- `status (ListBulkScreenshotsStatus | Unset)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | ListBulkScreenshotsResponse200]\nsync(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | ListBulkScreenshotsResponse200 | None\nawait asyncio_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | ListBulkScreenshotsResponse200]\nawait asyncio(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | ListBulkScreenshotsResponse200 | None\n```"
|
|
460
|
+
"body": "# Bulk\n\nFunctions for interacting with the `bulk` API resource. Each operation ships in four forms — `sync` / `sync_detailed` and their `async` counterparts.\n\n## Create Bulk\n\nCreate mixed bulk job\n\nEnqueues screenshots or scrapes in a single batch.\nProvide `urls` (simple list) or `items` (per-item config), not both.\nWebhook deliveries include `X-ByteKit-Event: bulk.completed` so\nreceivers can dispatch on the header without parsing the body shape.\nThe body follows `BulkCompletedWebhook`: at most 500 complete items and\n1 MiB, followed by cursor recovery through the existing mixed-item route\nwhenever `recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 4 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 32 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's richer per-item override\nbudget), which reaches 28.7 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 4 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**Parameters**\n\n- `body (CreateBulkBody): Provide `urls` (simple list) OR `items` (per-item config), not`\n- `both. `type` selects the capture kind per entry — only`\n- ``screenshot` and `scrape` are accepted (`recording` is`\n- `deactivated). Behaviour fields may be set per item or via`\n- ``defaults`; a per-item value overrides the matching default.`\n- `This includes `type`: an entry with no `type` of its own`\n- `inherits `defaults.type`, falling back to `screenshot` only`\n- `when neither is set.`\n- `The top-level object, each `items[]` entry, and `defaults``\n- `each reject unrecognized keys with a 422 `validation_error``\n- `(the offending key name appears in the error's `details``\n- `message text) rather than silently discarding them.`\n- ``items[]` and `defaults` do not share one field set`\n- ``device_scale_factor` is accepted only under `defaults` (a`\n- `per-item value 422s), and `duration`/`scenario` are accepted`\n- `only per item (a `defaults` value 422s). `metadata` is`\n- `different from those three: it is valid both at the top`\n- `level of the body and per item, but rejected with a 422 if`\n- `placed under `defaults`. See the `422` response below.`\n- `webhook_url` — `str` — Webhook endpoint URL (HTTPS only; http:// rejected with 400 invalid_url, reason scheme_unsupported)\n- `urls` — `list[str] | Unset` — Simple URL list. Provide urls OR items, not both.\n- `items` — `list[CreateBulkBodyItemsItem] | Unset` — Per-item configs. Provide urls OR items, not both.\n- `defaults` — `CreateBulkBodyDefaults | Unset` — Default behaviour applied to every entry unless the item overrides it.\n- `webhook_secret` — `str | Unset` — HMAC secret used to sign webhook deliveries. Each delivery carries `X-Webhook- Timestamp` and `X-Webhook-Signature` (`sha256=` + the hex HMAC-SHA256 of `timestamp.body`). See https://bytekit.com/docs/guides/webhooks for verification code.\n- `metadata` — `Metadata | Unset` — Arbitrary key-value metadata. Max 4096 bytes when JSON-serialized.\n\n**Call styles**\n\n```python\nsync_detailed(client=client, body=body) -> Response[CreateBulkResponse202 | CreateBulkResponse403 | Error | Error]\nsync(client=client, body=body) -> CreateBulkResponse202 | CreateBulkResponse403 | Error | Error | None\nawait asyncio_detailed(client=client, body=body) -> Response[CreateBulkResponse202 | CreateBulkResponse403 | Error | Error]\nawait asyncio(client=client, body=body) -> CreateBulkResponse202 | CreateBulkResponse403 | Error | Error | None\n```\n\n## Delete Bulk\n\nCancel a bulk job\n\nCancels an in-flight bulk job: drains its still-queued (pending) child jobs and refunds the quota\nheld for exactly those drained children. Children already completed, failed, or in progress are\nuntouched and keep their charge. Idempotent — cancelling an already-terminal job (completed, failed,\nor cancelled) is a no-op that returns 200 with the job's real, unchanged status and refunds nothing.\n\n**Parameters**\n\n- `id (str)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client) -> Response[DeleteBulkResponse200 | Error]\nsync(id=id, client=client) -> DeleteBulkResponse200 | Error | None\nawait asyncio_detailed(id=id, client=client) -> Response[DeleteBulkResponse200 | Error]\nawait asyncio(id=id, client=client) -> DeleteBulkResponse200 | Error | None\n```\n\n## Get Bulk\n\nGet bulk job status\n\nReturns the job envelope. Items are listed by `GET /v1/bulk/\\{id\\}/screenshots`.\n\n**Cancelled by the platform.** When the account can no longer spend (its bandwidth\nbalance is exhausted, or the account is deleted) while items are still pending, ByteKit\ncancels the job itself. It then reads `status: cancelled` even though you never called\n`DELETE /v1/bulk/\\{id\\}`, and the cancellation sends no webhook.\n\n**Job ids from other create routes.** The job is looked up by account only, so the id\nof a job created by `POST /v1/scrape/bulk` or `POST /v1/fetch/bulk` is found here too, not\na `404`, with that job's envelope. An id from another account answers `404`.\n\n**Parameters**\n\n- `id (str)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client) -> Response[Error | GetBulkResponse200 | GetBulkResponse202]\nsync(id=id, client=client) -> Error | GetBulkResponse200 | GetBulkResponse202 | None\nawait asyncio_detailed(id=id, client=client) -> Response[Error | GetBulkResponse200 | GetBulkResponse202]\nawait asyncio(id=id, client=client) -> Error | GetBulkResponse200 | GetBulkResponse202 | None\n```\n\n## List Bulk Screenshots\n\nList bulk job items\n\nReturns the bulk job's items, discriminated by `type`.\n\n**Downloading item artifacts.** For a `completed` item with a storage key,\n`image_url` (`type: screenshot`) and both `content_url` and `markdown_url`\n(`type: scrape`) are **pre-signed** URLs, minted fresh on every read of\nthis endpoint and valid for **600 seconds (10 minutes)** —\nthe same signing lifetime as `content_url` on `GET /v1/fetch/bulk/\\{id\\}`.\nDownload inside that window, or re-poll this endpoint for a fresh\nsignature.\n\n**When no signature is minted.** Three cases mint none: an item that is not\n`completed`, a `completed` item with no storage key, and a `completed` item\nwhose object could not be signed — during an object-storage outage, for\ninstance. In all three the item's stored value is returned unchanged: `null`\nwhile nothing has been stored, and otherwise a **private, unsigned**\nobject-storage URL that answers `401`. These fields are neither nulled nor\nflagged in that case, so treat an artifact URL as usable only once you have\ndownloaded it, and re-poll for a fresh signature otherwise.\n`artifact_warnings` and its `artifact_unavailable` code describe the sibling\n`artifacts` object on `type: scrape` items only — they say nothing about\n`image_url`, `content_url`, or `markdown_url`.\n\n**Parameters**\n\n- `id (str)`\n- `cursor (str | Unset)`\n- `limit (int | Unset)`\n- `status (ListBulkScreenshotsStatus | Unset)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | ListBulkScreenshotsResponse200]\nsync(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | ListBulkScreenshotsResponse200 | None\nawait asyncio_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | ListBulkScreenshotsResponse200]\nawait asyncio(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | ListBulkScreenshotsResponse200 | None\n```"
|
|
461
461
|
},
|
|
462
462
|
"sdk/python/client": {
|
|
463
463
|
"title": "Client",
|
|
@@ -472,7 +472,7 @@
|
|
|
472
472
|
"sdk/python/fetch-bulk": {
|
|
473
473
|
"title": "Fetch Bulk",
|
|
474
474
|
"section": "SDK Reference",
|
|
475
|
-
"body": "# Fetch Bulk\n\nFunctions for interacting with the `fetch_bulk` API resource. Each operation ships in four forms — `sync` / `sync_detailed` and their `async` counterparts.\n\n## Create Fetch Bulk\n\nBulk fetch URLs\n\nEnqueues multiple URLs for HTTP fetching. Results delivered via webhook.\nDoes not support options that require page rendering (wait_for_selector, etc.).\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/fetch/bulk/\\{id\\}` whenever\n`recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 2 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 20 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's per-item override budget),\nwhich reaches 16.8 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 2 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**Parameters**\n\n- `body (CreateFetchBulkBody)`\n- `urls` — `list[CreateFetchBulkBodyUrlsItemType1 | str]`\n- `webhook_url` — `str` — Webhook endpoint URL (HTTPS only; http:// rejected with 400 invalid_url, reason scheme_unsupported)\n- `defaults` — `CreateFetchBulkBodyDefaults | Unset`\n- `webhook_secret` — `str | Unset` — HMAC secret used to sign webhook deliveries. Each delivery carries `X-Webhook- Timestamp` and `X-Webhook-Signature` (`sha256=` + the hex HMAC-SHA256 of `timestamp.body`). See https://bytekit.com/docs/guides/webhooks for verification code.\n- `metadata` — `Metadata | Unset` — Arbitrary key-value metadata. Max 4096 bytes when JSON-serialized.\n\n**Call styles**\n\n```python\nsync_detailed(client=client, body=body) -> Response[CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error]\nsync(client=client, body=body) -> CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error | None\nawait asyncio_detailed(client=client, body=body) -> Response[CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error]\nawait asyncio(client=client, body=body) -> CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error | None\n```\n\n## Get Fetch Bulk\n\nGet fetch bulk job status\n\nReturns the job envelope plus its per-URL items.\n\n**Downloading item content.** Each completed item's `content_url` is a\n**pre-signed** URL, minted fresh on every read of this endpoint and valid\nfor **600 seconds (10 minutes)** — the same signing lifetime as the\n`image_url` returned by `GET /v1/bulk/\\{id\\}/screenshots`. The underlying\nobjects are private, so an unsigned URL returns `401`: download the\ncontent inside that window, or re-poll this endpoint for a fresh\nsignature. Items that are not `completed`, and completed items with no\nstored object, or completed items whose object cannot be signed, carry\n`null`; the latter report `artifact_unavailable`. The private unsigned\nstorage URL is never returned.\n\n**Cancelled by the platform.** When the account can no longer spend (its bandwidth\nbalance is exhausted, or the account is deleted) while items are still pending, ByteKit\ncancels the job itself. It then reads `status: cancelled` even though you never called\n`DELETE /v1/bulk/\\{id\\}`, and the cancellation sends no webhook.\n\n**Job ids from other create routes.** The job is looked up by account only, so the id\nof a job created by `POST /v1/scrape/bulk` or `POST /v1/bulk` is found here too, not a\n`404`, with the job envelope and `items: []`: only items fetched through\n`POST /v1/fetch/bulk` are listed. An id from another account answers `404`.\n\n**Parameters**\n\n- `id (str)`\n- `cursor (str | Unset)`\n- `limit (int | Unset)`\n- `status (GetFetchBulkStatus | Unset)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetFetchBulkResponse200 | GetFetchBulkResponse202]\nsync(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetFetchBulkResponse200 | GetFetchBulkResponse202 | None\nawait asyncio_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetFetchBulkResponse200 | GetFetchBulkResponse202]\nawait asyncio(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetFetchBulkResponse200 | GetFetchBulkResponse202 | None\n```"
|
|
475
|
+
"body": "# Fetch Bulk\n\nFunctions for interacting with the `fetch_bulk` API resource. Each operation ships in four forms — `sync` / `sync_detailed` and their `async` counterparts.\n\n## Create Fetch Bulk\n\nBulk fetch URLs\n\nEnqueues multiple URLs for HTTP fetching. Results delivered via webhook.\nDoes not support options that require page rendering (wait_for_selector, etc.).\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/fetch/bulk/\\{id\\}` whenever\n`recovery_required` is true.\n\n**Limits:** request bodies are guarded in a two-tier shape. A streamed body\nwith no `Content-Length` header is capped at 2 MB before your API key\nis checked; a body that declares `Content-Length` is instead bounded\nthere by a 20 MB fail-safe (not the real limit — see below), since\nthat branch reads nothing until your key is verified. Once your key\nis verified, a second check re-gates the body against your account's\nown `max_bulk_size` (at this endpoint's per-item override budget),\nwhich reaches 16.8 MB for the largest documented account. A\nstandard-plan account's effective ceiling is 2 MB; either tier's\noverrun returns a `400` with error code `request_too_large`.\n\n**Parameters**\n\n- `body (CreateFetchBulkBody)`\n- `urls` — `list[CreateFetchBulkBodyUrlsItemType1 | str]`\n- `webhook_url` — `str` — Webhook endpoint URL (HTTPS only; http:// rejected with 400 invalid_url, reason scheme_unsupported)\n- `defaults` — `CreateFetchBulkBodyDefaults | Unset`\n- `webhook_secret` — `str | Unset` — HMAC secret used to sign webhook deliveries. Each delivery carries `X-Webhook- Timestamp` and `X-Webhook-Signature` (`sha256=` + the hex HMAC-SHA256 of `timestamp.body`). See https://bytekit.com/docs/guides/webhooks for verification code.\n- `metadata` — `Metadata | Unset` — Arbitrary key-value metadata. Max 4096 bytes when JSON-serialized.\n\n**Call styles**\n\n```python\nsync_detailed(client=client, body=body) -> Response[CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error | Error]\nsync(client=client, body=body) -> CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error | Error | None\nawait asyncio_detailed(client=client, body=body) -> Response[CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error | Error]\nawait asyncio(client=client, body=body) -> CreateFetchBulkResponse202 | CreateFetchBulkResponse403 | Error | Error | None\n```\n\n## Get Fetch Bulk\n\nGet fetch bulk job status\n\nReturns the job envelope plus its per-URL items.\n\n**Downloading item content.** Each completed item's `content_url` is a\n**pre-signed** URL, minted fresh on every read of this endpoint and valid\nfor **600 seconds (10 minutes)** — the same signing lifetime as the\n`image_url` returned by `GET /v1/bulk/\\{id\\}/screenshots`. The underlying\nobjects are private, so an unsigned URL returns `401`: download the\ncontent inside that window, or re-poll this endpoint for a fresh\nsignature. Items that are not `completed`, and completed items with no\nstored object, or completed items whose object cannot be signed, carry\n`null`; the latter report `artifact_unavailable`. The private unsigned\nstorage URL is never returned.\n\n**Cancelled by the platform.** When the account can no longer spend (its bandwidth\nbalance is exhausted, or the account is deleted) while items are still pending, ByteKit\ncancels the job itself. It then reads `status: cancelled` even though you never called\n`DELETE /v1/bulk/\\{id\\}`, and the cancellation sends no webhook.\n\n**Job ids from other create routes.** The job is looked up by account only, so the id\nof a job created by `POST /v1/scrape/bulk` or `POST /v1/bulk` is found here too, not a\n`404`, with the job envelope and `items: []`: only items fetched through\n`POST /v1/fetch/bulk` are listed. An id from another account answers `404`.\n\n**Parameters**\n\n- `id (str)`\n- `cursor (str | Unset)`\n- `limit (int | Unset)`\n- `status (GetFetchBulkStatus | Unset)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetFetchBulkResponse200 | GetFetchBulkResponse202]\nsync(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetFetchBulkResponse200 | GetFetchBulkResponse202 | None\nawait asyncio_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetFetchBulkResponse200 | GetFetchBulkResponse202]\nawait asyncio(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetFetchBulkResponse200 | GetFetchBulkResponse202 | None\n```"
|
|
476
476
|
},
|
|
477
477
|
"sdk/python/monitors": {
|
|
478
478
|
"title": "Monitors",
|
|
@@ -487,7 +487,7 @@
|
|
|
487
487
|
"sdk/python/scrape-bulk": {
|
|
488
488
|
"title": "Scrape Bulk",
|
|
489
489
|
"section": "SDK Reference",
|
|
490
|
-
"body": "# Scrape Bulk\n\nFunctions for interacting with the `scrape_bulk` API resource. Each operation ships in four forms — `sync` / `sync_detailed` and their `async` counterparts.\n\n## Create Scrape Bulk\n\nBulk scrape URLs\n\nEnqueues multiple URLs for scraping. Results delivered via webhook.\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/scrape/bulk/\\{id\\}` whenever\n`recovery_required` is true.\n\n**Unknown keys.** An unknown key on an `items[]` entry, or at the top level of\nthe body, is rejected with `422 validation_error`. An unknown key inside\n`defaults` is not: it is dropped without a warning and the request is accepted\nwith `202`. The exception is `cookies` and `headers`, on an item or in `defaults`: they\nanswer `400 validation_error`.\n\n**Parameters**\n\n- `body (CreateScrapeBulkBody)`\n- `webhook_url` — `str` — Webhook endpoint URL (HTTPS only; http:// rejected with 400 invalid_url, reason scheme_unsupported)\n- `urls` — `list[str] | Unset` — Simple URL list. Provide urls OR items, not both.\n- `items` — `list[CreateScrapeBulkBodyItemsItem] | Unset` — Per-item configs. Provide urls OR items, not both.\n- `defaults` — `CreateScrapeBulkBodyDefaults | Unset`\n- `webhook_secret` — `str | Unset` — HMAC secret used to sign webhook deliveries. Each delivery carries `X-Webhook- Timestamp` and `X-Webhook-Signature` (`sha256=` + the hex HMAC-SHA256 of `timestamp.body`). See https://bytekit.com/docs/guides/webhooks for verification code.\n- `metadata` — `Metadata | Unset` — Arbitrary key-value metadata. Max 4096 bytes when JSON-serialized.\n- `custom` — `CreateScrapeBulkBodyCustom | Unset` — Top-level user-supplied JSON payload, capped at 4096 UTF-8 bytes. Applied to every scrape-type entry that does not provide its own per-entry `custom` (the per-entry value wins). Echoed on each entry's success envelope in the bulk results response (the key is omitted when no `custom` was supplied at either level). Distinct from the system-owned `metadata` column and never used as a cache-key input.\n\n**Call styles**\n\n```python\nsync_detailed(client=client, body=body) -> Response[CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error]\nsync(client=client, body=body) -> CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error | None\nawait asyncio_detailed(client=client, body=body) -> Response[CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error]\nawait asyncio(client=client, body=body) -> CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error | None\n```\n\n## Get Scrape Bulk\n\nGet scrape bulk job status\n\nReturns the job envelope plus its rehydrated per-URL scrape envelopes.\n\n**Downloading item content.** A `raw` or `markdown` artifact within the\n10-MiB inline cap is returned inline. An oversized one is replaced by a\n**pre-signed** URL, minted fresh on every read of this endpoint and valid\nfor **86400 seconds (24 hours)**. The underlying objects are private, so an\nunsigned URL returns `401`: download the content inside that window, or\nre-poll this endpoint for a fresh signature. An artifact that was never\nstored, or whose object cannot be signed, is omitted from `formats` and\nreported as `artifact_unavailable` in `warnings`. The private unsigned\nstorage URL is never returned.\n\n**Cancelled by the platform.** When the account can no longer spend (its bandwidth\nbalance is exhausted, or the account is deleted) while items are still pending, ByteKit\ncancels the job itself. It then reads `status: cancelled` even though you never called\n`DELETE /v1/bulk/\\{id\\}`, and the cancellation sends no webhook.\n\n**Job ids from other create routes.** The job is looked up by account only, so the id\nof a job created by `POST /v1/fetch/bulk` or `POST /v1/bulk` is found here too, not a `404`.\nThe items listed are the job's scrape rows: a fetch-bulk job's items appear, and a\n`POST /v1/bulk` job shows its scrape items but not its screenshots. An id from another\naccount answers `404`.\n\n**Parameters**\n\n- `id (str)`\n- `cursor (str | Unset)`\n- `limit (int | Unset)`\n- `status (GetScrapeBulkStatus | Unset)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202]\nsync(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202 | None\nawait asyncio_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202]\nawait asyncio(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202 | None\n```"
|
|
490
|
+
"body": "# Scrape Bulk\n\nFunctions for interacting with the `scrape_bulk` API resource. Each operation ships in four forms — `sync` / `sync_detailed` and their `async` counterparts.\n\n## Create Scrape Bulk\n\nBulk scrape URLs\n\nEnqueues multiple URLs for scraping. Results delivered via webhook.\nCompletion deliveries use `X-ByteKit-Event: bulk.completed` and the\n`BulkCompletedWebhook` contract: at most 500 complete items and 1 MiB,\nfollowed by cursor recovery through `GET /v1/scrape/bulk/\\{id\\}` whenever\n`recovery_required` is true.\n\n**Unknown keys.** An unknown key on an `items[]` entry, or at the top level of\nthe body, is rejected with `422 validation_error`. An unknown key inside\n`defaults` is not: it is dropped without a warning and the request is accepted\nwith `202`. The exception is `cookies` and `headers`, on an item or in `defaults`: they\nanswer `400 validation_error`.\n\n**Parameters**\n\n- `body (CreateScrapeBulkBody)`\n- `webhook_url` — `str` — Webhook endpoint URL (HTTPS only; http:// rejected with 400 invalid_url, reason scheme_unsupported)\n- `urls` — `list[str] | Unset` — Simple URL list. Provide urls OR items, not both.\n- `items` — `list[CreateScrapeBulkBodyItemsItem] | Unset` — Per-item configs. Provide urls OR items, not both.\n- `defaults` — `CreateScrapeBulkBodyDefaults | Unset`\n- `webhook_secret` — `str | Unset` — HMAC secret used to sign webhook deliveries. Each delivery carries `X-Webhook- Timestamp` and `X-Webhook-Signature` (`sha256=` + the hex HMAC-SHA256 of `timestamp.body`). See https://bytekit.com/docs/guides/webhooks for verification code.\n- `metadata` — `Metadata | Unset` — Arbitrary key-value metadata. Max 4096 bytes when JSON-serialized.\n- `custom` — `CreateScrapeBulkBodyCustom | Unset` — Top-level user-supplied JSON payload, capped at 4096 UTF-8 bytes. Applied to every scrape-type entry that does not provide its own per-entry `custom` (the per-entry value wins). Echoed on each entry's success envelope in the bulk results response (the key is omitted when no `custom` was supplied at either level). Distinct from the system-owned `metadata` column and never used as a cache-key input.\n\n**Call styles**\n\n```python\nsync_detailed(client=client, body=body) -> Response[CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error | Error]\nsync(client=client, body=body) -> CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error | Error | None\nawait asyncio_detailed(client=client, body=body) -> Response[CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error | Error]\nawait asyncio(client=client, body=body) -> CreateScrapeBulkResponse202 | CreateScrapeBulkResponse403 | Error | Error | None\n```\n\n## Get Scrape Bulk\n\nGet scrape bulk job status\n\nReturns the job envelope plus its rehydrated per-URL scrape envelopes.\n\n**Downloading item content.** A `raw` or `markdown` artifact within the\n10-MiB inline cap is returned inline. An oversized one is replaced by a\n**pre-signed** URL, minted fresh on every read of this endpoint and valid\nfor **86400 seconds (24 hours)**. The underlying objects are private, so an\nunsigned URL returns `401`: download the content inside that window, or\nre-poll this endpoint for a fresh signature. An artifact that was never\nstored, or whose object cannot be signed, is omitted from `formats` and\nreported as `artifact_unavailable` in `warnings`. The private unsigned\nstorage URL is never returned.\n\n**Cancelled by the platform.** When the account can no longer spend (its bandwidth\nbalance is exhausted, or the account is deleted) while items are still pending, ByteKit\ncancels the job itself. It then reads `status: cancelled` even though you never called\n`DELETE /v1/bulk/\\{id\\}`, and the cancellation sends no webhook.\n\n**Job ids from other create routes.** The job is looked up by account only, so the id\nof a job created by `POST /v1/fetch/bulk` or `POST /v1/bulk` is found here too, not a `404`.\nThe items listed are the job's scrape rows: a fetch-bulk job's items appear, and a\n`POST /v1/bulk` job shows its scrape items but not its screenshots. An id from another\naccount answers `404`.\n\n**Parameters**\n\n- `id (str)`\n- `cursor (str | Unset)`\n- `limit (int | Unset)`\n- `status (GetScrapeBulkStatus | Unset)`\n\n**Call styles**\n\n```python\nsync_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202]\nsync(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202 | None\nawait asyncio_detailed(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Response[Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202]\nawait asyncio(id=id, client=client, cursor=cursor, limit=limit, status=status) -> Error | GetScrapeBulkResponse200 | GetScrapeBulkResponse202 | None\n```"
|
|
491
491
|
},
|
|
492
492
|
"sdk/python/screenshots": {
|
|
493
493
|
"title": "Screenshots",
|
|
@@ -517,7 +517,7 @@
|
|
|
517
517
|
"sdk/typescript/account": {
|
|
518
518
|
"title": "Account",
|
|
519
519
|
"section": "SDK Reference",
|
|
520
|
-
"body": "# Account\n\nAccount
|
|
520
|
+
"body": "# Account\n\nAccount details. Accessed via `client.account`.\n\n## get\n\n```ts\nclient.account.get(requestOptions?: RequestOptions): Promise<GetAccountResponse>\n```\n\nGET /v1/account — get the authenticated account.\n\n`requestOptions` carries the CLIENT-side abort budget (`requestTimeoutMs`) and an\noptional caller `signal`; both override the constructor's `timeoutMs` default."
|
|
521
521
|
},
|
|
522
522
|
"sdk/typescript/bulk": {
|
|
523
523
|
"title": "Bulk",
|
|
@@ -527,7 +527,7 @@
|
|
|
527
527
|
"sdk/typescript/client": {
|
|
528
528
|
"title": "Client",
|
|
529
529
|
"section": "SDK Reference",
|
|
530
|
-
"body": "# Client\n\nThe ByteKit TypeScript SDK is a thin, type-safe wrapper over the REST API. Create a\n client with your API key, then call resource methods.\n\n```ts\nimport { ByteKit } from '@hunt-labs/bytekit-sdk';\n\nconst client = new ByteKit({\n apiKey: process.env.BYTEKIT_API_KEY!, // your sk_live_… key\n});\n```\n\n## Options (`ByteKitOptions`)\n\n- `apiKey` (required) — `string`\n- `baseUrl` — `string` Defaults to `https://api.bytekit.com`.\n- `timeoutMs` — `number` — Default CLIENT-SIDE request timeout in ms — the abort budget for the whole HTTP\nround-trip made by this SDK, covering time-to-headers **and** the response body\nread (so a large legitimate body counts against it too). `0` disables the SDK-side\ntimeout. Default 120000.\n\nNOT the same thing as `ScrapeOpts.timeout_ms`, which is the SERVER-side budget\nByteKit applies to the scrape itself. Override per call with\n`RequestOptions.requestTimeoutMs`.\n\n## Resources\n\nThe client exposes one property per resource:\n\n- [`client.scrape`](https://bytekit.com/docs/sdk/typescript/scrape) — Fetch a URL as raw HTML, clean markdown, or structured content.\n- [`client.screenshots`](https://bytekit.com/docs/sdk/typescript/screenshots) — Capture full-page or viewport screenshots.\n- [`client.bulk`](https://bytekit.com/docs/sdk/typescript/bulk) — Fan out many URLs in parallel and get one webhook when the job completes.\n- [`client.fetch`](https://bytekit.com/docs/sdk/typescript/fetch) — Low-latency raw HTTP fetch with byte-for-byte upstream responses.\n- [`client.monitors`](https://bytekit.com/docs/sdk/typescript/monitors) — Watch a URL on a schedule and webhook on change.\n- [`client.sitemap`](https://bytekit.com/docs/sdk/typescript/sitemap) — Discover URLs from a domain's sitemap or by crawling.\n- [`client.search`](https://bytekit.com/docs/sdk/typescript/search) — Run a web search and return ranked organic results.\n- [`client.account`](https://bytekit.com/docs/sdk/typescript/account) — Account
|
|
530
|
+
"body": "# Client\n\nThe ByteKit TypeScript SDK is a thin, type-safe wrapper over the REST API. Create a\n client with your API key, then call resource methods.\n\n```ts\nimport { ByteKit } from '@hunt-labs/bytekit-sdk';\n\nconst client = new ByteKit({\n apiKey: process.env.BYTEKIT_API_KEY!, // your sk_live_… key\n});\n```\n\n## Options (`ByteKitOptions`)\n\n- `apiKey` (required) — `string`\n- `baseUrl` — `string` Defaults to `https://api.bytekit.com`.\n- `timeoutMs` — `number` — Default CLIENT-SIDE request timeout in ms — the abort budget for the whole HTTP\nround-trip made by this SDK, covering time-to-headers **and** the response body\nread (so a large legitimate body counts against it too). `0` disables the SDK-side\ntimeout. Default 120000.\n\nNOT the same thing as `ScrapeOpts.timeout_ms`, which is the SERVER-side budget\nByteKit applies to the scrape itself. Override per call with\n`RequestOptions.requestTimeoutMs`.\n\n## Resources\n\nThe client exposes one property per resource:\n\n- [`client.scrape`](https://bytekit.com/docs/sdk/typescript/scrape) — Fetch a URL as raw HTML, clean markdown, or structured content.\n- [`client.screenshots`](https://bytekit.com/docs/sdk/typescript/screenshots) — Capture full-page or viewport screenshots.\n- [`client.bulk`](https://bytekit.com/docs/sdk/typescript/bulk) — Fan out many URLs in parallel and get one webhook when the job completes.\n- [`client.fetch`](https://bytekit.com/docs/sdk/typescript/fetch) — Low-latency raw HTTP fetch with byte-for-byte upstream responses.\n- [`client.monitors`](https://bytekit.com/docs/sdk/typescript/monitors) — Watch a URL on a schedule and webhook on change.\n- [`client.sitemap`](https://bytekit.com/docs/sdk/typescript/sitemap) — Discover URLs from a domain's sitemap or by crawling.\n- [`client.search`](https://bytekit.com/docs/sdk/typescript/search) — Run a web search and return ranked organic results.\n- [`client.account`](https://bytekit.com/docs/sdk/typescript/account) — Account details.\n- [`client.usage`](https://bytekit.com/docs/sdk/typescript/usage) — Billing-period and daily usage breakdowns.\n- [`client.webhooks`](https://bytekit.com/docs/sdk/typescript/webhooks) — List and retry webhook deliveries.\n\n## Errors\n\nAny non-2xx response throws a `ByteKitError` carrying the HTTP `status` and the API `code`.\n\n```ts\nimport { ByteKit, ByteKitError } from '@hunt-labs/bytekit-sdk';\n\ntry {\n await client.scrape.create({ url: 'https://example.com' });\n} catch (err) {\n if (err instanceof ByteKitError) {\n console.error(`${err.status} ${err.code}: ${err.message}`);\n }\n}\n```"
|
|
531
531
|
},
|
|
532
532
|
"sdk/typescript/fetch": {
|
|
533
533
|
"title": "Fetch",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hunt-labs/bytekit-mcp",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.30",
|
|
4
4
|
"description": "ByteKit MCP server — exposes ByteKit web-data tools (scrape, screenshot, search, docs) to AI agents over the Model Context Protocol, hosted or as a local stdio server.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|