@onkernel/sdk 0.114.0 → 0.116.0
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 +14 -0
- package/package.json +1 -1
- package/resources/credentials.d.mts +97 -10
- package/resources/credentials.d.mts.map +1 -1
- package/resources/credentials.d.ts +97 -10
- package/resources/credentials.d.ts.map +1 -1
- package/resources/search/contents.d.mts +85 -56
- package/resources/search/contents.d.mts.map +1 -1
- package/resources/search/contents.d.ts +85 -56
- package/resources/search/contents.d.ts.map +1 -1
- package/resources/search/contents.js +13 -10
- package/resources/search/contents.js.map +1 -1
- package/resources/search/contents.mjs +13 -10
- package/resources/search/contents.mjs.map +1 -1
- package/resources/search/search.d.mts +65 -51
- package/resources/search/search.d.mts.map +1 -1
- package/resources/search/search.d.ts +65 -51
- package/resources/search/search.d.ts.map +1 -1
- package/resources/search/search.js.map +1 -1
- package/resources/search/search.mjs.map +1 -1
- package/resources/vaults/items.d.mts +14 -2
- package/resources/vaults/items.d.mts.map +1 -1
- package/resources/vaults/items.d.ts +14 -2
- package/resources/vaults/items.d.ts.map +1 -1
- package/src/resources/credentials.ts +112 -10
- package/src/resources/search/contents.ts +86 -62
- package/src/resources/search/search.ts +65 -51
- package/src/resources/vaults/items.ts +15 -2
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -938,36 +938,37 @@ export interface Request {
|
|
|
938
938
|
export namespace Request {
|
|
939
939
|
export interface SearchContentOptions {
|
|
940
940
|
/**
|
|
941
|
-
*
|
|
942
|
-
* the chosen identity is not bypassed.
|
|
941
|
+
* Requires source=auto or source=browser in deferred retrieval.
|
|
943
942
|
*/
|
|
944
943
|
browser?: SearchContentOptions.Browser;
|
|
945
944
|
|
|
946
945
|
format?: 'markdown' | 'text';
|
|
947
946
|
|
|
948
947
|
/**
|
|
949
|
-
*
|
|
950
|
-
*
|
|
951
|
-
*
|
|
952
|
-
*
|
|
953
|
-
*
|
|
954
|
-
* otherwise provider content age is reported as unknown via fetched_at.
|
|
948
|
+
* For source=auto, maximum acceptable age of retained provider content, measured
|
|
949
|
+
* from when the search received it from the provider. A value of 0 disables reuse
|
|
950
|
+
* of retained content, so every result is fetched through a browser.
|
|
951
|
+
* source=provider reuses retained provider content without freshness validation.
|
|
952
|
+
* source=browser always fetches through a browser and does not use this age limit.
|
|
955
953
|
*/
|
|
956
954
|
max_age_hours?: number;
|
|
957
955
|
|
|
958
956
|
/**
|
|
959
|
-
* Per-result Unicode character limit after extraction.
|
|
957
|
+
* Per-result Unicode character limit after extraction. Retained provider content
|
|
958
|
+
* cannot exceed what was stored at search time; such results report truncated when
|
|
959
|
+
* the stored text was already truncated.
|
|
960
960
|
*/
|
|
961
961
|
max_chars?: number;
|
|
962
962
|
|
|
963
963
|
/**
|
|
964
|
-
*
|
|
965
|
-
*
|
|
966
|
-
*
|
|
967
|
-
*
|
|
968
|
-
*
|
|
969
|
-
*
|
|
970
|
-
*
|
|
964
|
+
* auto uses retained provider content within max_age_hours; for deferred retrieval
|
|
965
|
+
* it falls back to a Kernel browser (caller-supplied or temporary) for results
|
|
966
|
+
* without it. Inline retrieval never uses a browser. provider reuses retained
|
|
967
|
+
* provider content when available, without freshness validation, and never
|
|
968
|
+
* provisions a browser. browser fetches each URL through a Kernel browser, either
|
|
969
|
+
* caller-supplied or temporary. No option makes a new provider request. Defaults
|
|
970
|
+
* to auto for both inline and deferred retrieval. Missing documents produce
|
|
971
|
+
* per-result unavailable outcomes, not request failures.
|
|
971
972
|
*/
|
|
972
973
|
source?: 'auto' | 'provider' | 'browser';
|
|
973
974
|
|
|
@@ -980,17 +981,22 @@ export namespace Request {
|
|
|
980
981
|
|
|
981
982
|
export namespace SearchContentOptions {
|
|
982
983
|
/**
|
|
983
|
-
*
|
|
984
|
-
* the chosen identity is not bypassed.
|
|
984
|
+
* Requires source=auto or source=browser in deferred retrieval.
|
|
985
985
|
*/
|
|
986
986
|
export interface Browser {
|
|
987
987
|
/**
|
|
988
988
|
* Existing browser session ID authorized for the caller and selected project.
|
|
989
|
-
* Reuses its cookies, proxy, and browser configuration
|
|
990
|
-
*
|
|
991
|
-
*
|
|
992
|
-
*
|
|
993
|
-
*
|
|
989
|
+
* Reuses its cookies, proxy, and browser configuration; requests follow that
|
|
990
|
+
* browser's existing network access behavior, with no additional destination
|
|
991
|
+
* allowlist in this endpoint. Kernel does not delete a caller-supplied browser.
|
|
992
|
+
* Render mode uses a temporary tab; website activity may still change shared
|
|
993
|
+
* cookies and storage. When omitted and any result needs browser retrieval, Kernel
|
|
994
|
+
* creates one temporary browser for the request using the dashboard launch
|
|
995
|
+
* defaults (headful, stealth, default proxy), tags it with search_id, and deletes
|
|
996
|
+
* it when the request finishes. It is billed and counts toward browser concurrency
|
|
997
|
+
* like any other browser. A concurrency rejection returns 429 for source=browser;
|
|
998
|
+
* for source=auto, results with retained content are still returned and the rest
|
|
999
|
+
* report the rejection.
|
|
994
1000
|
*/
|
|
995
1001
|
browser_id?: string;
|
|
996
1002
|
|
|
@@ -1070,7 +1076,9 @@ export namespace Result {
|
|
|
1070
1076
|
status: 'ok' | 'unavailable' | 'blocked' | 'timeout' | 'unsupported_type' | 'extraction_failed' | 'error';
|
|
1071
1077
|
|
|
1072
1078
|
/**
|
|
1073
|
-
* Kernel cache outcome.
|
|
1079
|
+
* Kernel content cache outcome. Kernel has no content cache yet: responses report
|
|
1080
|
+
* bypass or unknown, and hit and miss are reserved. Provider-internal cache
|
|
1081
|
+
* behavior may be unknown.
|
|
1074
1082
|
*/
|
|
1075
1083
|
cache_status?: 'hit' | 'miss' | 'bypass' | 'unknown';
|
|
1076
1084
|
|
|
@@ -1088,7 +1096,7 @@ export namespace Result {
|
|
|
1088
1096
|
extractor_version?: string;
|
|
1089
1097
|
|
|
1090
1098
|
/**
|
|
1091
|
-
*
|
|
1099
|
+
* When Kernel received the content from the provider.
|
|
1092
1100
|
*/
|
|
1093
1101
|
fetched_at?: string | null;
|
|
1094
1102
|
|
|
@@ -1105,7 +1113,7 @@ export namespace Result {
|
|
|
1105
1113
|
http_status?: number;
|
|
1106
1114
|
|
|
1107
1115
|
/**
|
|
1108
|
-
* Original retrieval method
|
|
1116
|
+
* Original retrieval method.
|
|
1109
1117
|
*/
|
|
1110
1118
|
method?: 'provider' | 'browser_curl' | 'browser_render';
|
|
1111
1119
|
|
|
@@ -1254,8 +1262,8 @@ export namespace Strategy {
|
|
|
1254
1262
|
|
|
1255
1263
|
export interface Usage {
|
|
1256
1264
|
/**
|
|
1257
|
-
* Number of result URLs for which a Kernel browser retrieval
|
|
1258
|
-
* excluding cache-only hits.
|
|
1265
|
+
* Number of result URLs for which a Kernel browser retrieval received a response
|
|
1266
|
+
* from the target, excluding cache-only hits.
|
|
1259
1267
|
*/
|
|
1260
1268
|
content_fetches: number;
|
|
1261
1269
|
|
|
@@ -1398,36 +1406,37 @@ export interface SearchCreateParams {
|
|
|
1398
1406
|
export namespace SearchCreateParams {
|
|
1399
1407
|
export interface SearchContentOptions {
|
|
1400
1408
|
/**
|
|
1401
|
-
*
|
|
1402
|
-
* the chosen identity is not bypassed.
|
|
1409
|
+
* Requires source=auto or source=browser in deferred retrieval.
|
|
1403
1410
|
*/
|
|
1404
1411
|
browser?: SearchContentOptions.Browser;
|
|
1405
1412
|
|
|
1406
1413
|
format?: 'markdown' | 'text';
|
|
1407
1414
|
|
|
1408
1415
|
/**
|
|
1409
|
-
*
|
|
1410
|
-
*
|
|
1411
|
-
*
|
|
1412
|
-
*
|
|
1413
|
-
*
|
|
1414
|
-
* otherwise provider content age is reported as unknown via fetched_at.
|
|
1416
|
+
* For source=auto, maximum acceptable age of retained provider content, measured
|
|
1417
|
+
* from when the search received it from the provider. A value of 0 disables reuse
|
|
1418
|
+
* of retained content, so every result is fetched through a browser.
|
|
1419
|
+
* source=provider reuses retained provider content without freshness validation.
|
|
1420
|
+
* source=browser always fetches through a browser and does not use this age limit.
|
|
1415
1421
|
*/
|
|
1416
1422
|
max_age_hours?: number;
|
|
1417
1423
|
|
|
1418
1424
|
/**
|
|
1419
|
-
* Per-result Unicode character limit after extraction.
|
|
1425
|
+
* Per-result Unicode character limit after extraction. Retained provider content
|
|
1426
|
+
* cannot exceed what was stored at search time; such results report truncated when
|
|
1427
|
+
* the stored text was already truncated.
|
|
1420
1428
|
*/
|
|
1421
1429
|
max_chars?: number;
|
|
1422
1430
|
|
|
1423
1431
|
/**
|
|
1424
|
-
*
|
|
1425
|
-
*
|
|
1426
|
-
*
|
|
1427
|
-
*
|
|
1428
|
-
*
|
|
1429
|
-
*
|
|
1430
|
-
*
|
|
1432
|
+
* auto uses retained provider content within max_age_hours; for deferred retrieval
|
|
1433
|
+
* it falls back to a Kernel browser (caller-supplied or temporary) for results
|
|
1434
|
+
* without it. Inline retrieval never uses a browser. provider reuses retained
|
|
1435
|
+
* provider content when available, without freshness validation, and never
|
|
1436
|
+
* provisions a browser. browser fetches each URL through a Kernel browser, either
|
|
1437
|
+
* caller-supplied or temporary. No option makes a new provider request. Defaults
|
|
1438
|
+
* to auto for both inline and deferred retrieval. Missing documents produce
|
|
1439
|
+
* per-result unavailable outcomes, not request failures.
|
|
1431
1440
|
*/
|
|
1432
1441
|
source?: 'auto' | 'provider' | 'browser';
|
|
1433
1442
|
|
|
@@ -1440,17 +1449,22 @@ export namespace SearchCreateParams {
|
|
|
1440
1449
|
|
|
1441
1450
|
export namespace SearchContentOptions {
|
|
1442
1451
|
/**
|
|
1443
|
-
*
|
|
1444
|
-
* the chosen identity is not bypassed.
|
|
1452
|
+
* Requires source=auto or source=browser in deferred retrieval.
|
|
1445
1453
|
*/
|
|
1446
1454
|
export interface Browser {
|
|
1447
1455
|
/**
|
|
1448
1456
|
* Existing browser session ID authorized for the caller and selected project.
|
|
1449
|
-
* Reuses its cookies, proxy, and browser configuration
|
|
1450
|
-
*
|
|
1451
|
-
*
|
|
1452
|
-
*
|
|
1453
|
-
*
|
|
1457
|
+
* Reuses its cookies, proxy, and browser configuration; requests follow that
|
|
1458
|
+
* browser's existing network access behavior, with no additional destination
|
|
1459
|
+
* allowlist in this endpoint. Kernel does not delete a caller-supplied browser.
|
|
1460
|
+
* Render mode uses a temporary tab; website activity may still change shared
|
|
1461
|
+
* cookies and storage. When omitted and any result needs browser retrieval, Kernel
|
|
1462
|
+
* creates one temporary browser for the request using the dashboard launch
|
|
1463
|
+
* defaults (headful, stealth, default proxy), tags it with search_id, and deletes
|
|
1464
|
+
* it when the request finishes. It is billed and counts toward browser concurrency
|
|
1465
|
+
* like any other browser. A concurrency rejection returns 429 for source=browser;
|
|
1466
|
+
* for source=auto, results with retained content are still returned and the rest
|
|
1467
|
+
* report the rejection.
|
|
1454
1468
|
*/
|
|
1455
1469
|
browser_id?: string;
|
|
1456
1470
|
|
|
@@ -413,8 +413,9 @@ export namespace CardVaultItemSpec {
|
|
|
413
413
|
|
|
414
414
|
/**
|
|
415
415
|
* AgentCard reusable live payment card. Test-mode card creation is not supported.
|
|
416
|
-
* Each checkout creates an
|
|
417
|
-
*
|
|
416
|
+
* Each checkout creates an authorization for spec.merchant / spec.amount that the
|
|
417
|
+
* cardholder approves, unless AgentCard runs it under one of the cardholder's
|
|
418
|
+
* autopilot rules. The card stays ready after each authorization.
|
|
418
419
|
*/
|
|
419
420
|
export interface AgentCardCardVaultItemSpec {
|
|
420
421
|
/**
|
|
@@ -442,6 +443,18 @@ export namespace CardVaultItemSpec {
|
|
|
442
443
|
* picks on the approval screen.
|
|
443
444
|
*/
|
|
444
445
|
card_id?: string;
|
|
446
|
+
|
|
447
|
+
/**
|
|
448
|
+
* Origin of the top-level checkout page, such as https://shop.example.com: https,
|
|
449
|
+
* a lowercase host, a port only when it is not 443, and no path. http is accepted
|
|
450
|
+
* only for localhost test pages. Checkouts without a preparation send it to
|
|
451
|
+
* AgentCard, which uses it to match the cardholder's autopilot rules; prepared
|
|
452
|
+
* checkouts send the preparation's merchant_origin instead. Kernel sends the
|
|
453
|
+
* declared value and does not compare it with the page the browser has open.
|
|
454
|
+
* Omitted, those checkouts ask the cardholder to approve. Card updates replace the
|
|
455
|
+
* whole spec, so an update that omits it removes it.
|
|
456
|
+
*/
|
|
457
|
+
checkout_origin?: string;
|
|
445
458
|
}
|
|
446
459
|
}
|
|
447
460
|
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.116.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.116.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.116.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.116.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|