Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 84 additions & 0 deletions src/lib/seam/connect/openapi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29115,6 +29115,90 @@ export default {
'x-title': 'List Access Grants',
},
},
'/access_grants/request_access_methods': {
post: {
description:
'Adds additional requested access methods to an existing Access Grant.',
operationId: 'accessGrantsRequestAccessMethodsPost',
requestBody: {
content: {
'application/json': {
schema: {
properties: {
access_grant_id: {
description:
'ID of the Access Grant to add access methods to.',
format: 'uuid',
type: 'string',
},
requested_access_methods: {
description:
'Array of requested access methods to add to the access grant.',
items: {
properties: {
code: {
description:
"Specific PIN code to use for this access method. Only applicable when mode is 'code'.",
maxLength: 9,
minLength: 4,
pattern: '^\\d+$',
type: 'string',
},
mode: {
description:
'Access method mode. Supported values: `code`, `card`, `mobile_key`.',
enum: ['code', 'card', 'mobile_key'],
type: 'string',
},
},
required: ['mode'],
type: 'object',
},
minItems: 1,
type: 'array',
},
},
required: ['access_grant_id', 'requested_access_methods'],
type: 'object',
},
},
},
},
responses: {
200: {
content: {
'application/json': {
schema: {
properties: {
access_grant: { $ref: '#/components/schemas/access_grant' },
ok: { type: 'boolean' },
},
required: ['access_grant', 'ok'],
type: 'object',
},
},
},
description: 'OK',
},
400: { description: 'Bad Request' },
401: { description: 'Unauthorized' },
},
security: [
{ pat_with_workspace: [] },
{ console_session_with_workspace: [] },
{ api_key: [] },
{ client_session_with_customer: [] },
],
summary: '/access_grants/request_access_methods',
tags: [],
'x-draft': 'Early access.',
'x-fern-sdk-group-name': ['access_grants'],
'x-fern-sdk-method-name': 'request_access_methods',
'x-fern-sdk-return-value': 'access_grant',
'x-response-key': 'access_grant',
'x-title': 'Add Requested Access Methods to Access Grant',
},
},
'/access_grants/unmanaged/get': {
get: {
description:
Expand Down
76 changes: 76 additions & 0 deletions src/lib/seam/connect/route-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13551,6 +13551,82 @@ export type Routes = {
}[]
}
}
'/access_grants/request_access_methods': {
route: '/access_grants/request_access_methods'
method: 'POST'
queryParams: {}
jsonBody: {}
commonParams: {
/** ID of the Access Grant to add access methods to. */
access_grant_id: string
/** Array of requested access methods to add to the access grant. */
requested_access_methods: {
/** Access method mode. Supported values: `code`, `card`, `mobile_key`. */
mode: 'code' | 'card' | 'mobile_key'
/** Specific PIN code to use for this access method. Only applicable when mode is 'code'. */
code?: string | undefined
}[]
}
formData: {}
jsonResponse: {
/** Represents an Access Grant. Access Grants enable you to grant a user identity access to spaces, entrances, and devices through one or more access methods, such as mobile keys, plastic cards, and PIN codes. You can create an Access Grant for an existing user identity, or you can create a new user identity *while* creating the new Access Grant. */
access_grant: {
/** ID of the Seam workspace associated with the Access Grant. */
workspace_id: string
/** ID of the Access Grant. */
access_grant_id: string
/** Unique key for the access grant within the workspace. */
access_grant_key?: string | undefined
/** ID of user identity to which the Access Grant gives access. */
user_identity_id: string
/**
* @deprecated Use `space_ids`.*/
location_ids: string[]
/** IDs of the spaces to which the Access Grant gives access. */
space_ids: string[]
/** Access methods that the user requested for the Access Grant. */
requested_access_methods: {
/** Display name of the access method. */
display_name: string
/** Access method mode. Supported values: `code`, `card`, `mobile_key`. */
mode: 'code' | 'card' | 'mobile_key'
/** Specific PIN code to use for this access method. Only applicable when mode is 'code'. */
code?: string | undefined
/** Date and time at which the requested access method was added to the Access Grant. */
created_at: string
/** IDs of the access methods created for the requested access method. */
created_access_method_ids: string[]
}[]
/** IDs of the access methods created for the Access Grant. */
access_method_ids: string[]
/** Client Session Token. Only returned if the Access Grant has a mobile_key access method. */
client_session_token?: string | undefined
/** Name of the Access Grant. If not provided, the display name will be computed. */
name: string | null
/** Display name of the Access Grant. */
display_name: string
/** Instant Key URL. Only returned if the Access Grant has a single mobile_key access_method. */
instant_key_url?: string | undefined
/** Date and time at which the Access Grant was created. */
created_at: string
/** Date and time at which the Access Grant starts. */
starts_at: string
/** Date and time at which the Access Grant ends. */
ends_at: string | null
/** Warnings associated with the [access grant](https://docs.seam.co/latest/capability-guides/access-grants). */
warnings: {
/** 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: 'being_deleted'
}[]
/** ID of the customization profile associated with the Access Grant. */
customization_profile_id?: string | undefined
}
}
}
'/access_grants/unmanaged/get': {
route: '/access_grants/unmanaged/get'
method: 'GET' | 'POST'
Expand Down