@onkernel/sdk 0.123.0 → 0.125.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.
Files changed (49) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/package.json +1 -1
  3. package/resources/api-keys.d.mts +67 -2
  4. package/resources/api-keys.d.mts.map +1 -1
  5. package/resources/api-keys.d.ts +67 -2
  6. package/resources/api-keys.d.ts.map +1 -1
  7. package/resources/api-keys.js +2 -1
  8. package/resources/api-keys.js.map +1 -1
  9. package/resources/api-keys.mjs +2 -1
  10. package/resources/api-keys.mjs.map +1 -1
  11. package/resources/browser-pools.d.mts +1 -1
  12. package/resources/browser-pools.d.mts.map +1 -1
  13. package/resources/browser-pools.d.ts +1 -1
  14. package/resources/browser-pools.d.ts.map +1 -1
  15. package/resources/browsers/playwright/playwright.d.mts +0 -4
  16. package/resources/browsers/playwright/playwright.d.mts.map +1 -1
  17. package/resources/browsers/playwright/playwright.d.ts +0 -4
  18. package/resources/browsers/playwright/playwright.d.ts.map +1 -1
  19. package/resources/browsers/playwright/playwright.js +0 -4
  20. package/resources/browsers/playwright/playwright.js.map +1 -1
  21. package/resources/browsers/playwright/playwright.mjs +0 -4
  22. package/resources/browsers/playwright/playwright.mjs.map +1 -1
  23. package/resources/vaults/index.d.mts +1 -1
  24. package/resources/vaults/index.d.mts.map +1 -1
  25. package/resources/vaults/index.d.ts +1 -1
  26. package/resources/vaults/index.d.ts.map +1 -1
  27. package/resources/vaults/index.js.map +1 -1
  28. package/resources/vaults/index.mjs.map +1 -1
  29. package/resources/vaults/items.d.mts +106 -14
  30. package/resources/vaults/items.d.mts.map +1 -1
  31. package/resources/vaults/items.d.ts +106 -14
  32. package/resources/vaults/items.d.ts.map +1 -1
  33. package/resources/vaults/vaults.d.mts +2 -2
  34. package/resources/vaults/vaults.d.mts.map +1 -1
  35. package/resources/vaults/vaults.d.ts +2 -2
  36. package/resources/vaults/vaults.d.ts.map +1 -1
  37. package/resources/vaults/vaults.js.map +1 -1
  38. package/resources/vaults/vaults.mjs.map +1 -1
  39. package/src/resources/api-keys.ts +76 -2
  40. package/src/resources/browser-pools.ts +1 -1
  41. package/src/resources/browsers/playwright/playwright.ts +0 -4
  42. package/src/resources/vaults/index.ts +2 -0
  43. package/src/resources/vaults/items.ts +148 -6
  44. package/src/resources/vaults/vaults.ts +4 -0
  45. package/src/version.ts +1 -1
  46. package/version.d.mts +1 -1
  47. package/version.d.ts +1 -1
  48. package/version.js +1 -1
  49. package/version.mjs +1 -1
@@ -600,6 +600,44 @@ export interface CollectVaultItemOperationRequest {
600
600
  type: 'collect';
601
601
  }
602
602
 
603
+ /**
604
+ * Report a real merchant transaction outcome for an issued Kernel Visa credential.
605
+ * Never infer success from filling checkout or receiving a credential. Supply the
606
+ * observed status, transaction type, actual amount, currency and timestamp.
607
+ * Unknown outcomes require manual reconciliation, not retry. Each purchase accepts
608
+ * one report.
609
+ */
610
+ export interface ConfirmTransactionVaultItemOperationRequest {
611
+ /**
612
+ * Actual transaction amount in minor units, no greater than the approved limit.
613
+ */
614
+ amount: number;
615
+
616
+ /**
617
+ * Must match the approved purchase currency.
618
+ */
619
+ currency: string;
620
+
621
+ /**
622
+ * Time the merchant outcome was observed.
623
+ */
624
+ occurred_at: string;
625
+
626
+ status: 'APPROVED' | 'DECLINED' | 'PENDING' | 'ERROR' | 'CANCELLED';
627
+
628
+ transaction_type:
629
+ | 'PURCHASE'
630
+ | 'AUTHORIZATION'
631
+ | 'CAPTURE'
632
+ | 'REFUND'
633
+ | 'REVERSAL'
634
+ | 'VERIFICATION'
635
+ | 'CHARGEBACK'
636
+ | 'FRAUD';
637
+
638
+ type: 'confirm_transaction';
639
+ }
640
+
603
641
  export interface CredentialAccountVaultItem {
604
642
  id: string;
605
643
 
@@ -652,6 +690,8 @@ export namespace CredentialAccountVaultItem {
652
690
 
653
691
  type:
654
692
  | 'authorize'
693
+ | 'restart_verification'
694
+ | 'confirm_transaction'
655
695
  | 'collect'
656
696
  | 'prepare_checkout'
657
697
  | 'fill'
@@ -960,6 +1000,8 @@ export namespace CredentialVaultItem {
960
1000
 
961
1001
  type:
962
1002
  | 'authorize'
1003
+ | 'restart_verification'
1004
+ | 'confirm_transaction'
963
1005
  | 'collect'
964
1006
  | 'prepare_checkout'
965
1007
  | 'fill'
@@ -1177,12 +1219,16 @@ export interface KernelCardState {
1177
1219
  /**
1178
1220
  * pending_authorization on a Visa purchase waits for the cardholder to approve it
1179
1221
  * through the spend_approval action; an unused link expires after 30 minutes.
1180
- * recovery_required means approving the purchase or issuing the one-time code has
1181
- * an unresolved outcome. Kernel never approves again or issues another code for
1182
- * the item automatically, and the item cannot be deleted or replaced until the
1183
- * original attempt is reconciled with support. When status_reason says the
1184
- * provider refused retrieval before acceptance, no code was issued and a later
1185
- * read retries. declined means the card network refused to issue a code.
1222
+ * recovery_required means verification, approving the purchase or issuing the
1223
+ * one-time code has an unresolved outcome. A server-classified initial attestation
1224
+ * failure before intent dispatch may advertise restart_verification to prepare a
1225
+ * fresh local verification link; this does not approve spending or replay any
1226
+ * provider request. Unclassified legacy recovery and uncertain intent creation
1227
+ * cannot restart. Kernel never approves again or issues another code for the item
1228
+ * automatically, and the item cannot be deleted or replaced until the original
1229
+ * attempt is reconciled with support. When status_reason says the provider refused
1230
+ * retrieval before acceptance, no code was issued and a later read retries.
1231
+ * declined means the card network refused to issue a code.
1186
1232
  */
1187
1233
  status:
1188
1234
  | 'requested'
@@ -1257,6 +1303,17 @@ export interface KernelCardVaultItemSpec {
1257
1303
  */
1258
1304
  wallet: string;
1259
1305
 
1306
+ /**
1307
+ * Actual merchant category when known. Omit rather than invent a category.
1308
+ */
1309
+ merchant_category?: string;
1310
+
1311
+ /**
1312
+ * Actual merchant MCC when known. Omit rather than invent a code. 0000 is not
1313
+ * accepted.
1314
+ */
1315
+ merchant_category_code?: string;
1316
+
1260
1317
  /**
1261
1318
  * The merchant's ISO 3166-1 alpha-2 country code. Required for Visa cards, whose
1262
1319
  * one-time code is issued for the merchant's country.
@@ -1847,6 +1904,21 @@ export interface PrepareCheckoutVaultItemOperationRequest {
1847
1904
  type: 'prepare_checkout';
1848
1905
  }
1849
1906
 
1907
+ /**
1908
+ * Explicitly prepare a fresh local verification session for the same Kernel Visa
1909
+ * purchase and connected wallet, only when restart_verification is advertised.
1910
+ * Kernel must have durable proof of an initial attestation failure before intent
1911
+ * dispatch. Replaces the spend_approval capability and discards session-bound
1912
+ * verification data without calling the provider or granting spend consent. The
1913
+ * cardholder must use the new link, verify again and explicitly approve the
1914
+ * purchase. Unknown intent creation, legacy unclassified recovery, enrollment
1915
+ * completion, issuance and confirmation cannot restart. Do not automatically retry
1916
+ * this operation.
1917
+ */
1918
+ export interface RestartVerificationVaultItemOperationRequest {
1919
+ type: 'restart_verification';
1920
+ }
1921
+
1850
1922
  export interface VaultCardAliases {
1851
1923
  cvc: string;
1852
1924
 
@@ -2059,6 +2131,8 @@ export namespace VaultItem {
2059
2131
 
2060
2132
  type:
2061
2133
  | 'authorize'
2134
+ | 'restart_verification'
2135
+ | 'confirm_transaction'
2062
2136
  | 'collect'
2063
2137
  | 'prepare_checkout'
2064
2138
  | 'fill'
@@ -2132,6 +2206,8 @@ export namespace VaultItem {
2132
2206
 
2133
2207
  type:
2134
2208
  | 'authorize'
2209
+ | 'restart_verification'
2210
+ | 'confirm_transaction'
2135
2211
  | 'collect'
2136
2212
  | 'prepare_checkout'
2137
2213
  | 'fill'
@@ -2281,6 +2357,8 @@ export namespace VaultItemOperationResponse {
2281
2357
 
2282
2358
  type:
2283
2359
  | 'authorize'
2360
+ | 'restart_verification'
2361
+ | 'confirm_transaction'
2284
2362
  | 'collect'
2285
2363
  | 'prepare_checkout'
2286
2364
  | 'fill'
@@ -2354,6 +2432,8 @@ export namespace VaultItemOperationResponse {
2354
2432
 
2355
2433
  type:
2356
2434
  | 'authorize'
2435
+ | 'restart_verification'
2436
+ | 'confirm_transaction'
2357
2437
  | 'collect'
2358
2438
  | 'prepare_checkout'
2359
2439
  | 'fill'
@@ -2739,6 +2819,8 @@ export interface ItemEventsParams {
2739
2819
 
2740
2820
  export type ItemPerformOperationParams =
2741
2821
  | ItemPerformOperationParams.AuthorizeVaultItemOperationRequest
2822
+ | ItemPerformOperationParams.RestartVerificationVaultItemOperationRequest
2823
+ | ItemPerformOperationParams.ConfirmTransactionVaultItemOperationRequest
2742
2824
  | ItemPerformOperationParams.CollectVaultItemOperationRequest
2743
2825
  | ItemPerformOperationParams.PrepareCheckoutVaultItemOperationRequest
2744
2826
  | ItemPerformOperationParams.FillVaultItemOperationRequest
@@ -2762,6 +2844,64 @@ export declare namespace ItemPerformOperationParams {
2762
2844
  type: 'authorize';
2763
2845
  }
2764
2846
 
2847
+ export interface RestartVerificationVaultItemOperationRequest {
2848
+ /**
2849
+ * Path param
2850
+ */
2851
+ id_or_name: string;
2852
+
2853
+ /**
2854
+ * Body param
2855
+ */
2856
+ type: 'restart_verification';
2857
+ }
2858
+
2859
+ export interface ConfirmTransactionVaultItemOperationRequest {
2860
+ /**
2861
+ * Path param
2862
+ */
2863
+ id_or_name: string;
2864
+
2865
+ /**
2866
+ * Body param: Actual transaction amount in minor units, no greater than the
2867
+ * approved limit.
2868
+ */
2869
+ amount: number;
2870
+
2871
+ /**
2872
+ * Body param: Must match the approved purchase currency.
2873
+ */
2874
+ currency: string;
2875
+
2876
+ /**
2877
+ * Body param: Time the merchant outcome was observed.
2878
+ */
2879
+ occurred_at: string;
2880
+
2881
+ /**
2882
+ * Body param
2883
+ */
2884
+ status: 'APPROVED' | 'DECLINED' | 'PENDING' | 'ERROR' | 'CANCELLED';
2885
+
2886
+ /**
2887
+ * Body param
2888
+ */
2889
+ transaction_type:
2890
+ | 'PURCHASE'
2891
+ | 'AUTHORIZATION'
2892
+ | 'CAPTURE'
2893
+ | 'REFUND'
2894
+ | 'REVERSAL'
2895
+ | 'VERIFICATION'
2896
+ | 'CHARGEBACK'
2897
+ | 'FRAUD';
2898
+
2899
+ /**
2900
+ * Body param
2901
+ */
2902
+ type: 'confirm_transaction';
2903
+ }
2904
+
2765
2905
  export interface CollectVaultItemOperationRequest {
2766
2906
  /**
2767
2907
  * Path param
@@ -3233,6 +3373,7 @@ export declare namespace Items {
3233
3373
  type CardVaultItemSpec as CardVaultItemSpec,
3234
3374
  type CardVaultItemState as CardVaultItemState,
3235
3375
  type CollectVaultItemOperationRequest as CollectVaultItemOperationRequest,
3376
+ type ConfirmTransactionVaultItemOperationRequest as ConfirmTransactionVaultItemOperationRequest,
3236
3377
  type CredentialAccountVaultItem as CredentialAccountVaultItem,
3237
3378
  type CredentialAccountVaultItemRequest as CredentialAccountVaultItemRequest,
3238
3379
  type CredentialCollectionAction as CredentialCollectionAction,
@@ -3272,6 +3413,7 @@ export declare namespace Items {
3272
3413
  type OnePasswordRecoverVaultItemOperationRequest as OnePasswordRecoverVaultItemOperationRequest,
3273
3414
  type OnePasswordRequestAccessVaultItemOperationRequest as OnePasswordRequestAccessVaultItemOperationRequest,
3274
3415
  type PrepareCheckoutVaultItemOperationRequest as PrepareCheckoutVaultItemOperationRequest,
3416
+ type RestartVerificationVaultItemOperationRequest as RestartVerificationVaultItemOperationRequest,
3275
3417
  type VaultCardAliases as VaultCardAliases,
3276
3418
  type VaultCardFillField as VaultCardFillField,
3277
3419
  type VaultCheckoutContext as VaultCheckoutContext,
@@ -10,6 +10,7 @@ import {
10
10
  CardVaultItemSpec,
11
11
  CardVaultItemState,
12
12
  CollectVaultItemOperationRequest,
13
+ ConfirmTransactionVaultItemOperationRequest,
13
14
  CredentialAccountVaultItem,
14
15
  CredentialAccountVaultItemRequest,
15
16
  CredentialCollectionAction,
@@ -58,6 +59,7 @@ import {
58
59
  OnePasswordRecoverVaultItemOperationRequest,
59
60
  OnePasswordRequestAccessVaultItemOperationRequest,
60
61
  PrepareCheckoutVaultItemOperationRequest,
62
+ RestartVerificationVaultItemOperationRequest,
61
63
  VaultCardAliases,
62
64
  VaultCardFillField,
63
65
  VaultCheckoutContext,
@@ -270,6 +272,7 @@ export declare namespace Vaults {
270
272
  type CardVaultItemSpec as CardVaultItemSpec,
271
273
  type CardVaultItemState as CardVaultItemState,
272
274
  type CollectVaultItemOperationRequest as CollectVaultItemOperationRequest,
275
+ type ConfirmTransactionVaultItemOperationRequest as ConfirmTransactionVaultItemOperationRequest,
273
276
  type CredentialAccountVaultItem as CredentialAccountVaultItem,
274
277
  type CredentialAccountVaultItemRequest as CredentialAccountVaultItemRequest,
275
278
  type CredentialCollectionAction as CredentialCollectionAction,
@@ -309,6 +312,7 @@ export declare namespace Vaults {
309
312
  type OnePasswordRecoverVaultItemOperationRequest as OnePasswordRecoverVaultItemOperationRequest,
310
313
  type OnePasswordRequestAccessVaultItemOperationRequest as OnePasswordRequestAccessVaultItemOperationRequest,
311
314
  type PrepareCheckoutVaultItemOperationRequest as PrepareCheckoutVaultItemOperationRequest,
315
+ type RestartVerificationVaultItemOperationRequest as RestartVerificationVaultItemOperationRequest,
312
316
  type VaultCardAliases as VaultCardAliases,
313
317
  type VaultCardFillField as VaultCardFillField,
314
318
  type VaultCheckoutContext as VaultCheckoutContext,
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.123.0'; // x-release-please-version
1
+ export const VERSION = '0.125.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.123.0";
1
+ export declare const VERSION = "0.125.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.123.0";
1
+ export declare const VERSION = "0.125.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.123.0'; // x-release-please-version
4
+ exports.VERSION = '0.125.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.123.0'; // x-release-please-version
1
+ export const VERSION = '0.125.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map