@1claw/sdk 0.41.1 → 0.41.3

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.
@@ -4506,10 +4506,257 @@ export interface paths {
4506
4506
  patch?: never;
4507
4507
  trace?: never;
4508
4508
  };
4509
+ "/v1/agents/{agent_id}/cards/order": {
4510
+ parameters: {
4511
+ query?: never;
4512
+ header?: never;
4513
+ path?: never;
4514
+ cookie?: never;
4515
+ };
4516
+ get?: never;
4517
+ put?: never;
4518
+ /**
4519
+ * Order a payment card (x402)
4520
+ * @description Order a prepaid or gift card for an agent. Drives the x402 payment flow server-side using the agent's Ethereum signing key (funded with USDC on Base). Requires `cards_enabled` on the agent and a Pro or higher plan. An `Idempotency-Key` header is required.
4521
+ */
4522
+ post: operations["orderCard"];
4523
+ delete?: never;
4524
+ options?: never;
4525
+ head?: never;
4526
+ patch?: never;
4527
+ trace?: never;
4528
+ };
4529
+ "/v1/cards": {
4530
+ parameters: {
4531
+ query?: never;
4532
+ header?: never;
4533
+ path?: never;
4534
+ cookie?: never;
4535
+ };
4536
+ /**
4537
+ * List payment cards
4538
+ * @description List cards for the caller (agents see only their own). Always masked (last4 only).
4539
+ */
4540
+ get: operations["listCards"];
4541
+ put?: never;
4542
+ post?: never;
4543
+ delete?: never;
4544
+ options?: never;
4545
+ head?: never;
4546
+ patch?: never;
4547
+ trace?: never;
4548
+ };
4549
+ "/v1/cards/import": {
4550
+ parameters: {
4551
+ query?: never;
4552
+ header?: never;
4553
+ path?: never;
4554
+ cookie?: never;
4555
+ };
4556
+ get?: never;
4557
+ put?: never;
4558
+ /**
4559
+ * Import a card (human-only)
4560
+ * @description Manually import an existing card. Full storage mode — PAN stored encrypted, CVV as a one-time-read secret. Human-only.
4561
+ */
4562
+ post: operations["importCard"];
4563
+ delete?: never;
4564
+ options?: never;
4565
+ head?: never;
4566
+ patch?: never;
4567
+ trace?: never;
4568
+ };
4569
+ "/v1/cards/gift-cards/search": {
4570
+ parameters: {
4571
+ query?: never;
4572
+ header?: never;
4573
+ path?: never;
4574
+ cookie?: never;
4575
+ };
4576
+ get?: never;
4577
+ put?: never;
4578
+ /**
4579
+ * Search gift-card brands
4580
+ * @description Search available Laso gift-card brands/servers for the org's Laso account.
4581
+ */
4582
+ post: operations["searchGiftCards"];
4583
+ delete?: never;
4584
+ options?: never;
4585
+ head?: never;
4586
+ patch?: never;
4587
+ trace?: never;
4588
+ };
4589
+ "/v1/cards/{card_id}": {
4590
+ parameters: {
4591
+ query?: never;
4592
+ header?: never;
4593
+ path?: never;
4594
+ cookie?: never;
4595
+ };
4596
+ /**
4597
+ * Get a payment card
4598
+ * @description Get a single card (masked — last4 only).
4599
+ */
4600
+ get: operations["getCard"];
4601
+ put?: never;
4602
+ post?: never;
4603
+ delete?: never;
4604
+ options?: never;
4605
+ head?: never;
4606
+ /** Update a card's reveal policy (human-only) */
4607
+ patch: operations["updateCard"];
4608
+ trace?: never;
4609
+ };
4610
+ "/v1/cards/{card_id}/reveal": {
4611
+ parameters: {
4612
+ query?: never;
4613
+ header?: never;
4614
+ path?: never;
4615
+ cookie?: never;
4616
+ };
4617
+ get?: never;
4618
+ put?: never;
4619
+ /**
4620
+ * Reveal card details
4621
+ * @description Reveal full card details (PAN/CVV or gift-card redemption). Humans must re-authenticate with their account password via the `X-Auth-Confirm` header. Agents may reveal only when a human has enabled a per-card reveal policy. Once revealed, the card can be used anywhere up to its balance — 1Claw has no further control.
4622
+ */
4623
+ post: operations["revealCard"];
4624
+ delete?: never;
4625
+ options?: never;
4626
+ head?: never;
4627
+ patch?: never;
4628
+ trace?: never;
4629
+ };
4630
+ "/v1/cards/{card_id}/void": {
4631
+ parameters: {
4632
+ query?: never;
4633
+ header?: never;
4634
+ path?: never;
4635
+ cookie?: never;
4636
+ };
4637
+ get?: never;
4638
+ put?: never;
4639
+ /**
4640
+ * Void a card
4641
+ * @description 1Claw-level lock that blocks all further reveals/refreshes. Forward-looking only — a card revealed before void remains live.
4642
+ */
4643
+ post: operations["voidCard"];
4644
+ delete?: never;
4645
+ options?: never;
4646
+ head?: never;
4647
+ patch?: never;
4648
+ trace?: never;
4649
+ };
4650
+ "/v1/cards/{card_id}/refresh": {
4651
+ parameters: {
4652
+ query?: never;
4653
+ header?: never;
4654
+ path?: never;
4655
+ cookie?: never;
4656
+ };
4657
+ get?: never;
4658
+ put?: never;
4659
+ /**
4660
+ * Refresh a card's balance
4661
+ * @description Proxy Laso refresh to update balance/status. Rate-limited to once per 5 minutes per card (429 on exceed).
4662
+ */
4663
+ post: operations["refreshCard"];
4664
+ delete?: never;
4665
+ options?: never;
4666
+ head?: never;
4667
+ patch?: never;
4668
+ trace?: never;
4669
+ };
4509
4670
  }
4510
4671
  export type webhooks = Record<string, never>;
4511
4672
  export interface components {
4512
4673
  schemas: {
4674
+ OrderCardRequest: {
4675
+ /** @enum {string} */
4676
+ kind: "prepaid" | "gift_card";
4677
+ /**
4678
+ * @description USD amount to load onto the card.
4679
+ * @example 25.00
4680
+ */
4681
+ amount_usd: string;
4682
+ /** @description Optional Laso gift-card server/brand id (gift cards only). */
4683
+ laso_server_id?: string;
4684
+ /** @description Optional country (prepaid cards; defaults to US). */
4685
+ country?: string;
4686
+ };
4687
+ /** @description Masked card view — never contains PAN/CVV. */
4688
+ CardResponse: {
4689
+ /** Format: uuid */
4690
+ id: string;
4691
+ /** Format: uuid */
4692
+ agent_id?: string | null;
4693
+ /** @enum {string} */
4694
+ issuer: "laso" | "manual";
4695
+ /** @enum {string} */
4696
+ kind: "prepaid" | "gift_card";
4697
+ brand?: string;
4698
+ last4?: string;
4699
+ exp_month?: number;
4700
+ exp_year?: number;
4701
+ currency: string;
4702
+ order_amount_usd?: string;
4703
+ balance?: string;
4704
+ /** @enum {string} */
4705
+ status: "ordering" | "pending" | "ready" | "depleted" | "expired" | "voided" | "orphaned_payment";
4706
+ /** @enum {string} */
4707
+ storage_mode: "reference" | "full";
4708
+ reveal_policy: {
4709
+ [key: string]: unknown;
4710
+ };
4711
+ /** Format: date-time */
4712
+ void_after?: string;
4713
+ /** Format: date-time */
4714
+ created_at: string;
4715
+ /** Format: date-time */
4716
+ updated_at: string;
4717
+ };
4718
+ CardListResponse: {
4719
+ cards: components["schemas"]["CardResponse"][];
4720
+ };
4721
+ /** @description Revealed card details — sensitive. Returned only by the reveal endpoint. */
4722
+ CardRevealResponse: {
4723
+ /** Format: uuid */
4724
+ id: string;
4725
+ pan?: string;
4726
+ cvv?: string;
4727
+ exp_month?: number;
4728
+ exp_year?: number;
4729
+ brand?: string;
4730
+ /** @description Gift-card redemption payload (URL/code/PIN) when applicable. */
4731
+ redemption?: {
4732
+ [key: string]: unknown;
4733
+ };
4734
+ disclaimer: string;
4735
+ };
4736
+ /** @description Human-settable per-card reveal policy + lifecycle controls. */
4737
+ UpdateCardRequest: {
4738
+ agent_reveal?: boolean;
4739
+ max_reveals?: number;
4740
+ /** Format: date-time */
4741
+ reveal_expires_at?: string | null;
4742
+ /** Format: date-time */
4743
+ void_after?: string | null;
4744
+ };
4745
+ ImportCardRequest: {
4746
+ pan: string;
4747
+ cvv: string;
4748
+ exp_month: number;
4749
+ exp_year: number;
4750
+ brand?: string;
4751
+ currency?: string;
4752
+ balance?: string;
4753
+ /** Format: uuid */
4754
+ agent_id?: string;
4755
+ };
4756
+ SearchGiftCardsRequest: {
4757
+ query?: string;
4758
+ country?: string;
4759
+ };
4513
4760
  /** @description RFC 7807 error envelope */
4514
4761
  ProblemDetails: {
4515
4762
  type?: string;
@@ -5033,12 +5280,30 @@ export interface components {
5033
5280
  xrpl_allowed_tx_types?: string[];
5034
5281
  /**
5035
5282
  * @description Per-chain guardrail overrides. Keys are signing chains (ethereum, bitcoin, solana, xrp, cardano, tron).
5036
- * Each value may include max_value, daily_limit, to_allowlist, token_allowlist (legacy *_eth keys accepted).
5283
+ * Each value may include max_value, daily_limit, to_allowlist, token_allowlist, max_per_day, overhead_budget, max_ata_creates_per_day.
5037
5284
  * Strictest of global and per-chain limits wins. Daily limits apply per chain family spend, not cross-chain totals.
5038
5285
  */
5039
5286
  per_chain_guardrails?: {
5040
5287
  [key: string]: unknown;
5041
5288
  };
5289
+ /** @description Max transactions per UTC calendar day. Null = unlimited. */
5290
+ tx_max_per_day?: number | null;
5291
+ /** @description Per-chain daily overhead budget in native units (e.g. {"solana":"0.5","xrp":"100"}). */
5292
+ tx_overhead_budget?: {
5293
+ [key: string]: string;
5294
+ } | null;
5295
+ /** @description Solana wallet addresses whose ATAs may be created. Empty = unrestricted. */
5296
+ solana_ata_allowlist?: string[];
5297
+ /** @description Whether this agent may order payment cards (x402 card ordering). Pro+ tier. */
5298
+ cards_enabled?: boolean;
5299
+ /** @description Maximum USD amount for a single card order. */
5300
+ card_max_order_usd?: string;
5301
+ /** @description Maximum cumulative USD spent ordering cards per rolling 24h window. */
5302
+ card_daily_limit_usd?: string;
5303
+ /** @description Allowed x402 payTo recipients for card orders (empty = built-in Laso recipients). */
5304
+ card_payto_allowlist?: string[];
5305
+ /** @description Whether agents may reveal card details subject to per-card reveal policy. */
5306
+ card_reveal_enabled?: boolean;
5042
5307
  /**
5043
5308
  * Format: date-time
5044
5309
  * @description Optional expiration time for the agent's API key.
@@ -5083,6 +5348,24 @@ export interface components {
5083
5348
  intents_require_tee?: boolean;
5084
5349
  /** @description When true, execute requests must arrive via TEE and all direct secret reads are blocked (Pro+ only) */
5085
5350
  execution_require_tee?: boolean;
5351
+ /** @description Max transactions per UTC calendar day. Null = unlimited. */
5352
+ tx_max_per_day?: number | null;
5353
+ /** @description Per-chain daily overhead budget in native units. */
5354
+ tx_overhead_budget?: {
5355
+ [key: string]: string;
5356
+ } | null;
5357
+ /** @description Solana wallet addresses whose ATAs may be created. */
5358
+ solana_ata_allowlist?: string[];
5359
+ /** @description Whether this agent may order payment cards (x402 card ordering). Pro+ tier. */
5360
+ cards_enabled?: boolean;
5361
+ /** @description Maximum USD amount for a single card order. null clears. */
5362
+ card_max_order_usd?: string | null;
5363
+ /** @description Maximum cumulative USD spent ordering cards per rolling 24h window. null clears. */
5364
+ card_daily_limit_usd?: string | null;
5365
+ /** @description Allowed x402 payTo recipients for card orders (empty = built-in Laso recipients). */
5366
+ card_payto_allowlist?: string[];
5367
+ /** @description Whether agents may reveal card details subject to per-card reveal policy. */
5368
+ card_reveal_enabled?: boolean;
5086
5369
  /**
5087
5370
  * @description Enable OIDC federation (RFC 8693 token-exchange) for this agent.
5088
5371
  * When true, the agent may call POST /v1/auth/federated-token to mint
@@ -5182,6 +5465,30 @@ export interface components {
5182
5465
  intents_require_tee?: boolean;
5183
5466
  /** @description When true, execute requests must arrive via TEE and all direct secret reads are blocked (Pro+ only) */
5184
5467
  execution_require_tee?: boolean;
5468
+ /** @description Max transactions per UTC calendar day. Null = unlimited. */
5469
+ tx_max_per_day?: number | null;
5470
+ /** @description Per-chain daily overhead budget in native units. */
5471
+ tx_overhead_budget?: {
5472
+ [key: string]: string;
5473
+ } | null;
5474
+ /** @description Solana wallet addresses whose ATAs may be created. */
5475
+ solana_ata_allowlist?: string[];
5476
+ /** @description Whether this agent may order payment cards (x402 card ordering). */
5477
+ cards_enabled?: boolean;
5478
+ /** @description Maximum USD amount for a single card order. */
5479
+ card_max_order_usd?: string;
5480
+ /** @description Maximum cumulative USD spent ordering cards per rolling 24h window. */
5481
+ card_daily_limit_usd?: string;
5482
+ /** @description Allowed x402 payTo recipients for card orders (empty = built-in Laso recipients). */
5483
+ card_payto_allowlist?: string[];
5484
+ /** @description Whether agents may reveal card details subject to per-card reveal policy. */
5485
+ card_reveal_enabled?: boolean;
5486
+ /** @description Today's transaction count (UTC calendar day). Present when intents_api_enabled. */
5487
+ tx_count_today?: number;
5488
+ /** @description Today's overhead spend by chain in native units. */
5489
+ tx_overhead_today_by_chain?: {
5490
+ [key: string]: string;
5491
+ };
5185
5492
  /**
5186
5493
  * @description Whether this agent may mint OIDC federation tokens via
5187
5494
  * POST /v1/auth/federated-token. False by default.
@@ -7464,6 +7771,7 @@ export interface components {
7464
7771
  SecretPath: string;
7465
7772
  AgentId: string;
7466
7773
  PolicyId: string;
7774
+ CardId: string;
7467
7775
  /** @description Set to `true` or `1` to include the raw signed transaction hex in the response. Omitted by default to reduce key exfiltration risk. Only the literal values "true" or "1" enable inclusion; any other value or omission returns responses without signed_tx. Applies to GET /v1/agents/{agent_id}/transactions and GET /v1/agents/{agent_id}/transactions/{tx_id}. */
7468
7776
  IncludeSignedTx: boolean;
7469
7777
  };
@@ -13216,5 +13524,239 @@ export interface operations {
13216
13524
  403: components["responses"]["Forbidden"];
13217
13525
  };
13218
13526
  };
13527
+ orderCard: {
13528
+ parameters: {
13529
+ query?: never;
13530
+ header: {
13531
+ "Idempotency-Key": string;
13532
+ };
13533
+ path: {
13534
+ agent_id: components["parameters"]["AgentId"];
13535
+ };
13536
+ cookie?: never;
13537
+ };
13538
+ requestBody: {
13539
+ content: {
13540
+ "application/json": components["schemas"]["OrderCardRequest"];
13541
+ };
13542
+ };
13543
+ responses: {
13544
+ /** @description Card order accepted (status pending) */
13545
+ 201: {
13546
+ headers: {
13547
+ [name: string]: unknown;
13548
+ };
13549
+ content: {
13550
+ "application/json": components["schemas"]["CardResponse"];
13551
+ };
13552
+ };
13553
+ 400: components["responses"]["BadRequest"];
13554
+ 403: components["responses"]["Forbidden"];
13555
+ 409: components["responses"]["Conflict"];
13556
+ };
13557
+ };
13558
+ listCards: {
13559
+ parameters: {
13560
+ query?: never;
13561
+ header?: never;
13562
+ path?: never;
13563
+ cookie?: never;
13564
+ };
13565
+ requestBody?: never;
13566
+ responses: {
13567
+ /** @description Card list */
13568
+ 200: {
13569
+ headers: {
13570
+ [name: string]: unknown;
13571
+ };
13572
+ content: {
13573
+ "application/json": components["schemas"]["CardListResponse"];
13574
+ };
13575
+ };
13576
+ };
13577
+ };
13578
+ importCard: {
13579
+ parameters: {
13580
+ query?: never;
13581
+ header?: never;
13582
+ path?: never;
13583
+ cookie?: never;
13584
+ };
13585
+ requestBody: {
13586
+ content: {
13587
+ "application/json": components["schemas"]["ImportCardRequest"];
13588
+ };
13589
+ };
13590
+ responses: {
13591
+ /** @description Card imported */
13592
+ 201: {
13593
+ headers: {
13594
+ [name: string]: unknown;
13595
+ };
13596
+ content: {
13597
+ "application/json": components["schemas"]["CardResponse"];
13598
+ };
13599
+ };
13600
+ 400: components["responses"]["BadRequest"];
13601
+ 403: components["responses"]["Forbidden"];
13602
+ };
13603
+ };
13604
+ searchGiftCards: {
13605
+ parameters: {
13606
+ query?: never;
13607
+ header?: never;
13608
+ path?: never;
13609
+ cookie?: never;
13610
+ };
13611
+ requestBody?: {
13612
+ content: {
13613
+ "application/json": components["schemas"]["SearchGiftCardsRequest"];
13614
+ };
13615
+ };
13616
+ responses: {
13617
+ /** @description Available gift-card brands (provider-shaped payload) */
13618
+ 200: {
13619
+ headers: {
13620
+ [name: string]: unknown;
13621
+ };
13622
+ content: {
13623
+ "application/json": {
13624
+ [key: string]: unknown;
13625
+ };
13626
+ };
13627
+ };
13628
+ };
13629
+ };
13630
+ getCard: {
13631
+ parameters: {
13632
+ query?: never;
13633
+ header?: never;
13634
+ path: {
13635
+ card_id: components["parameters"]["CardId"];
13636
+ };
13637
+ cookie?: never;
13638
+ };
13639
+ requestBody?: never;
13640
+ responses: {
13641
+ /** @description Card details */
13642
+ 200: {
13643
+ headers: {
13644
+ [name: string]: unknown;
13645
+ };
13646
+ content: {
13647
+ "application/json": components["schemas"]["CardResponse"];
13648
+ };
13649
+ };
13650
+ 404: components["responses"]["NotFound"];
13651
+ };
13652
+ };
13653
+ updateCard: {
13654
+ parameters: {
13655
+ query?: never;
13656
+ header?: never;
13657
+ path: {
13658
+ card_id: components["parameters"]["CardId"];
13659
+ };
13660
+ cookie?: never;
13661
+ };
13662
+ requestBody: {
13663
+ content: {
13664
+ "application/json": components["schemas"]["UpdateCardRequest"];
13665
+ };
13666
+ };
13667
+ responses: {
13668
+ /** @description Card updated */
13669
+ 200: {
13670
+ headers: {
13671
+ [name: string]: unknown;
13672
+ };
13673
+ content: {
13674
+ "application/json": components["schemas"]["CardResponse"];
13675
+ };
13676
+ };
13677
+ 403: components["responses"]["Forbidden"];
13678
+ 404: components["responses"]["NotFound"];
13679
+ };
13680
+ };
13681
+ revealCard: {
13682
+ parameters: {
13683
+ query?: never;
13684
+ header?: {
13685
+ /** @description Account password (humans) for re-authentication. */
13686
+ "X-Auth-Confirm"?: string;
13687
+ };
13688
+ path: {
13689
+ card_id: components["parameters"]["CardId"];
13690
+ };
13691
+ cookie?: never;
13692
+ };
13693
+ requestBody?: never;
13694
+ responses: {
13695
+ /** @description Revealed card details (sensitive) */
13696
+ 200: {
13697
+ headers: {
13698
+ [name: string]: unknown;
13699
+ };
13700
+ content: {
13701
+ "application/json": components["schemas"]["CardRevealResponse"];
13702
+ };
13703
+ };
13704
+ 403: components["responses"]["Forbidden"];
13705
+ 404: components["responses"]["NotFound"];
13706
+ };
13707
+ };
13708
+ voidCard: {
13709
+ parameters: {
13710
+ query?: never;
13711
+ header?: never;
13712
+ path: {
13713
+ card_id: components["parameters"]["CardId"];
13714
+ };
13715
+ cookie?: never;
13716
+ };
13717
+ requestBody?: never;
13718
+ responses: {
13719
+ /** @description Card voided */
13720
+ 200: {
13721
+ headers: {
13722
+ [name: string]: unknown;
13723
+ };
13724
+ content: {
13725
+ "application/json": components["schemas"]["CardResponse"];
13726
+ };
13727
+ };
13728
+ 404: components["responses"]["NotFound"];
13729
+ };
13730
+ };
13731
+ refreshCard: {
13732
+ parameters: {
13733
+ query?: never;
13734
+ header?: never;
13735
+ path: {
13736
+ card_id: components["parameters"]["CardId"];
13737
+ };
13738
+ cookie?: never;
13739
+ };
13740
+ requestBody?: never;
13741
+ responses: {
13742
+ /** @description Card refreshed */
13743
+ 200: {
13744
+ headers: {
13745
+ [name: string]: unknown;
13746
+ };
13747
+ content: {
13748
+ "application/json": components["schemas"]["CardResponse"];
13749
+ };
13750
+ };
13751
+ 404: components["responses"]["NotFound"];
13752
+ /** @description Refreshed too recently */
13753
+ 429: {
13754
+ headers: {
13755
+ [name: string]: unknown;
13756
+ };
13757
+ content?: never;
13758
+ };
13759
+ };
13760
+ };
13219
13761
  }
13220
13762
  //# sourceMappingURL=api-types.d.ts.map