@agent-os-sdk/client 0.5.2 → 0.5.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.
@@ -3315,6 +3315,256 @@
3315
3315
  }
3316
3316
  }
3317
3317
  },
3318
+ "/v1/api/graph/commit": {
3319
+ "post": {
3320
+ "tags": [
3321
+ "GraphSpec"
3322
+ ],
3323
+ "summary": "Commit GraphSpec — atomic, idempotent, validated.",
3324
+ "description": "**Flow:**\n1. Validate spec_version (reject unsupported)\n2. Verify agent exists in workspace\n3. Check optimistic concurrency (expected_revision)\n4. Call DataPlane to validate/normalize\n5. Canonicalize JSON for deterministic hashing\n6. Idempotence: if revision unchanged, return no_change\n7. Persist with atomic check\n8. Return canonical spec + new revision\n\n**Status Codes:**\n- 200: Success (includes no_change case)\n- 400: Missing workspace\n- 404: Agent not found\n- 409: Revision mismatch (concurrent edit)\n- 422: Validation failed / unsupported spec version\n- 502: DataPlane unreachable",
3325
+ "requestBody": {
3326
+ "content": {
3327
+ "application/json": {
3328
+ "schema": {
3329
+ "$ref": "#/components/schemas/CommitGraphSpecRequest"
3330
+ }
3331
+ },
3332
+ "text/json": {
3333
+ "schema": {
3334
+ "$ref": "#/components/schemas/CommitGraphSpecRequest"
3335
+ }
3336
+ },
3337
+ "application/*+json": {
3338
+ "schema": {
3339
+ "$ref": "#/components/schemas/CommitGraphSpecRequest"
3340
+ }
3341
+ }
3342
+ }
3343
+ },
3344
+ "responses": {
3345
+ "200": {
3346
+ "description": "OK",
3347
+ "content": {
3348
+ "application/json": {
3349
+ "schema": {
3350
+ "$ref": "#/components/schemas/CommitGraphSpecResponseApiEnvelope"
3351
+ }
3352
+ }
3353
+ }
3354
+ },
3355
+ "400": {
3356
+ "description": "Bad Request",
3357
+ "content": {
3358
+ "application/json": {
3359
+ "schema": {
3360
+ "$ref": "#/components/schemas/ProblemDetails"
3361
+ }
3362
+ }
3363
+ }
3364
+ },
3365
+ "404": {
3366
+ "description": "Not Found",
3367
+ "content": {
3368
+ "application/json": {
3369
+ "schema": {
3370
+ "$ref": "#/components/schemas/ProblemDetails"
3371
+ }
3372
+ }
3373
+ }
3374
+ },
3375
+ "409": {
3376
+ "description": "Conflict",
3377
+ "content": {
3378
+ "application/json": {
3379
+ "schema": {
3380
+ "$ref": "#/components/schemas/ProblemDetails"
3381
+ }
3382
+ }
3383
+ }
3384
+ },
3385
+ "422": {
3386
+ "description": "Unprocessable Content",
3387
+ "content": {
3388
+ "application/json": {
3389
+ "schema": {
3390
+ "$ref": "#/components/schemas/ProblemDetails"
3391
+ }
3392
+ }
3393
+ }
3394
+ },
3395
+ "502": {
3396
+ "description": "Bad Gateway",
3397
+ "content": {
3398
+ "application/json": {
3399
+ "schema": {
3400
+ "$ref": "#/components/schemas/ProblemDetails"
3401
+ }
3402
+ }
3403
+ }
3404
+ }
3405
+ }
3406
+ }
3407
+ },
3408
+ "/v1/api/graph/{agentId}": {
3409
+ "get": {
3410
+ "tags": [
3411
+ "GraphSpec"
3412
+ ],
3413
+ "summary": "Get current graph spec with revision.",
3414
+ "parameters": [
3415
+ {
3416
+ "name": "agentId",
3417
+ "in": "path",
3418
+ "required": true,
3419
+ "schema": {
3420
+ "type": "string",
3421
+ "format": "uuid"
3422
+ }
3423
+ }
3424
+ ],
3425
+ "responses": {
3426
+ "200": {
3427
+ "description": "OK",
3428
+ "content": {
3429
+ "application/json": {
3430
+ "schema": {
3431
+ "$ref": "#/components/schemas/GetGraphSpecResponseApiEnvelope"
3432
+ }
3433
+ }
3434
+ }
3435
+ },
3436
+ "400": {
3437
+ "description": "Bad Request",
3438
+ "content": {
3439
+ "application/json": {
3440
+ "schema": {
3441
+ "$ref": "#/components/schemas/ProblemDetails"
3442
+ }
3443
+ }
3444
+ }
3445
+ },
3446
+ "404": {
3447
+ "description": "Not Found",
3448
+ "content": {
3449
+ "application/json": {
3450
+ "schema": {
3451
+ "$ref": "#/components/schemas/ProblemDetails"
3452
+ }
3453
+ }
3454
+ }
3455
+ },
3456
+ "500": {
3457
+ "description": "Internal Server Error",
3458
+ "content": {
3459
+ "application/json": {
3460
+ "schema": {
3461
+ "$ref": "#/components/schemas/ProblemDetails"
3462
+ }
3463
+ }
3464
+ }
3465
+ }
3466
+ }
3467
+ }
3468
+ },
3469
+ "/v1/api/graph/{agentId}/revisions": {
3470
+ "get": {
3471
+ "tags": [
3472
+ "GraphSpec"
3473
+ ],
3474
+ "summary": "List revision history for an agent (metadata only, not full spec).",
3475
+ "parameters": [
3476
+ {
3477
+ "name": "agentId",
3478
+ "in": "path",
3479
+ "required": true,
3480
+ "schema": {
3481
+ "type": "string",
3482
+ "format": "uuid"
3483
+ }
3484
+ },
3485
+ {
3486
+ "name": "limit",
3487
+ "in": "query",
3488
+ "schema": {
3489
+ "type": "integer",
3490
+ "format": "int32",
3491
+ "default": 50
3492
+ }
3493
+ }
3494
+ ],
3495
+ "responses": {
3496
+ "200": {
3497
+ "description": "OK",
3498
+ "content": {
3499
+ "application/json": {
3500
+ "schema": {
3501
+ "$ref": "#/components/schemas/RevisionListResponseApiEnvelope"
3502
+ }
3503
+ }
3504
+ }
3505
+ },
3506
+ "400": {
3507
+ "description": "Bad Request",
3508
+ "content": {
3509
+ "application/json": {
3510
+ "schema": {
3511
+ "$ref": "#/components/schemas/ProblemDetails"
3512
+ }
3513
+ }
3514
+ }
3515
+ }
3516
+ }
3517
+ }
3518
+ },
3519
+ "/v1/api/graph/{agentId}/revisions/{revision}": {
3520
+ "get": {
3521
+ "tags": [
3522
+ "GraphSpec"
3523
+ ],
3524
+ "summary": "Get a specific revision with full graph spec.",
3525
+ "parameters": [
3526
+ {
3527
+ "name": "agentId",
3528
+ "in": "path",
3529
+ "required": true,
3530
+ "schema": {
3531
+ "type": "string",
3532
+ "format": "uuid"
3533
+ }
3534
+ },
3535
+ {
3536
+ "name": "revision",
3537
+ "in": "path",
3538
+ "required": true,
3539
+ "schema": {
3540
+ "type": "string"
3541
+ }
3542
+ }
3543
+ ],
3544
+ "responses": {
3545
+ "200": {
3546
+ "description": "OK",
3547
+ "content": {
3548
+ "application/json": {
3549
+ "schema": {
3550
+ "$ref": "#/components/schemas/RevisionDetailResponseApiEnvelope"
3551
+ }
3552
+ }
3553
+ }
3554
+ },
3555
+ "404": {
3556
+ "description": "Not Found",
3557
+ "content": {
3558
+ "application/json": {
3559
+ "schema": {
3560
+ "$ref": "#/components/schemas/ProblemDetails"
3561
+ }
3562
+ }
3563
+ }
3564
+ }
3565
+ }
3566
+ }
3567
+ },
3318
3568
  "/v1/api/knowledge/datasets": {
3319
3569
  "get": {
3320
3570
  "tags": [
@@ -6380,8 +6630,25 @@
6380
6630
  }
6381
6631
  },
6382
6632
  "responses": {
6383
- "200": {
6384
- "description": "OK"
6633
+ "201": {
6634
+ "description": "Created",
6635
+ "content": {
6636
+ "application/json": {
6637
+ "schema": {
6638
+ "$ref": "#/components/schemas/TriggerSecretResponse"
6639
+ }
6640
+ }
6641
+ }
6642
+ },
6643
+ "400": {
6644
+ "description": "Bad Request",
6645
+ "content": {
6646
+ "application/json": {
6647
+ "schema": {
6648
+ "$ref": "#/components/schemas/ProblemDetails"
6649
+ }
6650
+ }
6651
+ }
6385
6652
  }
6386
6653
  }
6387
6654
  },
@@ -6529,17 +6796,44 @@
6529
6796
  ],
6530
6797
  "responses": {
6531
6798
  "200": {
6532
- "description": "OK"
6533
- }
6534
- }
6535
- }
6536
- },
6537
- "/v1/api/triggers/invoke/{triggerId}": {
6538
- "post": {
6539
- "tags": [
6540
- "Triggers"
6541
- ],
6542
- "summary": "Invoke a trigger to start an agent run.\nSECURITY: Requires HMAC-SHA256 signature over raw request body.\nSignature format: X-Signature: sha256=[64_lowercase_hex]\nPayload: X-Timestamp + \".\" + raw_request_body",
6799
+ "description": "OK",
6800
+ "content": {
6801
+ "application/json": {
6802
+ "schema": {
6803
+ "$ref": "#/components/schemas/TriggerSecretResponse"
6804
+ }
6805
+ }
6806
+ }
6807
+ },
6808
+ "401": {
6809
+ "description": "Unauthorized",
6810
+ "content": {
6811
+ "application/json": {
6812
+ "schema": {
6813
+ "$ref": "#/components/schemas/ProblemDetails"
6814
+ }
6815
+ }
6816
+ }
6817
+ },
6818
+ "404": {
6819
+ "description": "Not Found",
6820
+ "content": {
6821
+ "application/json": {
6822
+ "schema": {
6823
+ "$ref": "#/components/schemas/ProblemDetails"
6824
+ }
6825
+ }
6826
+ }
6827
+ }
6828
+ }
6829
+ }
6830
+ },
6831
+ "/v1/api/triggers/invoke/{triggerId}": {
6832
+ "post": {
6833
+ "tags": [
6834
+ "Triggers"
6835
+ ],
6836
+ "summary": "Invoke a trigger to start an agent run.\nSECURITY: Requires HMAC-SHA256 signature over raw request body.\nSignature format: X-Signature: sha256=[64_lowercase_hex]\nPayload: X-Timestamp + \".\" + raw_request_body",
6543
6837
  "parameters": [
6544
6838
  {
6545
6839
  "name": "triggerId",
@@ -7991,6 +8285,88 @@
7991
8285
  },
7992
8286
  "additionalProperties": false
7993
8287
  },
8288
+ "CommitGraphSpecRequest": {
8289
+ "type": "object",
8290
+ "properties": {
8291
+ "spec_version": {
8292
+ "type": "string",
8293
+ "nullable": true
8294
+ },
8295
+ "agent_id": {
8296
+ "type": "string",
8297
+ "format": "uuid"
8298
+ },
8299
+ "graph_spec": { },
8300
+ "expected_revision": {
8301
+ "type": "string",
8302
+ "nullable": true
8303
+ },
8304
+ "source": {
8305
+ "type": "string",
8306
+ "description": "Source of the commit: ui.dragdrop, ui.json, meta_builder, system",
8307
+ "nullable": true
8308
+ }
8309
+ },
8310
+ "additionalProperties": false
8311
+ },
8312
+ "CommitGraphSpecResponse": {
8313
+ "type": "object",
8314
+ "properties": {
8315
+ "status": {
8316
+ "type": "string",
8317
+ "description": "Explicit status: committed, no_change, conflict",
8318
+ "nullable": true
8319
+ },
8320
+ "agent_id": {
8321
+ "type": "string",
8322
+ "format": "uuid"
8323
+ },
8324
+ "revision": {
8325
+ "type": "string",
8326
+ "nullable": true
8327
+ },
8328
+ "current_revision": {
8329
+ "type": "string",
8330
+ "description": "Only present in conflict response (409 body).",
8331
+ "nullable": true
8332
+ },
8333
+ "canonical_spec": {
8334
+ "nullable": true
8335
+ },
8336
+ "committed_at": {
8337
+ "type": "string",
8338
+ "format": "date-time",
8339
+ "nullable": true
8340
+ },
8341
+ "warnings": {
8342
+ "type": "array",
8343
+ "items": {
8344
+ "$ref": "#/components/schemas/ValidationMessage"
8345
+ },
8346
+ "nullable": true
8347
+ },
8348
+ "validation": {
8349
+ "$ref": "#/components/schemas/ValidationResult"
8350
+ }
8351
+ },
8352
+ "additionalProperties": false
8353
+ },
8354
+ "CommitGraphSpecResponseApiEnvelope": {
8355
+ "type": "object",
8356
+ "properties": {
8357
+ "data": {
8358
+ "$ref": "#/components/schemas/CommitGraphSpecResponse"
8359
+ },
8360
+ "hints": {
8361
+ "type": "array",
8362
+ "items": {
8363
+ "$ref": "#/components/schemas/ApiHint"
8364
+ },
8365
+ "nullable": true
8366
+ }
8367
+ },
8368
+ "additionalProperties": false
8369
+ },
7994
8370
  "ConfirmUploadRequest": {
7995
8371
  "type": "object",
7996
8372
  "properties": {
@@ -8666,6 +9042,54 @@
8666
9042
  },
8667
9043
  "additionalProperties": false
8668
9044
  },
9045
+ "GetGraphSpecResponse": {
9046
+ "type": "object",
9047
+ "properties": {
9048
+ "agent_id": {
9049
+ "type": "string",
9050
+ "format": "uuid"
9051
+ },
9052
+ "revision": {
9053
+ "type": "string",
9054
+ "nullable": true
9055
+ },
9056
+ "canonical_spec": {
9057
+ "nullable": true
9058
+ },
9059
+ "committed_at": {
9060
+ "type": "string",
9061
+ "format": "date-time",
9062
+ "nullable": true
9063
+ },
9064
+ "warnings": {
9065
+ "type": "array",
9066
+ "items": {
9067
+ "$ref": "#/components/schemas/ValidationMessage"
9068
+ },
9069
+ "nullable": true
9070
+ },
9071
+ "validation": {
9072
+ "$ref": "#/components/schemas/ValidationResult"
9073
+ }
9074
+ },
9075
+ "additionalProperties": false
9076
+ },
9077
+ "GetGraphSpecResponseApiEnvelope": {
9078
+ "type": "object",
9079
+ "properties": {
9080
+ "data": {
9081
+ "$ref": "#/components/schemas/GetGraphSpecResponse"
9082
+ },
9083
+ "hints": {
9084
+ "type": "array",
9085
+ "items": {
9086
+ "$ref": "#/components/schemas/ApiHint"
9087
+ },
9088
+ "nullable": true
9089
+ }
9090
+ },
9091
+ "additionalProperties": false
9092
+ },
8669
9093
  "GrantAccessRequest": {
8670
9094
  "type": "object",
8671
9095
  "properties": {
@@ -9140,6 +9564,117 @@
9140
9564
  },
9141
9565
  "additionalProperties": false
9142
9566
  },
9567
+ "RevisionDetailResponse": {
9568
+ "type": "object",
9569
+ "properties": {
9570
+ "agent_id": {
9571
+ "type": "string",
9572
+ "format": "uuid"
9573
+ },
9574
+ "revision": {
9575
+ "type": "string",
9576
+ "nullable": true
9577
+ },
9578
+ "graph_spec": { },
9579
+ "created_at": {
9580
+ "type": "string",
9581
+ "format": "date-time"
9582
+ },
9583
+ "source": {
9584
+ "type": "string",
9585
+ "nullable": true
9586
+ },
9587
+ "actor_user_id": {
9588
+ "type": "string",
9589
+ "format": "uuid",
9590
+ "nullable": true
9591
+ },
9592
+ "warnings": {
9593
+ "type": "array",
9594
+ "items": {
9595
+ "$ref": "#/components/schemas/ValidationMessage"
9596
+ },
9597
+ "nullable": true
9598
+ }
9599
+ },
9600
+ "additionalProperties": false
9601
+ },
9602
+ "RevisionDetailResponseApiEnvelope": {
9603
+ "type": "object",
9604
+ "properties": {
9605
+ "data": {
9606
+ "$ref": "#/components/schemas/RevisionDetailResponse"
9607
+ },
9608
+ "hints": {
9609
+ "type": "array",
9610
+ "items": {
9611
+ "$ref": "#/components/schemas/ApiHint"
9612
+ },
9613
+ "nullable": true
9614
+ }
9615
+ },
9616
+ "additionalProperties": false
9617
+ },
9618
+ "RevisionListItem": {
9619
+ "type": "object",
9620
+ "properties": {
9621
+ "revision": {
9622
+ "type": "string",
9623
+ "nullable": true
9624
+ },
9625
+ "created_at": {
9626
+ "type": "string",
9627
+ "format": "date-time"
9628
+ },
9629
+ "source": {
9630
+ "type": "string",
9631
+ "nullable": true
9632
+ },
9633
+ "actor_user_id": {
9634
+ "type": "string",
9635
+ "format": "uuid",
9636
+ "nullable": true
9637
+ }
9638
+ },
9639
+ "additionalProperties": false
9640
+ },
9641
+ "RevisionListResponse": {
9642
+ "type": "object",
9643
+ "properties": {
9644
+ "agent_id": {
9645
+ "type": "string",
9646
+ "format": "uuid"
9647
+ },
9648
+ "total": {
9649
+ "type": "integer",
9650
+ "format": "int32"
9651
+ },
9652
+ "items": {
9653
+ "type": "array",
9654
+ "items": {
9655
+ "$ref": "#/components/schemas/RevisionListItem"
9656
+ },
9657
+ "nullable": true
9658
+ }
9659
+ },
9660
+ "additionalProperties": false
9661
+ },
9662
+ "RevisionListResponseApiEnvelope": {
9663
+ "type": "object",
9664
+ "properties": {
9665
+ "data": {
9666
+ "$ref": "#/components/schemas/RevisionListResponse"
9667
+ },
9668
+ "hints": {
9669
+ "type": "array",
9670
+ "items": {
9671
+ "$ref": "#/components/schemas/ApiHint"
9672
+ },
9673
+ "nullable": true
9674
+ }
9675
+ },
9676
+ "additionalProperties": false
9677
+ },
9143
9678
  "RunDetailResponse": {
9144
9679
  "type": "object",
9145
9680
  "properties": {
@@ -9431,6 +9966,36 @@
9431
9966
  },
9432
9967
  "additionalProperties": false
9433
9968
  },
9969
+ "SigningContract": {
9970
+ "type": "object",
9971
+ "properties": {
9972
+ "algorithm": {
9973
+ "type": "string",
9974
+ "nullable": true
9975
+ },
9976
+ "signature_header": {
9977
+ "type": "string",
9978
+ "nullable": true
9979
+ },
9980
+ "timestamp_header": {
9981
+ "type": "string",
9982
+ "nullable": true
9983
+ },
9984
+ "timestamp_format": {
9985
+ "type": "string",
9986
+ "nullable": true
9987
+ },
9988
+ "string_to_sign": {
9989
+ "type": "string",
9990
+ "nullable": true
9991
+ },
9992
+ "signature_format": {
9993
+ "type": "string",
9994
+ "nullable": true
9995
+ }
9996
+ },
9997
+ "additionalProperties": false
9998
+ },
9434
9999
  "SpanData": {
9435
10000
  "type": "object",
9436
10001
  "properties": {
@@ -9663,6 +10228,86 @@
9663
10228
  },
9664
10229
  "additionalProperties": false
9665
10230
  },
10231
+ "TriggerRequestContract": {
10232
+ "type": "object",
10233
+ "properties": {
10234
+ "method": {
10235
+ "type": "string",
10236
+ "nullable": true
10237
+ },
10238
+ "invoke_url": {
10239
+ "type": "string",
10240
+ "nullable": true
10241
+ },
10242
+ "headers": {
10243
+ "type": "object",
10244
+ "additionalProperties": {
10245
+ "type": "string"
10246
+ },
10247
+ "nullable": true
10248
+ },
10249
+ "signing": {
10250
+ "$ref": "#/components/schemas/SigningContract"
10251
+ },
10252
+ "body_schema_json": {
10253
+ "type": "string",
10254
+ "nullable": true
10255
+ },
10256
+ "example_payload_json": {
10257
+ "type": "string",
10258
+ "nullable": true
10259
+ },
10260
+ "curl_example": {
10261
+ "type": "string",
10262
+ "nullable": true
10263
+ }
10264
+ },
10265
+ "additionalProperties": false
10266
+ },
10267
+ "TriggerSecretResponse": {
10268
+ "type": "object",
10269
+ "properties": {
10270
+ "id": {
10271
+ "type": "string",
10272
+ "format": "uuid"
10273
+ },
10274
+ "name": {
10275
+ "type": "string",
10276
+ "nullable": true
10277
+ },
10278
+ "agent_id": {
10279
+ "type": "string",
10280
+ "format": "uuid"
10281
+ },
10282
+ "workspace_id": {
10283
+ "type": "string",
10284
+ "format": "uuid"
10285
+ },
10286
+ "trigger_type": {
10287
+ "type": "string",
10288
+ "nullable": true
10289
+ },
10290
+ "secret_key": {
10291
+ "type": "string",
10292
+ "nullable": true
10293
+ },
10294
+ "invoke_url": {
10295
+ "type": "string",
10296
+ "nullable": true
10297
+ },
10298
+ "request_contract": {
10299
+ "$ref": "#/components/schemas/TriggerRequestContract"
10300
+ },
10301
+ "is_active": {
10302
+ "type": "boolean"
10303
+ },
10304
+ "created_at": {
10305
+ "type": "string",
10306
+ "format": "date-time"
10307
+ }
10308
+ },
10309
+ "additionalProperties": false
10310
+ },
9666
10311
  "TriggerTemplateDto": {
9667
10312
  "required": [
9668
10313
  "kind",
@@ -9984,6 +10629,49 @@
9984
10629
  "additionalProperties": false,
9985
10630
  "description": "Validation error from graph validation.\nAligned with Data Plane validator output (RFC 6901 JSON Pointer paths)."
9986
10631
  },
10632
+ "ValidationMessage": {
10633
+ "type": "object",
10634
+ "properties": {
10635
+ "code": {
10636
+ "type": "string",
10637
+ "nullable": true
10638
+ },
10639
+ "message": {
10640
+ "type": "string",
10641
+ "nullable": true
10642
+ },
10643
+ "path": {
10644
+ "type": "string",
10645
+ "nullable": true
10646
+ },
10647
+ "node_id": {
10648
+ "type": "string",
10649
+ "nullable": true
10650
+ },
10651
+ "severity": {
10652
+ "type": "string",
10653
+ "nullable": true
10654
+ }
10655
+ },
10656
+ "additionalProperties": false
10657
+ },
10658
+ "ValidationResult": {
10659
+ "type": "object",
10660
+ "properties": {
10661
+ "valid": {
10662
+ "type": "boolean"
10663
+ },
10664
+ "errors": {
10665
+ "type": "array",
10666
+ "items": {
10667
+ "$ref": "#/components/schemas/ValidationMessage"
10668
+ },
10669
+ "nullable": true
10670
+ }
10671
+ },
10672
+ "additionalProperties": false,
10673
+ "description": "Validation result block returned in all commit responses."
10674
+ },
9987
10675
  "VectorQueryRequest": {
9988
10676
  "type": "object",
9989
10677
  "properties": {
@@ -10232,6 +10920,9 @@
10232
10920
  {
10233
10921
  "name": "Graphs"
10234
10922
  },
10923
+ {
10924
+ "name": "GraphSpec"
10925
+ },
10235
10926
  {
10236
10927
  "name": "Knowledge"
10237
10928
  },