@1claw/openapi-spec 0.57.0 → 0.58.2

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 (4) hide show
  1. package/README.md +22 -2
  2. package/openapi.json +1066 -25
  3. package/openapi.yaml +730 -58
  4. package/package.json +1 -1
package/openapi.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "openapi": "3.1.0",
3
3
  "info": {
4
4
  "title": "1Claw API",
5
- "version": "0.57.0",
5
+ "version": "0.58.0",
6
6
  "description": "Secure secret management for AI agents. Provides vaults, secrets,\npolicy-based access control, agent identity, Intents API,\nsharing, billing, and audit logging. Automations (workflow_spec,\nwebhook tokens, event triggers, Assist), cloud runtimes with\ninteractive shell sessions, agent memory, and discovery.\n\nAll endpoints require JWT Bearer authentication unless marked with\n`security: []`.\n",
7
7
  "contact": {
8
8
  "email": "ops@1claw.xyz"
@@ -9648,8 +9648,15 @@
9648
9648
  }
9649
9649
  ],
9650
9650
  "responses": {
9651
- "204": {
9652
- "description": "Deleted"
9651
+ "200": {
9652
+ "description": "Soft-deleted; slug released for reuse within the org",
9653
+ "content": {
9654
+ "application/json": {
9655
+ "schema": {
9656
+ "$ref": "#/components/schemas/PlatformAppDeleteResponse"
9657
+ }
9658
+ }
9659
+ }
9653
9660
  },
9654
9661
  "403": {
9655
9662
  "description": "Only human users can delete platform apps"
@@ -9657,6 +9664,71 @@
9657
9664
  }
9658
9665
  }
9659
9666
  },
9667
+ "/v1/platform/apps/{appId}/transfer-ownership": {
9668
+ "post": {
9669
+ "tags": [
9670
+ "Platform"
9671
+ ],
9672
+ "summary": "Transfer platform app to another organization",
9673
+ "description": "Moves the platform app record to another organization. Requires org\nowner/admin in the source org and step-up auth (`X-Auth-Confirm`,\npurpose `platform.app.transfer`). End-user connections and provisioned\nresources remain in their original organizations.\n",
9674
+ "operationId": "transferPlatformAppOwnership",
9675
+ "security": [
9676
+ {
9677
+ "BearerAuth": []
9678
+ }
9679
+ ],
9680
+ "parameters": [
9681
+ {
9682
+ "in": "path",
9683
+ "name": "appId",
9684
+ "required": true,
9685
+ "schema": {
9686
+ "type": "string",
9687
+ "format": "uuid"
9688
+ }
9689
+ },
9690
+ {
9691
+ "in": "header",
9692
+ "name": "X-Auth-Confirm",
9693
+ "required": true,
9694
+ "schema": {
9695
+ "type": "string"
9696
+ }
9697
+ }
9698
+ ],
9699
+ "requestBody": {
9700
+ "required": true,
9701
+ "content": {
9702
+ "application/json": {
9703
+ "schema": {
9704
+ "$ref": "#/components/schemas/TransferPlatformAppOwnershipRequest"
9705
+ }
9706
+ }
9707
+ }
9708
+ },
9709
+ "responses": {
9710
+ "200": {
9711
+ "description": "Ownership transferred",
9712
+ "content": {
9713
+ "application/json": {
9714
+ "schema": {
9715
+ "$ref": "#/components/schemas/TransferPlatformAppOwnershipResponse"
9716
+ }
9717
+ }
9718
+ }
9719
+ },
9720
+ "400": {
9721
+ "$ref": "#/components/responses/BadRequest"
9722
+ },
9723
+ "403": {
9724
+ "$ref": "#/components/responses/Forbidden"
9725
+ },
9726
+ "404": {
9727
+ "$ref": "#/components/responses/NotFound"
9728
+ }
9729
+ }
9730
+ }
9731
+ },
9660
9732
  "/v1/platform/apps/{appId}/rotate-key": {
9661
9733
  "post": {
9662
9734
  "tags": [
@@ -9913,6 +9985,54 @@
9913
9985
  }
9914
9986
  },
9915
9987
  "/v1/platform/apps/{appId}/templates/{template_id}": {
9988
+ "get": {
9989
+ "tags": [
9990
+ "Platform"
9991
+ ],
9992
+ "summary": "Get a bootstrap template",
9993
+ "description": "Returns the full template spec for a platform app. plt_ or user JWT.",
9994
+ "operationId": "getPlatformTemplate",
9995
+ "security": [
9996
+ {
9997
+ "BearerAuth": []
9998
+ }
9999
+ ],
10000
+ "parameters": [
10001
+ {
10002
+ "in": "path",
10003
+ "name": "appId",
10004
+ "required": true,
10005
+ "schema": {
10006
+ "type": "string",
10007
+ "format": "uuid"
10008
+ }
10009
+ },
10010
+ {
10011
+ "in": "path",
10012
+ "name": "template_id",
10013
+ "required": true,
10014
+ "schema": {
10015
+ "type": "string",
10016
+ "format": "uuid"
10017
+ }
10018
+ }
10019
+ ],
10020
+ "responses": {
10021
+ "200": {
10022
+ "description": "Template details",
10023
+ "content": {
10024
+ "application/json": {
10025
+ "schema": {
10026
+ "$ref": "#/components/schemas/PlatformTemplateResponse"
10027
+ }
10028
+ }
10029
+ }
10030
+ },
10031
+ "404": {
10032
+ "$ref": "#/components/responses/NotFound"
10033
+ }
10034
+ }
10035
+ },
9916
10036
  "patch": {
9917
10037
  "tags": [
9918
10038
  "Platform"
@@ -11085,6 +11205,53 @@
11085
11205
  }
11086
11206
  },
11087
11207
  "/v1/platform/apps/{appId}/spend-policies/{policyId}": {
11208
+ "get": {
11209
+ "tags": [
11210
+ "Platform"
11211
+ ],
11212
+ "summary": "Get a spend policy by ID",
11213
+ "operationId": "getSpendPolicy",
11214
+ "security": [
11215
+ {
11216
+ "BearerAuth": []
11217
+ }
11218
+ ],
11219
+ "parameters": [
11220
+ {
11221
+ "in": "path",
11222
+ "name": "appId",
11223
+ "required": true,
11224
+ "schema": {
11225
+ "type": "string",
11226
+ "format": "uuid"
11227
+ }
11228
+ },
11229
+ {
11230
+ "in": "path",
11231
+ "name": "policyId",
11232
+ "required": true,
11233
+ "schema": {
11234
+ "type": "string",
11235
+ "format": "uuid"
11236
+ }
11237
+ }
11238
+ ],
11239
+ "responses": {
11240
+ "200": {
11241
+ "description": "Spend policy",
11242
+ "content": {
11243
+ "application/json": {
11244
+ "schema": {
11245
+ "$ref": "#/components/schemas/SpendPolicyResponse"
11246
+ }
11247
+ }
11248
+ }
11249
+ },
11250
+ "404": {
11251
+ "$ref": "#/components/responses/NotFound"
11252
+ }
11253
+ }
11254
+ },
11088
11255
  "delete": {
11089
11256
  "tags": [
11090
11257
  "Platform"
@@ -11108,7 +11275,615 @@
11108
11275
  },
11109
11276
  {
11110
11277
  "in": "path",
11111
- "name": "policyId",
11278
+ "name": "policyId",
11279
+ "required": true,
11280
+ "schema": {
11281
+ "type": "string",
11282
+ "format": "uuid"
11283
+ }
11284
+ }
11285
+ ],
11286
+ "responses": {
11287
+ "204": {
11288
+ "description": "Deleted"
11289
+ },
11290
+ "404": {
11291
+ "$ref": "#/components/responses/NotFound"
11292
+ }
11293
+ }
11294
+ }
11295
+ },
11296
+ "/v1/platform/connections/{connectionId}/spend-policy": {
11297
+ "get": {
11298
+ "tags": [
11299
+ "Platform"
11300
+ ],
11301
+ "summary": "Get effective spend policy for a connection",
11302
+ "description": "Returns the effective spend policy for the connected user, resolving\nper-user overrides before app-level defaults. Requires plt_ platform auth.\n",
11303
+ "operationId": "getConnectionSpendPolicy",
11304
+ "security": [
11305
+ {
11306
+ "BearerAuth": []
11307
+ }
11308
+ ],
11309
+ "parameters": [
11310
+ {
11311
+ "in": "path",
11312
+ "name": "connectionId",
11313
+ "required": true,
11314
+ "schema": {
11315
+ "type": "string",
11316
+ "format": "uuid"
11317
+ }
11318
+ }
11319
+ ],
11320
+ "responses": {
11321
+ "200": {
11322
+ "description": "Effective spend policy (or null)",
11323
+ "content": {
11324
+ "application/json": {
11325
+ "schema": {
11326
+ "type": "object",
11327
+ "properties": {
11328
+ "policy": {
11329
+ "oneOf": [
11330
+ {
11331
+ "$ref": "#/components/schemas/SpendPolicyResponse"
11332
+ },
11333
+ {
11334
+ "type": "null"
11335
+ }
11336
+ ]
11337
+ }
11338
+ }
11339
+ }
11340
+ }
11341
+ }
11342
+ },
11343
+ "404": {
11344
+ "$ref": "#/components/responses/NotFound"
11345
+ }
11346
+ }
11347
+ },
11348
+ "put": {
11349
+ "tags": [
11350
+ "Platform"
11351
+ ],
11352
+ "summary": "Set per-user spend policy override",
11353
+ "description": "Replace the per-user spend policy for a connected user (deactivates the\nprevious active row, then inserts). Requires plt_ platform auth.\nOptional `Idempotency-Key` header must cover the full request body — reusing\nthe same key with different parameters returns 409.\n",
11354
+ "operationId": "setUserSpendPolicy",
11355
+ "security": [
11356
+ {
11357
+ "BearerAuth": []
11358
+ }
11359
+ ],
11360
+ "parameters": [
11361
+ {
11362
+ "in": "path",
11363
+ "name": "connectionId",
11364
+ "required": true,
11365
+ "schema": {
11366
+ "type": "string",
11367
+ "format": "uuid"
11368
+ }
11369
+ },
11370
+ {
11371
+ "in": "header",
11372
+ "name": "Idempotency-Key",
11373
+ "required": false,
11374
+ "schema": {
11375
+ "type": "string"
11376
+ },
11377
+ "description": "Optional replay protection; same key + body returns cached response (409 on body mismatch)."
11378
+ }
11379
+ ],
11380
+ "requestBody": {
11381
+ "required": true,
11382
+ "content": {
11383
+ "application/json": {
11384
+ "schema": {
11385
+ "$ref": "#/components/schemas/CreateSpendPolicyRequest"
11386
+ }
11387
+ }
11388
+ }
11389
+ },
11390
+ "responses": {
11391
+ "200": {
11392
+ "description": "Spend policy set (or idempotent replay)",
11393
+ "content": {
11394
+ "application/json": {
11395
+ "schema": {
11396
+ "$ref": "#/components/schemas/SpendPolicyResponse"
11397
+ }
11398
+ }
11399
+ }
11400
+ },
11401
+ "201": {
11402
+ "description": "Spend policy created",
11403
+ "content": {
11404
+ "application/json": {
11405
+ "schema": {
11406
+ "$ref": "#/components/schemas/SpendPolicyResponse"
11407
+ }
11408
+ }
11409
+ }
11410
+ },
11411
+ "400": {
11412
+ "$ref": "#/components/responses/BadRequest"
11413
+ },
11414
+ "403": {
11415
+ "$ref": "#/components/responses/Forbidden"
11416
+ },
11417
+ "404": {
11418
+ "$ref": "#/components/responses/NotFound"
11419
+ },
11420
+ "409": {
11421
+ "description": "Idempotency-Key reused with different body"
11422
+ }
11423
+ }
11424
+ }
11425
+ },
11426
+ "/v1/platform/connections/{connectionId}/approvals": {
11427
+ "get": {
11428
+ "tags": [
11429
+ "Platform"
11430
+ ],
11431
+ "summary": "List approvals for a platform connection",
11432
+ "description": "Returns approvals assigned to the connection's user, filtered to agents\nprovisioned on the connection. Requires plt_ platform auth.\n",
11433
+ "operationId": "listConnectionApprovals",
11434
+ "security": [
11435
+ {
11436
+ "BearerAuth": []
11437
+ }
11438
+ ],
11439
+ "parameters": [
11440
+ {
11441
+ "in": "path",
11442
+ "name": "connectionId",
11443
+ "required": true,
11444
+ "schema": {
11445
+ "type": "string",
11446
+ "format": "uuid"
11447
+ }
11448
+ },
11449
+ {
11450
+ "name": "status",
11451
+ "in": "query",
11452
+ "required": false,
11453
+ "schema": {
11454
+ "type": "string"
11455
+ }
11456
+ },
11457
+ {
11458
+ "name": "risk_tier",
11459
+ "in": "query",
11460
+ "required": false,
11461
+ "schema": {
11462
+ "type": "integer"
11463
+ }
11464
+ },
11465
+ {
11466
+ "name": "limit",
11467
+ "in": "query",
11468
+ "required": false,
11469
+ "schema": {
11470
+ "type": "integer",
11471
+ "default": 50
11472
+ }
11473
+ },
11474
+ {
11475
+ "name": "offset",
11476
+ "in": "query",
11477
+ "required": false,
11478
+ "schema": {
11479
+ "type": "integer",
11480
+ "default": 0
11481
+ }
11482
+ }
11483
+ ],
11484
+ "responses": {
11485
+ "200": {
11486
+ "description": "Connection-scoped approvals",
11487
+ "content": {
11488
+ "application/json": {
11489
+ "schema": {
11490
+ "$ref": "#/components/schemas/ApprovalListResponse"
11491
+ }
11492
+ }
11493
+ }
11494
+ },
11495
+ "404": {
11496
+ "$ref": "#/components/responses/NotFound"
11497
+ }
11498
+ }
11499
+ }
11500
+ },
11501
+ "/v1/platform/connections/{connectionId}/approvals/{approvalId}": {
11502
+ "get": {
11503
+ "tags": [
11504
+ "Platform"
11505
+ ],
11506
+ "summary": "Get a connection-scoped approval",
11507
+ "operationId": "getConnectionApproval",
11508
+ "security": [
11509
+ {
11510
+ "BearerAuth": []
11511
+ }
11512
+ ],
11513
+ "parameters": [
11514
+ {
11515
+ "in": "path",
11516
+ "name": "connectionId",
11517
+ "required": true,
11518
+ "schema": {
11519
+ "type": "string",
11520
+ "format": "uuid"
11521
+ }
11522
+ },
11523
+ {
11524
+ "in": "path",
11525
+ "name": "approvalId",
11526
+ "required": true,
11527
+ "schema": {
11528
+ "type": "string",
11529
+ "format": "uuid"
11530
+ }
11531
+ }
11532
+ ],
11533
+ "responses": {
11534
+ "200": {
11535
+ "description": "Approval detail",
11536
+ "content": {
11537
+ "application/json": {
11538
+ "schema": {
11539
+ "$ref": "#/components/schemas/ApprovalResponse"
11540
+ }
11541
+ }
11542
+ }
11543
+ },
11544
+ "404": {
11545
+ "$ref": "#/components/responses/NotFound"
11546
+ }
11547
+ }
11548
+ }
11549
+ },
11550
+ "/v1/platform/connections/{connectionId}/pending-approvals": {
11551
+ "get": {
11552
+ "tags": [
11553
+ "Platform"
11554
+ ],
11555
+ "summary": "List pending consensus approvals for a connection",
11556
+ "description": "Returns pending approvals for agents provisioned on the connection,\nincluding `action_payload` and `payload_hash` for consensus UX.\nRequires plt_ platform auth.\n",
11557
+ "operationId": "listConnectionPendingApprovals",
11558
+ "security": [
11559
+ {
11560
+ "BearerAuth": []
11561
+ }
11562
+ ],
11563
+ "parameters": [
11564
+ {
11565
+ "in": "path",
11566
+ "name": "connectionId",
11567
+ "required": true,
11568
+ "schema": {
11569
+ "type": "string",
11570
+ "format": "uuid"
11571
+ }
11572
+ },
11573
+ {
11574
+ "name": "status",
11575
+ "in": "query",
11576
+ "schema": {
11577
+ "type": "string",
11578
+ "default": "pending"
11579
+ }
11580
+ },
11581
+ {
11582
+ "name": "limit",
11583
+ "in": "query",
11584
+ "schema": {
11585
+ "type": "integer",
11586
+ "default": 50
11587
+ }
11588
+ },
11589
+ {
11590
+ "name": "offset",
11591
+ "in": "query",
11592
+ "schema": {
11593
+ "type": "integer",
11594
+ "default": 0
11595
+ }
11596
+ }
11597
+ ],
11598
+ "responses": {
11599
+ "200": {
11600
+ "description": "Pending approvals list",
11601
+ "content": {
11602
+ "application/json": {
11603
+ "schema": {
11604
+ "$ref": "#/components/schemas/PendingApprovalListResponse"
11605
+ }
11606
+ }
11607
+ }
11608
+ },
11609
+ "404": {
11610
+ "$ref": "#/components/responses/NotFound"
11611
+ }
11612
+ }
11613
+ }
11614
+ },
11615
+ "/v1/platform/connections/{connectionId}/pending-approvals/{approvalId}": {
11616
+ "get": {
11617
+ "tags": [
11618
+ "Platform"
11619
+ ],
11620
+ "summary": "Get a connection-scoped pending approval (with payload_hash)",
11621
+ "operationId": "getConnectionPendingApproval",
11622
+ "security": [
11623
+ {
11624
+ "BearerAuth": []
11625
+ }
11626
+ ],
11627
+ "parameters": [
11628
+ {
11629
+ "in": "path",
11630
+ "name": "connectionId",
11631
+ "required": true,
11632
+ "schema": {
11633
+ "type": "string",
11634
+ "format": "uuid"
11635
+ }
11636
+ },
11637
+ {
11638
+ "in": "path",
11639
+ "name": "approvalId",
11640
+ "required": true,
11641
+ "schema": {
11642
+ "type": "string",
11643
+ "format": "uuid"
11644
+ }
11645
+ }
11646
+ ],
11647
+ "responses": {
11648
+ "200": {
11649
+ "description": "Pending approval detail including action_payload and payload_hash",
11650
+ "content": {
11651
+ "application/json": {
11652
+ "schema": {
11653
+ "$ref": "#/components/schemas/PendingApprovalResponse"
11654
+ }
11655
+ }
11656
+ }
11657
+ },
11658
+ "404": {
11659
+ "$ref": "#/components/responses/NotFound"
11660
+ }
11661
+ }
11662
+ }
11663
+ },
11664
+ "/v1/platform/connections/{connectionId}/pending-approvals/{approvalId}/decide": {
11665
+ "post": {
11666
+ "tags": [
11667
+ "Platform"
11668
+ ],
11669
+ "summary": "Decide a pending approval for a connection user",
11670
+ "description": "Platform apps vote on behalf of the connected user after verifying intent\nout-of-band (e.g. wallet mandate). Requires `payload_hash` matching the\npending row. Accepts `decision`: `approve` or `reject` (aliases `approved` /\n`rejected`). plt_ auth only; scoped to agents on the connection.\n",
11671
+ "operationId": "decideConnectionPendingApproval",
11672
+ "security": [
11673
+ {
11674
+ "BearerAuth": []
11675
+ }
11676
+ ],
11677
+ "parameters": [
11678
+ {
11679
+ "in": "path",
11680
+ "name": "connectionId",
11681
+ "required": true,
11682
+ "schema": {
11683
+ "type": "string",
11684
+ "format": "uuid"
11685
+ }
11686
+ },
11687
+ {
11688
+ "in": "path",
11689
+ "name": "approvalId",
11690
+ "required": true,
11691
+ "schema": {
11692
+ "type": "string",
11693
+ "format": "uuid"
11694
+ }
11695
+ }
11696
+ ],
11697
+ "requestBody": {
11698
+ "required": true,
11699
+ "content": {
11700
+ "application/json": {
11701
+ "schema": {
11702
+ "$ref": "#/components/schemas/ApprovePendingApprovalRequest"
11703
+ }
11704
+ }
11705
+ }
11706
+ },
11707
+ "responses": {
11708
+ "200": {
11709
+ "description": "Updated pending approval",
11710
+ "content": {
11711
+ "application/json": {
11712
+ "schema": {
11713
+ "$ref": "#/components/schemas/PendingApprovalResponse"
11714
+ }
11715
+ }
11716
+ }
11717
+ },
11718
+ "400": {
11719
+ "$ref": "#/components/responses/BadRequest"
11720
+ },
11721
+ "403": {
11722
+ "$ref": "#/components/responses/Forbidden"
11723
+ },
11724
+ "404": {
11725
+ "$ref": "#/components/responses/NotFound"
11726
+ },
11727
+ "409": {
11728
+ "description": "Already voted"
11729
+ }
11730
+ }
11731
+ }
11732
+ },
11733
+ "/v1/platform/connections/{connectionId}/approvals/{approvalId}/decide": {
11734
+ "post": {
11735
+ "tags": [
11736
+ "Platform"
11737
+ ],
11738
+ "summary": "Decide a mobile/agent approval for a connection user",
11739
+ "description": "Platform apps decide agent approval requests on behalf of the connected user.\nAccepts `decision`: `approved` or `rejected` (aliases `approve` / `reject`).\nplt_ auth only.\n",
11740
+ "operationId": "decideConnectionApproval",
11741
+ "security": [
11742
+ {
11743
+ "BearerAuth": []
11744
+ }
11745
+ ],
11746
+ "parameters": [
11747
+ {
11748
+ "in": "path",
11749
+ "name": "connectionId",
11750
+ "required": true,
11751
+ "schema": {
11752
+ "type": "string",
11753
+ "format": "uuid"
11754
+ }
11755
+ },
11756
+ {
11757
+ "in": "path",
11758
+ "name": "approvalId",
11759
+ "required": true,
11760
+ "schema": {
11761
+ "type": "string",
11762
+ "format": "uuid"
11763
+ }
11764
+ }
11765
+ ],
11766
+ "requestBody": {
11767
+ "required": true,
11768
+ "content": {
11769
+ "application/json": {
11770
+ "schema": {
11771
+ "type": "object",
11772
+ "required": [
11773
+ "decision"
11774
+ ],
11775
+ "properties": {
11776
+ "decision": {
11777
+ "type": "string",
11778
+ "enum": [
11779
+ "approved",
11780
+ "rejected",
11781
+ "approve",
11782
+ "reject"
11783
+ ]
11784
+ },
11785
+ "reason": {
11786
+ "type": "string"
11787
+ }
11788
+ }
11789
+ }
11790
+ }
11791
+ }
11792
+ },
11793
+ "responses": {
11794
+ "200": {
11795
+ "description": "Decided approval",
11796
+ "content": {
11797
+ "application/json": {
11798
+ "schema": {
11799
+ "$ref": "#/components/schemas/ApprovalResponse"
11800
+ }
11801
+ }
11802
+ }
11803
+ },
11804
+ "403": {
11805
+ "$ref": "#/components/responses/Forbidden"
11806
+ },
11807
+ "404": {
11808
+ "$ref": "#/components/responses/NotFound"
11809
+ },
11810
+ "409": {
11811
+ "description": "Already decided"
11812
+ }
11813
+ }
11814
+ }
11815
+ },
11816
+ "/v1/platform/connections/{connectionId}/signing-keys/{chain}": {
11817
+ "delete": {
11818
+ "tags": [
11819
+ "Platform"
11820
+ ],
11821
+ "summary": "Deactivate a signing key for a connection agent",
11822
+ "description": "Deactivates the signing key for an agent provisioned on the connection.\nWhen multiple agents exist, pass `agent_id` query param. plt_ auth only.\n",
11823
+ "operationId": "deactivateConnectionSigningKey",
11824
+ "security": [
11825
+ {
11826
+ "BearerAuth": []
11827
+ }
11828
+ ],
11829
+ "parameters": [
11830
+ {
11831
+ "in": "path",
11832
+ "name": "connectionId",
11833
+ "required": true,
11834
+ "schema": {
11835
+ "type": "string",
11836
+ "format": "uuid"
11837
+ }
11838
+ },
11839
+ {
11840
+ "in": "path",
11841
+ "name": "chain",
11842
+ "required": true,
11843
+ "schema": {
11844
+ "type": "string"
11845
+ }
11846
+ },
11847
+ {
11848
+ "in": "query",
11849
+ "name": "agent_id",
11850
+ "required": false,
11851
+ "schema": {
11852
+ "type": "string",
11853
+ "format": "uuid"
11854
+ }
11855
+ }
11856
+ ],
11857
+ "responses": {
11858
+ "204": {
11859
+ "description": "Key deactivated"
11860
+ },
11861
+ "400": {
11862
+ "description": "Multiple agents — agent_id required"
11863
+ },
11864
+ "404": {
11865
+ "$ref": "#/components/responses/NotFound"
11866
+ }
11867
+ }
11868
+ }
11869
+ },
11870
+ "/v1/platform/connections/{connectionId}/runtimes": {
11871
+ "post": {
11872
+ "tags": [
11873
+ "Platform"
11874
+ ],
11875
+ "summary": "Create a runtime for a connection agent",
11876
+ "description": "Creates a Cloud Runtime in the end-user's org for an agent on this connection.\nUse instead of `POST /v1/runtimes` with a plt_ key (which resolves to the platform org).\nApp must verify user intent out-of-band (e.g. wallet mandate) before calling.\n",
11877
+ "operationId": "createConnectionRuntime",
11878
+ "security": [
11879
+ {
11880
+ "BearerAuth": []
11881
+ }
11882
+ ],
11883
+ "parameters": [
11884
+ {
11885
+ "in": "path",
11886
+ "name": "connectionId",
11112
11887
  "required": true,
11113
11888
  "schema": {
11114
11889
  "type": "string",
@@ -11116,9 +11891,29 @@
11116
11891
  }
11117
11892
  }
11118
11893
  ],
11894
+ "requestBody": {
11895
+ "required": true,
11896
+ "content": {
11897
+ "application/json": {
11898
+ "schema": {
11899
+ "$ref": "#/components/schemas/CreateConnectionRuntimeRequest"
11900
+ }
11901
+ }
11902
+ }
11903
+ },
11119
11904
  "responses": {
11120
- "204": {
11121
- "description": "Deleted"
11905
+ "201": {
11906
+ "description": "Runtime created",
11907
+ "content": {
11908
+ "application/json": {
11909
+ "schema": {
11910
+ "$ref": "#/components/schemas/RuntimeResponse"
11911
+ }
11912
+ }
11913
+ }
11914
+ },
11915
+ "403": {
11916
+ "$ref": "#/components/responses/Forbidden"
11122
11917
  },
11123
11918
  "404": {
11124
11919
  "$ref": "#/components/responses/NotFound"
@@ -11126,14 +11921,14 @@
11126
11921
  }
11127
11922
  }
11128
11923
  },
11129
- "/v1/platform/connections/{connectionId}/spend-policy": {
11130
- "put": {
11924
+ "/v1/platform/connections/{connectionId}/agents/{agentId}/chat": {
11925
+ "post": {
11131
11926
  "tags": [
11132
11927
  "Platform"
11133
11928
  ],
11134
- "summary": "Set per-user spend policy override",
11135
- "description": "Override the app-wide spend policy for a specific connected user. This\npolicy takes precedence over the app default. Remove by deleting the\nconnection-level policy.\n",
11136
- "operationId": "setUserSpendPolicy",
11929
+ "summary": "Chat with a connection agent (plt_ scoped)",
11930
+ "description": "Send a chat message to an agent provisioned on this connection, acting as the\nconnected end-user. Use instead of `POST /v1/agents/{id}/chat` with a plt_ key.\n",
11931
+ "operationId": "connectionAgentChat",
11137
11932
  "security": [
11138
11933
  {
11139
11934
  "BearerAuth": []
@@ -11148,6 +11943,15 @@
11148
11943
  "type": "string",
11149
11944
  "format": "uuid"
11150
11945
  }
11946
+ },
11947
+ {
11948
+ "in": "path",
11949
+ "name": "agentId",
11950
+ "required": true,
11951
+ "schema": {
11952
+ "type": "string",
11953
+ "format": "uuid"
11954
+ }
11151
11955
  }
11152
11956
  ],
11153
11957
  "requestBody": {
@@ -11155,27 +11959,20 @@
11155
11959
  "content": {
11156
11960
  "application/json": {
11157
11961
  "schema": {
11158
- "$ref": "#/components/schemas/CreateSpendPolicyRequest"
11962
+ "$ref": "#/components/schemas/SendChatMessageRequest"
11159
11963
  }
11160
11964
  }
11161
11965
  }
11162
11966
  },
11163
11967
  "responses": {
11164
11968
  "200": {
11165
- "description": "Spend policy set",
11166
- "content": {
11167
- "application/json": {
11168
- "schema": {
11169
- "$ref": "#/components/schemas/SpendPolicyResponse"
11170
- }
11171
- }
11172
- }
11173
- },
11174
- "400": {
11175
- "$ref": "#/components/responses/BadRequest"
11969
+ "description": "Message sent (JSON or SSE stream)"
11176
11970
  },
11177
11971
  "403": {
11178
11972
  "$ref": "#/components/responses/Forbidden"
11973
+ },
11974
+ "404": {
11975
+ "$ref": "#/components/responses/NotFound"
11179
11976
  }
11180
11977
  }
11181
11978
  }
@@ -13737,6 +14534,61 @@
13737
14534
  }
13738
14535
  }
13739
14536
  },
14537
+ "/v1/agents/{agent_id}/automations": {
14538
+ "post": {
14539
+ "tags": [
14540
+ "Automations"
14541
+ ],
14542
+ "summary": "Create agent automation (agent-only)",
14543
+ "operationId": "createAgentAutomation",
14544
+ "description": "Agent-scoped create for simple manual or webhook automations from chat/runtime tools.\nAllowed step types: log, notify, memory_get, memory_put, wait (max 10).\nCron, swap, http, and transaction steps require human dashboard setup.\nRequires agent JWT; agent_id in path must match the caller.\n",
14545
+ "parameters": [
14546
+ {
14547
+ "name": "agent_id",
14548
+ "in": "path",
14549
+ "required": true,
14550
+ "schema": {
14551
+ "type": "string",
14552
+ "format": "uuid"
14553
+ }
14554
+ }
14555
+ ],
14556
+ "requestBody": {
14557
+ "required": true,
14558
+ "content": {
14559
+ "application/json": {
14560
+ "schema": {
14561
+ "$ref": "#/components/schemas/AgentCreateAutomationRequest"
14562
+ }
14563
+ }
14564
+ }
14565
+ },
14566
+ "responses": {
14567
+ "201": {
14568
+ "description": "Automation created (includes one-time webhook credentials when trigger_type is webhook)",
14569
+ "content": {
14570
+ "application/json": {
14571
+ "schema": {
14572
+ "$ref": "#/components/schemas/AutomationCreatedResponse"
14573
+ }
14574
+ }
14575
+ }
14576
+ },
14577
+ "400": {
14578
+ "$ref": "#/components/responses/BadRequest"
14579
+ },
14580
+ "401": {
14581
+ "$ref": "#/components/responses/Unauthorized"
14582
+ },
14583
+ "403": {
14584
+ "$ref": "#/components/responses/Forbidden"
14585
+ },
14586
+ "404": {
14587
+ "$ref": "#/components/responses/NotFound"
14588
+ }
14589
+ }
14590
+ }
14591
+ },
13740
14592
  "/v1/runtimes": {
13741
14593
  "post": {
13742
14594
  "tags": [
@@ -14199,7 +15051,7 @@
14199
15051
  "Runtimes"
14200
15052
  ],
14201
15053
  "summary": "Chat with a running runtime agent",
14202
- "description": "Human-only. Proxies to the runtime container's OpenAI-compatible\n`POST /v1/chat/completions` (hermes / openclaw / openclaude chat bridge).\nStarts the runtime if stopped. Streams SSE when `Accept: text/event-stream`\nor `stream: true`. Conversation history is ephemeral (pass `messages`).\nRequires a public URL (shell access, Shroud sidecar, or HTTP hosting).\n",
15054
+ "description": "Human-only. Proxies to the runtime container's OpenAI-compatible\n`POST /v1/chat/completions` (hermes / openclaw / openclaude / opencode chat bridge).\nStarts the runtime if stopped. Streams SSE when `Accept: text/event-stream`\nor `stream: true`. Conversation history is ephemeral (pass `messages`).\nRequires a public URL (shell access, Shroud sidecar, or HTTP hosting).\n",
14203
15055
  "operationId": "runtimeChat",
14204
15056
  "parameters": [
14205
15057
  {
@@ -24898,6 +25750,69 @@
24898
25750
  }
24899
25751
  }
24900
25752
  },
25753
+ "PlatformAppDeleteResponse": {
25754
+ "type": "object",
25755
+ "required": [
25756
+ "deleted",
25757
+ "soft_delete",
25758
+ "slug_released",
25759
+ "former_slug"
25760
+ ],
25761
+ "properties": {
25762
+ "deleted": {
25763
+ "type": "boolean"
25764
+ },
25765
+ "soft_delete": {
25766
+ "type": "boolean"
25767
+ },
25768
+ "slug_released": {
25769
+ "type": "boolean"
25770
+ },
25771
+ "former_slug": {
25772
+ "type": "string"
25773
+ }
25774
+ }
25775
+ },
25776
+ "TransferPlatformAppOwnershipRequest": {
25777
+ "type": "object",
25778
+ "properties": {
25779
+ "target_org_id": {
25780
+ "type": "string",
25781
+ "format": "uuid"
25782
+ },
25783
+ "target_user_email": {
25784
+ "type": "string",
25785
+ "format": "email"
25786
+ }
25787
+ },
25788
+ "description": "Provide `target_org_id` or `target_user_email` (owner/admin in destination org)."
25789
+ },
25790
+ "TransferPlatformAppOwnershipResponse": {
25791
+ "type": "object",
25792
+ "required": [
25793
+ "app_id",
25794
+ "former_org_id",
25795
+ "new_org_id",
25796
+ "message"
25797
+ ],
25798
+ "properties": {
25799
+ "app_id": {
25800
+ "type": "string",
25801
+ "format": "uuid"
25802
+ },
25803
+ "former_org_id": {
25804
+ "type": "string",
25805
+ "format": "uuid"
25806
+ },
25807
+ "new_org_id": {
25808
+ "type": "string",
25809
+ "format": "uuid"
25810
+ },
25811
+ "message": {
25812
+ "type": "string"
25813
+ }
25814
+ }
25815
+ },
24901
25816
  "PlatformAppResponse": {
24902
25817
  "type": "object",
24903
25818
  "properties": {
@@ -25944,6 +26859,24 @@
25944
26859
  }
25945
26860
  }
25946
26861
  },
26862
+ "ApprovalListResponse": {
26863
+ "type": "object",
26864
+ "required": [
26865
+ "approvals",
26866
+ "total"
26867
+ ],
26868
+ "properties": {
26869
+ "approvals": {
26870
+ "type": "array",
26871
+ "items": {
26872
+ "$ref": "#/components/schemas/ApprovalResponse"
26873
+ }
26874
+ },
26875
+ "total": {
26876
+ "type": "integer"
26877
+ }
26878
+ }
26879
+ },
25947
26880
  "ApprovalStatusResponse": {
25948
26881
  "type": "object",
25949
26882
  "required": [
@@ -26341,6 +27274,20 @@
26341
27274
  "format": "uuid"
26342
27275
  }
26343
27276
  },
27277
+ "runtime_ids": {
27278
+ "type": "array",
27279
+ "items": {
27280
+ "type": "string",
27281
+ "format": "uuid"
27282
+ }
27283
+ },
27284
+ "automation_ids": {
27285
+ "type": "array",
27286
+ "items": {
27287
+ "type": "string",
27288
+ "format": "uuid"
27289
+ }
27290
+ },
26344
27291
  "claimed_at": {
26345
27292
  "type": "string",
26346
27293
  "format": "date-time",
@@ -27672,6 +28619,48 @@
27672
28619
  }
27673
28620
  }
27674
28621
  },
28622
+ "AgentCreateAutomationRequest": {
28623
+ "type": "object",
28624
+ "required": [
28625
+ "name",
28626
+ "workflow_spec"
28627
+ ],
28628
+ "description": "Agent-scoped automation create. Defaults to manual trigger.\nworkflow_spec must use only agent-allowed step types (log, notify, memory_get, memory_put, wait).\n",
28629
+ "properties": {
28630
+ "name": {
28631
+ "type": "string",
28632
+ "maxLength": 128
28633
+ },
28634
+ "trigger_type": {
28635
+ "type": "string",
28636
+ "enum": [
28637
+ "manual",
28638
+ "webhook"
28639
+ ],
28640
+ "default": "manual"
28641
+ },
28642
+ "workflow_spec": {
28643
+ "oneOf": [
28644
+ {
28645
+ "type": "array",
28646
+ "items": {
28647
+ "type": "object",
28648
+ "additionalProperties": true
28649
+ }
28650
+ },
28651
+ {
28652
+ "type": "object",
28653
+ "additionalProperties": true
28654
+ }
28655
+ ]
28656
+ },
28657
+ "auto_trigger": {
28658
+ "type": "boolean",
28659
+ "default": false,
28660
+ "description": "When true (manual trigger only), start a run immediately after creation"
28661
+ }
28662
+ }
28663
+ },
27675
28664
  "UpdateAutomationRequest": {
27676
28665
  "type": "object",
27677
28666
  "properties": {
@@ -27804,6 +28793,14 @@
27804
28793
  "nullable": true,
27805
28794
  "description": "Resolved agent display name (enriched list field)"
27806
28795
  },
28796
+ "created_by_type": {
28797
+ "type": "string",
28798
+ "enum": [
28799
+ "user",
28800
+ "agent"
28801
+ ],
28802
+ "description": "Whether the automation was created by a human or agent (chat-native create)"
28803
+ },
27807
28804
  "created_at": {
27808
28805
  "type": "string",
27809
28806
  "format": "date-time"
@@ -28033,6 +29030,48 @@
28033
29030
  }
28034
29031
  }
28035
29032
  },
29033
+ "CreateConnectionRuntimeRequest": {
29034
+ "type": "object",
29035
+ "required": [
29036
+ "name"
29037
+ ],
29038
+ "properties": {
29039
+ "name": {
29040
+ "type": "string"
29041
+ },
29042
+ "agent_id": {
29043
+ "type": "string",
29044
+ "format": "uuid",
29045
+ "description": "Required when multiple agents on the connection; defaults to sole agent"
29046
+ },
29047
+ "template": {
29048
+ "type": "string"
29049
+ },
29050
+ "preset": {
29051
+ "type": "string",
29052
+ "default": "medium"
29053
+ },
29054
+ "env_public": {
29055
+ "type": "object",
29056
+ "additionalProperties": true
29057
+ },
29058
+ "idle_timeout_secs": {
29059
+ "type": "integer"
29060
+ },
29061
+ "expose_http": {
29062
+ "type": "boolean"
29063
+ },
29064
+ "slug": {
29065
+ "type": "string"
29066
+ },
29067
+ "inbound_auth": {
29068
+ "type": "string"
29069
+ },
29070
+ "startup_command": {
29071
+ "type": "string"
29072
+ }
29073
+ }
29074
+ },
28036
29075
  "CreateRuntimeRequest": {
28037
29076
  "type": "object",
28038
29077
  "required": [
@@ -30807,7 +31846,9 @@
30807
31846
  "type": "string",
30808
31847
  "enum": [
30809
31848
  "approve",
30810
- "reject"
31849
+ "reject",
31850
+ "approved",
31851
+ "rejected"
30811
31852
  ]
30812
31853
  },
30813
31854
  "payload_hash": {