@celigo/api-specs 0.2.20 → 0.2.22

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.
package/dist/ai-agent.yml CHANGED
@@ -4951,13 +4951,26 @@ components:
4951
4951
  are re-joined into the record's original shape — the object with its array, or the array of rows —
4952
4952
  carrying any response-mapping enrichment, and that re-joined record is what the next step
4953
4953
  receives. Not for locating records in an export's HTTP response; use
4954
- `http.response.resourcePath` for that.
4954
+ `http.response.resourcePath` for that. Applies to steps that receive a record — imports and
4955
+ lookups (an export referenced as a page processor of a flow, API, or Tool). A standalone export
4956
+ (a flow's page generator) has no incoming record, so the fields are saved but have no effect on
4957
+ the records it produces; to emit one record per array element from a standalone export, use a
4958
+ `hooks.preSavePage` script, or for a file-definition export make the repeating segment the
4959
+ record boundary in the definition's rules.
4955
4960
  x-celigo-ai-guidance:
4956
4961
  - |-
4957
4962
  Two modes, decided by the SHAPE of the record entering the step. Object record with a child
4958
4963
  array under a field → set ``pathToMany`` to that field. Array record (a ``groupByFields``
4959
4964
  export, a CSV/file group, a script that returns an array) → leave ``pathToMany`` blank; each
4960
4965
  element becomes one record. Live-verified 2026-09-10 on flows, Tools, and APIs.
4966
+ - |-
4967
+ Only imports and lookups (exports placed as page processors) fan out. On a standalone export
4968
+ (a flow's page generator) the API saves ``oneToMany`` / ``pathToMany`` and applies neither:
4969
+ the records reach the next step unchanged and no error is raised. Live-verified 2026-09-18 on
4970
+ a flow test run — an order record with three ``lines`` reached the import as ONE record with
4971
+ the setting on the export, and as THREE child records with the same setting on the import.
4972
+ Never propose these fields as the way to split a standalone export's records; that is
4973
+ ``hooks.preSavePage`` work (or, for a file definition, the definition's record boundary).
4961
4974
  - |-
4962
4975
  Blank ``pathToMany`` on an OBJECT record fails every record with code ``oneToMany_error``:
4963
4976
  "Failed to extract child records from oneToMany import data. Record at index 0 was not an
@@ -4987,8 +5000,14 @@ components:
4987
5000
  Path to the array of child records inside an object record when `oneToMany` is true, in dot
4988
5001
  notation (`items`, `lines.lineItems`). Leave blank when the incoming record is itself an array
4989
5002
  (grouped or row-based data) — each element is then a child record. A path that does not resolve
4990
- to an array processes zero records and reports success.
5003
+ to an array processes zero records and reports success. Read only on steps that receive a
5004
+ record (imports, lookup exports); on a standalone export it is saved and ignored — see `oneToMany`.
4991
5005
  x-celigo-ai-guidance:
5006
+ - |-
5007
+ Inert on a standalone export (a flow's page generator) exactly like ``oneToMany`` — the value
5008
+ is saved, the export's records reach the next step unchanged, and nothing errors
5009
+ (live-verified 2026-09-18). Splitting a standalone export's records into one per element is
5010
+ ``hooks.preSavePage`` work, or the file definition's record boundary; never this field.
4992
5011
  - |-
4993
5012
  Set this ONLY when the record entering the step is an object whose children sit under a field.
4994
5013
  On an array record (a ``groupByFields`` export, a CSV/file group, a script returning an array)
package/dist/export.yml CHANGED
@@ -803,13 +803,26 @@ components:
803
803
  are re-joined into the record's original shape — the object with its array, or the array of rows —
804
804
  carrying any response-mapping enrichment, and that re-joined record is what the next step
805
805
  receives. Not for locating records in an export's HTTP response; use
806
- `http.response.resourcePath` for that.
806
+ `http.response.resourcePath` for that. Applies to steps that receive a record — imports and
807
+ lookups (an export referenced as a page processor of a flow, API, or Tool). A standalone export
808
+ (a flow's page generator) has no incoming record, so the fields are saved but have no effect on
809
+ the records it produces; to emit one record per array element from a standalone export, use a
810
+ `hooks.preSavePage` script, or for a file-definition export make the repeating segment the
811
+ record boundary in the definition's rules.
807
812
  x-celigo-ai-guidance:
808
813
  - |-
809
814
  Two modes, decided by the SHAPE of the record entering the step. Object record with a child
810
815
  array under a field → set ``pathToMany`` to that field. Array record (a ``groupByFields``
811
816
  export, a CSV/file group, a script that returns an array) → leave ``pathToMany`` blank; each
812
817
  element becomes one record. Live-verified 2026-09-10 on flows, Tools, and APIs.
818
+ - |-
819
+ Only imports and lookups (exports placed as page processors) fan out. On a standalone export
820
+ (a flow's page generator) the API saves ``oneToMany`` / ``pathToMany`` and applies neither:
821
+ the records reach the next step unchanged and no error is raised. Live-verified 2026-09-18 on
822
+ a flow test run — an order record with three ``lines`` reached the import as ONE record with
823
+ the setting on the export, and as THREE child records with the same setting on the import.
824
+ Never propose these fields as the way to split a standalone export's records; that is
825
+ ``hooks.preSavePage`` work (or, for a file definition, the definition's record boundary).
813
826
  - |-
814
827
  Blank ``pathToMany`` on an OBJECT record fails every record with code ``oneToMany_error``:
815
828
  "Failed to extract child records from oneToMany import data. Record at index 0 was not an
@@ -839,8 +852,14 @@ components:
839
852
  Path to the array of child records inside an object record when `oneToMany` is true, in dot
840
853
  notation (`items`, `lines.lineItems`). Leave blank when the incoming record is itself an array
841
854
  (grouped or row-based data) — each element is then a child record. A path that does not resolve
842
- to an array processes zero records and reports success.
855
+ to an array processes zero records and reports success. Read only on steps that receive a
856
+ record (imports, lookup exports); on a standalone export it is saved and ignored — see `oneToMany`.
843
857
  x-celigo-ai-guidance:
858
+ - |-
859
+ Inert on a standalone export (a flow's page generator) exactly like ``oneToMany`` — the value
860
+ is saved, the export's records reach the next step unchanged, and nothing errors
861
+ (live-verified 2026-09-18). Splitting a standalone export's records into one per element is
862
+ ``hooks.preSavePage`` work, or the file definition's record boundary; never this field.
844
863
  - |-
845
864
  Set this ONLY when the record entering the step is an object whose children sit under a field.
846
865
  On an array record (a ``groupByFields`` export, a CSV/file group, a script returning an array)
package/dist/import.yml CHANGED
@@ -10581,13 +10581,26 @@ components:
10581
10581
  are re-joined into the record's original shape — the object with its array, or the array of rows —
10582
10582
  carrying any response-mapping enrichment, and that re-joined record is what the next step
10583
10583
  receives. Not for locating records in an export's HTTP response; use
10584
- `http.response.resourcePath` for that.
10584
+ `http.response.resourcePath` for that. Applies to steps that receive a record — imports and
10585
+ lookups (an export referenced as a page processor of a flow, API, or Tool). A standalone export
10586
+ (a flow's page generator) has no incoming record, so the fields are saved but have no effect on
10587
+ the records it produces; to emit one record per array element from a standalone export, use a
10588
+ `hooks.preSavePage` script, or for a file-definition export make the repeating segment the
10589
+ record boundary in the definition's rules.
10585
10590
  x-celigo-ai-guidance:
10586
10591
  - |-
10587
10592
  Two modes, decided by the SHAPE of the record entering the step. Object record with a child
10588
10593
  array under a field → set ``pathToMany`` to that field. Array record (a ``groupByFields``
10589
10594
  export, a CSV/file group, a script that returns an array) → leave ``pathToMany`` blank; each
10590
10595
  element becomes one record. Live-verified 2026-09-10 on flows, Tools, and APIs.
10596
+ - |-
10597
+ Only imports and lookups (exports placed as page processors) fan out. On a standalone export
10598
+ (a flow's page generator) the API saves ``oneToMany`` / ``pathToMany`` and applies neither:
10599
+ the records reach the next step unchanged and no error is raised. Live-verified 2026-09-18 on
10600
+ a flow test run — an order record with three ``lines`` reached the import as ONE record with
10601
+ the setting on the export, and as THREE child records with the same setting on the import.
10602
+ Never propose these fields as the way to split a standalone export's records; that is
10603
+ ``hooks.preSavePage`` work (or, for a file definition, the definition's record boundary).
10591
10604
  - |-
10592
10605
  Blank ``pathToMany`` on an OBJECT record fails every record with code ``oneToMany_error``:
10593
10606
  "Failed to extract child records from oneToMany import data. Record at index 0 was not an
@@ -10617,8 +10630,14 @@ components:
10617
10630
  Path to the array of child records inside an object record when `oneToMany` is true, in dot
10618
10631
  notation (`items`, `lines.lineItems`). Leave blank when the incoming record is itself an array
10619
10632
  (grouped or row-based data) — each element is then a child record. A path that does not resolve
10620
- to an array processes zero records and reports success.
10633
+ to an array processes zero records and reports success. Read only on steps that receive a
10634
+ record (imports, lookup exports); on a standalone export it is saved and ignored — see `oneToMany`.
10621
10635
  x-celigo-ai-guidance:
10636
+ - |-
10637
+ Inert on a standalone export (a flow's page generator) exactly like ``oneToMany`` — the value
10638
+ is saved, the export's records reach the next step unchanged, and nothing errors
10639
+ (live-verified 2026-09-18). Splitting a standalone export's records into one per element is
10640
+ ``hooks.preSavePage`` work, or the file definition's record boundary; never this field.
10622
10641
  - |-
10623
10642
  Set this ONLY when the record entering the step is an object whose children sit under a field.
10624
10643
  On an array record (a ``groupByFields`` export, a CSV/file group, a script returning an array)
package/dist/tool.yml CHANGED
@@ -382,6 +382,86 @@ paths:
382
382
  - |-
383
383
  Updates an existing tool with the provided configuration.
384
384
  This is used for major updates to a tool's structure or behavior.
385
+ patch:
386
+ x-internal: false
387
+ summary: Patch a tool
388
+ description: |-
389
+ Partially updates a tool using a JSON Patch document (RFC 6902).
390
+ The `add`, `remove`, `replace`, and `move` operations are supported
391
+ (`copy` and `test` are rejected), and only on the following whitelisted
392
+ paths:
393
+
394
+ | Path | Description |
395
+ |------|-------------|
396
+ | `/name` | Tool display name |
397
+ | `/description` | Tool description |
398
+ | `/aiDescription` | AI-generated description object |
399
+ | `/input/debugUntil` | Tool Input debug capture expiry (ISO-8601, at most 1 hour in the future; 422 beyond the cap) |
400
+ | `/output/debugUntil` | Tool Output debug capture expiry (ISO-8601, at most 1 hour in the future; 422 beyond the cap) |
401
+
402
+ All other paths are rejected with 422 (`not a whitelisted property`).
403
+
404
+ PATCH is the intended way to update these fields without accidentally
405
+ resetting other tool configuration via `PUT`. In particular, it is how
406
+ you arm and disarm step debug capture: `replace` `/input/debugUntil` or
407
+ `/output/debugUntil` with a future ISO timestamp to start capturing, or
408
+ a past timestamp to stop. While armed, captured logs are readable at
409
+ `GET /v1/tools/{_id}/tool_input/requests` and
410
+ `GET /v1/tools/{_id}/tool_output/requests`.
411
+ operationId: patchTool
412
+ tags:
413
+ - Tools
414
+ parameters:
415
+ - name: _id
416
+ in: path
417
+ description: The unique identifier of the tool
418
+ required: true
419
+ schema:
420
+ type: string
421
+ format: objectId
422
+ x-celigo-refModel: tools
423
+ examples:
424
+ - 69d462d5b9c28ea0b7f82522
425
+ requestBody:
426
+ required: true
427
+ content:
428
+ application/json:
429
+ schema:
430
+ $ref: '#/components/schemas/JsonPatchRequest'
431
+ examples:
432
+ rename:
433
+ summary: Rename a tool
434
+ value:
435
+ - op: replace
436
+ path: /name
437
+ value: Updated Tool Name
438
+ update_description:
439
+ summary: Update tool description
440
+ value:
441
+ - op: replace
442
+ path: /description
443
+ value: Updated tool description
444
+ arm_input_debug:
445
+ summary: Arm input debug capture for 30 minutes
446
+ value:
447
+ - op: replace
448
+ path: /input/debugUntil
449
+ value: '2026-08-25T12:30:00.000Z'
450
+ disarm_output_debug:
451
+ summary: Disarm output debug capture
452
+ value:
453
+ - op: replace
454
+ path: /output/debugUntil
455
+ value: '2020-01-01T00:00:00.000Z'
456
+ responses:
457
+ '204':
458
+ description: Tool patched successfully.
459
+ '401':
460
+ $ref: '#/components/responses/401-unauthorized'
461
+ '404':
462
+ $ref: '#/components/responses/404-not-found'
463
+ '422':
464
+ $ref: '#/components/responses/422-unprocessable-entity'
385
465
  delete:
386
466
  x-internal: false
387
467
  summary: Delete a tool
@@ -1348,12 +1428,20 @@ paths:
1348
1428
  summary: List captured debug requests for a tool step
1349
1429
  description: |-
1350
1430
  Lists the debug request records captured for a specific step of a tool.
1351
- These are the raw outbound requests the step issued, retained for
1352
- troubleshooting. Use the `key` of an entry with
1353
- `GET /v1/tools/{_id}/{_stepId}/requests/{key}` to fetch the full detail
1354
- of a single captured request.
1431
+ These are the raw request/response payloads the step processed, retained
1432
+ for troubleshooting while debug capture is active for the step. Use the
1433
+ `key` of an entry with `GET /v1/tools/{_id}/{_stepId}/requests/{key}` to
1434
+ fetch the full detail of a single captured request.
1435
+
1436
+ When more records match than fit in one page, `nextPageURL` returns the
1437
+ relative URL for the next page.
1355
1438
 
1356
- Returns `{requests: []}` when the step has captured no debug requests.
1439
+ **Important:** Time parameters (`time_lte`, `time_gt`) must be epoch
1440
+ milliseconds (integers), not ISO 8601 strings. When `time_lte` is
1441
+ provided, `time_gt` is also required.
1442
+
1443
+ Requires the `manage:tool:logs` permission. Returns `{requests: []}` when
1444
+ the step has captured no debug requests.
1357
1445
  operationId: listToolStepRequests
1358
1446
  tags:
1359
1447
  - Tools
@@ -1372,14 +1460,91 @@ paths:
1372
1460
  in: path
1373
1461
  required: true
1374
1462
  description: |-
1375
- Export or import step id whose captured debug requests you want. Must be a
1376
- step ObjectId — reserved path segments such as `invocations`, `invoke`, and
1377
- `test` are not valid step ids.
1463
+ The step whose captured logs to list. Either the ObjectId of an
1464
+ export or import step defined directly in this tool's routers, or one
1465
+ of the virtual step ids `tool_input` / `tool_output` (logs captured
1466
+ via `input.debugUntil` / `output.debugUntil`). Steps nested inside a
1467
+ child tool are addressed on that child tool's id. Reserved path
1468
+ segments such as `invocations`, `invoke`, and `test` are not valid
1469
+ step ids.
1378
1470
  schema:
1379
1471
  type: string
1380
- format: objectId
1381
1472
  examples:
1382
1473
  - 67ee026136f4d1eeb529ad63
1474
+ - tool_input
1475
+ - tool_output
1476
+ - name: time_gt
1477
+ in: query
1478
+ required: false
1479
+ description: |-
1480
+ Lower bound of the time window (exclusive), as epoch milliseconds.
1481
+ Required when `time_lte` is provided.
1482
+ schema:
1483
+ type: integer
1484
+ format: int64
1485
+ examples:
1486
+ - 1776917000000
1487
+ - name: time_lte
1488
+ in: query
1489
+ required: false
1490
+ description: |-
1491
+ Upper bound of the time window (inclusive), as epoch milliseconds.
1492
+ Defaults to now if omitted. When provided, `time_gt` is also required.
1493
+ schema:
1494
+ type: integer
1495
+ format: int64
1496
+ examples:
1497
+ - 1776917346304
1498
+ - name: method
1499
+ in: query
1500
+ required: false
1501
+ description: |-
1502
+ Only return records with these HTTP methods. Repeat the parameter to
1503
+ filter on multiple values.
1504
+ style: form
1505
+ explode: true
1506
+ schema:
1507
+ type: array
1508
+ items:
1509
+ type: string
1510
+ examples:
1511
+ - - POST
1512
+ - GET
1513
+ - name: statusCode
1514
+ in: query
1515
+ required: false
1516
+ description: |-
1517
+ Only return records with these response status codes. Repeat the
1518
+ parameter to filter on multiple values.
1519
+ style: form
1520
+ explode: true
1521
+ schema:
1522
+ type: array
1523
+ items:
1524
+ type: string
1525
+ examples:
1526
+ - - '200'
1527
+ - '422'
1528
+ - name: stage
1529
+ in: query
1530
+ required: false
1531
+ description: |-
1532
+ Only return records for these processing stages. Repeat the parameter
1533
+ to filter on multiple values.
1534
+ style: form
1535
+ explode: true
1536
+ schema:
1537
+ type: array
1538
+ items:
1539
+ type: string
1540
+ - name: nextPageToken
1541
+ in: query
1542
+ required: false
1543
+ description: |-
1544
+ Continuation token for pagination. Do not construct this manually —
1545
+ follow the `nextPageURL` returned by the previous page instead.
1546
+ schema:
1547
+ type: string
1383
1548
  responses:
1384
1549
  '200':
1385
1550
  description: |-
@@ -1396,7 +1561,31 @@ paths:
1396
1561
  description: Captured debug request records.
1397
1562
  items:
1398
1563
  type: object
1564
+ description: Summary of one captured debug request.
1565
+ properties:
1566
+ key:
1567
+ type: string
1568
+ description: |-
1569
+ Identifier of the captured record; pass it to
1570
+ `GET /v1/tools/{_id}/{_stepId}/requests/{key}`.
1571
+ time:
1572
+ type: integer
1573
+ description: Capture time as epoch milliseconds.
1574
+ method:
1575
+ type: string
1576
+ description: HTTP method of the captured request.
1577
+ statusCode:
1578
+ type: string
1579
+ description: Response status code of the captured request.
1580
+ stage:
1581
+ type: string
1582
+ description: Processing stage the record was captured in.
1399
1583
  additionalProperties: true
1584
+ nextPageURL:
1585
+ type: string
1586
+ description: |-
1587
+ Relative URL of the next page. Present only when more
1588
+ records match than were returned.
1400
1589
  required:
1401
1590
  - requests
1402
1591
  examples:
@@ -1404,8 +1593,148 @@ paths:
1404
1593
  summary: No debug requests captured
1405
1594
  value:
1406
1595
  requests: []
1596
+ populated:
1597
+ summary: Captured debug requests for a tool step
1598
+ value:
1599
+ requests:
1600
+ - key: 5481201053696-a10af1ade8fe477a847771c1e3716e36-200-POST
1601
+ time: 1776917346304
1602
+ method: POST
1603
+ statusCode: '200'
1407
1604
  '401':
1408
1605
  $ref: '#/components/responses/401-unauthorized'
1606
+ '403':
1607
+ $ref: '#/components/responses/403-forbidden'
1608
+ '404':
1609
+ $ref: '#/components/responses/404-not-found'
1610
+ '422':
1611
+ description: 'Invalid time filter parameters. Error code: `invalid_or_missing_field`.'
1612
+ content:
1613
+ application/json:
1614
+ schema:
1615
+ $ref: '#/components/schemas/Error'
1616
+ examples:
1617
+ invalid_time:
1618
+ value:
1619
+ errors:
1620
+ - code: invalid_or_missing_field
1621
+ message: time_lte must be an epoch millisecond value, not an ISO string.
1622
+ missing_time_gt:
1623
+ value:
1624
+ errors:
1625
+ - code: invalid_or_missing_field
1626
+ message: 'Invalid or Missing Field: time_gt'
1627
+ delete:
1628
+ x-internal: false
1629
+ summary: Delete captured debug requests for a tool step
1630
+ description: |-
1631
+ Deletes captured debug request records for a specific step of a tool, by
1632
+ their `key` values from `GET /v1/tools/{_id}/{_stepId}/requests`. Between
1633
+ 1 and 1000 keys can be deleted per call.
1634
+
1635
+ The response lists the keys that were deleted and, separately, any keys
1636
+ that failed to delete along with the failure reason.
1637
+
1638
+ Requires the `manage:tool:logs:deletion` permission.
1639
+ operationId: deleteToolStepRequests
1640
+ tags:
1641
+ - Tools
1642
+ parameters:
1643
+ - name: _id
1644
+ in: path
1645
+ required: true
1646
+ description: The unique identifier of the tool.
1647
+ schema:
1648
+ type: string
1649
+ format: objectId
1650
+ x-celigo-refModel: tools
1651
+ examples:
1652
+ - 69d462d5b9c28ea0b7f82522
1653
+ - name: _stepId
1654
+ in: path
1655
+ required: true
1656
+ description: |-
1657
+ The step whose captured logs to delete. Either the ObjectId of an
1658
+ export or import step defined directly in this tool's routers, or one
1659
+ of the virtual step ids `tool_input` / `tool_output` (logs captured
1660
+ via `input.debugUntil` / `output.debugUntil`).
1661
+ schema:
1662
+ type: string
1663
+ examples:
1664
+ - 67ee026136f4d1eeb529ad63
1665
+ - tool_input
1666
+ - tool_output
1667
+ requestBody:
1668
+ required: true
1669
+ content:
1670
+ application/json:
1671
+ schema:
1672
+ type: object
1673
+ description: Keys of the captured debug requests to delete.
1674
+ properties:
1675
+ keys:
1676
+ type: array
1677
+ description: |-
1678
+ Keys of the records to delete, from the
1679
+ `GET /v1/tools/{_id}/{_stepId}/requests` listing.
1680
+ minItems: 1
1681
+ maxItems: 1000
1682
+ items:
1683
+ type: string
1684
+ required:
1685
+ - keys
1686
+ examples:
1687
+ default:
1688
+ summary: Delete two captured debug requests
1689
+ value:
1690
+ keys:
1691
+ - 5481201053696-a10af1ade8fe477a847771c1e3716e36-200-POST
1692
+ - 5481201048878-b21bf2bef9ff588b958882d2f4827f47-422-POST
1693
+ responses:
1694
+ '200':
1695
+ description: |-
1696
+ Deletion outcome. `deleted` lists the removed keys; `errors` lists
1697
+ keys that could not be removed with the failure reason.
1698
+ content:
1699
+ application/json:
1700
+ schema:
1701
+ type: object
1702
+ description: Deletion result envelope.
1703
+ properties:
1704
+ deleted:
1705
+ type: array
1706
+ description: Keys of the records that were deleted.
1707
+ items:
1708
+ type: string
1709
+ errors:
1710
+ type: array
1711
+ description: Records that failed to delete.
1712
+ items:
1713
+ type: object
1714
+ properties:
1715
+ key:
1716
+ type: string
1717
+ description: Key of the record that failed to delete.
1718
+ error:
1719
+ type: string
1720
+ description: Failure reason.
1721
+ required:
1722
+ - deleted
1723
+ - errors
1724
+ examples:
1725
+ default:
1726
+ summary: All requested records deleted
1727
+ value:
1728
+ deleted:
1729
+ - 5481201053696-a10af1ade8fe477a847771c1e3716e36-200-POST
1730
+ - 5481201048878-b21bf2bef9ff588b958882d2f4827f47-422-POST
1731
+ errors: []
1732
+ '400':
1733
+ $ref: '#/components/responses/400-bad-request'
1734
+ '401':
1735
+ $ref: '#/components/responses/401-unauthorized'
1736
+ '403':
1737
+ $ref: '#/components/responses/403-forbidden'
1409
1738
  '404':
1410
1739
  $ref: '#/components/responses/404-not-found'
1411
1740
  /v1/tools/{_id}/{_stepId}/requests/{key}:
@@ -1416,6 +1745,14 @@ paths:
1416
1745
  Returns the full detail of a single captured debug request for a tool
1417
1746
  step, identified by its `key`. Obtain the `key` from
1418
1747
  `GET /v1/tools/{_id}/{_stepId}/requests`.
1748
+
1749
+ The record carries the captured request/response payloads for the step,
1750
+ plus the `key`, record `id`, and capture `time`. For `tool_input`,
1751
+ `tool_output`, and ToolImport steps the stored body is the in-memory JSON
1752
+ record (not adaptor-masked). Router Import/Export bubbles keep existing
1753
+ adaptor masking.
1754
+
1755
+ Requires the `manage:tool:logs` permission.
1419
1756
  operationId: getToolStepRequest
1420
1757
  tags:
1421
1758
  - Tools
@@ -1434,14 +1771,19 @@ paths:
1434
1771
  in: path
1435
1772
  required: true
1436
1773
  description: |-
1437
- Export or import step id the captured request belongs to. Must be a step
1438
- ObjectId — reserved path segments such as `invocations`, `invoke`, and
1439
- `test` are not valid step ids.
1774
+ The step the captured request belongs to. Either the ObjectId of an
1775
+ export or import step defined directly in this tool's routers, or one
1776
+ of the virtual step ids `tool_input` / `tool_output` (logs captured
1777
+ via `input.debugUntil` / `output.debugUntil`). Steps nested inside a
1778
+ child tool are addressed on that child tool's id. Reserved path
1779
+ segments such as `invocations`, `invoke`, and `test` are not valid
1780
+ step ids.
1440
1781
  schema:
1441
1782
  type: string
1442
- format: objectId
1443
1783
  examples:
1444
1784
  - 67ee026136f4d1eeb529ad63
1785
+ - tool_input
1786
+ - tool_output
1445
1787
  - name: key
1446
1788
  in: path
1447
1789
  required: true
@@ -1457,18 +1799,131 @@ paths:
1457
1799
  application/json:
1458
1800
  schema:
1459
1801
  type: object
1460
- description: A single captured debug request record.
1802
+ description: |-
1803
+ A single captured debug request record, including the captured
1804
+ request/response payloads.
1805
+ properties:
1806
+ key:
1807
+ type: string
1808
+ description: Echoes the `key` path parameter.
1809
+ id:
1810
+ type: string
1811
+ description: Internal storage id parsed from the log filename.
1812
+ time:
1813
+ type: integer
1814
+ format: int64
1815
+ description: Epoch milliseconds when this pair was stored.
1816
+ request:
1817
+ type: object
1818
+ description: |-
1819
+ The captured request envelope. Synthetic `tool_input` /
1820
+ `tool_output` / ToolImport logs store the in-memory JSON
1821
+ record; router Import/Export bubbles store the adaptor HTTP
1822
+ request.
1823
+ properties:
1824
+ method:
1825
+ type: string
1826
+ description: HTTP method (`GET`, `POST`, …). Synthetic captures use `POST`.
1827
+ examples:
1828
+ - POST
1829
+ url:
1830
+ type: string
1831
+ description: |-
1832
+ Fully-resolved URL sent. Present on adaptor HTTP
1833
+ captures; omitted on synthetic `tool_input` /
1834
+ `tool_output` / ToolImport logs.
1835
+ headers:
1836
+ type: object
1837
+ description: |-
1838
+ Headers sent with the request. Adaptor HTTP captures
1839
+ mask credentials; synthetic captures have no adaptor
1840
+ masking.
1841
+ additionalProperties: true
1842
+ body:
1843
+ description: |-
1844
+ Captured request payload. Object for synthetic
1845
+ `tool_input` / `tool_output` / ToolImport logs (the
1846
+ in-memory JSON record). String for adaptor HTTP
1847
+ router-bubble captures.
1848
+ response:
1849
+ type: object
1850
+ description: The captured response envelope.
1851
+ properties:
1852
+ statusCode:
1853
+ type: integer
1854
+ description: HTTP status code (`200` on success, `422` on schema/transform failure for synthetic captures).
1855
+ examples:
1856
+ - 200
1857
+ headers:
1858
+ type: object
1859
+ description: Response headers. Empty object on synthetic captures that did not issue HTTP.
1860
+ additionalProperties: true
1861
+ body:
1862
+ description: |-
1863
+ Captured response payload. Object for synthetic
1864
+ `tool_input` / `tool_output` / ToolImport logs. String
1865
+ for adaptor HTTP router-bubble captures.
1866
+ receivedAt:
1867
+ type: integer
1868
+ format: int64
1869
+ description: Epoch milliseconds when this pair was captured. Present on synthetic logs.
1870
+ context:
1871
+ type: object
1872
+ description: |-
1873
+ Run correlation for synthetic logs keyed by tool id. Present
1874
+ on `tool_input` / `tool_output` / ToolImport captures so the
1875
+ originating flow or job can be recovered; omitted on adaptor
1876
+ HTTP router-bubble logs.
1877
+ properties:
1878
+ _rootContainerId:
1879
+ type: string
1880
+ description: Owning flow, API, or tool id of the run that produced this capture.
1881
+ _jobId:
1882
+ type: string
1883
+ description: Job id of the run that produced this capture.
1461
1884
  additionalProperties: true
1462
1885
  examples:
1463
- default:
1464
- summary: One captured debug request
1886
+ adaptor_http:
1887
+ summary: Router-bubble HTTP capture
1888
+ value:
1889
+ key: 5481201053696-a10af1ade8fe477a847771c1e3716e36-200-POST
1890
+ id: a10af1ade8fe477a847771c1e3716e36
1891
+ time: 1776917346304
1892
+ request:
1893
+ method: POST
1894
+ url: https://httpbin.org/post
1895
+ headers:
1896
+ content-type: application/json
1897
+ body: '{"orderId":"SO-1042"}'
1898
+ response:
1899
+ statusCode: 200
1900
+ headers:
1901
+ content-type: application/json
1902
+ body: '{"ok":true}'
1903
+ tool_input:
1904
+ summary: Synthetic Tool Input capture
1465
1905
  value:
1466
- key: 6a2e23bbcf5b64ca6b93b774
1467
- method: POST
1468
- url: https://httpbin.org/post
1469
- statusCode: 200
1906
+ key: 5481201053696-b20bf2bde8fe477a847771c1e3716e36-200-POST
1907
+ id: b20bf2bde8fe477a847771c1e3716e36
1908
+ time: 1776917346304
1909
+ request:
1910
+ method: POST
1911
+ headers: {}
1912
+ body:
1913
+ customerId: CUST-1001
1914
+ response:
1915
+ statusCode: 200
1916
+ headers: {}
1917
+ receivedAt: 1776917346304
1918
+ body:
1919
+ customerId: CUST-1001
1920
+ validated: true
1921
+ context:
1922
+ _jobId: 69d462d5b9c28ea0b7f82533
1470
1923
  '401':
1471
1924
  $ref: '#/components/responses/401-unauthorized'
1925
+ '403':
1926
+ $ref: '#/components/responses/403-forbidden'
1472
1927
  '404':
1473
1928
  $ref: '#/components/responses/404-not-found'
1474
1929
  components:
@@ -3894,6 +4349,18 @@ components:
3894
4349
  format: email
3895
4350
  transform:
3896
4351
  $ref: '#/components/schemas/Transform'
4352
+ debugUntil:
4353
+ type: string
4354
+ format: date-time
4355
+ description: |
4356
+ Enables debug capture for the tool input stage until this timestamp.
4357
+ While it is in the future, invocations write input-stage
4358
+ request/response logs, listed at
4359
+ `GET /v1/tools/{_id}/tool_input/requests`. At most 1 hour in the
4360
+ future. A past timestamp (or omitting the field) stops capture.
4361
+ Arm/disarm with `PATCH /v1/tools/{_id}` path `/input/debugUntil`.
4362
+ examples:
4363
+ - '2026-08-25T12:30:00.000Z'
3897
4364
  mockInput:
3898
4365
  type: object
3899
4366
  description: |
@@ -4039,6 +4506,18 @@ components:
4039
4506
  examples:
4040
4507
  - postProcessOutput
4041
4508
  - validateOutput
4509
+ debugUntil:
4510
+ type: string
4511
+ format: date-time
4512
+ description: |
4513
+ Enables debug capture for the tool output stage until this timestamp.
4514
+ While it is in the future, invocations write output-stage
4515
+ request/response logs, listed at
4516
+ `GET /v1/tools/{_id}/tool_output/requests`. At most 1 hour in the
4517
+ future. A past timestamp (or omitting the field) stops capture.
4518
+ Arm/disarm with `PATCH /v1/tools/{_id}` path `/output/debugUntil`.
4519
+ examples:
4520
+ - '2026-08-25T12:30:00.000Z'
4042
4521
  mockInput:
4043
4522
  type: object
4044
4523
  description: |
@@ -4597,6 +5076,41 @@ components:
4597
5076
  - message
4598
5077
  required:
4599
5078
  - errors
5079
+ JsonPatchOperation:
5080
+ type: object
5081
+ description: A single JSON Patch operation (RFC 6902).
5082
+ required:
5083
+ - op
5084
+ - path
5085
+ properties:
5086
+ op:
5087
+ type: string
5088
+ enum:
5089
+ - replace
5090
+ - add
5091
+ - remove
5092
+ x-enumDescriptions:
5093
+ replace: Replaces the value at the specified path.
5094
+ add: Sets the value at the specified path.
5095
+ remove: Removes the value at the specified path.
5096
+ description: The operation to perform.
5097
+ path:
5098
+ type: string
5099
+ description: |-
5100
+ JSON Pointer (RFC 6901) to the field to patch. Only
5101
+ whitelisted paths are accepted — unlisted paths return
5102
+ `422` with `"<path> is not a whitelisted property"`.
5103
+ value:
5104
+ description: The new value to set. Required for `replace` and `add`, omit for `remove`.
5105
+ JsonPatchRequest:
5106
+ type: array
5107
+ description: |-
5108
+ A JSON Patch document (RFC 6902). Send an array of patch
5109
+ operations on whitelisted fields — all other paths are rejected
5110
+ with 422.
5111
+ minItems: 1
5112
+ items:
5113
+ $ref: '#/components/schemas/JsonPatchOperation'
4600
5114
  IAResourceResponse:
4601
5115
  type: object
4602
5116
  description: Integration app response fields for resources that are part of integration apps
@@ -18925,13 +19439,26 @@ components:
18925
19439
  are re-joined into the record's original shape — the object with its array, or the array of rows —
18926
19440
  carrying any response-mapping enrichment, and that re-joined record is what the next step
18927
19441
  receives. Not for locating records in an export's HTTP response; use
18928
- `http.response.resourcePath` for that.
19442
+ `http.response.resourcePath` for that. Applies to steps that receive a record — imports and
19443
+ lookups (an export referenced as a page processor of a flow, API, or Tool). A standalone export
19444
+ (a flow's page generator) has no incoming record, so the fields are saved but have no effect on
19445
+ the records it produces; to emit one record per array element from a standalone export, use a
19446
+ `hooks.preSavePage` script, or for a file-definition export make the repeating segment the
19447
+ record boundary in the definition's rules.
18929
19448
  x-celigo-ai-guidance:
18930
19449
  - |-
18931
19450
  Two modes, decided by the SHAPE of the record entering the step. Object record with a child
18932
19451
  array under a field → set ``pathToMany`` to that field. Array record (a ``groupByFields``
18933
19452
  export, a CSV/file group, a script that returns an array) → leave ``pathToMany`` blank; each
18934
19453
  element becomes one record. Live-verified 2026-09-10 on flows, Tools, and APIs.
19454
+ - |-
19455
+ Only imports and lookups (exports placed as page processors) fan out. On a standalone export
19456
+ (a flow's page generator) the API saves ``oneToMany`` / ``pathToMany`` and applies neither:
19457
+ the records reach the next step unchanged and no error is raised. Live-verified 2026-09-18 on
19458
+ a flow test run — an order record with three ``lines`` reached the import as ONE record with
19459
+ the setting on the export, and as THREE child records with the same setting on the import.
19460
+ Never propose these fields as the way to split a standalone export's records; that is
19461
+ ``hooks.preSavePage`` work (or, for a file definition, the definition's record boundary).
18935
19462
  - |-
18936
19463
  Blank ``pathToMany`` on an OBJECT record fails every record with code ``oneToMany_error``:
18937
19464
  "Failed to extract child records from oneToMany import data. Record at index 0 was not an
@@ -18961,8 +19488,14 @@ components:
18961
19488
  Path to the array of child records inside an object record when `oneToMany` is true, in dot
18962
19489
  notation (`items`, `lines.lineItems`). Leave blank when the incoming record is itself an array
18963
19490
  (grouped or row-based data) — each element is then a child record. A path that does not resolve
18964
- to an array processes zero records and reports success.
19491
+ to an array processes zero records and reports success. Read only on steps that receive a
19492
+ record (imports, lookup exports); on a standalone export it is saved and ignored — see `oneToMany`.
18965
19493
  x-celigo-ai-guidance:
19494
+ - |-
19495
+ Inert on a standalone export (a flow's page generator) exactly like ``oneToMany`` — the value
19496
+ is saved, the export's records reach the next step unchanged, and nothing errors
19497
+ (live-verified 2026-09-18). Splitting a standalone export's records into one per element is
19498
+ ``hooks.preSavePage`` work, or the file definition's record boundary; never this field.
18966
19499
  - |-
18967
19500
  Set this ONLY when the record entering the step is an object whose children sit under a field.
18968
19501
  On an array record (a ``groupByFields`` export, a CSV/file group, a script returning an array)
@@ -33428,9 +33961,9 @@ components:
33428
33961
  errors:
33429
33962
  - code: dependencies_not_deleted
33430
33963
  message: export 6902d88c10b42b2eaac9b2a1 must be deleted before you can delete connection 6398ddf316be761fb16a6523
33431
- 403-forbidden:
33964
+ 422-unprocessable-entity:
33432
33965
  description: |
33433
- Forbidden. The authenticated caller does not have permission to perform this operation.
33966
+ Unprocessable entity. The request was well-formed but was unable to be followed due to semantic errors.
33434
33967
  content:
33435
33968
  application/json:
33436
33969
  schema:
@@ -33439,11 +33972,11 @@ components:
33439
33972
  default:
33440
33973
  value:
33441
33974
  errors:
33442
- - code: forbidden
33443
- message: You do not have permission to access this resource.
33444
- 422-unprocessable-entity:
33975
+ - code: unprocessable_entity
33976
+ message: The request could not be processed due to a semantic error.
33977
+ 403-forbidden:
33445
33978
  description: |
33446
- Unprocessable entity. The request was well-formed but was unable to be followed due to semantic errors.
33979
+ Forbidden. The authenticated caller does not have permission to perform this operation.
33447
33980
  content:
33448
33981
  application/json:
33449
33982
  schema:
@@ -33452,7 +33985,7 @@ components:
33452
33985
  default:
33453
33986
  value:
33454
33987
  errors:
33455
- - code: unprocessable_entity
33456
- message: The request could not be processed due to a semantic error.
33988
+ - code: forbidden
33989
+ message: You do not have permission to access this resource.
33457
33990
  x-enable-proxy: true
33458
33991
  x-internal: false
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@celigo/api-specs",
3
- "version": "0.2.20",
3
+ "version": "0.2.22",
4
4
  "private": false,
5
5
  "description": "Public OpenAPI bundles (dist/) and the celigo-cli lint schema pack (schemas.json).",
6
6
  "keywords": [
package/schemas.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "provenance": {
3
3
  "repo": "celigo/integrator-api-specs",
4
- "iasCommit": "7ad7e60",
4
+ "iasCommit": "c51aefb",
5
5
  "generatedAt": "2026-09-18"
6
6
  },
7
7
  "roots": {
@@ -8414,6 +8414,7 @@
8414
8414
  "object"
8415
8415
  ],
8416
8416
  "p": {
8417
+ "debugUntil": 1,
8417
8418
  "description": 1,
8418
8419
  "mockInput": 10,
8419
8420
  "name": 1,
@@ -8503,6 +8504,7 @@
8503
8504
  "object"
8504
8505
  ],
8505
8506
  "p": {
8507
+ "debugUntil": 1,
8506
8508
  "description": 1,
8507
8509
  "hooks": 196,
8508
8510
  "lookups": 709,