Skip to content

Commit b42ec7c

Browse files
authored
feat: Sync with Seam API via 0fee8af7be074106719a1e64384bef8613a6fc6e (#2730)
1 parent c3167ab commit b42ec7c

File tree

2 files changed

+306
-0
lines changed

2 files changed

+306
-0
lines changed

src/lib/seam/connect/openapi.ts

Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67587,6 +67587,129 @@ export default {
6758767587
'x-undocumented': 'Internal endpoint for customer portals.',
6758867588
},
6758967589
},
67590+
'/seam/customer/v1/reservations/list_access_grants': {
67591+
get: {
67592+
description:
67593+
'Lists access grants linked to a reservation by reservation_key.',
67594+
operationId: 'seamCustomerV1ReservationsListAccessGrantsGet',
67595+
parameters: [
67596+
{
67597+
in: 'query',
67598+
name: 'customer_key',
67599+
required: false,
67600+
schema: {
67601+
description:
67602+
'The customer_key identifying the customer. Required when not using client_session_with_customer auth.',
67603+
type: 'string',
67604+
},
67605+
},
67606+
{
67607+
in: 'query',
67608+
name: 'reservation_key',
67609+
required: true,
67610+
schema: {
67611+
description: 'The reservation_key to filter access grants by.',
67612+
type: 'string',
67613+
},
67614+
},
67615+
],
67616+
responses: {
67617+
200: {
67618+
content: {
67619+
'application/json': {
67620+
schema: {
67621+
properties: {
67622+
access_grants: {
67623+
items: { $ref: '#/components/schemas/access_grant' },
67624+
type: 'array',
67625+
},
67626+
ok: { type: 'boolean' },
67627+
},
67628+
required: ['access_grants', 'ok'],
67629+
type: 'object',
67630+
},
67631+
},
67632+
},
67633+
description: 'OK',
67634+
},
67635+
400: { description: 'Bad Request' },
67636+
401: { description: 'Unauthorized' },
67637+
},
67638+
security: [
67639+
{ client_session_with_customer: [] },
67640+
{ console_session_with_workspace: [] },
67641+
],
67642+
summary: '/seam/customer/v1/reservations/list_access_grants',
67643+
tags: [],
67644+
'x-fern-sdk-group-name': ['seam', 'customer', 'v1', 'reservations'],
67645+
'x-fern-sdk-method-name': 'list_access_grants',
67646+
'x-fern-sdk-return-value': 'access_grants',
67647+
'x-response-key': 'access_grants',
67648+
'x-title': 'List Access Grants for Reservation',
67649+
'x-undocumented': 'Internal endpoint for customer portals.',
67650+
},
67651+
post: {
67652+
description:
67653+
'Lists access grants linked to a reservation by reservation_key.',
67654+
operationId: 'seamCustomerV1ReservationsListAccessGrantsPost',
67655+
requestBody: {
67656+
content: {
67657+
'application/json': {
67658+
schema: {
67659+
properties: {
67660+
customer_key: {
67661+
description:
67662+
'The customer_key identifying the customer. Required when not using client_session_with_customer auth.',
67663+
type: 'string',
67664+
},
67665+
reservation_key: {
67666+
description:
67667+
'The reservation_key to filter access grants by.',
67668+
type: 'string',
67669+
},
67670+
},
67671+
required: ['reservation_key'],
67672+
type: 'object',
67673+
},
67674+
},
67675+
},
67676+
},
67677+
responses: {
67678+
200: {
67679+
content: {
67680+
'application/json': {
67681+
schema: {
67682+
properties: {
67683+
access_grants: {
67684+
items: { $ref: '#/components/schemas/access_grant' },
67685+
type: 'array',
67686+
},
67687+
ok: { type: 'boolean' },
67688+
},
67689+
required: ['access_grants', 'ok'],
67690+
type: 'object',
67691+
},
67692+
},
67693+
},
67694+
description: 'OK',
67695+
},
67696+
400: { description: 'Bad Request' },
67697+
401: { description: 'Unauthorized' },
67698+
},
67699+
security: [
67700+
{ client_session_with_customer: [] },
67701+
{ console_session_with_workspace: [] },
67702+
],
67703+
summary: '/seam/customer/v1/reservations/list_access_grants',
67704+
tags: [],
67705+
'x-fern-sdk-group-name': ['seam', 'customer', 'v1', 'reservations'],
67706+
'x-fern-sdk-method-name': 'list_access_grants',
67707+
'x-fern-sdk-return-value': 'access_grants',
67708+
'x-response-key': 'access_grants',
67709+
'x-title': 'List Access Grants for Reservation',
67710+
'x-undocumented': 'Internal endpoint for customer portals.',
67711+
},
67712+
},
6759067713
'/seam/customer/v1/settings/business_verticals/list': {
6759167714
get: {
6759267715
description: 'Returns all available business verticals.',

src/lib/seam/connect/route-types.ts

Lines changed: 183 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75533,6 +75533,189 @@ export type Routes = {
7553375533
}
7553475534
maxDuration: undefined
7553575535
}
75536+
'/seam/customer/v1/reservations/list_access_grants': {
75537+
route: '/seam/customer/v1/reservations/list_access_grants'
75538+
method: 'GET' | 'POST'
75539+
queryParams: {}
75540+
jsonBody: {}
75541+
commonParams: {
75542+
/** The customer_key identifying the customer. Required when not using client_session_with_customer auth. */
75543+
customer_key?: string | undefined
75544+
/** The reservation_key to filter access grants by. */
75545+
reservation_key: string
75546+
}
75547+
formData: {}
75548+
jsonResponse: {
75549+
access_grants: {
75550+
/** ID of the Seam workspace associated with the Access Grant. */
75551+
workspace_id: string
75552+
/** ID of the Access Grant. */
75553+
access_grant_id: string
75554+
/** Unique key for the access grant within the workspace. */
75555+
access_grant_key?: string | undefined
75556+
/** Reservation key for the access grant. */
75557+
reservation_key?: string | undefined
75558+
/** ID of user identity to which the Access Grant gives access. */
75559+
user_identity_id: string
75560+
/**
75561+
* @deprecated Use `space_ids`.*/
75562+
location_ids: string[]
75563+
/** IDs of the spaces to which the Access Grant gives access. */
75564+
space_ids: string[]
75565+
/** Access methods that the user requested for the Access Grant. */
75566+
requested_access_methods: {
75567+
/** Display name of the access method. */
75568+
display_name: string
75569+
/** Access method mode. Supported values: `code`, `card`, `mobile_key`. */
75570+
mode: 'code' | 'card' | 'mobile_key'
75571+
/** Specific PIN code to use for this access method. Only applicable when mode is 'code'. */
75572+
code?: string | undefined
75573+
/** Maximum number of times the instant key can be used. Only applicable when mode is 'mobile_key'. Defaults to 1 if not specified. */
75574+
instant_key_max_use_count?: number | undefined
75575+
/** Date and time at which the requested access method was added to the Access Grant. */
75576+
created_at: string
75577+
/** IDs of the access methods created for the requested access method. */
75578+
created_access_method_ids: string[]
75579+
}[]
75580+
/** IDs of the access methods created for the Access Grant. */
75581+
access_method_ids: string[]
75582+
/** Client Session Token. Only returned if the Access Grant has a mobile_key access method. */
75583+
client_session_token?: string | undefined
75584+
/** Name of the Access Grant. If not provided, the display name will be computed. */
75585+
name: string | null
75586+
/** Display name of the Access Grant. */
75587+
display_name: string
75588+
/** Instant Key URL. Only returned if the Access Grant has a single mobile_key access_method. */
75589+
instant_key_url?: string | undefined
75590+
/** Date and time at which the Access Grant was created. */
75591+
created_at: string
75592+
/** Date and time at which the Access Grant starts. */
75593+
starts_at: string
75594+
/** Date and time at which the Access Grant ends. */
75595+
ends_at: string | null
75596+
/** Warnings associated with the [access grant](https://docs.seam.co/latest/capability-guides/access-grants). */
75597+
warnings: (
75598+
| {
75599+
/** Date and time at which Seam created the warning. */
75600+
created_at: string
75601+
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
75602+
message: string
75603+
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
75604+
warning_code: 'being_deleted'
75605+
}
75606+
| {
75607+
/** Date and time at which Seam created the warning. */
75608+
created_at: string
75609+
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
75610+
message: string
75611+
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
75612+
warning_code: 'underprovisioned_access'
75613+
}
75614+
| {
75615+
/** Date and time at which Seam created the warning. */
75616+
created_at: string
75617+
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
75618+
message: string
75619+
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
75620+
warning_code: 'overprovisioned_access'
75621+
}
75622+
| {
75623+
/** Date and time at which Seam created the warning. */
75624+
created_at: string
75625+
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
75626+
message: string
75627+
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
75628+
warning_code: 'updating_access_times'
75629+
/** IDs of the access methods being updated. */
75630+
access_method_ids: string[]
75631+
}
75632+
| {
75633+
/** Date and time at which Seam created the warning. */
75634+
created_at: string
75635+
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
75636+
message: string
75637+
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
75638+
warning_code: 'requested_code_unavailable'
75639+
/** ID of the device where the requested code was unavailable. */
75640+
device_id: string
75641+
/** The originally requested PIN code that was unavailable. */
75642+
original_code: string
75643+
/** The new PIN code that was assigned instead. */
75644+
new_code: string
75645+
}
75646+
| {
75647+
/** Date and time at which Seam created the warning. */
75648+
created_at: string
75649+
/** Detailed description of the warning. Provides insights into the issue and potentially how to rectify it. */
75650+
message: string
75651+
/** Unique identifier of the type of warning. Enables quick recognition and categorization of the issue. */
75652+
warning_code: 'device_does_not_support_access_codes'
75653+
/** ID of the device that does not support access codes. */
75654+
device_id: string
75655+
}
75656+
)[]
75657+
/** Errors associated with the [access grant](https://docs.seam.co/latest/capability-guides/access-grants). */
75658+
errors: {
75659+
/** Date and time at which Seam created the error. */
75660+
created_at: string
75661+
/** Detailed description of the error. Provides insights into the issue and potentially how to rectify it. */
75662+
message: string
75663+
/** Unique identifier of the type of error. Enables quick recognition and categorization of the issue. */
75664+
error_code: 'cannot_create_requested_access_methods'
75665+
}[]
75666+
/** ID of the customization profile associated with the Access Grant. */
75667+
customization_profile_id?: string | undefined
75668+
/** List of pending mutations for the access grant. This shows updates that are in progress. */
75669+
pending_mutations: (
75670+
| {
75671+
/** Date and time at which the mutation was created. */
75672+
created_at: string
75673+
/** Detailed description of the mutation. */
75674+
message: string
75675+
/** Mutation code to indicate that Seam is in the process of updating the spaces (devices) associated with this access grant. */
75676+
mutation_code: 'updating_spaces'
75677+
/** Previous location configuration. */
75678+
from: {
75679+
/** Previous device IDs where access codes existed. */
75680+
device_ids: string[]
75681+
}
75682+
/** New location configuration. */
75683+
to: {
75684+
/** New device IDs where access codes should be created. */
75685+
device_ids: string[]
75686+
/** Common code key to ensure PIN code reuse across devices. */
75687+
common_code_key?: (string | null) | undefined
75688+
}
75689+
}
75690+
| {
75691+
/** Date and time at which the mutation was created. */
75692+
created_at: string
75693+
/** Detailed description of the mutation. */
75694+
message: string
75695+
/** Mutation code to indicate that Seam is in the process of updating the access times for this access grant. */
75696+
mutation_code: 'updating_access_times'
75697+
/** IDs of the access methods being updated. */
75698+
access_method_ids: string[]
75699+
/** Previous access time configuration. */
75700+
from: {
75701+
/** Previous start time for access. */
75702+
starts_at: string | null
75703+
/** Previous end time for access. */
75704+
ends_at: string | null
75705+
}
75706+
/** New access time configuration. */
75707+
to: {
75708+
/** New start time for access. */
75709+
starts_at: string | null
75710+
/** New end time for access. */
75711+
ends_at: string | null
75712+
}
75713+
}
75714+
)[]
75715+
}[]
75716+
}
75717+
maxDuration: undefined
75718+
}
7553675719
'/seam/customer/v1/settings/business_verticals/list': {
7553775720
route: '/seam/customer/v1/settings/business_verticals/list'
7553875721
method: 'GET' | 'POST'

0 commit comments

Comments
 (0)