Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
seambot committed Dec 20, 2024
1 parent e190d9c commit d8ba920
Show file tree
Hide file tree
Showing 3 changed files with 175 additions and 0 deletions.
44 changes: 44 additions & 0 deletions src/lib/seam/connect/models/acs/acs-access-group.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,47 @@ export type AcsAccessGroupExternalType = z.infer<
typeof acs_access_group_external_type
>

const common_acs_access_group_warning = z.object({
created_at: z
.string()
.datetime()
.describe('Date and time at which Seam created the warning.'),
message: z
.string()
.describe(
'Detailed description of the warning. Provides insights into the issue and potentially how to rectify it.',
),
})

const warning_code_description =
'Unique identifier of the type of warning. Enables quick recognition and categorization of the issue.'

export const unknown_issue_with_acs_access_group =
common_acs_access_group_warning
.extend({
warning_code: z
.literal('unknown_issue_with_acs_access_group')
.describe(warning_code_description),
})
.describe(
'An unknown issue occurred while syncing the state of this access group with the provider. ' +
'This issue may affect the proper functioning of this access group.',
)

const acs_access_group_warning = unknown_issue_with_acs_access_group.describe(
'Warning associated with the `acs_access_group`.',
)

const acs_access_group_warning_map = z.object({
unknown_issue_with_acs_access_group: unknown_issue_with_acs_access_group
.optional()
.nullable(),
})

export type AcsAccessGroupWarningMap = z.infer<
typeof acs_access_group_warning_map
>

const common_acs_access_group = z.object({
acs_access_group_id: z.string().uuid().describe('ID of the access group.'),
acs_system_id: z
Expand Down Expand Up @@ -52,6 +93,9 @@ const common_acs_access_group = z.object({
.string()
.datetime()
.describe('Date and time at which the access group was created.'),
warnings: z
.array(acs_access_group_warning)
.describe('Warnings associated with the `acs_access_group`.'),
})

export const acs_access_group = common_acs_access_group.extend({
Expand Down
95 changes: 95 additions & 0 deletions src/lib/seam/connect/openapi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,34 @@ export default {
},
is_managed: { enum: [true], type: 'boolean' },
name: { description: 'Name of the access group.', type: 'string' },
warnings: {
description: 'Warnings associated with the `acs_access_group`.',
items: {
description: 'Warning associated with the `acs_access_group`.',
properties: {
created_at: {
description:
'Date and time at which Seam created the warning.',
format: 'date-time',
type: 'string',
},
message: {
description:
'Detailed description of the warning. Provides insights into the issue and potentially how to rectify it.',
type: 'string',
},
warning_code: {
description:
'Unique identifier of the type of warning. Enables quick recognition and categorization of the issue.',
enum: ['unknown_issue_with_acs_access_group'],
type: 'string',
},
},
required: ['created_at', 'message', 'warning_code'],
type: 'object',
},
type: 'array',
},
workspace_id: {
description:
'ID of the [workspace](https://docs.seam.co/latest/core-concepts/workspaces) that contains the access group.',
Expand All @@ -262,6 +290,7 @@ export default {
'external_type',
'external_type_display_name',
'created_at',
'warnings',
'is_managed',
],
type: 'object',
Expand Down Expand Up @@ -12468,6 +12497,36 @@ export default {
description: 'Name of the access group.',
type: 'string',
},
warnings: {
description:
'Warnings associated with the `acs_access_group`.',
items: {
description:
'Warning associated with the `acs_access_group`.',
properties: {
created_at: {
description:
'Date and time at which Seam created the warning.',
format: 'date-time',
type: 'string',
},
message: {
description:
'Detailed description of the warning. Provides insights into the issue and potentially how to rectify it.',
type: 'string',
},
warning_code: {
description:
'Unique identifier of the type of warning. Enables quick recognition and categorization of the issue.',
enum: ['unknown_issue_with_acs_access_group'],
type: 'string',
},
},
required: ['created_at', 'message', 'warning_code'],
type: 'object',
},
type: 'array',
},
workspace_id: {
description:
'ID of the [workspace](https://docs.seam.co/latest/core-concepts/workspaces) that contains the access group.',
Expand All @@ -12486,6 +12545,7 @@ export default {
'external_type',
'external_type_display_name',
'created_at',
'warnings',
'is_managed',
],
type: 'object',
Expand Down Expand Up @@ -12613,6 +12673,40 @@ export default {
description: 'Name of the access group.',
type: 'string',
},
warnings: {
description:
'Warnings associated with the `acs_access_group`.',
items: {
description:
'Warning associated with the `acs_access_group`.',
properties: {
created_at: {
description:
'Date and time at which Seam created the warning.',
format: 'date-time',
type: 'string',
},
message: {
description:
'Detailed description of the warning. Provides insights into the issue and potentially how to rectify it.',
type: 'string',
},
warning_code: {
description:
'Unique identifier of the type of warning. Enables quick recognition and categorization of the issue.',
enum: ['unknown_issue_with_acs_access_group'],
type: 'string',
},
},
required: [
'created_at',
'message',
'warning_code',
],
type: 'object',
},
type: 'array',
},
workspace_id: {
description:
'ID of the [workspace](https://docs.seam.co/latest/core-concepts/workspaces) that contains the access group.',
Expand All @@ -12631,6 +12725,7 @@ export default {
'external_type',
'external_type_display_name',
'created_at',
'warnings',
'is_managed',
],
type: 'object',
Expand Down
36 changes: 36 additions & 0 deletions src/lib/seam/connect/route-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4572,6 +4572,15 @@ export interface Routes {
external_type_display_name: string
/** Date and time at which the access group was created. */
created_at: string
/** Warnings associated with the `acs_access_group`. */
warnings: Array<{
/** Date and time at which Seam created the warning. */
created_at: string
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
message: string
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
warning_code: 'unknown_issue_with_acs_access_group'
}>
is_managed: true
}
}
Expand Down Expand Up @@ -4623,6 +4632,15 @@ export interface Routes {
external_type_display_name: string
/** Date and time at which the access group was created. */
created_at: string
/** Warnings associated with the `acs_access_group`. */
warnings: Array<{
/** Date and time at which Seam created the warning. */
created_at: string
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
message: string
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
warning_code: 'unknown_issue_with_acs_access_group'
}>
is_managed: true
}>
}
Expand Down Expand Up @@ -4899,6 +4917,15 @@ export interface Routes {
external_type_display_name: string
/** Date and time at which the access group was created. */
created_at: string
/** Warnings associated with the `acs_access_group`. */
warnings: Array<{
/** Date and time at which Seam created the warning. */
created_at: string
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
message: string
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
warning_code: 'unknown_issue_with_acs_access_group'
}>
is_managed: false
}
}
Expand Down Expand Up @@ -4950,6 +4977,15 @@ export interface Routes {
external_type_display_name: string
/** Date and time at which the access group was created. */
created_at: string
/** Warnings associated with the `acs_access_group`. */
warnings: Array<{
/** Date and time at which Seam created the warning. */
created_at: string
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
message: string
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
warning_code: 'unknown_issue_with_acs_access_group'
}>
is_managed: false
}>
}
Expand Down

0 comments on commit d8ba920

Please sign in to comment.