@celigo/api-specs 0.2.38 → 0.2.40

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.
@@ -240,7 +240,11 @@ paths:
240
240
  openai:
241
241
  instructions: Validate that each record has a non-empty email field.
242
242
  model: gpt-4.1-mini-2025-04-14
243
- tools: []
243
+ pii:
244
+ entities: []
245
+ mask: false
246
+ moderation:
247
+ categories: []
244
248
  '401':
245
249
  $ref: '#/components/responses/401-unauthorized'
246
250
  '404':
@@ -578,14 +582,14 @@ components:
578
582
  description: URI that identifies the resource on the MCP server.
579
583
  examples:
580
584
  - resource://policies/data-retention
581
- AiAgentConfig:
585
+ GuardrailAiAgentConfig:
582
586
  type: object
583
587
  description: |
584
- AI Agent configuration used by both AiAgentImport and GuardrailImport (ai_agent type).
585
-
586
- Configures which AI provider and model to use, along with instructions, parameter
587
- tuning, output format, and available tools. Providers come in two families with
588
- two configuration formats:
588
+ LLM configuration for an `ai_agent` guardrail — which provider and model evaluate each
589
+ record, with instructions, parameter tuning, and output format. Guardrails never invoke
590
+ tools, so unlike an AI agent import no block here accepts a `tools` array; MCP `prompts`
591
+ and `resources` remain available. Providers come in two families with two configuration
592
+ formats:
589
593
 
590
594
  - **Built-in providers** — each has its own configuration block.
591
595
  - **openai**: OpenAI models (GPT-4.1, GPT-5, etc.). Configure via the `openai` object.
@@ -593,13 +597,19 @@ components:
593
597
  - **anthropic**: Anthropic Claude models via the LiteLLM proxy. Configure via `litellm` with overrides in `litellm._overrides.anthropic`.
594
598
  - **Catalog providers** — `mistral`, `xai`, `huggingface`, `deepseek`, `cohere`, `groq`. Added
595
599
  as catalog data rather than platform code, they share one generic flat format:
596
- `model`, `modelOptions`, `instructions`, `output`, and the `tools` / `prompts` /
597
- `resources` arrays directly on this object.
600
+ `model`, `modelOptions`, `instructions`, `output`, and the `prompts` / `resources`
601
+ arrays directly on this object.
598
602
 
599
603
  A `_connectionId` on the parent import selects bring-your-own-key (BYOK)
600
604
  credentials. Without one, built-in providers run on platform-managed
601
605
  credentials; catalog providers have no platform-managed credentials, so they
602
606
  save without a connection but cannot run until one is attached.
607
+ x-celigo-ai-guidance:
608
+ - |-
609
+ Do not send `tools` on any block. A non-empty array at `tools`, `openai.tools`,
610
+ `litellm._overrides.gemini.tools`, or `litellm._overrides.anthropic.tools` fails the
611
+ save with 422 `guardrail_tools_not_allowed` naming that path. Responses still echo
612
+ `openai.tools: []` on OpenAI guardrails; do not copy it back into a write.
603
613
  required:
604
614
  - provider
605
615
  properties:
@@ -636,7 +646,7 @@ components:
636
646
  generic flat format — `model` and `modelOptions` directly on this object,
637
647
  never an `openai` or `litellm` block.
638
648
  - |-
639
- Catalog providers are BYOK-only at run time: the agent saves without a
649
+ Catalog providers are BYOK-only at run time: the guardrail saves without a
640
650
  `_connectionId`, but its first run fails with 422 `invalid_request` ("No API
641
651
  key configured for provider …"). Always attach an HTTP connection to the
642
652
  vendor's API (token auth) when the provider is a catalog provider.
@@ -738,65 +748,10 @@ components:
738
748
  verbose:
739
749
  type: string
740
750
  description: Level of detail in the model's response, for models that expose it.
741
- tools:
742
- type: array
743
- description: |-
744
- Tools available to a catalog-provider agent (generic flat format). Entries mirror
745
- the built-in providers' tool entries: a Celigo Tool by `_toolId`, an MCP server by
746
- `_mcpConnectionId`, or a vendor web-search tool.
747
- items:
748
- type: object
749
- properties:
750
- type:
751
- type: string
752
- enum:
753
- - tool
754
- - mcp
755
- - web_search
756
- x-enumDescriptions:
757
- tool: Reference a reusable Celigo Tool resource.
758
- mcp: Connect to an MCP server for additional external tools.
759
- web_search: Search the web for real-time information, where the vendor's model supports it.
760
- description: Type of tool entry.
761
- tool:
762
- type: object
763
- description: Reference to a Celigo Tool resource, used when type is "tool".
764
- properties:
765
- _toolId:
766
- type: string
767
- format: objectId
768
- x-celigo-refModel: tools
769
- description: The Celigo Tool to call.
770
- mcp:
771
- type: object
772
- description: MCP server connection, used when type is "mcp".
773
- properties:
774
- _mcpConnectionId:
775
- type: string
776
- format: objectId
777
- x-celigo-refModel: connections
778
- description: Connection to the MCP server.
779
- allowedTools:
780
- type: array
781
- description: |-
782
- Specific tools to allow from the MCP server (all if omitted). Each entry
783
- is either a plain tool name or an object carrying display metadata.
784
- items:
785
- type:
786
- - string
787
- - object
788
- config:
789
- type: object
790
- additionalProperties: true
791
- description: Tool-specific options for vendor-native tools (for example web-search settings).
792
- x-celigo-ai-guidance:
793
- - |-
794
- References are checked on save: an unknown `_toolId` or `_mcpConnectionId`
795
- fails with 422 `invalid_ref` naming the array index.
796
751
  prompts:
797
752
  type: array
798
753
  description: |-
799
- MCP prompt entries available to a catalog-provider agent (generic flat format).
754
+ MCP prompt entries available to a catalog-provider guardrail (generic flat format).
800
755
  Each entry references one MCP connection and the prompt names allowed from it.
801
756
  items:
802
757
  type: object
@@ -818,7 +773,7 @@ components:
818
773
  description: Connection to the MCP server that exposes the prompts.
819
774
  allowedPrompts:
820
775
  type: array
821
- description: Prompt names the agent may fetch from the server.
776
+ description: Prompt names the model may fetch from the server.
822
777
  items:
823
778
  type: string
824
779
  x-celigo-ai-guidance:
@@ -839,7 +794,7 @@ components:
839
794
  type: string
840
795
  maxLength: 1000000
841
796
  description: |
842
- System prompt that defines the AI agent's behavior, goals, and constraints.
797
+ System prompt that defines the check's behavior, goals, and constraints.
843
798
  examples:
844
799
  - You are a data validation agent. Check each record for completeness.
845
800
  x-celigo-ui-override: Required by the AI agent configuration form (the model's system prompt). Encoded here to mirror the form so builders produce connectable configurations.
@@ -858,7 +813,7 @@ components:
858
813
  - |-
859
814
  With platform-managed credentials (no `_connectionId` on the parent
860
815
  import), the model must be one the platform hosts. The save does not
861
- check this — an unlisted model saves, and the agent's first run fails
816
+ check this — an unlisted model saves, and the guardrail's first run fails
862
817
  with 422 `invalid_model`, whose message lists the hosted models. A
863
818
  BYOK connection bypasses the hosted list and the model string is
864
819
  passed through to the provider as-is.
@@ -880,13 +835,15 @@ components:
880
835
  - medium
881
836
  - high
882
837
  - xhigh
838
+ - max
883
839
  x-enumDescriptions:
884
840
  none: No additional reasoning effort.
885
841
  minimal: Least reasoning effort for simple, straightforward tasks.
886
842
  low: Light reasoning for moderately simple tasks.
887
843
  medium: Balanced reasoning effort for typical tasks.
888
- high: Maximum reasoning effort for complex, multi-step tasks.
889
- xhigh: Highest reasoning effort for the most demanding, multi-step tasks.
844
+ high: Extensive reasoning effort for complex, multi-step tasks.
845
+ xhigh: Extended reasoning effort beyond high for demanding tasks.
846
+ max: Highest available reasoning effort.
890
847
  description: How much reasoning effort the model should invest
891
848
  x-celigo-ai-guidance:
892
849
  - |-
@@ -928,8 +885,7 @@ components:
928
885
  type: number
929
886
  minimum: 100
930
887
  maximum: 128000
931
- default: 5000
932
- description: Maximum number of tokens in the model's response (server default observed live on create)
888
+ description: Maximum number of tokens in the model's response. Unlike an AI agent import, a guardrail does not receive a server-written value when this is omitted.
933
889
  serviceTier:
934
890
  type: string
935
891
  enum:
@@ -940,7 +896,6 @@ components:
940
896
  auto: Let OpenAI automatically select the appropriate service tier.
941
897
  default: Standard service tier with normal rate limits and latency.
942
898
  priority: Premium tier with higher rate limits and lower latency at increased cost.
943
- default: default
944
899
  description: |-
945
900
  OpenAI service tier. "priority" provides higher rate limits and
946
901
  lower latency at increased cost.
@@ -968,7 +923,6 @@ components:
968
923
  text: Free-form text response from the model.
969
924
  json_schema: Structured JSON output conforming to a defined schema.
970
925
  blob: Binary data output for non-text content.
971
- default: text
972
926
  description: Output format type.
973
927
  schemaMode:
974
928
  type: string
@@ -988,7 +942,6 @@ components:
988
942
  x-celigo-ui-override: Required by the AI agent form when output format type is json_schema. Encoded here to mirror the form so builders produce connectable configurations.
989
943
  strict:
990
944
  type: boolean
991
- default: false
992
945
  description: When true, enforces strict schema validation on output.
993
946
  x-celigo-ai-guidance:
994
947
  - Whether to enforce strict schema validation on output
@@ -1027,6 +980,13 @@ components:
1027
980
  additionalproperties:
1028
981
  type: boolean
1029
982
  description: When true, the structured output may include properties beyond those defined in `properties`.
983
+ schema:
984
+ type: object
985
+ readOnly: true
986
+ additionalProperties: true
987
+ description: |-
988
+ Server-written copy of `jsonSchema`, present in responses once `jsonSchema`
989
+ is set. Send `jsonSchema`, not this field.
1030
990
  if:
1031
991
  properties:
1032
992
  type:
@@ -1047,7 +1007,6 @@ components:
1047
1007
  low: Minimal detail in the model's response.
1048
1008
  medium: Moderate detail in the model's response, the default level.
1049
1009
  high: Maximum detail and verbosity in the model's response.
1050
- default: medium
1051
1010
  description: Level of detail in the model's response
1052
1011
  x-celigo-ai-guidance:
1053
1012
  - |-
@@ -1056,165 +1015,11 @@ components:
1056
1015
  `gpt-4.1-nano`) accept only `medium` (the no-op default) — `low` and `high` are
1057
1016
  rejected by the provider at runtime.
1058
1017
  Omit the field entirely on non-GPT-5 models rather than relying on the default.
1059
- tools:
1060
- type: array
1061
- description: |
1062
- Tools available to the AI agent during processing.
1063
- items:
1064
- type: object
1065
- properties:
1066
- type:
1067
- type: string
1068
- enum:
1069
- - web_search
1070
- - mcp
1071
- - image_generation
1072
- - tool
1073
- x-enumDescriptions:
1074
- web_search: Search the web for real-time information.
1075
- mcp: Connect to an MCP server for additional external tools.
1076
- image_generation: Generate images using an AI image model.
1077
- tool: Reference a reusable Celigo Tool resource.
1078
- description: Type of tool.
1079
- webSearch:
1080
- type: object
1081
- description: Web search configuration (empty object to enable)
1082
- imageGeneration:
1083
- type: object
1084
- description: Image generation configuration
1085
- properties:
1086
- background:
1087
- type: string
1088
- description: Controls whether generated images have a transparent or opaque background; use transparent only with output formats that support it (png, webp).
1089
- enum:
1090
- - transparent
1091
- - opaque
1092
- x-enumDescriptions:
1093
- transparent: Generate an image with a transparent background.
1094
- opaque: Generate an image with a solid, non-transparent background.
1095
- quality:
1096
- type: string
1097
- description: Rendering quality of generated images, trading detail for generation speed and file size.
1098
- enum:
1099
- - low
1100
- - medium
1101
- - high
1102
- x-enumDescriptions:
1103
- low: Lower quality for faster generation and smaller file size.
1104
- medium: Balanced quality and generation speed.
1105
- high: Highest quality output with more detail.
1106
- size:
1107
- type: string
1108
- description: Pixel dimensions of generated images; choose square, portrait, or landscape to match the intended use.
1109
- enum:
1110
- - 1024x1024
1111
- - 1024x1536
1112
- - 1536x1024
1113
- x-enumDescriptions:
1114
- 1024x1024: Square image at 1024 by 1024 pixels.
1115
- 1024x1536: Portrait image at 1024 by 1536 pixels.
1116
- 1536x1024: Landscape image at 1536 by 1024 pixels.
1117
- outputFormat:
1118
- type: string
1119
- description: File format of generated images; use png or webp when transparency is needed.
1120
- enum:
1121
- - png
1122
- - webp
1123
- - jpeg
1124
- x-enumDescriptions:
1125
- png: PNG format with lossless compression, supports transparency.
1126
- webp: WebP format with efficient compression for web use.
1127
- jpeg: JPEG format with lossy compression for smaller file sizes.
1128
- mcp:
1129
- type: object
1130
- description: MCP server tool configuration
1131
- properties:
1132
- _mcpConnectionId:
1133
- type: string
1134
- format: objectId
1135
- x-celigo-refModel: connections
1136
- description: Connection to the MCP server
1137
- allowedTools:
1138
- type: array
1139
- description: |-
1140
- Specific tools to allow from the MCP server (all if
1141
- omitted). Each entry is either a plain tool name (legacy
1142
- form) or an object carrying display metadata.
1143
- items:
1144
- type:
1145
- - string
1146
- - object
1147
- properties:
1148
- name:
1149
- type: string
1150
- maxLength: 256
1151
- description: Tool name as exposed by the MCP server.
1152
- title:
1153
- type: string
1154
- maxLength: 300
1155
- description: Display title shown for the tool.
1156
- description:
1157
- type: string
1158
- maxLength: 1000
1159
- description: Display description shown for the tool.
1160
- required:
1161
- - name
1162
- x-celigo-ai-guidance:
1163
- - |-
1164
- Object entries accept only name/title/description — any
1165
- other key fails validation with "unknown field(s)", and
1166
- an object without a non-empty name fails with a
1167
- missing-required-field error. String entries are the
1168
- legacy form and stay valid.
1169
- allowedPrompts:
1170
- type: array
1171
- description: Specific prompts to allow from the MCP server (used for MCP prompt entries; all if omitted).
1172
- items:
1173
- type: string
1174
- tool:
1175
- type: object
1176
- description: |
1177
- Reference to a Celigo Tool resource.
1178
- properties:
1179
- _toolId:
1180
- type: string
1181
- format: objectId
1182
- x-celigo-refModel: tools
1183
- description: Reference to the Tool resource
1184
- overrides:
1185
- type: object
1186
- description: Per-agent overrides for the tool's internal resources
1187
- properties:
1188
- connections:
1189
- type: array
1190
- description: |
1191
- Remaps the tool's abstract connections for this agent. Each entry pairs
1192
- the tool's abstract connection placeholder (`_abstractId`) with the
1193
- concrete connection (`_id`) to use for this agent; entries without
1194
- `_id` keep the tool's own default connection.
1195
- items:
1196
- type:
1197
- - object
1198
- - 'null'
1199
- required:
1200
- - _abstractId
1201
- properties:
1202
- _abstractId:
1203
- type: string
1204
- format: objectId
1205
- description: The tool's abstract connection placeholder being overridden.
1206
- _id:
1207
- type: string
1208
- format: objectId
1209
- x-celigo-refModel: connections
1210
- description: Concrete connection to use in place of the abstract placeholder.
1211
1018
  prompts:
1212
1019
  type: array
1213
- description: |
1214
- MCP prompt entries available to the agent. Each item references one MCP connection
1215
- and the prompt names allowed from it. Configured alongside `tools` in the form but
1216
- stored separately; an entry's `allowedPrompts` is what distinguishes a prompt entry
1217
- from an MCP tool entry (which carries `allowedTools`).
1020
+ description: |-
1021
+ MCP prompt entries available to the guardrail's model. Each item references one
1022
+ MCP connection and the prompt names allowed from it.
1218
1023
  items:
1219
1024
  type: object
1220
1025
  properties:
@@ -1269,7 +1074,7 @@ components:
1269
1074
  With platform-managed credentials (no `_connectionId` on the parent
1270
1075
  import), the model must be one the platform hosts for the provider —
1271
1076
  Gemini and Anthropic Claude both have a hosted list. The save does not
1272
- check this — an unlisted model saves, and the agent's first run fails
1077
+ check this — an unlisted model saves, and the guardrail's first run fails
1273
1078
  with 422 `invalid_model`, whose message lists the hosted models.
1274
1079
  temperature:
1275
1080
  type: number
@@ -1284,7 +1089,6 @@ components:
1284
1089
  type: number
1285
1090
  minimum: 100
1286
1091
  maximum: 128000
1287
- default: 5000
1288
1092
  description: Maximum number of tokens in the response
1289
1093
  topP:
1290
1094
  type: number
@@ -1314,7 +1118,6 @@ components:
1314
1118
  text: Free-form text response from the model.
1315
1119
  json_schema: Structured JSON output conforming to a defined schema.
1316
1120
  blob: Binary data output for non-text content.
1317
- default: text
1318
1121
  schemaMode:
1319
1122
  type: string
1320
1123
  enum:
@@ -1334,7 +1137,6 @@ components:
1334
1137
  strict:
1335
1138
  type: boolean
1336
1139
  description: When true, enforces strict schema validation on output.
1337
- default: false
1338
1140
  jsonSchema:
1339
1141
  type: object
1340
1142
  description: JSON Schema for structured output. Required when `responseFormat.type` is "json_schema".
@@ -1397,124 +1199,11 @@ components:
1397
1199
  System instruction for Gemini models. Equivalent to OpenAI's `instructions`.
1398
1200
  Maximum 1,000,000 characters.
1399
1201
  x-celigo-ui-override: Required by the AI agent configuration form (the model's system prompt, the Gemini equivalent of `instructions`). Encoded here to mirror the form so builders produce connectable configurations.
1400
- tools:
1401
- type: array
1402
- description: Gemini-specific tools
1403
- items:
1404
- type: object
1405
- properties:
1406
- type:
1407
- type: string
1408
- enum:
1409
- - googleSearch
1410
- - urlContext
1411
- - fileSearch
1412
- - mcp
1413
- - tool
1414
- x-enumDescriptions:
1415
- googleSearch: Use Google Search for real-time information grounding.
1416
- urlContext: Retrieve and use content from specified URLs.
1417
- fileSearch: Search through previously uploaded files.
1418
- mcp: Connect to an MCP server for additional external tools.
1419
- tool: Reference a reusable Celigo Tool resource.
1420
- description: Type of Gemini tool.
1421
- googleSearch:
1422
- type: object
1423
- description: Google Search configuration (empty object to enable)
1424
- urlContext:
1425
- type: object
1426
- description: URL context configuration (empty object to enable)
1427
- fileSearch:
1428
- type: object
1429
- description: File search configuration, used when type is "fileSearch".
1430
- properties:
1431
- fileSearchStoreNames:
1432
- type: array
1433
- description: Names of the file search stores the model can query.
1434
- items:
1435
- type: string
1436
- mcp:
1437
- type: object
1438
- description: MCP server tool configuration, used when type is "mcp".
1439
- properties:
1440
- _mcpConnectionId:
1441
- type: string
1442
- format: objectId
1443
- x-celigo-refModel: connections
1444
- description: Connection to the MCP server.
1445
- allowedTools:
1446
- type: array
1447
- description: |-
1448
- Specific tools to allow from the MCP server (all if
1449
- omitted). Each entry is either a plain tool name
1450
- (legacy form) or an object carrying display metadata
1451
- — same contract as the OpenAI `allowedTools`.
1452
- items:
1453
- type:
1454
- - string
1455
- - object
1456
- properties:
1457
- name:
1458
- type: string
1459
- maxLength: 256
1460
- description: Tool name as exposed by the MCP server.
1461
- title:
1462
- type: string
1463
- maxLength: 300
1464
- description: Display title shown for the tool.
1465
- description:
1466
- type: string
1467
- maxLength: 1000
1468
- description: Display description shown for the tool.
1469
- required:
1470
- - name
1471
- allowedPrompts:
1472
- type: array
1473
- description: Specific prompts to allow from the MCP server (used for MCP prompt entries; all if omitted).
1474
- items:
1475
- type: string
1476
- tool:
1477
- type: object
1478
- description: Reference to a Celigo Tool resource, used when type is "tool".
1479
- properties:
1480
- _toolId:
1481
- type: string
1482
- format: objectId
1483
- x-celigo-refModel: tools
1484
- description: Reference to the Tool resource.
1485
- overrides:
1486
- type: object
1487
- description: Per-agent overrides for the tool's internal resources.
1488
- properties:
1489
- connections:
1490
- type: array
1491
- description: |
1492
- Remaps the tool's abstract connections for this agent. Each entry
1493
- pairs the tool's abstract connection placeholder (`_abstractId`)
1494
- with the concrete connection (`_id`) to use for this agent;
1495
- entries without `_id` keep the tool's own default connection.
1496
- items:
1497
- type:
1498
- - object
1499
- - 'null'
1500
- required:
1501
- - _abstractId
1502
- properties:
1503
- _abstractId:
1504
- type: string
1505
- format: objectId
1506
- description: The tool's abstract connection placeholder being overridden.
1507
- _id:
1508
- type: string
1509
- format: objectId
1510
- x-celigo-refModel: connections
1511
- description: Concrete connection to use in place of the abstract placeholder.
1512
1202
  prompts:
1513
1203
  type: array
1514
- description: |
1515
- MCP prompt entries available to the Gemini agent. Each item references one
1516
- MCP connection and the prompt names allowed from it. The presence of
1517
- `allowedPrompts` distinguishes a prompt entry from an MCP tool entry.
1204
+ description: |-
1205
+ MCP prompt entries available to the Gemini model. Each item references one
1206
+ MCP connection and the prompt names allowed from it.
1518
1207
  items:
1519
1208
  type: object
1520
1209
  properties:
@@ -1557,8 +1246,6 @@ components:
1557
1246
  x-enumDescriptions:
1558
1247
  text: Generate text content in the response.
1559
1248
  image: Generate image content in the response.
1560
- default:
1561
- - text
1562
1249
  topK:
1563
1250
  type: number
1564
1251
  description: Top-K sampling parameter for Gemini
@@ -1682,7 +1369,6 @@ components:
1682
1369
  enabled: Turn on extended thinking with an explicit token budget.
1683
1370
  disabled: Turn off extended thinking.
1684
1371
  adaptive: Let the model decide how much to think based on task complexity.
1685
- default: disabled
1686
1372
  description: Extended thinking mode.
1687
1373
  budgetTokens:
1688
1374
  type: number
@@ -1699,7 +1385,6 @@ components:
1699
1385
  x-enumDescriptions:
1700
1386
  summarized: Include a summarized view of the model's thinking in the response.
1701
1387
  omitted: Exclude the model's thinking from the response.
1702
- default: summarized
1703
1388
  description: How thinking output is surfaced in the response.
1704
1389
  effort:
1705
1390
  type: string
@@ -1735,140 +1420,12 @@ components:
1735
1420
  x-enumDescriptions:
1736
1421
  auto: Let Anthropic select the appropriate service tier.
1737
1422
  standard_only: Restrict processing to the standard service tier.
1738
- default: auto
1739
1423
  description: Anthropic service tier for the request.
1740
- tools:
1741
- type: array
1742
- description: Claude-specific tools.
1743
- items:
1744
- type: object
1745
- properties:
1746
- type:
1747
- type: string
1748
- enum:
1749
- - tool
1750
- - mcp
1751
- - webSearch
1752
- x-enumDescriptions:
1753
- tool: Reference a reusable Celigo Tool resource.
1754
- mcp: Connect to an MCP server for additional external tools.
1755
- webSearch: Search the web for real-time information.
1756
- description: Type of Claude tool.
1757
- tool:
1758
- type: object
1759
- description: Reference to a Celigo Tool resource, used when type is "tool".
1760
- properties:
1761
- _toolId:
1762
- type: string
1763
- format: objectId
1764
- x-celigo-refModel: tools
1765
- description: Reference to the Tool resource.
1766
- overrides:
1767
- type: object
1768
- description: Per-agent overrides for the tool's internal resources.
1769
- properties:
1770
- connections:
1771
- type: array
1772
- description: |
1773
- Remaps the tool's abstract connections for this agent. Each entry
1774
- pairs the tool's abstract connection placeholder (`_abstractId`)
1775
- with the concrete connection (`_id`) to use for this agent;
1776
- entries without `_id` keep the tool's own default connection.
1777
- items:
1778
- type:
1779
- - object
1780
- - 'null'
1781
- required:
1782
- - _abstractId
1783
- properties:
1784
- _abstractId:
1785
- type: string
1786
- format: objectId
1787
- description: The tool's abstract connection placeholder being overridden.
1788
- _id:
1789
- type: string
1790
- format: objectId
1791
- x-celigo-refModel: connections
1792
- description: Concrete connection to use in place of the abstract placeholder.
1793
- mcp:
1794
- type: object
1795
- description: MCP server tool configuration, used when type is "mcp".
1796
- properties:
1797
- _mcpConnectionId:
1798
- type: string
1799
- format: objectId
1800
- x-celigo-refModel: connections
1801
- description: Connection to the MCP server.
1802
- allowedTools:
1803
- type: array
1804
- description: Specific tools to allow from the MCP server (all if omitted).
1805
- items:
1806
- type: string
1807
- webSearch:
1808
- type: object
1809
- description: Web search configuration, used when type is "webSearch".
1810
- x-celigo-ai-guidance:
1811
- - |-
1812
- `allowedDomains` and `blockedDomains` are mutually exclusive — set at most
1813
- one. Sending both fails with 422 `invalid_hosted_tool`.
1814
- - |-
1815
- When `userLocation` is present, set at least one of `city`, `country`,
1816
- `region`, or `timezone`; an empty `userLocation` fails with 422
1817
- `missing_required_field`.
1818
- properties:
1819
- version:
1820
- type: string
1821
- pattern: ^\d{8}$
1822
- description: |-
1823
- Anthropic web search tool version (YYYYMMDD). Selects the tool version sent
1824
- on the wire; unsupported versions surface as an Anthropic 400.
1825
- examples:
1826
- - '20250305'
1827
- allowedDomains:
1828
- type: array
1829
- description: Domains the search may return results from. Mutually exclusive with `blockedDomains`.
1830
- items:
1831
- type: string
1832
- blockedDomains:
1833
- type: array
1834
- description: Domains to exclude from search results. Mutually exclusive with `allowedDomains`.
1835
- items:
1836
- type: string
1837
- userLocation:
1838
- type: object
1839
- description: |-
1840
- Approximate user location used to localize search results. When present, at
1841
- least one of `city`, `country`, `region`, or `timezone` must be set.
1842
- properties:
1843
- type:
1844
- type: string
1845
- enum:
1846
- - approximate
1847
- x-enumDescriptions:
1848
- approximate: Localize results to an approximate user location.
1849
- description: Location type. Always "approximate".
1850
- city:
1851
- type: string
1852
- maxLength: 256
1853
- description: City name for localizing search results.
1854
- country:
1855
- type: string
1856
- maxLength: 8
1857
- description: ISO 3166-1 alpha-2 country code for localizing search results.
1858
- region:
1859
- type: string
1860
- maxLength: 256
1861
- description: Region or state for localizing search results.
1862
- timezone:
1863
- type: string
1864
- maxLength: 64
1865
- description: IANA timezone for localizing search results.
1866
1424
  prompts:
1867
1425
  type: array
1868
- description: |
1869
- MCP prompt entries available to the Claude agent. Each item references one MCP
1870
- connection and the prompt names allowed from it. The presence of `allowedPrompts`
1871
- distinguishes a prompt entry from an MCP tool entry.
1426
+ description: |-
1427
+ MCP prompt entries available to the Claude model. Each item references one
1428
+ MCP connection and the prompt names allowed from it.
1872
1429
  items:
1873
1430
  type: object
1874
1431
  properties:
@@ -1944,49 +1501,24 @@ components:
1944
1501
  GuardrailConfig:
1945
1502
  type: object
1946
1503
  description: |-
1947
- Configuration for GuardrailImport adaptor type.
1948
-
1949
- Guardrails evaluate data flowing through integrations for safety and
1950
- compliance. The `type` field selects which check to apply, and the
1951
- corresponding sub-object (`aiAgent`, `pii`, or `moderation`) provides
1952
- the configuration.
1953
-
1954
- A `_connectionId` on the parent import is only needed for BYOK
1955
- `ai_agent` guardrails. In responses the server echoes the active type's
1956
- sub-object and applies the `confidenceThreshold` default; it also
1957
- returns inactive sibling sub-objects (e.g. `moderation: {categories: []}`
1958
- on a `pii` guardrail, or a populated `pii` left over from a type switch),
1959
- but only the active type's sub-object is meaningful. Legacy documents
1960
- may carry a server-written default `aiAgent` stub on `pii`/`moderation`
1961
- guardrails; current servers strip the inactive `aiAgent` on write.
1504
+ Selects the check a guardrail applies and carries its settings. `type` picks the check
1505
+ and the matching sub-object (`pii`, `moderation`, or `aiAgent`) configures it.
1506
+ Responses echo the active sub-object with `confidenceThreshold` defaulted and also
1507
+ return the inactive `pii` / `moderation` siblings as empty stubs
1508
+ (`pii: {entities: [], mask: false}`, `moderation: {categories: []}`) — only the active
1509
+ type's sub-object is meaningful. Guardrails created before the AI-agent stub was
1510
+ stripped on write may still return an inert `aiAgent` on `pii` / `moderation` guardrails.
1962
1511
  x-celigo-ai-guidance:
1963
1512
  - |-
1964
- Guardrails are safety and compliance checks that can be applied
1965
- to data flowing through integrations. Three mutually-exclusive
1966
- types are supported — see `type` below for the full decision
1967
- rule on which to pick:
1968
-
1969
- - **pii**: Detect (and optionally mask) personally identifiable
1970
- information. Local deterministic classifier; fixed enum of
1971
- entity types (`pii.entities`).
1972
- - **moderation**: Detect harmful / inappropriate / policy-
1973
- violating CONTENT. Local deterministic classifier; fixed enum
1974
- of categories (`moderation.categories` — `sexual`, `hate`,
1975
- `harassment`, `self_harm`, `violence`, `illicit`, etc.). Use
1976
- category names exactly as listed in the enum — e.g. `hate`
1977
- (not "hate speech"), `violence` (not "violent content"). Map
1978
- natural-language synonyms ("explicit" → `sexual`, "toxic" →
1979
- `harassment`, etc.) to the closest enum value rather than
1980
- falling back to `ai_agent`.
1981
- - **ai_agent**: LLM-evaluated judgement against custom
1982
- instructions. Catch-all for intents that don't fit `pii` or
1983
- `moderation` — domain-specific compliance, business-policy
1984
- checks, data-quality assertions, etc. Pick this LAST, not as
1985
- the default.
1513
+ Pick exactly one type. Prefer the deterministic local classifiers (`pii`, then
1514
+ `moderation`) whenever the brief's intent fits; use `ai_agent` only for custom
1515
+ judgement that has no `pii.entities` / `moderation.categories` analogue — the full
1516
+ decision rule is on `type`.
1986
1517
  - |-
1987
- Prefer the cheaper / more deterministic types (`pii` > `moderation` >
1988
- `ai_agent`) whenever the brief's intent fits.
1989
- - Guardrail imports do not require a `_connectionId` (unless using BYOK for `ai_agent` type).
1518
+ Guardrails never invoke tools. A non-empty `tools` array anywhere under `aiAgent`
1519
+ (`aiAgent.tools`, `aiAgent.openai.tools`, `aiAgent.litellm._overrides.gemini.tools`,
1520
+ `aiAgent.litellm._overrides.anthropic.tools`) fails the save with 422
1521
+ `guardrail_tools_not_allowed`; MCP `prompts` and `resources` are still accepted.
1990
1522
  properties:
1991
1523
  type:
1992
1524
  type: string
@@ -2098,9 +1630,10 @@ components:
2098
1630
  aiAgent:
2099
1631
  type: object
2100
1632
  description: |-
2101
- AI agent check configuration; set when `type` is `ai_agent`. On
2102
- `pii`/`moderation` guardrails a legacy server-written stub may
2103
- appear here — it is inert, and current servers strip it on write.
1633
+ LLM configuration for the check; set when `type` is `ai_agent` and validated
1634
+ against `GuardrailAiAgentConfig`. On `pii` / `moderation` guardrails a legacy
1635
+ server-written stub may appear here — it is inert, and current servers strip it on
1636
+ write.
2104
1637
  pii:
2105
1638
  type: object
2106
1639
  required:
@@ -2320,7 +1853,7 @@ components:
2320
1853
  - aiAgent
2321
1854
  properties:
2322
1855
  aiAgent:
2323
- $ref: '#/components/schemas/AiAgentConfig'
1856
+ $ref: '#/components/schemas/GuardrailAiAgentConfig'
2324
1857
  MappingField:
2325
1858
  type: object
2326
1859
  description: One Mapper 1.0 field-mapping entry.
@@ -2709,6 +2242,14 @@ components:
2709
2242
  description: |-
2710
2243
  Configuration for a guardrail import. `_connectionId` is only
2711
2244
  required for BYOK `ai_agent` guardrails.
2245
+ x-celigo-ai-guidance:
2246
+ - |-
2247
+ Guardrails evaluate structured records only. Do not send the import-level `blob` or
2248
+ `blobKeyPath` fields — either one fails the save with 422 `not_supported`
2249
+ ("Field "blob" is not supported for this import type").
2250
+ - |-
2251
+ Do not put a `tools` array anywhere under `guardrail.aiAgent` — a non-empty array on
2252
+ any provider block fails the save with 422 `guardrail_tools_not_allowed`.
2712
2253
  properties:
2713
2254
  name:
2714
2255
  type: string
@@ -2852,6 +2393,13 @@ components:
2852
2393
  description: Display name of the dependent resource.
2853
2394
  examples:
2854
2395
  - Import Orders to NetSuite
2396
+ type:
2397
+ type: string
2398
+ description: |-
2399
+ Sub-type of the dependent resource when its collection distinguishes one, such as
2400
+ `stream` for a listener export. Only present for resource types that carry a `type`.
2401
+ examples:
2402
+ - stream
2855
2403
  paths:
2856
2404
  type: array
2857
2405
  description: |-