@proteos/sdk 0.50.1 → 0.51.1

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/src/index.ts CHANGED
@@ -133,15 +133,18 @@ export type {
133
133
  CreateApiKeyRequest,
134
134
  CreatedApiKey,
135
135
  CreateOrganizationRequest,
136
+ CreateProfileRequest,
136
137
  CreateRoleRequest,
137
138
  CreateTeamRequest,
138
139
  CreateUserRequest,
139
140
  ListOrganizationsOptions,
140
141
  ListOrgUserRoleAssignmentsOptions,
142
+ ListProfilesOptions,
141
143
  ListRolePermissionsOptions,
142
144
  ListRolesOptions,
143
145
  ListTeamMembersOptions,
144
146
  ListTeamsOptions,
147
+ ListUserProfileAssignmentsOptions,
145
148
  ListUserRoleAssignmentsOptions,
146
149
  ListUsersOptions,
147
150
  // Me (caller-scoped) service
@@ -153,10 +156,14 @@ export type {
153
156
  Permission,
154
157
  // Platform entities
155
158
  PlatformEntity,
159
+ // Profile types (the org's user-types, one per user)
160
+ Profile,
161
+ ProfileService,
156
162
  // Role types
157
163
  Role,
158
164
  RoleEntityPermission,
159
165
  RoleService,
166
+ SetProfileRequest,
160
167
  // Share types (instance-level access)
161
168
  SharePermission,
162
169
  ShareRow,
@@ -166,11 +173,14 @@ export type {
166
173
  TeamService,
167
174
  UpdateMeRequest,
168
175
  UpdateOrganizationRequest,
176
+ UpdateProfileRequest,
169
177
  UpdateRoleRequest,
170
178
  UpdateTeamRequest,
171
179
  UpdateUserRequest,
172
180
  // User types
173
181
  User,
182
+ UserProfileAssignment,
183
+ UserProfileAssignmentService,
174
184
  // User role assignment types
175
185
  UserRoleAssignment,
176
186
  UserRoleAssignmentService,
@@ -185,10 +195,12 @@ export {
185
195
  OrganizationSchema,
186
196
  PLATFORM_ENTITIES,
187
197
  PLATFORM_ENTITY_SLUGS,
198
+ ProfileSchema,
188
199
  RoleEntityPermissionSchema,
189
200
  RoleSchema,
190
201
  SCOPED_PLATFORM_ENTITY_SLUGS,
191
202
  shareRouteFor,
203
+ UserProfileAssignmentSchema,
192
204
  UserRoleAssignmentSchema,
193
205
  UserSchema,
194
206
  } from './auth/index.js'
@@ -224,10 +236,13 @@ export type {
224
236
  AllFilterConfig,
225
237
  ApplySendingLimitPresetRequest,
226
238
  AttachContactAddressRequest,
239
+ AttachConversationBriefRequest,
227
240
  Attachment,
228
241
  AutomatedFilterConfig,
229
242
  AutomatedSignal,
230
243
  BlockContactRequest,
244
+ BounceClassification,
245
+ BounceKind,
231
246
  CallStatus,
232
247
  CallTokenResponse,
233
248
  Channel,
@@ -239,6 +254,9 @@ export type {
239
254
  ChannelActionStatus,
240
255
  ChannelActionTargetKind,
241
256
  ChannelActionType,
257
+ ChannelEvent,
258
+ ChannelEventService,
259
+ ChannelEventType,
242
260
  Connection,
243
261
  ConnectionCredentials,
244
262
  ConnectionScope,
@@ -246,6 +264,7 @@ export type {
246
264
  ConnectionStatus,
247
265
  ConnectionSyncRange,
248
266
  ConnectionSyncStatus,
267
+ ConnectorCatalogEntry,
249
268
  ConnectorKey,
250
269
  ConnectorProvider,
251
270
  ConsentStatus,
@@ -265,6 +284,9 @@ export type {
265
284
  // Aliased: the agent module already exports its own ContentBlock.
266
285
  ContentBlock as MessageContentBlock,
267
286
  Conversation,
287
+ ConversationBrief,
288
+ ConversationBriefService,
289
+ ConversationBriefStatus,
268
290
  ConversationFilter,
269
291
  ConversationFilterAction,
270
292
  ConversationFilterConfig,
@@ -281,6 +303,8 @@ export type {
281
303
  CreateAgentListenerRequest,
282
304
  CreateConnectionRequest,
283
305
  CreateContactGroupRequest,
306
+ CreateContactRequest,
307
+ CreateConversationBriefRequest,
284
308
  CreateConversationFilterRequest,
285
309
  CreateConversationTypeRequest,
286
310
  CreateGlossaryTermRequest,
@@ -288,9 +312,23 @@ export type {
288
312
  CreateToneProfileSetupRequest,
289
313
  DispatchMeetingBotRequest,
290
314
  DomainFilterConfig,
315
+ EmailDnsRecord,
316
+ EmailDomainStatus,
317
+ EmailEngagementQuality,
318
+ EmailHealth,
319
+ EmailHealthWindow,
320
+ EmailIp,
321
+ EmailProviderHealth,
322
+ EmailProviderStats,
323
+ EmailSender,
324
+ EmailSenderStatus,
325
+ EmailSuppression,
326
+ EmailSuppressionCounts,
327
+ EmailSuppressionKind,
291
328
  ErasureRequestStatus,
292
329
  FilterMatchOn,
293
330
  FrequencyCapRuleConfig,
331
+ GetConnectionHealthQuery,
294
332
  GlossaryTerm,
295
333
  GlossaryTermService,
296
334
  InmailParams,
@@ -300,11 +338,13 @@ export type {
300
338
  LimitRuleConfig,
301
339
  ListAgentListenersQuery,
302
340
  ListChannelActionsQuery,
341
+ ListChannelEventsQuery,
303
342
  ListConnectionsQuery,
304
343
  ListContactAddressesQuery,
305
344
  ListContactGroupsQuery,
306
345
  ListContactMergeProposalsQuery,
307
346
  ListContactsQuery,
347
+ ListConversationBriefsQuery,
308
348
  ListConversationFilterEventsQuery,
309
349
  ListConversationFiltersQuery,
310
350
  ListConversationsQuery,
@@ -324,6 +364,8 @@ export type {
324
364
  MergeContactsRequest,
325
365
  MergeProposalStatus,
326
366
  Message,
367
+ MessageDelivery,
368
+ MessageDeliveryStatus,
327
369
  MessageDirection,
328
370
  MessagePreview,
329
371
  MessageRecipient,
@@ -363,6 +405,7 @@ export type {
363
405
  SendingRuleType,
364
406
  SendMessageRequest,
365
407
  SendRecipient,
408
+ SetDefaultSenderRequest,
366
409
  SyncConnectionRequest,
367
410
  ToneProfile,
368
411
  ToneProfileScope,
@@ -380,6 +423,7 @@ export type {
380
423
  UpdateConnectionRequest,
381
424
  UpdateContactGroupRequest,
382
425
  UpdateContactRequest,
426
+ UpdateConversationBriefRequest,
383
427
  UpdateConversationFilterRequest,
384
428
  UpdateConversationTypeRequest,
385
429
  UpdateDraftRequest,
@@ -388,6 +432,7 @@ export type {
388
432
  UpdateSendingRuleRequest,
389
433
  VoiceService,
390
434
  VoiceTranscriptionStream,
435
+ WarmupRuleConfig,
391
436
  Weekday,
392
437
  WindowDay,
393
438
  WindowRuleConfig,
@@ -535,6 +580,11 @@ export {
535
580
  export type {
536
581
  // App types
537
582
  App,
583
+ // AppConfiguration types
584
+ AppConfiguration,
585
+ AppConfigurationService,
586
+ AppHome,
587
+ AppHomeType,
538
588
  AppService,
539
589
  // Array/enum attribute metas (config_schema renderers narrow on these)
540
590
  ArrayAttributeMeta,
@@ -548,6 +598,7 @@ export type {
548
598
  // Component types
549
599
  Component,
550
600
  ComponentService,
601
+ CreateAppConfigurationRequest,
551
602
  CreateAppRequest,
552
603
  CreateComponentRequest,
553
604
  CreateDesignReferenceRequest,
@@ -579,6 +630,7 @@ export type {
579
630
  FilterGroup,
580
631
  // List types
581
632
  List,
633
+ ListAppConfigurationsOptions,
582
634
  ListAppsOptions,
583
635
  ListComponentsOptions,
584
636
  ListDesignReferencesOptions,
@@ -619,6 +671,7 @@ export type {
619
671
  RelationAttributeMeta,
620
672
  SortConfig,
621
673
  SortDirection,
674
+ UpdateAppConfigurationRequest,
622
675
  UpdateAppRequest,
623
676
  UpdateComponentRequest,
624
677
  UpdateDesignReferenceRequest,
@@ -636,6 +689,8 @@ export type {
636
689
  // Value-level constants from meta
637
690
  // Meta Zod schemas
638
691
  export {
692
+ AppConfigurationSchema,
693
+ AppHomeSchema,
639
694
  AppSchema,
640
695
  AttributeSchema,
641
696
  acceptsCurrentUserDefault,
@@ -0,0 +1,100 @@
1
+ import type { ProteosClient } from '../client.js'
2
+ import { PageIterator } from '../iterator.js'
3
+ import type { ListResult } from '../types/common.js'
4
+ import type {
5
+ AppConfiguration,
6
+ CreateAppConfigurationRequest,
7
+ ListAppConfigurationsOptions,
8
+ UpdateAppConfigurationRequest,
9
+ } from './types.js'
10
+
11
+ const APP_CONFIGURATIONS_BASE_PATH = '/meta/v1/app-configurations'
12
+
13
+ /**
14
+ * Service for app configurations — the typed (app × profile) binding rows
15
+ * that say how an app presents itself: home, menu, agents, record pages.
16
+ * `profile_slug: ''` is the app's base configuration for everyone; a row with
17
+ * a profile is that profile's override (merged field-wise over the base).
18
+ */
19
+ export interface AppConfigurationService {
20
+ /** Lists app configurations (auto-paginating iterator). */
21
+ list(
22
+ options?: ListAppConfigurationsOptions,
23
+ ): PageIterator<AppConfiguration, ListAppConfigurationsOptions>
24
+
25
+ /** Fetches a single page of app configurations. */
26
+ listPage(options?: ListAppConfigurationsOptions): Promise<ListResult<AppConfiguration>>
27
+
28
+ /** Gets an app configuration by slug (404 when unknown). */
29
+ get(slug: string): Promise<AppConfiguration>
30
+
31
+ /**
32
+ * Creates an app configuration. Every reference (app, home list/page, menu,
33
+ * record pages) must exist; `profile_slug` and agent keys are other
34
+ * services' and are not validated.
35
+ * @throws {ProteosError} 409 `app_configuration_already_exists` when the
36
+ * (app_slug, profile_slug) pair is already bound.
37
+ */
38
+ create(request: CreateAppConfigurationRequest): Promise<AppConfiguration>
39
+
40
+ /**
41
+ * Creates or replaces an app configuration idempotently by slug
42
+ * (`PUT /meta/v1/app-configurations/:slug`). Replaces the whole
43
+ * configuration; the (app_slug, profile_slug) binding of an existing slug
44
+ * is immutable.
45
+ */
46
+ upsert(slug: string, request: CreateAppConfigurationRequest): Promise<AppConfiguration>
47
+
48
+ /** Partially updates an app configuration (`home: null` clears the home). */
49
+ update(slug: string, request: UpdateAppConfigurationRequest): Promise<AppConfiguration>
50
+
51
+ /** Deletes an app configuration. */
52
+ delete(slug: string): Promise<void>
53
+ }
54
+
55
+ export class AppConfigurationServiceImpl implements AppConfigurationService {
56
+ constructor(private readonly client: ProteosClient) {}
57
+
58
+ list(
59
+ options: ListAppConfigurationsOptions = {},
60
+ ): PageIterator<AppConfiguration, ListAppConfigurationsOptions> {
61
+ return new PageIterator((opts) => this.listPage(opts), options)
62
+ }
63
+
64
+ async listPage(
65
+ options: ListAppConfigurationsOptions = {},
66
+ ): Promise<ListResult<AppConfiguration>> {
67
+ return this.client.requestWithQuery<ListResult<AppConfiguration>>(
68
+ 'GET',
69
+ APP_CONFIGURATIONS_BASE_PATH,
70
+ options,
71
+ )
72
+ }
73
+
74
+ async get(slug: string): Promise<AppConfiguration> {
75
+ return this.client.request<AppConfiguration>('GET', `${APP_CONFIGURATIONS_BASE_PATH}/${slug}`)
76
+ }
77
+
78
+ async create(request: CreateAppConfigurationRequest): Promise<AppConfiguration> {
79
+ return this.client.request<AppConfiguration>('POST', APP_CONFIGURATIONS_BASE_PATH, request)
80
+ }
81
+
82
+ async upsert(slug: string, request: CreateAppConfigurationRequest): Promise<AppConfiguration> {
83
+ return this.client.request<AppConfiguration>('PUT', `${APP_CONFIGURATIONS_BASE_PATH}/${slug}`, {
84
+ ...request,
85
+ slug,
86
+ })
87
+ }
88
+
89
+ async update(slug: string, request: UpdateAppConfigurationRequest): Promise<AppConfiguration> {
90
+ return this.client.request<AppConfiguration>(
91
+ 'PATCH',
92
+ `${APP_CONFIGURATIONS_BASE_PATH}/${slug}`,
93
+ request,
94
+ )
95
+ }
96
+
97
+ async delete(slug: string): Promise<void> {
98
+ await this.client.request<void>('DELETE', `${APP_CONFIGURATIONS_BASE_PATH}/${slug}`)
99
+ }
100
+ }
package/src/meta/index.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import type { ProteosClient } from '../client.js'
2
+ import { type AppConfigurationService, AppConfigurationServiceImpl } from './app-configurations.js'
2
3
  import { type AppService, AppServiceImpl } from './apps.js'
3
4
  import { type ComponentService, ComponentServiceImpl } from './components.js'
4
5
  import { type DesignReferenceService, DesignReferenceServiceImpl } from './design-references.js'
@@ -79,6 +80,12 @@ export class MetaClient {
79
80
  */
80
81
  readonly apps: AppService
81
82
 
83
+ /**
84
+ * Service for managing app configurations — the typed (app × profile)
85
+ * bindings: home, menu, agents, record pages.
86
+ */
87
+ readonly appConfigurations: AppConfigurationService
88
+
82
89
  /**
83
90
  * Service for managing design references (stored DESIGN.md documents).
84
91
  */
@@ -99,10 +106,12 @@ export class MetaClient {
99
106
  this.pages = new PageServiceImpl(client)
100
107
  this.menuConfigurations = new MenuConfigurationServiceImpl(client)
101
108
  this.apps = new AppServiceImpl(client)
109
+ this.appConfigurations = new AppConfigurationServiceImpl(client)
102
110
  this.designReferences = new DesignReferenceServiceImpl(client)
103
111
  }
104
112
  }
105
113
 
114
+ export type { AppConfigurationService } from './app-configurations.js'
106
115
  export type { AppService } from './apps.js'
107
116
  export type { ComponentService } from './components.js'
108
117
  export * from './currency/index.js'
@@ -120,16 +129,21 @@ export type { PageService } from './pages.js'
120
129
  export type {
121
130
  // App types
122
131
  App,
132
+ // AppConfiguration types
133
+ AppConfiguration,
134
+ AppHome,
135
+ AppHomeType,
123
136
  ArrayAttributeMeta,
124
137
  Attribute,
125
- AttributeMeta,
126
138
  AttributeAccessRule,
139
+ AttributeMeta,
127
140
  AttributeRestrictions,
128
141
  AttributeType,
129
142
  Column,
130
143
  ComparisonOperator,
131
144
  // Component types
132
145
  Component,
146
+ CreateAppConfigurationRequest,
133
147
  CreateAppRequest,
134
148
  CreateComponentRequest,
135
149
  CreateDesignReferenceRequest,
@@ -142,6 +156,7 @@ export type {
142
156
  // Currency attribute meta + value
143
157
  CurrencyAttributeMeta,
144
158
  CurrencyValue,
159
+ CurrentUserDefault,
145
160
  DatetimeAttributeMeta,
146
161
  DatetimeFormat,
147
162
  DeployModuleRequest,
@@ -159,6 +174,7 @@ export type {
159
174
  FilterGroup,
160
175
  // List types
161
176
  List,
177
+ ListAppConfigurationsOptions,
162
178
  ListAppsOptions,
163
179
  ListComponentsOptions,
164
180
  ListDesignReferencesOptions,
@@ -188,6 +204,10 @@ export type {
188
204
  PageAction,
189
205
  PageActionKind,
190
206
  PageType,
207
+ // User attribute meta
208
+ PrincipalAttributeMeta,
209
+ PrincipalRef,
210
+ PrincipalType,
191
211
  PublicAccessOperation,
192
212
  PublicPageComponent,
193
213
  PublicPageResponse,
@@ -197,6 +217,7 @@ export type {
197
217
  SortDirection,
198
218
  StringAttributeMeta,
199
219
  StringFormat,
220
+ UpdateAppConfigurationRequest,
200
221
  UpdateAppRequest,
201
222
  UpdateComponentRequest,
202
223
  UpdateDesignReferenceRequest,
@@ -206,11 +227,6 @@ export type {
206
227
  UpdateMenuConfigurationRequest,
207
228
  UpdatePageRequest,
208
229
  UpdateVariableRequest,
209
- // User attribute meta
210
- PrincipalAttributeMeta,
211
- CurrentUserDefault,
212
- PrincipalRef,
213
- PrincipalType,
214
230
  UserAttributeMeta,
215
231
  // Variable types
216
232
  Variable,
@@ -218,10 +234,14 @@ export type {
218
234
  // Re-export value-level constants
219
235
  // Re-export Zod schemas
220
236
  export {
237
+ AppConfigurationSchema,
238
+ AppHomeSchema,
221
239
  AppSchema,
222
240
  AttributeSchema,
241
+ acceptsCurrentUserDefault,
223
242
  ColumnSchema,
224
243
  ComponentSchema,
244
+ CURRENT_USER_DEFAULT,
225
245
  CurrencyAttributeMetaSchema,
226
246
  DesignReferenceSchema,
227
247
  EntitySchema,
@@ -229,6 +249,7 @@ export {
229
249
  FileAttributeMetaSchema,
230
250
  FilterElementSchema,
231
251
  FilterGroupSchema,
252
+ isCurrentUserDefault,
232
253
  isPlatformAttributeName,
233
254
  ListSchema,
234
255
  ListViewSchema,
@@ -240,12 +261,9 @@ export {
240
261
  PageActionSchema,
241
262
  PageSchema,
242
263
  PLATFORM_ATTRIBUTE_NAMES,
243
- CURRENT_USER_DEFAULT,
244
- acceptsCurrentUserDefault,
245
- isCurrentUserDefault,
246
264
  parseCurrencyMeta,
247
- parsePrincipalMeta,
248
265
  parseFileMeta,
266
+ parsePrincipalMeta,
249
267
  parseRelationMeta,
250
268
  parseUserMeta,
251
269
  platformAttributes,
package/src/meta/types.ts CHANGED
@@ -994,7 +994,6 @@ export interface List extends AuditFields {
994
994
  /** Row-selection affordance; absent normalizes to `on_demand`. */
995
995
  selection_mode?: SelectionMode
996
996
  /** Record page to open from this list; empty/absent = org default for the entity. */
997
- default_page_slug?: string
998
997
  sorting: SortConfig[]
999
998
  filters: FilterGroup[]
1000
999
  }
@@ -1018,7 +1017,6 @@ export const ListSchema = AuditFieldsSchema.extend({
1018
1017
  columns: z.array(ColumnSchema),
1019
1018
  actions: z.array(PageActionSchema).optional(),
1020
1019
  selection_mode: SelectionModeSchema.optional(),
1021
- default_page_slug: z.string().optional(),
1022
1020
  sorting: z.array(SortConfigSchema),
1023
1021
  filters: z.array(FilterGroupSchema),
1024
1022
  })
@@ -1044,7 +1042,6 @@ export interface CreateListRequest {
1044
1042
  columns: Column[]
1045
1043
  actions?: PageAction[]
1046
1044
  selection_mode?: SelectionMode
1047
- default_page_slug?: string
1048
1045
  sorting: SortConfig[]
1049
1046
  filters: FilterGroup[]
1050
1047
  }
@@ -1059,7 +1056,6 @@ export interface UpdateListRequest {
1059
1056
  actions?: PageAction[]
1060
1057
  selection_mode?: SelectionMode
1061
1058
  /** Set to '' to clear back to the org default. */
1062
- default_page_slug?: string
1063
1059
  sorting?: SortConfig[]
1064
1060
  filters?: FilterGroup[]
1065
1061
  }
@@ -1329,6 +1325,100 @@ export interface UpdateMenuConfigurationRequest {
1329
1325
  is_default?: boolean
1330
1326
  }
1331
1327
 
1328
+ // ============================================================================
1329
+ // AppConfiguration Types
1330
+ // ============================================================================
1331
+
1332
+ /** What an app opens on: a list (records table) or a platform page. */
1333
+ export type AppHomeType = 'list' | 'page'
1334
+
1335
+ export interface AppHome {
1336
+ type: AppHomeType
1337
+ reference: string
1338
+ }
1339
+
1340
+ export const AppHomeSchema = z.object({
1341
+ type: z.enum(['list', 'page']),
1342
+ reference: z.string(),
1343
+ })
1344
+
1345
+ /**
1346
+ * AppConfiguration — a TYPED binding row: "how app X presents itself" to
1347
+ * everyone (`profile_slug: ''` = the app's default configuration) or to one
1348
+ * profile (an override). One row per (app, profile). The web merges
1349
+ * override ⊕ default field-wise and falls through to structural defaults (menu
1350
+ * `is_default`, first menu leaf, org-default agent, first page) for anything
1351
+ * still unset.
1352
+ */
1353
+ export interface AppConfiguration extends AuditFields {
1354
+ slug: string
1355
+ org_id: string
1356
+ module_slug: string
1357
+ app_slug: string
1358
+ /** Bound profile; `''` = the default configuration for everyone. */
1359
+ profile_slug: string
1360
+ /** Home; absent = the first list/page leaf of the resolved menu. */
1361
+ home?: AppHome | null
1362
+ /** Menu to show; `''` = the app's `is_default` menu. */
1363
+ menu_slug?: string
1364
+ /** Agent Ask Proteos preselects in this app; `''` = the org default. */
1365
+ default_agent_key?: string
1366
+ /** Agents offered in this app; empty = every org agent. */
1367
+ agent_keys?: string[]
1368
+ /** entity_slug → record page slug opened from this app. */
1369
+ record_pages?: Record<string, string>
1370
+ }
1371
+
1372
+ export const AppConfigurationSchema = AuditFieldsSchema.extend({
1373
+ slug: z.string(),
1374
+ org_id: z.string(),
1375
+ module_slug: z.string(),
1376
+ app_slug: z.string(),
1377
+ profile_slug: z.string(),
1378
+ home: AppHomeSchema.nullable().optional(),
1379
+ menu_slug: z.string().optional(),
1380
+ default_agent_key: z.string().optional(),
1381
+ agent_keys: z.array(z.string()).optional(),
1382
+ record_pages: z.record(z.string()).optional(),
1383
+ })
1384
+
1385
+ export interface ListAppConfigurationsOptions extends MetaListOptions {
1386
+ slug?: string
1387
+ module_slug?: string
1388
+ app_slug?: string
1389
+ profile_slug?: string
1390
+ /** `true` = only default rows (no profile), `false` = only profile overrides.
1391
+ * An empty `profile_slug` is never sent, so this is how default rows are
1392
+ * selected. */
1393
+ is_default?: boolean
1394
+ menu_slug?: string
1395
+ }
1396
+
1397
+ export interface CreateAppConfigurationRequest {
1398
+ slug: string
1399
+ module_slug?: string
1400
+ app_slug: string
1401
+ profile_slug?: string
1402
+ home?: AppHome | null
1403
+ menu_slug?: string
1404
+ default_agent_key?: string
1405
+ agent_keys?: string[]
1406
+ record_pages?: Record<string, string>
1407
+ }
1408
+
1409
+ /**
1410
+ * Partial update. `home` is tri-state: absent = unchanged, `null` = clear,
1411
+ * object = set. The (app_slug, profile_slug) binding is immutable.
1412
+ */
1413
+ export interface UpdateAppConfigurationRequest {
1414
+ module_slug?: string
1415
+ home?: AppHome | null
1416
+ menu_slug?: string
1417
+ default_agent_key?: string
1418
+ agent_keys?: string[]
1419
+ record_pages?: Record<string, string>
1420
+ }
1421
+
1332
1422
  // ============================================================================
1333
1423
  // App Types
1334
1424
  // ============================================================================
@@ -456,6 +456,8 @@ export interface Workflow extends AuditFields {
456
456
  key: string
457
457
  name: string
458
458
  description: string
459
+ /** Slug of the module that deployed this workflow; empty when it is org-owned. */
460
+ module_slug: string
459
461
  status: WorkflowStatus
460
462
  graph: WorkflowGraph
461
463
  version: number
@@ -533,6 +535,15 @@ export interface ListWorkflowsOptions extends ListOptions {
533
535
  name?: string
534
536
  'name[contains]'?: string
535
537
  status?: WorkflowStatus
538
+ /**
539
+ * Restrict to one module's workflows. The empty string is meaningful: it
540
+ * matches only the org-owned workflows no module deployed.
541
+ *
542
+ * `sort_by` additionally accepts a comma-separated list of sortable fields
543
+ * (`module_slug,name`) so a grouped list can order by its grouping column
544
+ * first; `sort_direction` applies to all of them.
545
+ */
546
+ module_slug?: string
536
547
  }
537
548
 
538
549
  // ---------------------------------------------------------------------------