@1claw/openapi-spec 0.41.2 → 0.41.4

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 (3) hide show
  1. package/openapi.json +868 -131
  2. package/openapi.yaml +478 -0
  3. package/package.json +38 -38
package/openapi.json CHANGED
@@ -130,6 +130,10 @@
130
130
  {
131
131
  "name": "Execution Intents",
132
132
  "description": "Execute HTTP calls, queries, and more through pre-configured bindings"
133
+ },
134
+ {
135
+ "name": "Payment Cards",
136
+ "description": "Order prepaid/gift cards via x402, then reveal, refresh, and void them"
133
137
  }
134
138
  ],
135
139
  "paths": {
@@ -8626,7 +8630,7 @@
8626
8630
  "Approvals"
8627
8631
  ],
8628
8632
  "summary": "Approve or reject",
8629
- "description": "Submit a decision (approve or reject) for a pending approval.\nHuman-only. The approval must be in `pending` status.\n",
8633
+ "description": "Submit a decision (approve or reject) for a pending approval.\nHuman-only. The approval must be in `pending` status.\nFor `card_order` approvals, approving auto-executes the x402 payment;\nrejecting marks the card as `rejected`.\nRisk tier 2+ approvals require step-up authentication via\n`X-Auth-Confirm` (account password or `rat_` re-auth token from\n`POST /v1/auth/reauth/begin` + `complete`). Risk tier 3 requires\npasskey or TOTP re-auth token.\n",
8630
8634
  "operationId": "decideApproval",
8631
8635
  "parameters": [
8632
8636
  {
@@ -8672,6 +8676,52 @@
8672
8676
  }
8673
8677
  }
8674
8678
  },
8679
+ "/v1/approvals/quick-decide": {
8680
+ "get": {
8681
+ "tags": [
8682
+ "Approvals"
8683
+ ],
8684
+ "summary": "One-click approve or deny (email link)",
8685
+ "description": "Public endpoint (no Bearer auth). The `token` query param is the\nauthenticator — SHA-256 hashed, single-use, 7-day TTL. On success\nredirects to `{public_url}/approvals/{id}?decided=true`.\nAuto-executes approved `card_order` and `policy_change` actions.\n",
8686
+ "operationId": "quickDecideApproval",
8687
+ "parameters": [
8688
+ {
8689
+ "name": "token",
8690
+ "in": "query",
8691
+ "required": true,
8692
+ "schema": {
8693
+ "type": "string"
8694
+ }
8695
+ },
8696
+ {
8697
+ "name": "decision",
8698
+ "in": "query",
8699
+ "required": true,
8700
+ "schema": {
8701
+ "type": "string",
8702
+ "enum": [
8703
+ "approved",
8704
+ "rejected"
8705
+ ]
8706
+ }
8707
+ }
8708
+ ],
8709
+ "responses": {
8710
+ "302": {
8711
+ "description": "Redirect to dashboard confirmation page"
8712
+ },
8713
+ "400": {
8714
+ "$ref": "#/components/responses/BadRequest"
8715
+ },
8716
+ "404": {
8717
+ "$ref": "#/components/responses/NotFound"
8718
+ },
8719
+ "409": {
8720
+ "$ref": "#/components/responses/Conflict"
8721
+ }
8722
+ }
8723
+ }
8724
+ },
8675
8725
  "/v1/deposit-destinations": {
8676
8726
  "post": {
8677
8727
  "tags": [
@@ -9957,156 +10007,759 @@
9957
10007
  }
9958
10008
  }
9959
10009
  }
9960
- }
9961
- },
9962
- "components": {
9963
- "securitySchemes": {
9964
- "BearerAuth": {
9965
- "type": "http",
9966
- "scheme": "bearer",
9967
- "bearerFormat": "JWT"
9968
- },
9969
- "ApiKeyAuth": {
9970
- "type": "http",
9971
- "scheme": "bearer",
9972
- "description": "1ck_ prefixed API key used as Bearer token"
9973
- }
9974
- },
9975
- "parameters": {
9976
- "VaultId": {
9977
- "name": "vault_id",
9978
- "in": "path",
9979
- "required": true,
9980
- "schema": {
9981
- "type": "string",
9982
- "format": "uuid"
9983
- }
9984
- },
9985
- "SecretPath": {
9986
- "name": "path",
9987
- "in": "path",
9988
- "required": true,
9989
- "schema": {
9990
- "type": "string"
9991
- },
9992
- "description": "Secret path (e.g. \"db/credentials\")"
9993
- },
9994
- "AgentId": {
9995
- "name": "agent_id",
9996
- "in": "path",
9997
- "required": true,
9998
- "schema": {
9999
- "type": "string",
10000
- "format": "uuid"
10001
- }
10002
- },
10003
- "PolicyId": {
10004
- "name": "policy_id",
10005
- "in": "path",
10006
- "required": true,
10007
- "schema": {
10008
- "type": "string",
10009
- "format": "uuid"
10010
- }
10011
- },
10012
- "IncludeSignedTx": {
10013
- "name": "include_signed_tx",
10014
- "in": "query",
10015
- "required": false,
10016
- "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}.\n",
10017
- "schema": {
10018
- "type": "boolean",
10019
- "default": false,
10020
- "example": false
10021
- }
10022
- }
10023
10010
  },
10024
- "responses": {
10025
- "BadRequest": {
10026
- "description": "Invalid request",
10027
- "content": {
10028
- "application/json": {
10011
+ "/v1/agents/{agent_id}/cards/order": {
10012
+ "post": {
10013
+ "tags": [
10014
+ "Payment Cards"
10015
+ ],
10016
+ "summary": "Order a payment card (x402)",
10017
+ "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. When `card_require_approval` is true (default), the order is held in `awaiting_approval` until a human approves via the dashboard, mobile app, or email one-click link; payment runs only after approval.\n",
10018
+ "operationId": "orderCard",
10019
+ "parameters": [
10020
+ {
10021
+ "$ref": "#/components/parameters/AgentId"
10022
+ },
10023
+ {
10024
+ "name": "Idempotency-Key",
10025
+ "in": "header",
10026
+ "required": true,
10029
10027
  "schema": {
10030
- "$ref": "#/components/schemas/ProblemDetails"
10028
+ "type": "string"
10031
10029
  }
10032
10030
  }
10033
- }
10034
- },
10035
- "Unauthorized": {
10036
- "description": "Authentication required or invalid",
10037
- "content": {
10038
- "application/json": {
10039
- "schema": {
10040
- "$ref": "#/components/schemas/ProblemDetails"
10031
+ ],
10032
+ "requestBody": {
10033
+ "required": true,
10034
+ "content": {
10035
+ "application/json": {
10036
+ "schema": {
10037
+ "$ref": "#/components/schemas/OrderCardRequest"
10038
+ }
10041
10039
  }
10042
10040
  }
10043
- }
10044
- },
10045
- "Forbidden": {
10046
- "description": "Insufficient permissions",
10047
- "content": {
10048
- "application/json": {
10049
- "schema": {
10050
- "$ref": "#/components/schemas/ProblemDetails"
10041
+ },
10042
+ "responses": {
10043
+ "200": {
10044
+ "description": "Idempotent replay of a prior order",
10045
+ "content": {
10046
+ "application/json": {
10047
+ "schema": {
10048
+ "$ref": "#/components/schemas/CardResponse"
10049
+ }
10050
+ }
10051
10051
  }
10052
- }
10053
- }
10054
- },
10055
- "NotFound": {
10056
- "description": "Resource not found",
10057
- "content": {
10058
- "application/json": {
10059
- "schema": {
10060
- "$ref": "#/components/schemas/ProblemDetails"
10052
+ },
10053
+ "201": {
10054
+ "description": "Card order accepted and payment submitted (status pending)",
10055
+ "content": {
10056
+ "application/json": {
10057
+ "schema": {
10058
+ "$ref": "#/components/schemas/CardResponse"
10059
+ }
10060
+ }
10061
10061
  }
10062
- }
10063
- }
10064
- },
10065
- "PaymentRequired": {
10066
- "description": "x402 payment required",
10067
- "content": {
10068
- "application/json": {
10069
- "schema": {
10070
- "$ref": "#/components/schemas/PaymentRequirement"
10062
+ },
10063
+ "202": {
10064
+ "description": "Card order queued for human approval (status awaiting_approval)",
10065
+ "content": {
10066
+ "application/json": {
10067
+ "schema": {
10068
+ "$ref": "#/components/schemas/CardResponse"
10069
+ }
10070
+ }
10071
10071
  }
10072
+ },
10073
+ "400": {
10074
+ "$ref": "#/components/responses/BadRequest"
10075
+ },
10076
+ "403": {
10077
+ "$ref": "#/components/responses/Forbidden"
10078
+ },
10079
+ "409": {
10080
+ "$ref": "#/components/responses/Conflict"
10072
10081
  }
10073
10082
  }
10074
- },
10075
- "Conflict": {
10076
- "description": "Resource already exists or conflict",
10077
- "content": {
10078
- "application/json": {
10079
- "schema": {
10080
- "$ref": "#/components/schemas/ProblemDetails"
10083
+ }
10084
+ },
10085
+ "/v1/cards": {
10086
+ "get": {
10087
+ "tags": [
10088
+ "Payment Cards"
10089
+ ],
10090
+ "summary": "List payment cards",
10091
+ "description": "List cards for the caller (agents see only their own). Always masked (last4 only).",
10092
+ "operationId": "listCards",
10093
+ "responses": {
10094
+ "200": {
10095
+ "description": "Card list",
10096
+ "content": {
10097
+ "application/json": {
10098
+ "schema": {
10099
+ "$ref": "#/components/schemas/CardListResponse"
10100
+ }
10101
+ }
10081
10102
  }
10082
10103
  }
10083
10104
  }
10084
10105
  }
10085
10106
  },
10086
- "schemas": {
10087
- "ProblemDetails": {
10088
- "type": "object",
10089
- "description": "RFC 7807 error envelope",
10090
- "properties": {
10091
- "type": {
10092
- "type": "string"
10093
- },
10094
- "title": {
10095
- "type": "string"
10107
+ "/v1/cards/import": {
10108
+ "post": {
10109
+ "tags": [
10110
+ "Payment Cards"
10111
+ ],
10112
+ "summary": "Import a card (human-only)",
10113
+ "description": "Manually import an existing card. Full storage mode — PAN stored encrypted, CVV as a one-time-read secret. Human-only.",
10114
+ "operationId": "importCard",
10115
+ "requestBody": {
10116
+ "required": true,
10117
+ "content": {
10118
+ "application/json": {
10119
+ "schema": {
10120
+ "$ref": "#/components/schemas/ImportCardRequest"
10121
+ }
10122
+ }
10123
+ }
10124
+ },
10125
+ "responses": {
10126
+ "201": {
10127
+ "description": "Card imported",
10128
+ "content": {
10129
+ "application/json": {
10130
+ "schema": {
10131
+ "$ref": "#/components/schemas/CardResponse"
10132
+ }
10133
+ }
10134
+ }
10096
10135
  },
10097
- "status": {
10098
- "type": "integer"
10136
+ "400": {
10137
+ "$ref": "#/components/responses/BadRequest"
10099
10138
  },
10100
- "detail": {
10101
- "type": "string"
10139
+ "403": {
10140
+ "$ref": "#/components/responses/Forbidden"
10102
10141
  }
10103
10142
  }
10104
- },
10105
- "ResetUsageEventsResponse": {
10106
- "type": "object",
10107
- "required": [
10108
- "deleted_events"
10109
- ],
10143
+ }
10144
+ },
10145
+ "/v1/cards/gift-cards/search": {
10146
+ "post": {
10147
+ "tags": [
10148
+ "Payment Cards"
10149
+ ],
10150
+ "summary": "Search gift-card brands",
10151
+ "description": "Search available Laso gift-card brands/servers for the org's Laso account.",
10152
+ "operationId": "searchGiftCards",
10153
+ "requestBody": {
10154
+ "required": false,
10155
+ "content": {
10156
+ "application/json": {
10157
+ "schema": {
10158
+ "$ref": "#/components/schemas/SearchGiftCardsRequest"
10159
+ }
10160
+ }
10161
+ }
10162
+ },
10163
+ "responses": {
10164
+ "200": {
10165
+ "description": "Available gift-card brands (provider-shaped payload)",
10166
+ "content": {
10167
+ "application/json": {
10168
+ "schema": {
10169
+ "type": "object",
10170
+ "additionalProperties": true
10171
+ }
10172
+ }
10173
+ }
10174
+ }
10175
+ }
10176
+ }
10177
+ },
10178
+ "/v1/cards/{card_id}": {
10179
+ "get": {
10180
+ "tags": [
10181
+ "Payment Cards"
10182
+ ],
10183
+ "summary": "Get a payment card",
10184
+ "description": "Get a single card (masked — last4 only).",
10185
+ "operationId": "getCard",
10186
+ "parameters": [
10187
+ {
10188
+ "$ref": "#/components/parameters/CardId"
10189
+ }
10190
+ ],
10191
+ "responses": {
10192
+ "200": {
10193
+ "description": "Card details",
10194
+ "content": {
10195
+ "application/json": {
10196
+ "schema": {
10197
+ "$ref": "#/components/schemas/CardResponse"
10198
+ }
10199
+ }
10200
+ }
10201
+ },
10202
+ "404": {
10203
+ "$ref": "#/components/responses/NotFound"
10204
+ }
10205
+ }
10206
+ },
10207
+ "patch": {
10208
+ "tags": [
10209
+ "Payment Cards"
10210
+ ],
10211
+ "summary": "Update a card's reveal policy (human-only)",
10212
+ "operationId": "updateCard",
10213
+ "parameters": [
10214
+ {
10215
+ "$ref": "#/components/parameters/CardId"
10216
+ }
10217
+ ],
10218
+ "requestBody": {
10219
+ "required": true,
10220
+ "content": {
10221
+ "application/json": {
10222
+ "schema": {
10223
+ "$ref": "#/components/schemas/UpdateCardRequest"
10224
+ }
10225
+ }
10226
+ }
10227
+ },
10228
+ "responses": {
10229
+ "200": {
10230
+ "description": "Card updated",
10231
+ "content": {
10232
+ "application/json": {
10233
+ "schema": {
10234
+ "$ref": "#/components/schemas/CardResponse"
10235
+ }
10236
+ }
10237
+ }
10238
+ },
10239
+ "403": {
10240
+ "$ref": "#/components/responses/Forbidden"
10241
+ },
10242
+ "404": {
10243
+ "$ref": "#/components/responses/NotFound"
10244
+ }
10245
+ }
10246
+ }
10247
+ },
10248
+ "/v1/cards/{card_id}/reveal": {
10249
+ "post": {
10250
+ "tags": [
10251
+ "Payment Cards"
10252
+ ],
10253
+ "summary": "Reveal card details",
10254
+ "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.\n",
10255
+ "operationId": "revealCard",
10256
+ "parameters": [
10257
+ {
10258
+ "$ref": "#/components/parameters/CardId"
10259
+ },
10260
+ {
10261
+ "name": "X-Auth-Confirm",
10262
+ "in": "header",
10263
+ "required": false,
10264
+ "description": "Account password (humans) for re-authentication.",
10265
+ "schema": {
10266
+ "type": "string"
10267
+ }
10268
+ }
10269
+ ],
10270
+ "responses": {
10271
+ "200": {
10272
+ "description": "Revealed card details (sensitive)",
10273
+ "content": {
10274
+ "application/json": {
10275
+ "schema": {
10276
+ "$ref": "#/components/schemas/CardRevealResponse"
10277
+ }
10278
+ }
10279
+ }
10280
+ },
10281
+ "403": {
10282
+ "$ref": "#/components/responses/Forbidden"
10283
+ },
10284
+ "404": {
10285
+ "$ref": "#/components/responses/NotFound"
10286
+ }
10287
+ }
10288
+ }
10289
+ },
10290
+ "/v1/cards/{card_id}/void": {
10291
+ "post": {
10292
+ "tags": [
10293
+ "Payment Cards"
10294
+ ],
10295
+ "summary": "Void a card",
10296
+ "description": "1Claw-level lock that blocks all further reveals/refreshes. Forward-looking only — a card revealed before void remains live.",
10297
+ "operationId": "voidCard",
10298
+ "parameters": [
10299
+ {
10300
+ "$ref": "#/components/parameters/CardId"
10301
+ }
10302
+ ],
10303
+ "responses": {
10304
+ "200": {
10305
+ "description": "Card voided",
10306
+ "content": {
10307
+ "application/json": {
10308
+ "schema": {
10309
+ "$ref": "#/components/schemas/CardResponse"
10310
+ }
10311
+ }
10312
+ }
10313
+ },
10314
+ "404": {
10315
+ "$ref": "#/components/responses/NotFound"
10316
+ }
10317
+ }
10318
+ }
10319
+ },
10320
+ "/v1/cards/{card_id}/refresh": {
10321
+ "post": {
10322
+ "tags": [
10323
+ "Payment Cards"
10324
+ ],
10325
+ "summary": "Refresh a card's balance",
10326
+ "description": "Proxy Laso refresh to update balance/status. Rate-limited to once per 5 minutes per card (429 on exceed).",
10327
+ "operationId": "refreshCard",
10328
+ "parameters": [
10329
+ {
10330
+ "$ref": "#/components/parameters/CardId"
10331
+ }
10332
+ ],
10333
+ "responses": {
10334
+ "200": {
10335
+ "description": "Card refreshed",
10336
+ "content": {
10337
+ "application/json": {
10338
+ "schema": {
10339
+ "$ref": "#/components/schemas/CardResponse"
10340
+ }
10341
+ }
10342
+ }
10343
+ },
10344
+ "404": {
10345
+ "$ref": "#/components/responses/NotFound"
10346
+ },
10347
+ "429": {
10348
+ "description": "Refreshed too recently"
10349
+ }
10350
+ }
10351
+ }
10352
+ }
10353
+ },
10354
+ "components": {
10355
+ "securitySchemes": {
10356
+ "BearerAuth": {
10357
+ "type": "http",
10358
+ "scheme": "bearer",
10359
+ "bearerFormat": "JWT"
10360
+ },
10361
+ "ApiKeyAuth": {
10362
+ "type": "http",
10363
+ "scheme": "bearer",
10364
+ "description": "1ck_ prefixed API key used as Bearer token"
10365
+ }
10366
+ },
10367
+ "parameters": {
10368
+ "VaultId": {
10369
+ "name": "vault_id",
10370
+ "in": "path",
10371
+ "required": true,
10372
+ "schema": {
10373
+ "type": "string",
10374
+ "format": "uuid"
10375
+ }
10376
+ },
10377
+ "SecretPath": {
10378
+ "name": "path",
10379
+ "in": "path",
10380
+ "required": true,
10381
+ "schema": {
10382
+ "type": "string"
10383
+ },
10384
+ "description": "Secret path (e.g. \"db/credentials\")"
10385
+ },
10386
+ "AgentId": {
10387
+ "name": "agent_id",
10388
+ "in": "path",
10389
+ "required": true,
10390
+ "schema": {
10391
+ "type": "string",
10392
+ "format": "uuid"
10393
+ }
10394
+ },
10395
+ "PolicyId": {
10396
+ "name": "policy_id",
10397
+ "in": "path",
10398
+ "required": true,
10399
+ "schema": {
10400
+ "type": "string",
10401
+ "format": "uuid"
10402
+ }
10403
+ },
10404
+ "CardId": {
10405
+ "name": "card_id",
10406
+ "in": "path",
10407
+ "required": true,
10408
+ "schema": {
10409
+ "type": "string",
10410
+ "format": "uuid"
10411
+ }
10412
+ },
10413
+ "IncludeSignedTx": {
10414
+ "name": "include_signed_tx",
10415
+ "in": "query",
10416
+ "required": false,
10417
+ "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}.\n",
10418
+ "schema": {
10419
+ "type": "boolean",
10420
+ "default": false,
10421
+ "example": false
10422
+ }
10423
+ }
10424
+ },
10425
+ "responses": {
10426
+ "BadRequest": {
10427
+ "description": "Invalid request",
10428
+ "content": {
10429
+ "application/json": {
10430
+ "schema": {
10431
+ "$ref": "#/components/schemas/ProblemDetails"
10432
+ }
10433
+ }
10434
+ }
10435
+ },
10436
+ "Unauthorized": {
10437
+ "description": "Authentication required or invalid",
10438
+ "content": {
10439
+ "application/json": {
10440
+ "schema": {
10441
+ "$ref": "#/components/schemas/ProblemDetails"
10442
+ }
10443
+ }
10444
+ }
10445
+ },
10446
+ "Forbidden": {
10447
+ "description": "Insufficient permissions",
10448
+ "content": {
10449
+ "application/json": {
10450
+ "schema": {
10451
+ "$ref": "#/components/schemas/ProblemDetails"
10452
+ }
10453
+ }
10454
+ }
10455
+ },
10456
+ "NotFound": {
10457
+ "description": "Resource not found",
10458
+ "content": {
10459
+ "application/json": {
10460
+ "schema": {
10461
+ "$ref": "#/components/schemas/ProblemDetails"
10462
+ }
10463
+ }
10464
+ }
10465
+ },
10466
+ "PaymentRequired": {
10467
+ "description": "x402 payment required",
10468
+ "content": {
10469
+ "application/json": {
10470
+ "schema": {
10471
+ "$ref": "#/components/schemas/PaymentRequirement"
10472
+ }
10473
+ }
10474
+ }
10475
+ },
10476
+ "Conflict": {
10477
+ "description": "Resource already exists or conflict",
10478
+ "content": {
10479
+ "application/json": {
10480
+ "schema": {
10481
+ "$ref": "#/components/schemas/ProblemDetails"
10482
+ }
10483
+ }
10484
+ }
10485
+ }
10486
+ },
10487
+ "schemas": {
10488
+ "OrderCardRequest": {
10489
+ "type": "object",
10490
+ "required": [
10491
+ "kind",
10492
+ "amount_usd"
10493
+ ],
10494
+ "properties": {
10495
+ "kind": {
10496
+ "type": "string",
10497
+ "enum": [
10498
+ "prepaid",
10499
+ "gift_card"
10500
+ ]
10501
+ },
10502
+ "amount_usd": {
10503
+ "type": "string",
10504
+ "description": "USD amount to load onto the card.",
10505
+ "example": "25.00"
10506
+ },
10507
+ "laso_server_id": {
10508
+ "type": "string",
10509
+ "description": "Optional Laso gift-card server/brand id (gift cards only)."
10510
+ },
10511
+ "country": {
10512
+ "type": "string",
10513
+ "description": "Optional country (prepaid cards; defaults to US)."
10514
+ }
10515
+ }
10516
+ },
10517
+ "CardResponse": {
10518
+ "type": "object",
10519
+ "description": "Masked card view — never contains PAN/CVV.",
10520
+ "required": [
10521
+ "id",
10522
+ "issuer",
10523
+ "kind",
10524
+ "currency",
10525
+ "status",
10526
+ "storage_mode",
10527
+ "reveal_policy",
10528
+ "created_at",
10529
+ "updated_at"
10530
+ ],
10531
+ "properties": {
10532
+ "id": {
10533
+ "type": "string",
10534
+ "format": "uuid"
10535
+ },
10536
+ "agent_id": {
10537
+ "type": "string",
10538
+ "format": "uuid",
10539
+ "nullable": true
10540
+ },
10541
+ "issuer": {
10542
+ "type": "string",
10543
+ "enum": [
10544
+ "laso",
10545
+ "manual"
10546
+ ]
10547
+ },
10548
+ "kind": {
10549
+ "type": "string",
10550
+ "enum": [
10551
+ "prepaid",
10552
+ "gift_card"
10553
+ ]
10554
+ },
10555
+ "brand": {
10556
+ "type": "string"
10557
+ },
10558
+ "last4": {
10559
+ "type": "string"
10560
+ },
10561
+ "exp_month": {
10562
+ "type": "integer"
10563
+ },
10564
+ "exp_year": {
10565
+ "type": "integer"
10566
+ },
10567
+ "currency": {
10568
+ "type": "string"
10569
+ },
10570
+ "order_amount_usd": {
10571
+ "type": "string"
10572
+ },
10573
+ "balance": {
10574
+ "type": "string"
10575
+ },
10576
+ "status": {
10577
+ "type": "string",
10578
+ "enum": [
10579
+ "ordering",
10580
+ "pending",
10581
+ "ready",
10582
+ "depleted",
10583
+ "expired",
10584
+ "voided",
10585
+ "orphaned_payment",
10586
+ "awaiting_approval",
10587
+ "rejected"
10588
+ ]
10589
+ },
10590
+ "storage_mode": {
10591
+ "type": "string",
10592
+ "enum": [
10593
+ "reference",
10594
+ "full"
10595
+ ]
10596
+ },
10597
+ "reveal_policy": {
10598
+ "type": "object",
10599
+ "additionalProperties": true
10600
+ },
10601
+ "approval_id": {
10602
+ "type": "string",
10603
+ "format": "uuid",
10604
+ "description": "Linked approval when status is awaiting_approval"
10605
+ },
10606
+ "void_after": {
10607
+ "type": "string",
10608
+ "format": "date-time"
10609
+ },
10610
+ "created_at": {
10611
+ "type": "string",
10612
+ "format": "date-time"
10613
+ },
10614
+ "updated_at": {
10615
+ "type": "string",
10616
+ "format": "date-time"
10617
+ }
10618
+ }
10619
+ },
10620
+ "CardListResponse": {
10621
+ "type": "object",
10622
+ "required": [
10623
+ "cards"
10624
+ ],
10625
+ "properties": {
10626
+ "cards": {
10627
+ "type": "array",
10628
+ "items": {
10629
+ "$ref": "#/components/schemas/CardResponse"
10630
+ }
10631
+ }
10632
+ }
10633
+ },
10634
+ "CardRevealResponse": {
10635
+ "type": "object",
10636
+ "description": "Revealed card details — sensitive. Returned only by the reveal endpoint.",
10637
+ "required": [
10638
+ "id",
10639
+ "disclaimer"
10640
+ ],
10641
+ "properties": {
10642
+ "id": {
10643
+ "type": "string",
10644
+ "format": "uuid"
10645
+ },
10646
+ "pan": {
10647
+ "type": "string"
10648
+ },
10649
+ "cvv": {
10650
+ "type": "string"
10651
+ },
10652
+ "exp_month": {
10653
+ "type": "integer"
10654
+ },
10655
+ "exp_year": {
10656
+ "type": "integer"
10657
+ },
10658
+ "brand": {
10659
+ "type": "string"
10660
+ },
10661
+ "redemption": {
10662
+ "type": "object",
10663
+ "additionalProperties": true,
10664
+ "description": "Gift-card redemption payload (URL/code/PIN) when applicable."
10665
+ },
10666
+ "disclaimer": {
10667
+ "type": "string"
10668
+ }
10669
+ }
10670
+ },
10671
+ "UpdateCardRequest": {
10672
+ "type": "object",
10673
+ "description": "Human-settable per-card reveal policy + lifecycle controls.",
10674
+ "properties": {
10675
+ "agent_reveal": {
10676
+ "type": "boolean"
10677
+ },
10678
+ "max_reveals": {
10679
+ "type": "integer"
10680
+ },
10681
+ "reveal_expires_at": {
10682
+ "type": "string",
10683
+ "format": "date-time",
10684
+ "nullable": true
10685
+ },
10686
+ "void_after": {
10687
+ "type": "string",
10688
+ "format": "date-time",
10689
+ "nullable": true
10690
+ }
10691
+ }
10692
+ },
10693
+ "ImportCardRequest": {
10694
+ "type": "object",
10695
+ "required": [
10696
+ "pan",
10697
+ "cvv",
10698
+ "exp_month",
10699
+ "exp_year"
10700
+ ],
10701
+ "properties": {
10702
+ "pan": {
10703
+ "type": "string"
10704
+ },
10705
+ "cvv": {
10706
+ "type": "string"
10707
+ },
10708
+ "exp_month": {
10709
+ "type": "integer"
10710
+ },
10711
+ "exp_year": {
10712
+ "type": "integer"
10713
+ },
10714
+ "brand": {
10715
+ "type": "string"
10716
+ },
10717
+ "currency": {
10718
+ "type": "string"
10719
+ },
10720
+ "balance": {
10721
+ "type": "string"
10722
+ },
10723
+ "agent_id": {
10724
+ "type": "string",
10725
+ "format": "uuid"
10726
+ }
10727
+ }
10728
+ },
10729
+ "SearchGiftCardsRequest": {
10730
+ "type": "object",
10731
+ "properties": {
10732
+ "query": {
10733
+ "type": "string"
10734
+ },
10735
+ "country": {
10736
+ "type": "string"
10737
+ }
10738
+ }
10739
+ },
10740
+ "ProblemDetails": {
10741
+ "type": "object",
10742
+ "description": "RFC 7807 error envelope",
10743
+ "properties": {
10744
+ "type": {
10745
+ "type": "string"
10746
+ },
10747
+ "title": {
10748
+ "type": "string"
10749
+ },
10750
+ "status": {
10751
+ "type": "integer"
10752
+ },
10753
+ "detail": {
10754
+ "type": "string"
10755
+ }
10756
+ }
10757
+ },
10758
+ "ResetUsageEventsResponse": {
10759
+ "type": "object",
10760
+ "required": [
10761
+ "deleted_events"
10762
+ ],
10110
10763
  "properties": {
10111
10764
  "deleted_events": {
10112
10765
  "type": "integer",
@@ -11427,6 +12080,34 @@
11427
12080
  },
11428
12081
  "description": "Solana wallet addresses whose ATAs may be created. Empty = unrestricted."
11429
12082
  },
12083
+ "cards_enabled": {
12084
+ "type": "boolean",
12085
+ "description": "Whether this agent may order payment cards (x402 card ordering). Pro+ tier."
12086
+ },
12087
+ "card_max_order_usd": {
12088
+ "type": "string",
12089
+ "description": "Maximum USD amount for a single card order."
12090
+ },
12091
+ "card_daily_limit_usd": {
12092
+ "type": "string",
12093
+ "description": "Maximum cumulative USD spent ordering cards per rolling 24h window."
12094
+ },
12095
+ "card_payto_allowlist": {
12096
+ "type": "array",
12097
+ "items": {
12098
+ "type": "string"
12099
+ },
12100
+ "description": "Allowed x402 payTo recipients for card orders (empty = built-in Laso recipients)."
12101
+ },
12102
+ "card_reveal_enabled": {
12103
+ "type": "boolean",
12104
+ "description": "Whether agents may reveal card details subject to per-card reveal policy."
12105
+ },
12106
+ "card_require_approval": {
12107
+ "type": "boolean",
12108
+ "default": true,
12109
+ "description": "When true, card orders route through the human approval queue before x402 payment."
12110
+ },
11430
12111
  "api_key_expires_at": {
11431
12112
  "type": "string",
11432
12113
  "format": "date-time",
@@ -11542,6 +12223,35 @@
11542
12223
  },
11543
12224
  "description": "Solana wallet addresses whose ATAs may be created."
11544
12225
  },
12226
+ "cards_enabled": {
12227
+ "type": "boolean",
12228
+ "description": "Whether this agent may order payment cards (x402 card ordering). Pro+ tier."
12229
+ },
12230
+ "card_max_order_usd": {
12231
+ "type": "string",
12232
+ "nullable": true,
12233
+ "description": "Maximum USD amount for a single card order. null clears."
12234
+ },
12235
+ "card_daily_limit_usd": {
12236
+ "type": "string",
12237
+ "nullable": true,
12238
+ "description": "Maximum cumulative USD spent ordering cards per rolling 24h window. null clears."
12239
+ },
12240
+ "card_payto_allowlist": {
12241
+ "type": "array",
12242
+ "items": {
12243
+ "type": "string"
12244
+ },
12245
+ "description": "Allowed x402 payTo recipients for card orders (empty = built-in Laso recipients)."
12246
+ },
12247
+ "card_reveal_enabled": {
12248
+ "type": "boolean",
12249
+ "description": "Whether agents may reveal card details subject to per-card reveal policy."
12250
+ },
12251
+ "card_require_approval": {
12252
+ "type": "boolean",
12253
+ "description": "When true, card orders route through the human approval queue before x402 payment."
12254
+ },
11545
12255
  "federation_enabled": {
11546
12256
  "type": "boolean",
11547
12257
  "description": "Enable OIDC federation (RFC 8693 token-exchange) for this agent.\nWhen true, the agent may call POST /v1/auth/federated-token to mint\nfederation tokens for the audiences listed in `federation_audiences`.\n"
@@ -11749,6 +12459,33 @@
11749
12459
  },
11750
12460
  "description": "Solana wallet addresses whose ATAs may be created."
11751
12461
  },
12462
+ "cards_enabled": {
12463
+ "type": "boolean",
12464
+ "description": "Whether this agent may order payment cards (x402 card ordering)."
12465
+ },
12466
+ "card_max_order_usd": {
12467
+ "type": "string",
12468
+ "description": "Maximum USD amount for a single card order."
12469
+ },
12470
+ "card_daily_limit_usd": {
12471
+ "type": "string",
12472
+ "description": "Maximum cumulative USD spent ordering cards per rolling 24h window."
12473
+ },
12474
+ "card_payto_allowlist": {
12475
+ "type": "array",
12476
+ "items": {
12477
+ "type": "string"
12478
+ },
12479
+ "description": "Allowed x402 payTo recipients for card orders (empty = built-in Laso recipients)."
12480
+ },
12481
+ "card_reveal_enabled": {
12482
+ "type": "boolean",
12483
+ "description": "Whether agents may reveal card details subject to per-card reveal policy."
12484
+ },
12485
+ "card_require_approval": {
12486
+ "type": "boolean",
12487
+ "description": "When true, card orders route through the human approval queue before x402 payment."
12488
+ },
11752
12489
  "tx_count_today": {
11753
12490
  "type": "integer",
11754
12491
  "description": "Today's transaction count (UTC calendar day). Present when intents_api_enabled."