@lunnoa/client 1.0.0 → 1.1.0

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/react.d.ts CHANGED
@@ -227,6 +227,8 @@ interface components {
227
227
  SKILLS: boolean;
228
228
  /** @description Whether the hexagonal agent builder canvas UI is enabled. */
229
229
  AGENT_BUILDER_CANVAS: boolean;
230
+ /** @description Whether the Solution Designer UI is enabled. */
231
+ SOLUTION_DESIGNER: boolean;
230
232
  /** @description Whether isolated code execution for agents is enabled. */
231
233
  CODE_EXECUTION: boolean;
232
234
  /** @description Whether SSO (OIDC) login is enabled. Requires at least one enabled SSO provider. */
@@ -967,563 +969,299 @@ interface components {
967
969
  /** @description Marks the row as managed by code (CLI / SDK). Defaults to true on this endpoint. */
968
970
  managedByCode?: boolean;
969
971
  };
970
- AgentResponseDto: {
972
+ UpsertObjectTypeBySlugDto: {
973
+ /** @description Stable workspace-scoped slug (lowercase, digits, hyphens). Used as the upsert key. */
974
+ slug: string;
975
+ /** @description Singular display name. */
976
+ name?: string;
977
+ /** @description Plural display name. */
978
+ namePlural?: string;
979
+ /** @description Description. */
980
+ description?: string;
971
981
  /**
972
- * @description Agent ID (UUID)
973
- * @example 4f7c9d2e-8a1b-4c3d-9e5f-6a7b8c9d0e1f
982
+ * @description Icon identifier.
983
+ * @default box
974
984
  */
975
- id: string;
985
+ icon: string;
976
986
  /**
977
- * @description Agent name
978
- * @example Invoice Triage Agent
987
+ * @description Hex colour.
988
+ * @default #3B82F6
989
+ */
990
+ color: string;
991
+ /** @description Field definitions grouped into sections. */
992
+ attributeSchema: {
993
+ [key: string]: unknown;
994
+ };
995
+ /** @description Optional state machine definition. */
996
+ stateSchema?: {
997
+ [key: string]: unknown;
998
+ } | null;
999
+ /** @description Whether the type is enabled. */
1000
+ isEnabled?: boolean;
1001
+ /**
1002
+ * @description When false (default), reject unknown attribute keys on entity writes.
1003
+ * @default false
1004
+ */
1005
+ allowUnknownAttributes: boolean;
1006
+ /**
1007
+ * @description Marks the type as code-managed. Defaults to true on upsert.
1008
+ * @default true
979
1009
  */
1010
+ managedByCode: boolean;
1011
+ };
1012
+ ObjectTypeUserSummaryDto: {
1013
+ /** @description User ID. */
1014
+ id: string;
1015
+ /** @description Email address of the user. */
1016
+ email: string;
1017
+ /** @description Display name of the user. */
980
1018
  name: string;
981
- /** @description Stable project-scoped slug for CLI / code deploy upserts. Included when `expansion=slug` is requested. */
982
- slug?: string | null;
983
- /** @description True when last written by code (CLI / SDK). Included when `expansion=managedByCode` is requested. */
984
- managedByCode?: boolean;
985
- /** @description ID of the AI provider connection assigned to the agent. Always included. Null when the agent falls back to the workspace default connection. */
986
- FK_aiConnectionId: string | null;
987
- /** @description Agent description. Included when `expansion=description` is requested. */
1019
+ };
1020
+ ObjectTypeCreatedByDto: {
1021
+ /** @description Workspace user ID. */
1022
+ id: string;
1023
+ user: components["schemas"]["ObjectTypeUserSummaryDto"];
1024
+ };
1025
+ ObjectTypeCountDto: {
1026
+ /** @description Number of non-deleted entities of this type. */
1027
+ objects: number;
1028
+ };
1029
+ ObjectTypeResponseDto: {
1030
+ /** @description Entity type ID. */
1031
+ id: string;
1032
+ /** @description Singular display name of the entity type. */
1033
+ name: string;
1034
+ /** @description Plural display name of the entity type. */
1035
+ namePlural: string;
1036
+ /** @description URL-safe slug, unique within the workspace. */
1037
+ slug: string;
1038
+ /** @description Icon identifier for the entity type. */
1039
+ icon: string;
1040
+ /** @description Hex colour of the entity type. */
1041
+ color: string;
1042
+ /** @description Whether the entity type is enabled. */
1043
+ isEnabled: boolean;
1044
+ /** @description When false, entity create/update rejects attribute keys not declared on the type. Reserved key `extensions` is always allowed. */
1045
+ allowUnknownAttributes: boolean;
1046
+ /** @description True when last written by code (CLI / SDK upsert). */
1047
+ managedByCode: boolean;
1048
+ /** @description Incremented when attributeSchema, stateSchema, or allowUnknownAttributes changes. */
1049
+ schemaRevision: number;
1050
+ /** @description Description of the entity type. Included when `expansion=description` is requested. */
988
1051
  description?: string | null;
989
- /** @description Public URL of the agent profile image. Included when `expansion=profileImageUrl` is requested. */
990
- profileImageUrl?: string | null;
1052
+ /** @description Field definitions grouped into sections. Included when `expansion=attributeSchema` is requested. */
1053
+ attributeSchema?: {
1054
+ [key: string]: unknown;
1055
+ };
1056
+ /** @description State machine definition. Included when `expansion=stateSchema` is requested. */
1057
+ stateSchema?: {
1058
+ [key: string]: unknown;
1059
+ } | null;
991
1060
  /**
992
1061
  * Format: date-time
993
- * @description Creation timestamp. Included when `expansion=createdAt` is requested.
1062
+ * @description Included when `expansion=createdAt` is requested.
994
1063
  */
995
1064
  createdAt?: string;
996
1065
  /**
997
1066
  * Format: date-time
998
- * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
1067
+ * @description Included when `expansion=updatedAt` is requested.
999
1068
  */
1000
1069
  updatedAt?: string;
1001
- /** @description System instructions authored for the agent. Included when `expansion=instructions` is requested. */
1002
- instructions?: string | null;
1003
- /**
1004
- * @description Model temperature. Included when `expansion=temperature` is requested.
1005
- * @example 1
1006
- */
1007
- temperature?: number;
1008
- /** @description Maximum output tokens per turn. Included when `expansion=maxOutputTokens` is requested. */
1009
- maxOutputTokens?: number | null;
1010
- /**
1011
- * @description Top-p sampling. Included when `expansion=topP` is requested.
1012
- * @example 1
1013
- */
1014
- topP?: number;
1015
- /**
1016
- * @description Frequency penalty. Included when `expansion=frequencyPenalty` is requested.
1017
- * @example 0
1018
- */
1019
- frequencyPenalty?: number;
1020
- /**
1021
- * @description Presence penalty. Included when `expansion=presencePenalty` is requested.
1022
- * @example 0
1023
- */
1024
- presencePenalty?: number;
1025
- /**
1026
- * @description Maximum retries for a failed model call. Included when `expansion=maxRetries` is requested.
1027
- * @example 0
1028
- */
1029
- maxRetries?: number;
1030
- /** @description Fixed sampling seed. Included when `expansion=seed` is requested. */
1031
- seed?: number | null;
1070
+ /** @description Workspace member who created the entity type. Included when `expansion=createdBy` is requested. */
1071
+ createdBy?: components["schemas"]["ObjectTypeCreatedByDto"];
1072
+ /** @description Included when `expansion=countObjects` is requested. */
1073
+ _count?: components["schemas"]["ObjectTypeCountDto"];
1074
+ };
1075
+ CreateObjectDto: {
1076
+ /** @description Display name of the entity. */
1077
+ name: string;
1032
1078
  /**
1033
- * @description Maximum tool roundtrips per turn. Included when `expansion=maxToolRoundtrips` is requested.
1034
- * @example 5
1079
+ * Format: uuid
1080
+ * @description ID of the entity type to create the entity under.
1035
1081
  */
1036
- maxToolRoundtrips?: number;
1082
+ objectTypeId: string;
1083
+ /** @description Initial state ID. Must exist in the entity type state schema. Defaults to the schema initial state when omitted. */
1084
+ state?: string;
1085
+ /** @description Dynamic attribute values keyed by field ID. */
1086
+ attributes?: {
1087
+ [key: string]: unknown;
1088
+ };
1037
1089
  /**
1038
- * @description How many previous messages are sent to the model. Included when `expansion=messageLookbackLimit` is requested.
1039
- * @example 40
1090
+ * Format: uuid
1091
+ * @description Workspace user ID of the entity owner.
1040
1092
  */
1041
- messageLookbackLimit?: number;
1042
- /** @description Configured tool nodes (app actions) for the agent. Included when `expansion=tools` is requested. */
1043
- tools?: {
1093
+ ownerId?: string;
1094
+ };
1095
+ ObjectTypeSummaryDto: {
1096
+ /** @description Entity type ID. */
1097
+ id: string;
1098
+ /** @description Singular display name of the entity type. */
1099
+ name: string;
1100
+ /** @description URL-safe slug of the entity type. */
1101
+ slug: string;
1102
+ /** @description Icon identifier for the entity type. */
1103
+ icon: string;
1104
+ /** @description Hex colour of the entity type. */
1105
+ color: string;
1106
+ /** @description Plural display name. Included when `expansion=objectType` is requested. */
1107
+ namePlural?: string;
1108
+ /** @description Field definitions grouped into sections. Included when `expansion=objectType` is requested on single-entity reads. */
1109
+ attributeSchema?: {
1044
1110
  [key: string]: unknown;
1045
- }[] | null;
1046
- /** @description Action IDs of the configured tools. Included when `expansion=toolIds` is requested. */
1047
- toolIds?: string[];
1048
- /** @description Instructions used when auto-naming new tasks. Included when `expansion=taskNamingInstructions` is requested. */
1049
- taskNamingInstructions?: string | null;
1050
- /** @description IDs of enabled provider built-in tools. Included when `expansion=enabledBuiltInTools` is requested. */
1051
- enabledBuiltInTools?: string[];
1052
- /** @description IDs of enabled platform tools. Included when `expansion=enabledPlatformTools` is requested. */
1053
- enabledPlatformTools?: string[];
1054
- /** @description Whether dynamic workflow-app action discovery is enabled. Included when `expansion=dynamicActionDiscoveryEnabled` is requested. */
1055
- dynamicActionDiscoveryEnabled?: boolean;
1056
- /** @description Whether dynamic MCP server discovery is enabled. Included when `expansion=dynamicMcpDiscoveryEnabled` is requested. */
1057
- dynamicMcpDiscoveryEnabled?: boolean;
1058
- /** @description Whether the agent maintains its own instructions. Included when `expansion=dynamicSelfInstructionsEnabled` is requested. */
1059
- dynamicSelfInstructionsEnabled?: boolean;
1060
- /** @description Whether long-term memory is enabled. Included when `expansion=memoryEnabled` is requested. */
1061
- memoryEnabled?: boolean;
1111
+ };
1112
+ /** @description State machine definition. Included when `expansion=objectType` is requested. */
1113
+ stateSchema?: {
1114
+ [key: string]: unknown;
1115
+ } | null;
1116
+ };
1117
+ ObjectUserSummaryDto: {
1118
+ /** @description User ID. */
1119
+ id: string;
1120
+ /** @description Email address of the user. */
1121
+ email: string;
1122
+ /** @description Display name of the user. */
1123
+ name: string;
1124
+ };
1125
+ ObjectWorkspaceUserSummaryDto: {
1126
+ /** @description Workspace user ID. */
1127
+ id: string;
1128
+ user: components["schemas"]["ObjectUserSummaryDto"];
1129
+ };
1130
+ ObjectStateHistoryUserSummaryDto: {
1131
+ /** @description User ID. */
1132
+ id: string;
1133
+ /** @description Display name of the user. */
1134
+ name: string;
1135
+ };
1136
+ ObjectStateHistoryChangedByDto: {
1137
+ /** @description Workspace user ID. */
1138
+ id: string;
1139
+ user: components["schemas"]["ObjectStateHistoryUserSummaryDto"];
1140
+ };
1141
+ ObjectStateHistoryItemDto: {
1142
+ /** @description State history entry ID. */
1143
+ id: string;
1144
+ /** @description State the entity moved from. Null for the initial state. */
1145
+ fromState: string | null;
1146
+ /** @description State the entity moved to. */
1147
+ toState: string;
1148
+ /** @description Reason recorded for the state change, if any. */
1149
+ reason: string | null;
1062
1150
  /**
1063
- * @description Memory partitioning scope. Included when `expansion=memoryScope` is requested.
1064
- * @enum {string}
1151
+ * Format: date-time
1152
+ * @description When the state change occurred.
1065
1153
  */
1066
- memoryScope?: "PER_USER" | "PER_AGENT" | "PER_USER_PER_AGENT";
1154
+ createdAt: string;
1155
+ /** @description Workspace member who made the change, if recorded. */
1156
+ changedBy: components["schemas"]["ObjectStateHistoryChangedByDto"] | null;
1157
+ };
1158
+ ObjectResponseDto: {
1159
+ /** @description Entity ID. */
1160
+ id: string;
1161
+ /** @description Display name of the entity. */
1162
+ name: string;
1163
+ /** @description Current state of the entity, if the type defines states. */
1164
+ state: string | null;
1165
+ /** @description Dynamic attribute values keyed by field ID. */
1166
+ attributes: {
1167
+ [key: string]: unknown;
1168
+ };
1067
1169
  /**
1068
- * @description Days memories are retained. Included when `expansion=memoryRetentionDays` is requested.
1069
- * @example 90
1170
+ * Format: date-time
1171
+ * @description Included when `expansion=createdAt` is requested.
1070
1172
  */
1071
- memoryRetentionDays?: number;
1072
- /** @description Suggested prompts shown to users starting a conversation. Included when `expansion=suggestedPrompts` is requested. */
1073
- suggestedPrompts?: string[];
1173
+ createdAt?: string;
1074
1174
  /**
1075
1175
  * Format: date-time
1076
- * @description When the first-time builder setup wizard was completed. Included when `expansion=builderSetupCompletedAt` is requested.
1176
+ * @description Included by default on list responses, otherwise when `expansion=updatedAt` is requested.
1077
1177
  */
1078
- builderSetupCompletedAt?: string | null;
1079
- /** @description Saved canvas node positions for the agent builder. Included when `expansion=builderCanvasPositions` is requested. */
1080
- builderCanvasPositions?: {
1081
- [key: string]: unknown;
1082
- } | null;
1083
- /** @description Selected model ID within the AI provider connection. Included when `expansion=selectedModelId` is requested. */
1084
- selectedModelId?: string | null;
1085
- /** @description Assigned AI provider connection. Included when `expansion=aiConnection` is requested. */
1086
- aiConnection?: {
1087
- id?: string;
1088
- name?: string;
1089
- providerConfig?: {
1090
- id?: string;
1091
- providerSlug?: string;
1092
- };
1093
- } | null;
1094
- /** @description Knowledge notebooks attached to the agent. Included when `expansion=knowledge` is requested. */
1095
- agentKnowledge?: {
1096
- id?: string;
1097
- knowledge?: {
1098
- id?: string;
1099
- name?: string;
1100
- };
1101
- }[];
1102
- /** @description Object types attached to the agent. Included when `expansion=objectTypes` is requested. */
1103
- agentObjectTypes?: {
1104
- id?: string;
1105
- scope?: string;
1106
- objectType?: {
1107
- id?: string;
1108
- name?: string;
1109
- slug?: string;
1110
- icon?: string | null;
1111
- color?: string | null;
1112
- };
1113
- }[];
1114
- /** @description Objects attached to the agent. Included when `expansion=objects` is requested. */
1115
- agentObjects?: {
1116
- id?: string;
1117
- scope?: string;
1118
- object?: {
1119
- id?: string;
1120
- name?: string;
1121
- state?: string;
1122
- objectType?: {
1123
- id?: string;
1124
- name?: string;
1125
- slug?: string;
1126
- icon?: string | null;
1127
- color?: string | null;
1128
- };
1129
- };
1130
- }[];
1131
- /** @description App connections available to the agent. Included when `expansion=connections` is requested. */
1132
- connections?: {
1133
- id?: string;
1134
- name?: string;
1135
- }[];
1136
- /** @description Variables attached to the agent. Included when `expansion=variables` is requested. */
1137
- agentVariables?: {
1138
- id?: string;
1139
- variable?: {
1140
- id?: string;
1141
- name?: string;
1142
- };
1143
- }[];
1144
- /** @description Workflows the agent can trigger. Included when `expansion=workflows` is requested. */
1145
- agentWorkflows?: {
1146
- id?: string;
1147
- workflow?: {
1148
- id?: string;
1149
- name?: string;
1150
- };
1151
- }[];
1152
- /** @description Sub-agent links for the agent. Included when `expansion=subAgents` is requested. */
1153
- agentSubAgents?: {
1154
- id?: string;
1155
- subagent?: {
1156
- id?: string;
1157
- name?: string;
1158
- };
1159
- parentAgent?: {
1160
- id?: string;
1161
- name?: string;
1162
- };
1163
- }[];
1164
- /** @description MCP servers attached to the agent, with per-tool overrides. Included when `expansion=mcpServers` is requested. */
1165
- agentMcpServers?: {
1166
- id?: string;
1167
- mcpServer?: {
1168
- id?: string;
1169
- slug?: string;
1170
- name?: string;
1171
- provider?: string;
1172
- logoUrl?: string | null;
1173
- description?: string | null;
1174
- };
1175
- toolOverrides?: {
1176
- id?: string;
1177
- toolName?: string;
1178
- enabled?: boolean;
1179
- requireApproval?: boolean;
1180
- }[];
1181
- }[];
1182
- /** @description A2A (agent-to-agent) endpoints attached to the agent. Included when `expansion=a2aAgents` is requested. */
1183
- agentA2aAgents?: {
1184
- id?: string;
1185
- a2aAgent?: {
1186
- id?: string;
1187
- slug?: string;
1188
- name?: string;
1189
- logoUrl?: string | null;
1190
- description?: string | null;
1191
- authType?: string;
1192
- };
1193
- }[];
1194
- /** @description Web access configuration. Included when `expansion=webAccess` is requested. */
1195
- agentWebAccess?: {
1196
- service?: string;
1197
- webSearchEnabled?: boolean;
1198
- websiteAccessEnabled?: boolean;
1199
- } | null;
1200
- /** @description Phone access configuration. Included when `expansion=phoneAccess` is requested. */
1201
- agentPhoneAccess?: {
1202
- service?: string;
1203
- outboundCallsEnabled?: boolean;
1204
- inboundCallsEnabled?: boolean;
1205
- } | null;
1206
- /** @description Project the agent belongs to. Included when `expansion=project` is requested. */
1207
- project?: {
1208
- id?: string;
1209
- name?: string;
1210
- };
1178
+ updatedAt?: string;
1179
+ /** @description Included by default on list responses with a minimal shape, otherwise when `expansion=objectType` is requested. */
1180
+ objectType?: components["schemas"]["ObjectTypeSummaryDto"];
1181
+ /** @description Included when `expansion=owner` is requested. */
1182
+ owner?: components["schemas"]["ObjectWorkspaceUserSummaryDto"] | null;
1183
+ /** @description Included when `expansion=createdBy` is requested. */
1184
+ createdBy?: components["schemas"]["ObjectWorkspaceUserSummaryDto"] | null;
1185
+ /** @description Most recent state changes (up to 50, newest first). Included when `expansion=stateHistory` is requested. */
1186
+ stateHistory?: components["schemas"]["ObjectStateHistoryItemDto"][];
1211
1187
  };
1212
- UpsertAgentToolDto: {
1213
- /** @description Workflow app id (catalogue slug). */
1214
- appId: string;
1215
- /** @description Catalogue action id. */
1216
- actionId: string;
1217
- /** @description Connection instance UUID pre-bound on the tool. */
1218
- connectionId?: string;
1219
- /** @description Tool display name for the model. */
1188
+ ObjectPaginationDto: {
1189
+ /** @description Current page number (1-based). */
1190
+ page: number;
1191
+ /** @description Number of items per page (maximum 100). */
1192
+ pageSize: number;
1193
+ /** @description Total number of matching entities. */
1194
+ totalCount: number;
1195
+ /** @description Total number of pages. */
1196
+ totalPages: number;
1197
+ };
1198
+ PaginatedObjectsResponseDto: {
1199
+ data: components["schemas"]["ObjectResponseDto"][];
1200
+ pagination: components["schemas"]["ObjectPaginationDto"];
1201
+ };
1202
+ UpdateObjectDto: {
1203
+ /** @description New display name of the entity. */
1220
1204
  name?: string;
1221
- /** @description Tool description shown to the model. */
1222
- description?: string;
1223
- /** @description Pre-filled tool config (fields left empty are filled by the model). */
1224
- input?: {
1205
+ /** @description Attribute values keyed by field ID. Merged into the existing attributes; fields not supplied are left unchanged. */
1206
+ attributes?: {
1225
1207
  [key: string]: unknown;
1226
1208
  };
1209
+ /** @description Workspace user ID of the new entity owner. */
1210
+ ownerId?: string;
1227
1211
  };
1228
- UpsertAgentBySlugDto: {
1229
- /**
1230
- * @description Stable project-scoped slug (lowercase, digits, hyphens). Used as the upsert key.
1231
- * @example support-triage
1232
- */
1233
- slug: string;
1234
- /** @description Display name. Defaults to the slug when omitted. */
1235
- name?: string;
1236
- description?: string;
1237
- /** @description System instructions / prompt for the agent. */
1238
- instructions: string;
1239
- /** @description Selected model id on the AI provider connection (e.g. `gpt-4o`). */
1240
- model: string;
1241
- /** @description AiProviderConnection UUID. When omitted, platform AI defaults apply. */
1242
- aiConnectionId?: string;
1243
- /** @description App Connection UUIDs the agent may use for tools. */
1244
- connectionIds?: string[];
1245
- /** @description Workflow UUIDs the agent may run (AgentWorkflow links). */
1246
- workflowIds?: string[];
1247
- /** @description Catalogue action tools (WorkflowNodeForRunner-shaped). */
1248
- tools?: components["schemas"]["UpsertAgentToolDto"][];
1249
- /** @description Marks the row as managed by code (CLI / SDK). Defaults to true on this endpoint. */
1250
- managedByCode?: boolean;
1212
+ ChangeObjectStateDto: {
1213
+ /** @description ID of the target state. Must be a valid transition from the current state when the entity type defines transitions. */
1214
+ newState: string;
1215
+ /** @description Reason for the state change. Required when the transition is configured with requiresReason. */
1216
+ reason?: string;
1251
1217
  };
1252
- WorkflowAppResponseDto: {
1253
- /** @description App ID, e.g. `gmail`. Matches the appId used in workflow execution steps. */
1218
+ ChangeObjectStateResponseDto: {
1219
+ /** @description Entity ID. */
1254
1220
  id: string;
1255
- /** @description Human-readable app name. */
1221
+ /** @description Display name of the entity. */
1256
1222
  name: string;
1257
- /** @description App description. */
1258
- description: string;
1259
- /** @description URL of the app logo. */
1260
- logoUrl: string;
1261
- /** @description Whether the app is published and available for use. */
1262
- isPublished: boolean;
1263
- /** @description Whether the app requires a connection before its actions and triggers can run. */
1264
- needsConnection: boolean;
1265
- /** @description Whether the app can be used by agents. */
1266
- availableForAgent: boolean;
1267
- /** @description Action definitions, each with id, name, description, iconUrl, needsConnection, availableForAgent, viewOptions and the declarative inputConfig field metadata used to render action UIs. */
1268
- actions: {
1269
- [key: string]: unknown;
1270
- }[];
1271
- /** @description Trigger definitions, each with id, name, description, iconUrl, needsConnection and the declarative inputConfig field metadata used to render trigger UIs. */
1272
- triggers: {
1273
- [key: string]: unknown;
1274
- }[];
1275
- /** @description Connection type definitions supported by the app (e.g. oauth2, apiKey, basic), each with id, name, description, connectionType and any declarative inputConfig fields. */
1276
- connections: {
1277
- [key: string]: unknown;
1278
- }[];
1223
+ /** @description State of the entity after the change. */
1224
+ state: string | null;
1225
+ /**
1226
+ * Format: date-time
1227
+ * @description When the entity was last updated.
1228
+ */
1229
+ updatedAt: string;
1279
1230
  };
1280
- ObjectTypeUserSummaryDto: {
1231
+ StateHistoryUserSummaryDto: {
1281
1232
  /** @description User ID. */
1282
1233
  id: string;
1283
- /** @description Email address of the user. */
1284
- email: string;
1285
1234
  /** @description Display name of the user. */
1286
1235
  name: string;
1236
+ /** @description Email address of the user. */
1237
+ email: string;
1287
1238
  };
1288
- ObjectTypeCreatedByDto: {
1239
+ StateHistoryChangedByDto: {
1289
1240
  /** @description Workspace user ID. */
1290
1241
  id: string;
1291
- user: components["schemas"]["ObjectTypeUserSummaryDto"];
1242
+ user: components["schemas"]["StateHistoryUserSummaryDto"];
1292
1243
  };
1293
- ObjectTypeCountDto: {
1294
- /** @description Number of non-deleted entities of this type. */
1295
- objects: number;
1244
+ ObjectStateHistoryEntryResponseDto: {
1245
+ /** @description State history entry ID. */
1246
+ id: string;
1247
+ /** @description State the entity moved from. Null for the initial state. */
1248
+ fromState: string | null;
1249
+ /** @description State the entity moved to. */
1250
+ toState: string;
1251
+ /** @description Reason recorded for the state change, if any. */
1252
+ reason: string | null;
1253
+ /**
1254
+ * Format: date-time
1255
+ * @description When the state change occurred.
1256
+ */
1257
+ createdAt: string;
1258
+ /** @description Workspace member who made the change, if recorded. */
1259
+ changedBy: components["schemas"]["StateHistoryChangedByDto"] | null;
1296
1260
  };
1297
- ObjectTypeResponseDto: {
1298
- /** @description Entity type ID. */
1261
+ ObjectStateInfoDto: {
1262
+ /** @description State ID. */
1299
1263
  id: string;
1300
- /** @description Singular display name of the entity type. */
1301
- name: string;
1302
- /** @description Plural display name of the entity type. */
1303
- namePlural: string;
1304
- /** @description URL-safe slug, unique within the workspace. */
1305
- slug: string;
1306
- /** @description Icon identifier for the entity type. */
1307
- icon: string;
1308
- /** @description Hex colour of the entity type. */
1309
- color: string;
1310
- /** @description Whether the entity type is enabled. */
1311
- isEnabled: boolean;
1312
- /** @description Description of the entity type. Included when `expansion=description` is requested. */
1313
- description?: string | null;
1314
- /** @description Field definitions grouped into sections. Included when `expansion=attributeSchema` is requested. */
1315
- attributeSchema?: {
1316
- [key: string]: unknown;
1317
- };
1318
- /** @description State machine definition. Included when `expansion=stateSchema` is requested. */
1319
- stateSchema?: {
1320
- [key: string]: unknown;
1321
- } | null;
1322
- /**
1323
- * Format: date-time
1324
- * @description Included when `expansion=createdAt` is requested.
1325
- */
1326
- createdAt?: string;
1327
- /**
1328
- * Format: date-time
1329
- * @description Included when `expansion=updatedAt` is requested.
1330
- */
1331
- updatedAt?: string;
1332
- /** @description Workspace member who created the entity type. Included when `expansion=createdBy` is requested. */
1333
- createdBy?: components["schemas"]["ObjectTypeCreatedByDto"];
1334
- /** @description Included when `expansion=countObjects` is requested. */
1335
- _count?: components["schemas"]["ObjectTypeCountDto"];
1336
- };
1337
- CreateObjectDto: {
1338
- /** @description Display name of the entity. */
1339
- name: string;
1340
- /**
1341
- * Format: uuid
1342
- * @description ID of the entity type to create the entity under.
1343
- */
1344
- objectTypeId: string;
1345
- /** @description Initial state ID. Must exist in the entity type state schema. Defaults to the schema initial state when omitted. */
1346
- state?: string;
1347
- /** @description Dynamic attribute values keyed by field ID. */
1348
- attributes?: {
1349
- [key: string]: unknown;
1350
- };
1351
- /**
1352
- * Format: uuid
1353
- * @description Workspace user ID of the entity owner.
1354
- */
1355
- ownerId?: string;
1356
- };
1357
- ObjectTypeSummaryDto: {
1358
- /** @description Entity type ID. */
1359
- id: string;
1360
- /** @description Singular display name of the entity type. */
1361
- name: string;
1362
- /** @description URL-safe slug of the entity type. */
1363
- slug: string;
1364
- /** @description Icon identifier for the entity type. */
1365
- icon: string;
1366
- /** @description Hex colour of the entity type. */
1367
- color: string;
1368
- /** @description Plural display name. Included when `expansion=objectType` is requested. */
1369
- namePlural?: string;
1370
- /** @description Field definitions grouped into sections. Included when `expansion=objectType` is requested on single-entity reads. */
1371
- attributeSchema?: {
1372
- [key: string]: unknown;
1373
- };
1374
- /** @description State machine definition. Included when `expansion=objectType` is requested. */
1375
- stateSchema?: {
1376
- [key: string]: unknown;
1377
- } | null;
1378
- };
1379
- ObjectUserSummaryDto: {
1380
- /** @description User ID. */
1381
- id: string;
1382
- /** @description Email address of the user. */
1383
- email: string;
1384
- /** @description Display name of the user. */
1385
- name: string;
1386
- };
1387
- ObjectWorkspaceUserSummaryDto: {
1388
- /** @description Workspace user ID. */
1389
- id: string;
1390
- user: components["schemas"]["ObjectUserSummaryDto"];
1391
- };
1392
- ObjectStateHistoryUserSummaryDto: {
1393
- /** @description User ID. */
1394
- id: string;
1395
- /** @description Display name of the user. */
1396
- name: string;
1397
- };
1398
- ObjectStateHistoryChangedByDto: {
1399
- /** @description Workspace user ID. */
1400
- id: string;
1401
- user: components["schemas"]["ObjectStateHistoryUserSummaryDto"];
1402
- };
1403
- ObjectStateHistoryItemDto: {
1404
- /** @description State history entry ID. */
1405
- id: string;
1406
- /** @description State the entity moved from. Null for the initial state. */
1407
- fromState: string | null;
1408
- /** @description State the entity moved to. */
1409
- toState: string;
1410
- /** @description Reason recorded for the state change, if any. */
1411
- reason: string | null;
1412
- /**
1413
- * Format: date-time
1414
- * @description When the state change occurred.
1415
- */
1416
- createdAt: string;
1417
- /** @description Workspace member who made the change, if recorded. */
1418
- changedBy: components["schemas"]["ObjectStateHistoryChangedByDto"] | null;
1419
- };
1420
- ObjectResponseDto: {
1421
- /** @description Entity ID. */
1422
- id: string;
1423
- /** @description Display name of the entity. */
1424
- name: string;
1425
- /** @description Current state of the entity, if the type defines states. */
1426
- state: string | null;
1427
- /** @description Dynamic attribute values keyed by field ID. */
1428
- attributes: {
1429
- [key: string]: unknown;
1430
- };
1431
- /**
1432
- * Format: date-time
1433
- * @description Included when `expansion=createdAt` is requested.
1434
- */
1435
- createdAt?: string;
1436
- /**
1437
- * Format: date-time
1438
- * @description Included by default on list responses, otherwise when `expansion=updatedAt` is requested.
1439
- */
1440
- updatedAt?: string;
1441
- /** @description Included by default on list responses with a minimal shape, otherwise when `expansion=objectType` is requested. */
1442
- objectType?: components["schemas"]["ObjectTypeSummaryDto"];
1443
- /** @description Included when `expansion=owner` is requested. */
1444
- owner?: components["schemas"]["ObjectWorkspaceUserSummaryDto"] | null;
1445
- /** @description Included when `expansion=createdBy` is requested. */
1446
- createdBy?: components["schemas"]["ObjectWorkspaceUserSummaryDto"] | null;
1447
- /** @description Most recent state changes (up to 50, newest first). Included when `expansion=stateHistory` is requested. */
1448
- stateHistory?: components["schemas"]["ObjectStateHistoryItemDto"][];
1449
- };
1450
- ObjectPaginationDto: {
1451
- /** @description Current page number (1-based). */
1452
- page: number;
1453
- /** @description Number of items per page (maximum 100). */
1454
- pageSize: number;
1455
- /** @description Total number of matching entities. */
1456
- totalCount: number;
1457
- /** @description Total number of pages. */
1458
- totalPages: number;
1459
- };
1460
- PaginatedObjectsResponseDto: {
1461
- data: components["schemas"]["ObjectResponseDto"][];
1462
- pagination: components["schemas"]["ObjectPaginationDto"];
1463
- };
1464
- UpdateObjectDto: {
1465
- /** @description New display name of the entity. */
1466
- name?: string;
1467
- /** @description Attribute values keyed by field ID. Merged into the existing attributes; fields not supplied are left unchanged. */
1468
- attributes?: {
1469
- [key: string]: unknown;
1470
- };
1471
- /** @description Workspace user ID of the new entity owner. */
1472
- ownerId?: string;
1473
- };
1474
- ChangeObjectStateDto: {
1475
- /** @description ID of the target state. Must be a valid transition from the current state when the entity type defines transitions. */
1476
- newState: string;
1477
- /** @description Reason for the state change. Required when the transition is configured with requiresReason. */
1478
- reason?: string;
1479
- };
1480
- ChangeObjectStateResponseDto: {
1481
- /** @description Entity ID. */
1482
- id: string;
1483
- /** @description Display name of the entity. */
1484
- name: string;
1485
- /** @description State of the entity after the change. */
1486
- state: string | null;
1487
- /**
1488
- * Format: date-time
1489
- * @description When the entity was last updated.
1490
- */
1491
- updatedAt: string;
1492
- };
1493
- StateHistoryUserSummaryDto: {
1494
- /** @description User ID. */
1495
- id: string;
1496
- /** @description Display name of the user. */
1497
- name: string;
1498
- /** @description Email address of the user. */
1499
- email: string;
1500
- };
1501
- StateHistoryChangedByDto: {
1502
- /** @description Workspace user ID. */
1503
- id: string;
1504
- user: components["schemas"]["StateHistoryUserSummaryDto"];
1505
- };
1506
- ObjectStateHistoryEntryResponseDto: {
1507
- /** @description State history entry ID. */
1508
- id: string;
1509
- /** @description State the entity moved from. Null for the initial state. */
1510
- fromState: string | null;
1511
- /** @description State the entity moved to. */
1512
- toState: string;
1513
- /** @description Reason recorded for the state change, if any. */
1514
- reason: string | null;
1515
- /**
1516
- * Format: date-time
1517
- * @description When the state change occurred.
1518
- */
1519
- createdAt: string;
1520
- /** @description Workspace member who made the change, if recorded. */
1521
- changedBy: components["schemas"]["StateHistoryChangedByDto"] | null;
1522
- };
1523
- ObjectStateInfoDto: {
1524
- /** @description State ID. */
1525
- id: string;
1526
- /** @description Display name of the state. */
1264
+ /** @description Display name of the state. */
1527
1265
  name: string;
1528
1266
  /** @description Colour associated with the state. */
1529
1267
  color?: string;
@@ -1586,6 +1324,334 @@ interface components {
1586
1324
  [key: string]: string;
1587
1325
  };
1588
1326
  };
1327
+ WorkflowAppResponseDto: {
1328
+ /** @description App ID, e.g. `gmail`. Matches the appId used in workflow execution steps. */
1329
+ id: string;
1330
+ /** @description Human-readable app name. */
1331
+ name: string;
1332
+ /** @description App description. */
1333
+ description: string;
1334
+ /** @description URL of the app logo. */
1335
+ logoUrl: string;
1336
+ /** @description Whether the app is published and available for use. */
1337
+ isPublished: boolean;
1338
+ /** @description Whether the app requires a connection before its actions and triggers can run. */
1339
+ needsConnection: boolean;
1340
+ /** @description Whether the app can be used by agents. */
1341
+ availableForAgent: boolean;
1342
+ /** @description Action definitions, each with id, name, description, iconUrl, needsConnection, availableForAgent, viewOptions and the declarative inputConfig field metadata used to render action UIs. */
1343
+ actions: {
1344
+ [key: string]: unknown;
1345
+ }[];
1346
+ /** @description Trigger definitions, each with id, name, description, iconUrl, needsConnection and the declarative inputConfig field metadata used to render trigger UIs. */
1347
+ triggers: {
1348
+ [key: string]: unknown;
1349
+ }[];
1350
+ /** @description Connection type definitions supported by the app (e.g. oauth2, apiKey, basic), each with id, name, description, connectionType and any declarative inputConfig fields. */
1351
+ connections: {
1352
+ [key: string]: unknown;
1353
+ }[];
1354
+ };
1355
+ AgentResponseDto: {
1356
+ /**
1357
+ * @description Agent ID (UUID)
1358
+ * @example 4f7c9d2e-8a1b-4c3d-9e5f-6a7b8c9d0e1f
1359
+ */
1360
+ id: string;
1361
+ /**
1362
+ * @description Agent name
1363
+ * @example Invoice Triage Agent
1364
+ */
1365
+ name: string;
1366
+ /** @description Stable project-scoped slug for CLI / code deploy upserts. Included when `expansion=slug` is requested. */
1367
+ slug?: string | null;
1368
+ /** @description True when last written by code (CLI / SDK). Included when `expansion=managedByCode` is requested. */
1369
+ managedByCode?: boolean;
1370
+ /** @description ID of the AI provider connection assigned to the agent. Always included. Null when the agent falls back to the workspace default connection. */
1371
+ FK_aiConnectionId: string | null;
1372
+ /** @description Agent description. Included when `expansion=description` is requested. */
1373
+ description?: string | null;
1374
+ /** @description Public URL of the agent profile image. Included when `expansion=profileImageUrl` is requested. */
1375
+ profileImageUrl?: string | null;
1376
+ /**
1377
+ * Format: date-time
1378
+ * @description Creation timestamp. Included when `expansion=createdAt` is requested.
1379
+ */
1380
+ createdAt?: string;
1381
+ /**
1382
+ * Format: date-time
1383
+ * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
1384
+ */
1385
+ updatedAt?: string;
1386
+ /** @description System instructions authored for the agent. Included when `expansion=instructions` is requested. */
1387
+ instructions?: string | null;
1388
+ /**
1389
+ * @description Model temperature. Included when `expansion=temperature` is requested.
1390
+ * @example 1
1391
+ */
1392
+ temperature?: number;
1393
+ /** @description Maximum output tokens per turn. Included when `expansion=maxOutputTokens` is requested. */
1394
+ maxOutputTokens?: number | null;
1395
+ /**
1396
+ * @description Top-p sampling. Included when `expansion=topP` is requested.
1397
+ * @example 1
1398
+ */
1399
+ topP?: number;
1400
+ /**
1401
+ * @description Frequency penalty. Included when `expansion=frequencyPenalty` is requested.
1402
+ * @example 0
1403
+ */
1404
+ frequencyPenalty?: number;
1405
+ /**
1406
+ * @description Presence penalty. Included when `expansion=presencePenalty` is requested.
1407
+ * @example 0
1408
+ */
1409
+ presencePenalty?: number;
1410
+ /**
1411
+ * @description Maximum retries for a failed model call. Included when `expansion=maxRetries` is requested.
1412
+ * @example 0
1413
+ */
1414
+ maxRetries?: number;
1415
+ /** @description Fixed sampling seed. Included when `expansion=seed` is requested. */
1416
+ seed?: number | null;
1417
+ /**
1418
+ * @description Maximum tool roundtrips per turn. Included when `expansion=maxToolRoundtrips` is requested.
1419
+ * @example 5
1420
+ */
1421
+ maxToolRoundtrips?: number;
1422
+ /**
1423
+ * @description How many previous messages are sent to the model. Included when `expansion=messageLookbackLimit` is requested.
1424
+ * @example 40
1425
+ */
1426
+ messageLookbackLimit?: number;
1427
+ /** @description Configured tool nodes (app actions) for the agent. Included when `expansion=tools` is requested. */
1428
+ tools?: {
1429
+ [key: string]: unknown;
1430
+ }[] | null;
1431
+ /** @description Action IDs of the configured tools. Included when `expansion=toolIds` is requested. */
1432
+ toolIds?: string[];
1433
+ /** @description Instructions used when auto-naming new tasks. Included when `expansion=taskNamingInstructions` is requested. */
1434
+ taskNamingInstructions?: string | null;
1435
+ /** @description IDs of enabled provider built-in tools. Included when `expansion=enabledBuiltInTools` is requested. */
1436
+ enabledBuiltInTools?: string[];
1437
+ /** @description IDs of enabled platform tools. Included when `expansion=enabledPlatformTools` is requested. */
1438
+ enabledPlatformTools?: string[];
1439
+ /** @description Whether dynamic workflow-app action discovery is enabled. Included when `expansion=dynamicActionDiscoveryEnabled` is requested. */
1440
+ dynamicActionDiscoveryEnabled?: boolean;
1441
+ /** @description Whether dynamic MCP server discovery is enabled. Included when `expansion=dynamicMcpDiscoveryEnabled` is requested. */
1442
+ dynamicMcpDiscoveryEnabled?: boolean;
1443
+ /** @description Whether the agent maintains its own instructions. Included when `expansion=dynamicSelfInstructionsEnabled` is requested. */
1444
+ dynamicSelfInstructionsEnabled?: boolean;
1445
+ /** @description Whether long-term memory is enabled. Included when `expansion=memoryEnabled` is requested. */
1446
+ memoryEnabled?: boolean;
1447
+ /** @description Whether runtime planning tools are enabled. Included when `expansion=enablePlanning` is requested. */
1448
+ enablePlanning?: boolean;
1449
+ /** @description Whether oversized tool-result offload is enabled. Included when `expansion=enableToolResultOffload` is requested. */
1450
+ enableToolResultOffload?: boolean;
1451
+ /** @description Byte threshold for tool-result offload. Included when `expansion=toolResultOffloadThresholdBytes` is requested. */
1452
+ toolResultOffloadThresholdBytes?: number;
1453
+ /** @description Whether long-horizon mode is enabled. Included when `expansion=longHorizonMode` is requested. */
1454
+ longHorizonMode?: boolean;
1455
+ /** @description prepareStep safety-net policy ids. Included when `expansion=enabledToolPolicies` is requested. */
1456
+ enabledToolPolicies?: string[];
1457
+ /** @description Per-tool force overrides. Included when `expansion=forcedTools` is requested. */
1458
+ forcedTools?: string[];
1459
+ /** @description When true with planning, gate heavy tools until plan approval. Included when `expansion=requirePlanApproval` is requested. */
1460
+ requirePlanApproval?: boolean;
1461
+ /** @description Optional elevated max steps for long-horizon mode. Included when `expansion=longHorizonMaxSteps` is requested. */
1462
+ longHorizonMaxSteps?: number | null;
1463
+ /** @description Optional max tokens per run hint for long-horizon mode. Included when `expansion=longHorizonMaxTokensPerRun` is requested. */
1464
+ longHorizonMaxTokensPerRun?: number | null;
1465
+ /**
1466
+ * @description Memory partitioning scope. Included when `expansion=memoryScope` is requested.
1467
+ * @enum {string}
1468
+ */
1469
+ memoryScope?: "PER_USER" | "PER_AGENT" | "PER_USER_PER_AGENT";
1470
+ /**
1471
+ * @description Days memories are retained. Included when `expansion=memoryRetentionDays` is requested.
1472
+ * @example 90
1473
+ */
1474
+ memoryRetentionDays?: number;
1475
+ /** @description Suggested prompts shown to users starting a conversation. Included when `expansion=suggestedPrompts` is requested. */
1476
+ suggestedPrompts?: string[];
1477
+ /**
1478
+ * Format: date-time
1479
+ * @description When the first-time builder setup wizard was completed. Included when `expansion=builderSetupCompletedAt` is requested.
1480
+ */
1481
+ builderSetupCompletedAt?: string | null;
1482
+ /** @description Saved canvas node positions for the agent builder. Included when `expansion=builderCanvasPositions` is requested. */
1483
+ builderCanvasPositions?: {
1484
+ [key: string]: unknown;
1485
+ } | null;
1486
+ /** @description Selected model ID within the AI provider connection. Included when `expansion=selectedModelId` is requested. */
1487
+ selectedModelId?: string | null;
1488
+ /** @description Assigned AI provider connection. Included when `expansion=aiConnection` is requested. */
1489
+ aiConnection?: {
1490
+ id?: string;
1491
+ name?: string;
1492
+ providerConfig?: {
1493
+ id?: string;
1494
+ providerSlug?: string;
1495
+ };
1496
+ } | null;
1497
+ /** @description Knowledge notebooks attached to the agent. Included when `expansion=knowledge` is requested. */
1498
+ agentKnowledge?: {
1499
+ id?: string;
1500
+ knowledge?: {
1501
+ id?: string;
1502
+ name?: string;
1503
+ };
1504
+ }[];
1505
+ /** @description Object types attached to the agent. Included when `expansion=objectTypes` is requested. */
1506
+ agentObjectTypes?: {
1507
+ id?: string;
1508
+ scope?: string;
1509
+ objectType?: {
1510
+ id?: string;
1511
+ name?: string;
1512
+ slug?: string;
1513
+ icon?: string | null;
1514
+ color?: string | null;
1515
+ };
1516
+ }[];
1517
+ /** @description Objects attached to the agent. Included when `expansion=objects` is requested. */
1518
+ agentObjects?: {
1519
+ id?: string;
1520
+ scope?: string;
1521
+ object?: {
1522
+ id?: string;
1523
+ name?: string;
1524
+ state?: string;
1525
+ objectType?: {
1526
+ id?: string;
1527
+ name?: string;
1528
+ slug?: string;
1529
+ icon?: string | null;
1530
+ color?: string | null;
1531
+ };
1532
+ };
1533
+ }[];
1534
+ /** @description App connections available to the agent. Included when `expansion=connections` is requested. */
1535
+ connections?: {
1536
+ id?: string;
1537
+ name?: string;
1538
+ }[];
1539
+ /** @description Variables attached to the agent. Included when `expansion=variables` is requested. */
1540
+ agentVariables?: {
1541
+ id?: string;
1542
+ variable?: {
1543
+ id?: string;
1544
+ name?: string;
1545
+ };
1546
+ }[];
1547
+ /** @description Workflows the agent can trigger. Included when `expansion=workflows` is requested. */
1548
+ agentWorkflows?: {
1549
+ id?: string;
1550
+ workflow?: {
1551
+ id?: string;
1552
+ name?: string;
1553
+ };
1554
+ }[];
1555
+ /** @description Sub-agent links for the agent. Included when `expansion=subAgents` is requested. */
1556
+ agentSubAgents?: {
1557
+ id?: string;
1558
+ subagent?: {
1559
+ id?: string;
1560
+ name?: string;
1561
+ };
1562
+ parentAgent?: {
1563
+ id?: string;
1564
+ name?: string;
1565
+ };
1566
+ }[];
1567
+ /** @description MCP servers attached to the agent, with per-tool overrides. Included when `expansion=mcpServers` is requested. */
1568
+ agentMcpServers?: {
1569
+ id?: string;
1570
+ mcpServer?: {
1571
+ id?: string;
1572
+ slug?: string;
1573
+ name?: string;
1574
+ provider?: string;
1575
+ logoUrl?: string | null;
1576
+ description?: string | null;
1577
+ };
1578
+ toolOverrides?: {
1579
+ id?: string;
1580
+ toolName?: string;
1581
+ enabled?: boolean;
1582
+ requireApproval?: boolean;
1583
+ }[];
1584
+ }[];
1585
+ /** @description A2A (agent-to-agent) endpoints attached to the agent. Included when `expansion=a2aAgents` is requested. */
1586
+ agentA2aAgents?: {
1587
+ id?: string;
1588
+ a2aAgent?: {
1589
+ id?: string;
1590
+ slug?: string;
1591
+ name?: string;
1592
+ logoUrl?: string | null;
1593
+ description?: string | null;
1594
+ authType?: string;
1595
+ };
1596
+ }[];
1597
+ /** @description Web access configuration. Included when `expansion=webAccess` is requested. */
1598
+ agentWebAccess?: {
1599
+ service?: string;
1600
+ webSearchEnabled?: boolean;
1601
+ websiteAccessEnabled?: boolean;
1602
+ } | null;
1603
+ /** @description Phone access configuration. Included when `expansion=phoneAccess` is requested. */
1604
+ agentPhoneAccess?: {
1605
+ service?: string;
1606
+ outboundCallsEnabled?: boolean;
1607
+ inboundCallsEnabled?: boolean;
1608
+ } | null;
1609
+ /** @description Project the agent belongs to. Included when `expansion=project` is requested. */
1610
+ project?: {
1611
+ id?: string;
1612
+ name?: string;
1613
+ };
1614
+ };
1615
+ UpsertAgentToolDto: {
1616
+ /** @description Workflow app id (catalogue slug). */
1617
+ appId: string;
1618
+ /** @description Catalogue action id. */
1619
+ actionId: string;
1620
+ /** @description Connection instance UUID pre-bound on the tool. */
1621
+ connectionId?: string;
1622
+ /** @description Tool display name for the model. */
1623
+ name?: string;
1624
+ /** @description Tool description shown to the model. */
1625
+ description?: string;
1626
+ /** @description Pre-filled tool config (fields left empty are filled by the model). */
1627
+ input?: {
1628
+ [key: string]: unknown;
1629
+ };
1630
+ };
1631
+ UpsertAgentBySlugDto: {
1632
+ /**
1633
+ * @description Stable project-scoped slug (lowercase, digits, hyphens). Used as the upsert key.
1634
+ * @example support-triage
1635
+ */
1636
+ slug: string;
1637
+ /** @description Display name. Defaults to the slug when omitted. */
1638
+ name?: string;
1639
+ description?: string;
1640
+ /** @description System instructions / prompt for the agent. */
1641
+ instructions: string;
1642
+ /** @description Selected model id on the AI provider connection (e.g. `gpt-4o`). */
1643
+ model: string;
1644
+ /** @description AiProviderConnection UUID. When omitted, platform AI defaults apply. */
1645
+ aiConnectionId?: string;
1646
+ /** @description App Connection UUIDs the agent may use for tools. */
1647
+ connectionIds?: string[];
1648
+ /** @description Workflow UUIDs the agent may run (AgentWorkflow links). */
1649
+ workflowIds?: string[];
1650
+ /** @description Catalogue action tools (WorkflowNodeForRunner-shaped). */
1651
+ tools?: components["schemas"]["UpsertAgentToolDto"][];
1652
+ /** @description Marks the row as managed by code (CLI / SDK). Defaults to true on this endpoint. */
1653
+ managedByCode?: boolean;
1654
+ };
1589
1655
  CreateKnowledgeDto: {
1590
1656
  /** @description Name of the knowledge base. */
1591
1657
  name: string;
@@ -1734,6 +1800,124 @@ interface components {
1734
1800
  /** @description Vector references (parts) in the group, ordered by part number. */
1735
1801
  vectorRefs: components["schemas"]["KnowledgeDocumentGroupVectorRefDto"][];
1736
1802
  };
1803
+ CreateVariableDto: {
1804
+ /** @description Name of the variable. */
1805
+ name: string;
1806
+ /** @description Description of the variable. */
1807
+ description?: string;
1808
+ /**
1809
+ * @description Scope of the variable (system, workspace or project).
1810
+ * @enum {string}
1811
+ */
1812
+ type: "system" | "workspace" | "project";
1813
+ /**
1814
+ * @description Data type of the variable value.
1815
+ * @enum {string}
1816
+ */
1817
+ dataType: "string" | "number" | "boolean" | "date" | "json";
1818
+ /** @description Project ID to scope the variable to. Must belong to the current workspace. */
1819
+ projectId?: string;
1820
+ /** @description Variable value, submitted as a string. Values with dataType `number` are converted to numbers on save. */
1821
+ value: string;
1822
+ };
1823
+ VariableWorkspaceDto: {
1824
+ /** @description Workspace ID. */
1825
+ id: string;
1826
+ /** @description Workspace name. */
1827
+ name: string;
1828
+ };
1829
+ VariableProjectDto: {
1830
+ /** @description Project ID. */
1831
+ id: string;
1832
+ /** @description Project name. */
1833
+ name: string;
1834
+ };
1835
+ VariableResponseDto: {
1836
+ /** @description Variable ID. */
1837
+ id: string;
1838
+ /** @description Variable name. */
1839
+ name: string;
1840
+ /**
1841
+ * @description Data type of the variable value.
1842
+ * @enum {string}
1843
+ */
1844
+ dataType: "string" | "number" | "boolean" | "date" | "json";
1845
+ /**
1846
+ * @description Scope of the variable (system, workspace or project).
1847
+ * @enum {string}
1848
+ */
1849
+ type: "system" | "workspace" | "project";
1850
+ /** @description Variable value. Included when `expansion=value` is requested. */
1851
+ value?: Record<string, never>;
1852
+ /** @description Variable description. Included when `expansion=description` is requested. */
1853
+ description?: string;
1854
+ /**
1855
+ * Format: date-time
1856
+ * @description Creation timestamp. Included when `expansion=createdAt` is requested.
1857
+ */
1858
+ createdAt?: string;
1859
+ /**
1860
+ * Format: date-time
1861
+ * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
1862
+ */
1863
+ updatedAt?: string;
1864
+ /** @description Owning workspace. Included when `expansion=workspace` is requested. */
1865
+ workspace?: components["schemas"]["VariableWorkspaceDto"];
1866
+ /** @description Owning project for project-scoped variables. Included when `expansion=project` is requested. */
1867
+ project?: components["schemas"]["VariableProjectDto"];
1868
+ };
1869
+ UpdateVariableDto: {
1870
+ /** @description Name of the variable. */
1871
+ name?: string;
1872
+ /** @description Description of the variable. */
1873
+ description?: string;
1874
+ /**
1875
+ * @description Scope of the variable (system, workspace or project).
1876
+ * @enum {string}
1877
+ */
1878
+ type?: "system" | "workspace" | "project";
1879
+ /**
1880
+ * @description Data type of the variable value.
1881
+ * @enum {string}
1882
+ */
1883
+ dataType?: "string" | "number" | "boolean" | "date" | "json";
1884
+ /** @description Project ID to scope the variable to. Must belong to the current workspace. */
1885
+ projectId?: string;
1886
+ /** @description Variable value, submitted as a string. Values with dataType `number` are converted to numbers on save. */
1887
+ value?: string;
1888
+ };
1889
+ ConnectionWorkspaceDto: {
1890
+ /** @description Workspace ID. */
1891
+ id: string;
1892
+ /** @description Workspace name. */
1893
+ name: string;
1894
+ };
1895
+ ConnectionResponseDto: {
1896
+ /** @description Connection ID. */
1897
+ id: string;
1898
+ /** @description Connection name. */
1899
+ name: string;
1900
+ /**
1901
+ * Format: date-time
1902
+ * @description Creation timestamp. Included when `expansion=createdAt` is requested.
1903
+ */
1904
+ createdAt?: string;
1905
+ /**
1906
+ * Format: date-time
1907
+ * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
1908
+ */
1909
+ updatedAt?: string;
1910
+ /** @description App connection type ID (e.g. the OAuth2 or API key connection definition of the app). Included when `expansion=connectionId` is requested. */
1911
+ connectionId?: string;
1912
+ /** @description ID of the workflow app this connection belongs to. Included when `expansion=workflowAppId` or `expansion=workflowApp` is requested. */
1913
+ workflowAppId?: string;
1914
+ /** @description Full workflow app definition for this connection. Included when `expansion=workflowApp` is requested on the list endpoint. */
1915
+ workflowApp?: {
1916
+ [key: string]: unknown;
1917
+ };
1918
+ /** @description Owning workspace. Included when `expansion=workspace` is requested. */
1919
+ workspace?: components["schemas"]["ConnectionWorkspaceDto"];
1920
+ };
1737
1921
  ManuallyRunWorkflowInputDataDto: {
1738
1922
  /**
1739
1923
  * @description Values for the custom input fields configured on the workflow "Manually Run" trigger, keyed by field ID. Pass an empty object when the trigger defines no custom input fields.
@@ -1966,124 +2150,6 @@ interface components {
1966
2150
  /** @description Optional display name for the ad-hoc Execution. */
1967
2151
  name?: string;
1968
2152
  };
1969
- CreateVariableDto: {
1970
- /** @description Name of the variable. */
1971
- name: string;
1972
- /** @description Description of the variable. */
1973
- description?: string;
1974
- /**
1975
- * @description Scope of the variable (system, workspace or project).
1976
- * @enum {string}
1977
- */
1978
- type: "system" | "workspace" | "project";
1979
- /**
1980
- * @description Data type of the variable value.
1981
- * @enum {string}
1982
- */
1983
- dataType: "string" | "number" | "boolean" | "date" | "json";
1984
- /** @description Project ID to scope the variable to. Must belong to the current workspace. */
1985
- projectId?: string;
1986
- /** @description Variable value, submitted as a string. Values with dataType `number` are converted to numbers on save. */
1987
- value: string;
1988
- };
1989
- VariableWorkspaceDto: {
1990
- /** @description Workspace ID. */
1991
- id: string;
1992
- /** @description Workspace name. */
1993
- name: string;
1994
- };
1995
- VariableProjectDto: {
1996
- /** @description Project ID. */
1997
- id: string;
1998
- /** @description Project name. */
1999
- name: string;
2000
- };
2001
- VariableResponseDto: {
2002
- /** @description Variable ID. */
2003
- id: string;
2004
- /** @description Variable name. */
2005
- name: string;
2006
- /**
2007
- * @description Data type of the variable value.
2008
- * @enum {string}
2009
- */
2010
- dataType: "string" | "number" | "boolean" | "date" | "json";
2011
- /**
2012
- * @description Scope of the variable (system, workspace or project).
2013
- * @enum {string}
2014
- */
2015
- type: "system" | "workspace" | "project";
2016
- /** @description Variable value. Included when `expansion=value` is requested. */
2017
- value?: Record<string, never>;
2018
- /** @description Variable description. Included when `expansion=description` is requested. */
2019
- description?: string;
2020
- /**
2021
- * Format: date-time
2022
- * @description Creation timestamp. Included when `expansion=createdAt` is requested.
2023
- */
2024
- createdAt?: string;
2025
- /**
2026
- * Format: date-time
2027
- * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
2028
- */
2029
- updatedAt?: string;
2030
- /** @description Owning workspace. Included when `expansion=workspace` is requested. */
2031
- workspace?: components["schemas"]["VariableWorkspaceDto"];
2032
- /** @description Owning project for project-scoped variables. Included when `expansion=project` is requested. */
2033
- project?: components["schemas"]["VariableProjectDto"];
2034
- };
2035
- UpdateVariableDto: {
2036
- /** @description Name of the variable. */
2037
- name?: string;
2038
- /** @description Description of the variable. */
2039
- description?: string;
2040
- /**
2041
- * @description Scope of the variable (system, workspace or project).
2042
- * @enum {string}
2043
- */
2044
- type?: "system" | "workspace" | "project";
2045
- /**
2046
- * @description Data type of the variable value.
2047
- * @enum {string}
2048
- */
2049
- dataType?: "string" | "number" | "boolean" | "date" | "json";
2050
- /** @description Project ID to scope the variable to. Must belong to the current workspace. */
2051
- projectId?: string;
2052
- /** @description Variable value, submitted as a string. Values with dataType `number` are converted to numbers on save. */
2053
- value?: string;
2054
- };
2055
- ConnectionWorkspaceDto: {
2056
- /** @description Workspace ID. */
2057
- id: string;
2058
- /** @description Workspace name. */
2059
- name: string;
2060
- };
2061
- ConnectionResponseDto: {
2062
- /** @description Connection ID. */
2063
- id: string;
2064
- /** @description Connection name. */
2065
- name: string;
2066
- /**
2067
- * Format: date-time
2068
- * @description Creation timestamp. Included when `expansion=createdAt` is requested.
2069
- */
2070
- createdAt?: string;
2071
- /**
2072
- * Format: date-time
2073
- * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
2074
- */
2075
- updatedAt?: string;
2076
- /** @description App connection type ID (e.g. the OAuth2 or API key connection definition of the app). Included when `expansion=connectionId` is requested. */
2077
- connectionId?: string;
2078
- /** @description ID of the workflow app this connection belongs to. Included when `expansion=workflowAppId` or `expansion=workflowApp` is requested. */
2079
- workflowAppId?: string;
2080
- /** @description Full workflow app definition for this connection. Included when `expansion=workflowApp` is requested on the list endpoint. */
2081
- workflowApp?: {
2082
- [key: string]: unknown;
2083
- };
2084
- /** @description Owning workspace. Included when `expansion=workspace` is requested. */
2085
- workspace?: components["schemas"]["ConnectionWorkspaceDto"];
2086
- };
2087
2153
  TaskListItemResponseDto: {
2088
2154
  /**
2089
2155
  * @description Task ID (UUID)
@@ -2229,6 +2295,8 @@ interface components {
2229
2295
  * @example Conversation covering the Q3 regional sales report
2230
2296
  */
2231
2297
  description?: string;
2298
+ /** @description Approve (true) or clear (false) the current runtime plan for plan-before-execute gating. */
2299
+ approvePlan?: boolean;
2232
2300
  };
2233
2301
  DeletedTaskResponseDto: {
2234
2302
  /**
@@ -2302,6 +2370,10 @@ interface components {
2302
2370
  * }
2303
2371
  */
2304
2372
  data?: Record<string, never>;
2373
+ /** @description Solution Designer handoff */
2374
+ solutionId?: string;
2375
+ planStepId?: string;
2376
+ delegationId?: string;
2305
2377
  };
2306
2378
  StreamMessageStopDto: {
2307
2379
  /** @description Partial assistant message to persist when stopping a stream */
@@ -2608,6 +2680,7 @@ declare const DEFINE_KINDS: {
2608
2680
  readonly action: "action";
2609
2681
  readonly workflow: "workflow";
2610
2682
  readonly agent: "agent";
2683
+ readonly entityType: "entityType";
2611
2684
  };
2612
2685
  /** Ref to an existing app Connection (credentials stay on Lunnoa). */
2613
2686
  interface ConnectionDefinition {
@@ -2674,6 +2747,25 @@ interface AgentDefinition {
2674
2747
  /** Action and/or workflow tool refs. */
2675
2748
  tools?: AgentToolDefinition[];
2676
2749
  }
2750
+ interface EntityTypeDefinition {
2751
+ kind: typeof DEFINE_KINDS.entityType;
2752
+ /** Stable workspace-scoped slug (upsert key). */
2753
+ slug: string;
2754
+ name?: string;
2755
+ namePlural?: string;
2756
+ description?: string;
2757
+ icon?: string;
2758
+ color?: string;
2759
+ /** Field definitions grouped into sections (same contract as Adminspace). */
2760
+ attributeSchema: Record<string, unknown>;
2761
+ stateSchema?: Record<string, unknown> | null;
2762
+ isEnabled?: boolean;
2763
+ /**
2764
+ * When false (default), entity writes reject undeclared attribute keys.
2765
+ * Reserved key `extensions` is always allowed as a JSON object.
2766
+ */
2767
+ allowUnknownAttributes?: boolean;
2768
+ }
2677
2769
 
2678
2770
  interface UpsertAgentToolInput {
2679
2771
  appId: string;
@@ -2967,6 +3059,20 @@ interface EntityTypeReadOptions {
2967
3059
  /** Fields to expand, e.g. `['attributeSchema', 'stateSchema', 'description']`. */
2968
3060
  expansion?: string | string[];
2969
3061
  }
3062
+ /** Payload for `POST /api/object-types/upsert`. */
3063
+ interface UpsertEntityTypeBySlugInput {
3064
+ slug: string;
3065
+ name?: string;
3066
+ namePlural?: string;
3067
+ description?: string;
3068
+ icon?: string;
3069
+ color?: string;
3070
+ attributeSchema: Record<string, unknown>;
3071
+ stateSchema?: Record<string, unknown> | null;
3072
+ isEnabled?: boolean;
3073
+ allowUnknownAttributes?: boolean;
3074
+ managedByCode?: boolean;
3075
+ }
2970
3076
  declare class EntityTypesResource {
2971
3077
  private readonly http;
2972
3078
  constructor(http: HttpClient);
@@ -2982,6 +3088,11 @@ declare class EntityTypesResource {
2982
3088
  get(id: string, options?: EntityTypeReadOptions): Promise<EntityType>;
2983
3089
  /** Returns a single entity type by its URL-safe slug. */
2984
3090
  getBySlug(slug: string, options?: EntityTypeReadOptions): Promise<EntityType>;
3091
+ /**
3092
+ * Creates or updates an entity type by workspace-scoped slug.
3093
+ * Prefer the CLI (`npx @lunnoa/client entity-types deploy`) for happy-path deploy.
3094
+ */
3095
+ upsertBySlug(definition: EntityTypeDefinition | UpsertEntityTypeBySlugInput): Promise<EntityType>;
2985
3096
  }
2986
3097
 
2987
3098
  type EligibleApprover = {