@seamapi/http 1.34.0 → 1.35.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/dist/connect.cjs +594 -561
- package/dist/connect.cjs.map +1 -1
- package/dist/connect.d.cts +238 -176
- package/lib/seam/connect/index.d.ts +0 -1
- package/lib/seam/connect/index.js +0 -1
- package/lib/seam/connect/index.js.map +1 -1
- package/lib/seam/connect/routes/{access-codes.d.ts → access-codes/access-codes.d.ts} +15 -13
- package/lib/seam/connect/routes/{access-codes.js → access-codes/access-codes.js} +35 -32
- package/lib/seam/connect/routes/access-codes/access-codes.js.map +1 -0
- package/lib/seam/connect/routes/access-codes/index.d.ts +3 -0
- package/lib/seam/connect/routes/access-codes/index.js +8 -0
- package/lib/seam/connect/routes/access-codes/index.js.map +1 -0
- package/lib/seam/connect/routes/access-codes/simulate/index.d.ts +1 -0
- package/lib/seam/connect/routes/access-codes/simulate/index.js +6 -0
- package/lib/seam/connect/routes/access-codes/simulate/index.js.map +1 -0
- package/lib/seam/connect/routes/{access-codes-simulate.d.ts → access-codes/simulate/simulate.d.ts} +7 -5
- package/lib/seam/connect/routes/{access-codes-simulate.js → access-codes/simulate/simulate.js} +14 -11
- package/lib/seam/connect/routes/{unstable-partner.js.map → access-codes/simulate/simulate.js.map} +1 -1
- package/lib/seam/connect/routes/access-codes/unmanaged/index.d.ts +1 -0
- package/lib/seam/connect/routes/access-codes/unmanaged/index.js +6 -0
- package/lib/seam/connect/routes/access-codes/unmanaged/index.js.map +1 -0
- package/lib/seam/connect/routes/{access-codes-unmanaged.d.ts → access-codes/unmanaged/unmanaged.d.ts} +10 -8
- package/lib/seam/connect/routes/{access-codes-unmanaged.js → access-codes/unmanaged/unmanaged.js} +24 -21
- package/lib/seam/connect/routes/access-codes/unmanaged/unmanaged.js.map +1 -0
- package/lib/seam/connect/routes/{access-grants.d.ts → access-grants/access-grants.d.ts} +14 -8
- package/lib/seam/connect/routes/{access-grants.js → access-grants/access-grants.js} +30 -19
- package/lib/seam/connect/routes/{noise-sensors.js.map → access-grants/access-grants.js.map} +1 -1
- package/lib/seam/connect/routes/access-grants/index.d.ts +1 -0
- package/lib/seam/connect/routes/access-grants/index.js +6 -0
- package/lib/seam/connect/routes/access-grants/index.js.map +1 -0
- package/lib/seam/connect/routes/{access-methods.d.ts → access-methods/access-methods.d.ts} +10 -8
- package/lib/seam/connect/routes/{access-methods.js → access-methods/access-methods.js} +21 -18
- package/lib/seam/connect/routes/access-methods/access-methods.js.map +1 -0
- package/lib/seam/connect/routes/access-methods/index.d.ts +1 -0
- package/lib/seam/connect/routes/access-methods/index.js +6 -0
- package/lib/seam/connect/routes/access-methods/index.js.map +1 -0
- package/lib/seam/connect/routes/{acs-access-groups.d.ts → acs/access-groups/access-groups.d.ts} +12 -10
- package/lib/seam/connect/routes/{acs-access-groups.js → acs/access-groups/access-groups.js} +29 -26
- package/lib/seam/connect/routes/acs/access-groups/access-groups.js.map +1 -0
- package/lib/seam/connect/routes/acs/access-groups/index.d.ts +1 -0
- package/lib/seam/connect/routes/acs/access-groups/index.js +6 -0
- package/lib/seam/connect/routes/acs/access-groups/index.js.map +1 -0
- package/lib/seam/connect/routes/{acs.d.ts → acs/acs.d.ts} +13 -11
- package/lib/seam/connect/routes/{acs.js → acs/acs.js} +20 -17
- package/lib/seam/connect/routes/acs/acs.js.map +1 -0
- package/lib/seam/connect/routes/{acs-credentials.d.ts → acs/credentials/credentials.d.ts} +13 -11
- package/lib/seam/connect/routes/{acs-credentials.js → acs/credentials/credentials.js} +29 -26
- package/lib/seam/connect/routes/acs/credentials/credentials.js.map +1 -0
- package/lib/seam/connect/routes/acs/credentials/index.d.ts +1 -0
- package/lib/seam/connect/routes/acs/credentials/index.js +6 -0
- package/lib/seam/connect/routes/acs/credentials/index.js.map +1 -0
- package/lib/seam/connect/routes/{acs-encoders.d.ts → acs/encoders/encoders.d.ts} +15 -13
- package/lib/seam/connect/routes/{acs-encoders.js → acs/encoders/encoders.js} +23 -20
- package/lib/seam/connect/routes/acs/encoders/encoders.js.map +1 -0
- package/lib/seam/connect/routes/acs/encoders/index.d.ts +2 -0
- package/lib/seam/connect/routes/acs/encoders/index.js +7 -0
- package/lib/seam/connect/routes/acs/encoders/index.js.map +1 -0
- package/lib/seam/connect/routes/acs/encoders/simulate/index.d.ts +1 -0
- package/lib/seam/connect/routes/acs/encoders/simulate/index.js +6 -0
- package/lib/seam/connect/routes/acs/encoders/simulate/index.js.map +1 -0
- package/lib/seam/connect/routes/{acs-encoders-simulate.d.ts → acs/encoders/simulate/simulate.d.ts} +7 -5
- package/lib/seam/connect/routes/{acs-encoders-simulate.js → acs/encoders/simulate/simulate.js} +17 -14
- package/lib/seam/connect/routes/acs/encoders/simulate/simulate.js.map +1 -0
- package/lib/seam/connect/routes/{acs-entrances.d.ts → acs/entrances/entrances.d.ts} +10 -8
- package/lib/seam/connect/routes/{acs-entrances.js → acs/entrances/entrances.js} +23 -20
- package/lib/seam/connect/routes/acs/entrances/entrances.js.map +1 -0
- package/lib/seam/connect/routes/acs/entrances/index.d.ts +1 -0
- package/lib/seam/connect/routes/acs/entrances/index.js +6 -0
- package/lib/seam/connect/routes/acs/entrances/index.js.map +1 -0
- package/lib/seam/connect/routes/acs/index.d.ts +7 -0
- package/lib/seam/connect/routes/acs/index.js +12 -0
- package/lib/seam/connect/routes/acs/index.js.map +1 -0
- package/lib/seam/connect/routes/acs/systems/index.d.ts +1 -0
- package/lib/seam/connect/routes/acs/systems/index.js +6 -0
- package/lib/seam/connect/routes/acs/systems/index.js.map +1 -0
- package/lib/seam/connect/routes/{acs-systems.d.ts → acs/systems/systems.d.ts} +10 -8
- package/lib/seam/connect/routes/{acs-systems.js → acs/systems/systems.js} +22 -19
- package/lib/seam/connect/routes/acs/systems/systems.js.map +1 -0
- package/lib/seam/connect/routes/acs/users/index.d.ts +1 -0
- package/lib/seam/connect/routes/acs/users/index.js +6 -0
- package/lib/seam/connect/routes/acs/users/index.js.map +1 -0
- package/lib/seam/connect/routes/{acs-users.d.ts → acs/users/users.d.ts} +14 -12
- package/lib/seam/connect/routes/{acs-users.js → acs/users/users.js} +34 -31
- package/lib/seam/connect/routes/acs/users/users.js.map +1 -0
- package/lib/seam/connect/routes/{action-attempts.d.ts → action-attempts/action-attempts.d.ts} +9 -7
- package/lib/seam/connect/routes/{action-attempts.js → action-attempts/action-attempts.js} +18 -15
- package/lib/seam/connect/routes/action-attempts/action-attempts.js.map +1 -0
- package/lib/seam/connect/routes/action-attempts/index.d.ts +1 -0
- package/lib/seam/connect/routes/action-attempts/index.js +6 -0
- package/lib/seam/connect/routes/action-attempts/index.js.map +1 -0
- package/lib/seam/connect/routes/{client-sessions.d.ts → client-sessions/client-sessions.d.ts} +12 -10
- package/lib/seam/connect/routes/{client-sessions.js → client-sessions/client-sessions.js} +24 -21
- package/lib/seam/connect/routes/client-sessions/client-sessions.js.map +1 -0
- package/lib/seam/connect/routes/client-sessions/index.d.ts +1 -0
- package/lib/seam/connect/routes/client-sessions/index.js +6 -0
- package/lib/seam/connect/routes/client-sessions/index.js.map +1 -0
- package/lib/seam/connect/routes/{connect-webviews.d.ts → connect-webviews/connect-webviews.d.ts} +10 -8
- package/lib/seam/connect/routes/{connect-webviews.js → connect-webviews/connect-webviews.js} +22 -19
- package/lib/seam/connect/routes/connect-webviews/connect-webviews.js.map +1 -0
- package/lib/seam/connect/routes/connect-webviews/index.d.ts +1 -0
- package/lib/seam/connect/routes/connect-webviews/index.js +6 -0
- package/lib/seam/connect/routes/connect-webviews/index.js.map +1 -0
- package/lib/seam/connect/routes/{connected-accounts.d.ts → connected-accounts/connected-accounts.d.ts} +12 -10
- package/lib/seam/connect/routes/{connected-accounts.js → connected-accounts/connected-accounts.js} +23 -20
- package/lib/seam/connect/routes/connected-accounts/connected-accounts.js.map +1 -0
- package/lib/seam/connect/routes/connected-accounts/index.d.ts +1 -0
- package/lib/seam/connect/routes/connected-accounts/index.js +6 -0
- package/lib/seam/connect/routes/connected-accounts/index.js.map +1 -0
- package/lib/seam/connect/routes/{devices.d.ts → devices/devices.d.ts} +13 -11
- package/lib/seam/connect/routes/{devices.js → devices/devices.js} +27 -24
- package/lib/seam/connect/routes/devices/devices.js.map +1 -0
- package/lib/seam/connect/routes/devices/index.d.ts +3 -0
- package/lib/seam/connect/routes/devices/index.js +8 -0
- package/lib/seam/connect/routes/devices/index.js.map +1 -0
- package/lib/seam/connect/routes/devices/simulate/index.d.ts +1 -0
- package/lib/seam/connect/routes/devices/simulate/index.js +6 -0
- package/lib/seam/connect/routes/devices/simulate/index.js.map +1 -0
- package/lib/seam/connect/routes/{devices-simulate.d.ts → devices/simulate/simulate.d.ts} +9 -7
- package/lib/seam/connect/routes/{devices-simulate.js → devices/simulate/simulate.js} +18 -15
- package/lib/seam/connect/routes/devices/simulate/simulate.js.map +1 -0
- package/lib/seam/connect/routes/devices/unmanaged/index.d.ts +1 -0
- package/lib/seam/connect/routes/devices/unmanaged/index.js +6 -0
- package/lib/seam/connect/routes/devices/unmanaged/index.js.map +1 -0
- package/lib/seam/connect/routes/{devices-unmanaged.d.ts → devices/unmanaged/unmanaged.d.ts} +9 -7
- package/lib/seam/connect/routes/{devices-unmanaged.js → devices/unmanaged/unmanaged.js} +20 -17
- package/lib/seam/connect/routes/devices/unmanaged/unmanaged.js.map +1 -0
- package/lib/seam/connect/routes/{events.d.ts → events/events.d.ts} +9 -7
- package/lib/seam/connect/routes/{events.js → events/events.js} +18 -15
- package/lib/seam/connect/routes/events/events.js.map +1 -0
- package/lib/seam/connect/routes/events/index.d.ts +1 -0
- package/lib/seam/connect/routes/events/index.js +6 -0
- package/lib/seam/connect/routes/events/index.js.map +1 -0
- package/lib/seam/connect/routes/index.d.ts +19 -37
- package/lib/seam/connect/routes/index.js +23 -37
- package/lib/seam/connect/routes/index.js.map +1 -1
- package/lib/seam/connect/routes/locks/index.d.ts +1 -0
- package/lib/seam/connect/routes/locks/index.js +6 -0
- package/lib/seam/connect/routes/locks/index.js.map +1 -0
- package/lib/seam/connect/routes/{locks.d.ts → locks/locks.d.ts} +11 -9
- package/lib/seam/connect/routes/{locks.js → locks/locks.js} +20 -17
- package/lib/seam/connect/routes/locks/locks.js.map +1 -0
- package/lib/seam/connect/routes/noise-sensors/index.d.ts +3 -0
- package/lib/seam/connect/routes/noise-sensors/index.js +8 -0
- package/lib/seam/connect/routes/noise-sensors/index.js.map +1 -0
- package/lib/seam/connect/routes/{noise-sensors.d.ts → noise-sensors/noise-sensors.d.ts} +10 -8
- package/lib/seam/connect/routes/{noise-sensors.js → noise-sensors/noise-sensors.js} +17 -14
- package/lib/seam/connect/routes/noise-sensors/noise-sensors.js.map +1 -0
- package/lib/seam/connect/routes/noise-sensors/noise-thresholds/index.d.ts +1 -0
- package/lib/seam/connect/routes/noise-sensors/noise-thresholds/index.js +6 -0
- package/lib/seam/connect/routes/noise-sensors/noise-thresholds/index.js.map +1 -0
- package/lib/seam/connect/routes/{noise-sensors-noise-thresholds.d.ts → noise-sensors/noise-thresholds/noise-thresholds.d.ts} +10 -8
- package/lib/seam/connect/routes/{noise-sensors-noise-thresholds.js → noise-sensors/noise-thresholds/noise-thresholds.js} +24 -21
- package/lib/seam/connect/routes/noise-sensors/noise-thresholds/noise-thresholds.js.map +1 -0
- package/lib/seam/connect/routes/noise-sensors/simulate/index.d.ts +1 -0
- package/lib/seam/connect/routes/noise-sensors/simulate/index.js +6 -0
- package/lib/seam/connect/routes/noise-sensors/simulate/index.js.map +1 -0
- package/lib/seam/connect/routes/{noise-sensors-simulate.d.ts → noise-sensors/simulate/simulate.d.ts} +7 -5
- package/lib/seam/connect/routes/{noise-sensors-simulate.js → noise-sensors/simulate/simulate.js} +14 -11
- package/lib/seam/connect/routes/noise-sensors/simulate/simulate.js.map +1 -0
- package/lib/seam/connect/routes/phones/index.d.ts +2 -0
- package/lib/seam/connect/routes/phones/index.js +7 -0
- package/lib/seam/connect/routes/phones/index.js.map +1 -0
- package/lib/seam/connect/routes/{phones.d.ts → phones/phones.d.ts} +11 -9
- package/lib/seam/connect/routes/{phones.js → phones/phones.js} +22 -19
- package/lib/seam/connect/routes/{events.js.map → phones/phones.js.map} +1 -1
- package/lib/seam/connect/routes/phones/simulate/index.d.ts +1 -0
- package/lib/seam/connect/routes/phones/simulate/index.js +6 -0
- package/lib/seam/connect/routes/phones/simulate/index.js.map +1 -0
- package/lib/seam/connect/routes/{phones-simulate.d.ts → phones/simulate/simulate.d.ts} +9 -7
- package/lib/seam/connect/routes/{phones-simulate.js → phones/simulate/simulate.js} +16 -13
- package/lib/seam/connect/routes/phones/simulate/simulate.js.map +1 -0
- package/lib/seam/connect/{seam-http.d.ts → routes/seam-http.d.ts} +24 -7
- package/lib/seam/connect/{seam-http.js → routes/seam-http.js} +31 -10
- package/lib/seam/connect/routes/seam-http.js.map +1 -0
- package/lib/seam/connect/routes/spaces/index.d.ts +1 -0
- package/lib/seam/connect/routes/spaces/index.js +6 -0
- package/lib/seam/connect/routes/spaces/index.js.map +1 -0
- package/lib/seam/connect/routes/{spaces.d.ts → spaces/spaces.d.ts} +14 -12
- package/lib/seam/connect/routes/{spaces.js → spaces/spaces.js} +31 -28
- package/lib/seam/connect/routes/spaces/spaces.js.map +1 -0
- package/lib/seam/connect/routes/{thermostats-daily-programs.d.ts → thermostats/daily-programs/daily-programs.d.ts} +9 -7
- package/lib/seam/connect/routes/{thermostats-daily-programs.js → thermostats/daily-programs/daily-programs.js} +18 -15
- package/lib/seam/connect/routes/thermostats/daily-programs/daily-programs.js.map +1 -0
- package/lib/seam/connect/routes/thermostats/daily-programs/index.d.ts +1 -0
- package/lib/seam/connect/routes/thermostats/daily-programs/index.js +6 -0
- package/lib/seam/connect/routes/thermostats/daily-programs/index.js.map +1 -0
- package/lib/seam/connect/routes/thermostats/index.d.ts +4 -0
- package/lib/seam/connect/routes/thermostats/index.js +9 -0
- package/lib/seam/connect/routes/thermostats/index.js.map +1 -0
- package/lib/seam/connect/routes/thermostats/schedules/index.d.ts +1 -0
- package/lib/seam/connect/routes/thermostats/schedules/index.js +6 -0
- package/lib/seam/connect/routes/thermostats/schedules/index.js.map +1 -0
- package/lib/seam/connect/routes/{thermostats-schedules.d.ts → thermostats/schedules/schedules.d.ts} +10 -8
- package/lib/seam/connect/routes/{thermostats-schedules.js → thermostats/schedules/schedules.js} +24 -21
- package/lib/seam/connect/routes/thermostats/schedules/schedules.js.map +1 -0
- package/lib/seam/connect/routes/thermostats/simulate/index.d.ts +1 -0
- package/lib/seam/connect/routes/thermostats/simulate/index.js +6 -0
- package/lib/seam/connect/routes/thermostats/simulate/index.js.map +1 -0
- package/lib/seam/connect/routes/{thermostats-simulate.d.ts → thermostats/simulate/simulate.d.ts} +7 -5
- package/lib/seam/connect/routes/{thermostats-simulate.js → thermostats/simulate/simulate.js} +15 -12
- package/lib/seam/connect/routes/{thermostats-daily-programs.js.map → thermostats/simulate/simulate.js.map} +1 -1
- package/lib/seam/connect/routes/{thermostats.d.ts → thermostats/thermostats.d.ts} +22 -20
- package/lib/seam/connect/routes/{thermostats.js → thermostats/thermostats.js} +36 -33
- package/lib/seam/connect/routes/thermostats/thermostats.js.map +1 -0
- package/lib/seam/connect/routes/{user-identities-enrollment-automations.d.ts → user-identities/enrollment-automations/enrollment-automations.d.ts} +10 -8
- package/lib/seam/connect/routes/{user-identities-enrollment-automations.js → user-identities/enrollment-automations/enrollment-automations.js} +23 -20
- package/lib/seam/connect/routes/user-identities/enrollment-automations/enrollment-automations.js.map +1 -0
- package/lib/seam/connect/routes/user-identities/enrollment-automations/index.d.ts +1 -0
- package/lib/seam/connect/routes/user-identities/enrollment-automations/index.js +6 -0
- package/lib/seam/connect/routes/user-identities/enrollment-automations/index.js.map +1 -0
- package/lib/seam/connect/routes/user-identities/index.d.ts +2 -0
- package/lib/seam/connect/routes/user-identities/index.js +7 -0
- package/lib/seam/connect/routes/user-identities/index.js.map +1 -0
- package/lib/seam/connect/routes/{user-identities.d.ts → user-identities/user-identities.d.ts} +18 -16
- package/lib/seam/connect/routes/{user-identities.js → user-identities/user-identities.js} +42 -39
- package/lib/seam/connect/routes/user-identities/user-identities.js.map +1 -0
- package/lib/seam/connect/routes/webhooks/index.d.ts +1 -0
- package/lib/seam/connect/routes/webhooks/index.js +6 -0
- package/lib/seam/connect/routes/webhooks/index.js.map +1 -0
- package/lib/seam/connect/routes/{webhooks.d.ts → webhooks/webhooks.d.ts} +12 -10
- package/lib/seam/connect/routes/{webhooks.js → webhooks/webhooks.js} +23 -20
- package/lib/seam/connect/routes/webhooks/webhooks.js.map +1 -0
- package/lib/seam/connect/routes/workspaces/index.d.ts +1 -0
- package/lib/seam/connect/routes/workspaces/index.js +6 -0
- package/lib/seam/connect/routes/workspaces/index.js.map +1 -0
- package/lib/seam/connect/routes/{workspaces.d.ts → workspaces/workspaces.d.ts} +13 -11
- package/lib/seam/connect/routes/{workspaces.js → workspaces/workspaces.js} +21 -18
- package/lib/seam/connect/routes/workspaces/workspaces.js.map +1 -0
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +9 -7
- package/src/lib/seam/connect/index.ts +0 -1
- package/src/lib/seam/connect/routes/{access-codes.ts → access-codes/access-codes.ts} +31 -28
- package/src/lib/seam/connect/routes/access-codes/index.ts +8 -0
- package/src/lib/seam/connect/routes/access-codes/simulate/index.ts +6 -0
- package/src/lib/seam/connect/routes/{access-codes-simulate.ts → access-codes/simulate/simulate.ts} +7 -5
- package/src/lib/seam/connect/routes/access-codes/unmanaged/index.ts +6 -0
- package/src/lib/seam/connect/routes/{access-codes-unmanaged.ts → access-codes/unmanaged/unmanaged.ts} +17 -15
- package/src/lib/seam/connect/routes/{access-grants.ts → access-grants/access-grants.ts} +33 -14
- package/src/lib/seam/connect/routes/access-grants/index.ts +6 -0
- package/src/lib/seam/connect/routes/{access-methods.ts → access-methods/access-methods.ts} +15 -13
- package/src/lib/seam/connect/routes/access-methods/index.ts +6 -0
- package/src/lib/seam/connect/routes/{acs-access-groups.ts → acs/access-groups/access-groups.ts} +22 -20
- package/src/lib/seam/connect/routes/acs/access-groups/index.ts +6 -0
- package/src/lib/seam/connect/routes/{acs.ts → acs/acs.ts} +16 -13
- package/src/lib/seam/connect/routes/{acs-credentials.ts → acs/credentials/credentials.ts} +31 -22
- package/src/lib/seam/connect/routes/acs/credentials/index.ts +6 -0
- package/src/lib/seam/connect/routes/{acs-encoders.ts → acs/encoders/encoders.ts} +25 -18
- package/src/lib/seam/connect/routes/acs/encoders/index.ts +7 -0
- package/src/lib/seam/connect/routes/acs/encoders/simulate/index.ts +6 -0
- package/src/lib/seam/connect/routes/{acs-encoders-simulate.ts → acs/encoders/simulate/simulate.ts} +10 -8
- package/src/lib/seam/connect/routes/{acs-entrances.ts → acs/entrances/entrances.ts} +16 -14
- package/src/lib/seam/connect/routes/acs/entrances/index.ts +6 -0
- package/src/lib/seam/connect/routes/acs/index.ts +12 -0
- package/src/lib/seam/connect/routes/acs/systems/index.ts +6 -0
- package/src/lib/seam/connect/routes/{acs-systems.ts → acs/systems/systems.ts} +15 -13
- package/src/lib/seam/connect/routes/acs/users/index.ts +6 -0
- package/src/lib/seam/connect/routes/{acs-users.ts → acs/users/users.ts} +29 -27
- package/src/lib/seam/connect/routes/{action-attempts.ts → action-attempts/action-attempts.ts} +13 -11
- package/src/lib/seam/connect/routes/action-attempts/index.ts +6 -0
- package/src/lib/seam/connect/routes/{client-sessions.ts → client-sessions/client-sessions.ts} +22 -17
- package/src/lib/seam/connect/routes/client-sessions/index.ts +6 -0
- package/src/lib/seam/connect/routes/{connect-webviews.ts → connect-webviews/connect-webviews.ts} +18 -14
- package/src/lib/seam/connect/routes/connect-webviews/index.ts +6 -0
- package/src/lib/seam/connect/routes/{connected-accounts.ts → connected-accounts/connected-accounts.ts} +23 -17
- package/src/lib/seam/connect/routes/connected-accounts/index.ts +6 -0
- package/src/lib/seam/connect/routes/{devices.ts → devices/devices.ts} +24 -19
- package/src/lib/seam/connect/routes/devices/index.ts +8 -0
- package/src/lib/seam/connect/routes/devices/simulate/index.ts +6 -0
- package/src/lib/seam/connect/routes/{devices-simulate.ts → devices/simulate/simulate.ts} +14 -10
- package/src/lib/seam/connect/routes/devices/unmanaged/index.ts +6 -0
- package/src/lib/seam/connect/routes/{devices-unmanaged.ts → devices/unmanaged/unmanaged.ts} +13 -11
- package/src/lib/seam/connect/routes/{events.ts → events/events.ts} +14 -10
- package/src/lib/seam/connect/routes/events/index.ts +6 -0
- package/src/lib/seam/connect/routes/index.ts +24 -37
- package/src/lib/seam/connect/routes/locks/index.ts +6 -0
- package/src/lib/seam/connect/routes/{locks.ts → locks/locks.ts} +18 -14
- package/src/lib/seam/connect/routes/noise-sensors/index.ts +8 -0
- package/src/lib/seam/connect/routes/{noise-sensors.ts → noise-sensors/noise-sensors.ts} +11 -8
- package/src/lib/seam/connect/routes/noise-sensors/noise-thresholds/index.ts +6 -0
- package/src/lib/seam/connect/routes/{noise-sensors-noise-thresholds.ts → noise-sensors/noise-thresholds/noise-thresholds.ts} +17 -15
- package/src/lib/seam/connect/routes/noise-sensors/simulate/index.ts +6 -0
- package/src/lib/seam/connect/routes/{noise-sensors-simulate.ts → noise-sensors/simulate/simulate.ts} +7 -5
- package/src/lib/seam/connect/routes/phones/index.ts +7 -0
- package/src/lib/seam/connect/routes/{phones.ts → phones/phones.ts} +20 -13
- package/src/lib/seam/connect/routes/phones/simulate/index.ts +6 -0
- package/src/lib/seam/connect/routes/{phones-simulate.ts → phones/simulate/simulate.ts} +10 -8
- package/src/lib/seam/connect/{seam-http.ts → routes/seam-http.ts} +37 -31
- package/src/lib/seam/connect/routes/spaces/index.ts +6 -0
- package/src/lib/seam/connect/routes/{spaces.ts → spaces/spaces.ts} +33 -25
- package/src/lib/seam/connect/routes/{thermostats-daily-programs.ts → thermostats/daily-programs/daily-programs.ts} +12 -10
- package/src/lib/seam/connect/routes/thermostats/daily-programs/index.ts +6 -0
- package/src/lib/seam/connect/routes/thermostats/index.ts +9 -0
- package/src/lib/seam/connect/routes/thermostats/schedules/index.ts +6 -0
- package/src/lib/seam/connect/routes/{thermostats-schedules.ts → thermostats/schedules/schedules.ts} +17 -15
- package/src/lib/seam/connect/routes/thermostats/simulate/index.ts +6 -0
- package/src/lib/seam/connect/routes/{thermostats-simulate.ts → thermostats/simulate/simulate.ts} +8 -6
- package/src/lib/seam/connect/routes/{thermostats.ts → thermostats/thermostats.ts} +43 -40
- package/src/lib/seam/connect/routes/{user-identities-enrollment-automations.ts → user-identities/enrollment-automations/enrollment-automations.ts} +16 -14
- package/src/lib/seam/connect/routes/user-identities/enrollment-automations/index.ts +6 -0
- package/src/lib/seam/connect/routes/user-identities/index.ts +7 -0
- package/src/lib/seam/connect/routes/{user-identities.ts → user-identities/user-identities.ts} +44 -35
- package/src/lib/seam/connect/routes/webhooks/index.ts +6 -0
- package/src/lib/seam/connect/routes/{webhooks.ts → webhooks/webhooks.ts} +23 -17
- package/src/lib/seam/connect/routes/workspaces/index.ts +6 -0
- package/src/lib/seam/connect/routes/{workspaces.ts → workspaces/workspaces.ts} +23 -17
- package/src/lib/version.ts +1 -1
- package/lib/seam/connect/routes/access-codes-simulate.js.map +0 -1
- package/lib/seam/connect/routes/access-codes-unmanaged.js.map +0 -1
- package/lib/seam/connect/routes/access-codes.js.map +0 -1
- package/lib/seam/connect/routes/access-grants.js.map +0 -1
- package/lib/seam/connect/routes/access-methods.js.map +0 -1
- package/lib/seam/connect/routes/acs-access-groups.js.map +0 -1
- package/lib/seam/connect/routes/acs-credentials.js.map +0 -1
- package/lib/seam/connect/routes/acs-encoders-simulate.js.map +0 -1
- package/lib/seam/connect/routes/acs-encoders.js.map +0 -1
- package/lib/seam/connect/routes/acs-entrances.js.map +0 -1
- package/lib/seam/connect/routes/acs-systems.js.map +0 -1
- package/lib/seam/connect/routes/acs-users.js.map +0 -1
- package/lib/seam/connect/routes/acs.js.map +0 -1
- package/lib/seam/connect/routes/action-attempts.js.map +0 -1
- package/lib/seam/connect/routes/client-sessions.js.map +0 -1
- package/lib/seam/connect/routes/connect-webviews.js.map +0 -1
- package/lib/seam/connect/routes/connected-accounts.js.map +0 -1
- package/lib/seam/connect/routes/devices-simulate.js.map +0 -1
- package/lib/seam/connect/routes/devices-unmanaged.js.map +0 -1
- package/lib/seam/connect/routes/devices.js.map +0 -1
- package/lib/seam/connect/routes/locks.js.map +0 -1
- package/lib/seam/connect/routes/noise-sensors-noise-thresholds.js.map +0 -1
- package/lib/seam/connect/routes/noise-sensors-simulate.js.map +0 -1
- package/lib/seam/connect/routes/phones-simulate.js.map +0 -1
- package/lib/seam/connect/routes/phones.js.map +0 -1
- package/lib/seam/connect/routes/spaces.js.map +0 -1
- package/lib/seam/connect/routes/thermostats-schedules.js.map +0 -1
- package/lib/seam/connect/routes/thermostats-simulate.js.map +0 -1
- package/lib/seam/connect/routes/thermostats.js.map +0 -1
- package/lib/seam/connect/routes/unstable-partner.d.ts +0 -17
- package/lib/seam/connect/routes/unstable-partner.js +0 -83
- package/lib/seam/connect/routes/user-identities-enrollment-automations.js.map +0 -1
- package/lib/seam/connect/routes/user-identities.js.map +0 -1
- package/lib/seam/connect/routes/webhooks.js.map +0 -1
- package/lib/seam/connect/routes/workspaces.js.map +0 -1
- package/lib/seam/connect/seam-http.js.map +0 -1
- package/src/lib/seam/connect/routes/unstable-partner.ts +0 -160
package/dist/connect.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/lib/lts-version.ts","../src/lib/version.ts","../src/lib/seam/connect/parse-options.ts","../src/lib/seam/connect/options.ts","../src/lib/seam/connect/token.ts","../src/lib/seam/connect/auth.ts","../src/lib/seam/connect/seam-http-error.ts","../src/lib/seam/connect/error-interceptor.ts","../src/lib/seam/connect/client.ts","../src/lib/seam/connect/openapi.ts","../src/lib/seam/connect/resolve-action-attempt.ts","../src/lib/seam/connect/seam-http-request.ts","../src/lib/seam/connect/seam-paginator.ts","../src/lib/seam/connect/routes/client-sessions.ts","../src/lib/seam/connect/routes/access-codes-simulate.ts","../src/lib/seam/connect/routes/access-codes-unmanaged.ts","../src/lib/seam/connect/routes/access-codes.ts","../src/lib/seam/connect/routes/access-grants.ts","../src/lib/seam/connect/routes/access-methods.ts","../src/lib/seam/connect/routes/acs-access-groups.ts","../src/lib/seam/connect/routes/acs-credentials.ts","../src/lib/seam/connect/routes/acs-encoders-simulate.ts","../src/lib/seam/connect/routes/acs-encoders.ts","../src/lib/seam/connect/routes/acs-entrances.ts","../src/lib/seam/connect/routes/acs-systems.ts","../src/lib/seam/connect/routes/acs-users.ts","../src/lib/seam/connect/routes/acs.ts","../src/lib/seam/connect/routes/action-attempts.ts","../src/lib/seam/connect/routes/connect-webviews.ts","../src/lib/seam/connect/routes/connected-accounts.ts","../src/lib/seam/connect/routes/devices-simulate.ts","../src/lib/seam/connect/routes/devices-unmanaged.ts","../src/lib/seam/connect/routes/devices.ts","../src/lib/seam/connect/routes/events.ts","../src/lib/seam/connect/routes/locks.ts","../src/lib/seam/connect/routes/noise-sensors-noise-thresholds.ts","../src/lib/seam/connect/routes/noise-sensors-simulate.ts","../src/lib/seam/connect/routes/noise-sensors.ts","../src/lib/seam/connect/routes/phones-simulate.ts","../src/lib/seam/connect/routes/phones.ts","../src/lib/seam/connect/routes/spaces.ts","../src/lib/seam/connect/routes/thermostats-daily-programs.ts","../src/lib/seam/connect/routes/thermostats-schedules.ts","../src/lib/seam/connect/routes/thermostats-simulate.ts","../src/lib/seam/connect/routes/thermostats.ts","../src/lib/seam/connect/routes/unstable-partner.ts","../src/lib/seam/connect/routes/user-identities-enrollment-automations.ts","../src/lib/seam/connect/routes/user-identities.ts","../src/lib/seam/connect/routes/webhooks.ts","../src/lib/seam/connect/routes/workspaces.ts","../src/lib/seam/connect/seam-http.ts","../src/lib/seam/connect/seam-http-multi-workspace.ts"],"names":["isAxiosError","axios","serializeUrlSearchParams","axiosRetry","exponentialDelay","_parent"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAO,IAAM,iBAAoB,GAAA,OAAA;;;ACAjC,IAAM,4BAA+B,GAAA,OAAA;AAErC,IA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EAAA;AACxB,IAAA,MAAM,kBAAqB,GAAA,EAAE,GAAG,OAAA,EAAS,mBAAoB,EAAA;AAC7D,IAAA,IACE,CAAC,sDAAA;AAAA,MACC;AAAA,KAEF,EAAA;AACA,MAAA,MAAM,IAAI,yCAAA;AAAA,QACR;AAAA,OACF;AAAA;AAEF,IAAO,OAAA,IAAI,wBAAuB,kBAAkB,CAAA;AAAA;AACtD,EAEA,IAAI,UAA0D,GAAA;AAC5D,IAAA,OAAO,kBAAmB,CAAA,UAAA,CAAW,IAAK,CAAA,MAAA,EAAQ,KAAK,QAAQ,CAAA;AAAA;AAEnE","file":"connect.cjs","sourcesContent":["export const seamApiLtsVersion = '1.0.0'\n","const seamapiJavascriptHttpVersion = '0.0.0'\n\nexport default seamapiJavascriptHttpVersion\n","import { seamApiLtsVersion } from 'lib/lts-version.js'\nimport version from 'lib/version.js'\n\nimport { getAuthHeaders } from './auth.js'\nimport type { Client, ClientOptions } from './client.js'\nimport {\n isSeamHttpMultiWorkspaceOptionsWithClient,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n SeamHttpInvalidOptionsError,\n type SeamHttpMultiWorkspaceOptions,\n type SeamHttpOptions,\n type SeamHttpRequestOptions,\n} from './options.js'\n\nexport const defaultEndpoint = 'https://connect.getseam.com'\n\nexport const sdkHeaders = {\n 'seam-sdk-name': 'seamapi/javascript-http',\n 'seam-sdk-version': version,\n 'seam-lts-version': seamApiLtsVersion,\n}\n\nexport type Options =\n | SeamHttpMultiWorkspaceOptions\n | (SeamHttpOptions & { publishableKey?: string })\n\ntype ParsedOptions = Required<\n (ClientOptions | { client: Client }) & SeamHttpRequestOptions\n>\n\nexport const parseOptions = (\n apiKeyOrOptions: string | Options,\n): ParsedOptions => {\n const options = getNormalizedOptions(apiKeyOrOptions)\n\n if (isSeamHttpOptionsWithClient(options)) return options\n if (isSeamHttpMultiWorkspaceOptionsWithClient(options)) return options\n\n return {\n ...options,\n axiosOptions: {\n baseURL: options.endpoint ?? getEndpointFromEnv() ?? defaultEndpoint,\n withCredentials: isSeamHttpOptionsWithClientSessionToken(options),\n ...options.axiosOptions,\n headers: {\n ...getAuthHeaders(options),\n ...options.axiosOptions?.headers,\n ...sdkHeaders,\n },\n },\n axiosRetryOptions: {\n ...options.axiosRetryOptions,\n },\n }\n}\n\nconst getNormalizedOptions = (\n apiKeyOrOptions: string | Options,\n): SeamHttpOptions & Required<SeamHttpRequestOptions> => {\n const options =\n typeof apiKeyOrOptions === 'string'\n ? { apiKey: apiKeyOrOptions }\n : apiKeyOrOptions\n\n const requestOptions = {\n waitForActionAttempt: options.waitForActionAttempt ?? true,\n }\n\n if (isSeamHttpOptionsWithClient(options)) {\n return {\n ...options,\n ...requestOptions,\n }\n }\n\n const apiKey =\n 'apiKey' in options ? options.apiKey : getApiKeyFromEnv(options)\n\n const personalAccessToken =\n 'personalAccessToken' in options\n ? options.personalAccessToken\n : getPersonalAccessTokenFromEnv(options)\n\n const workspaceId =\n 'workspaceId' in options ? options.workspaceId : getWorkspaceIdFromEnv()\n\n if (\n apiKey != null &&\n personalAccessToken != null &&\n !('apiKey' in options) &&\n !('personalAccessToken' in options)\n ) {\n throw new SeamHttpInvalidOptionsError(\n 'Both SEAM_API_KEY and SEAM_PERSONAL_ACCESS_TOKEN environment variables are defined. Please use only one authentication method.',\n )\n }\n\n return {\n ...options,\n ...(apiKey != null ? { apiKey } : {}),\n ...(workspaceId != null ? { workspaceId } : {}),\n ...(personalAccessToken != null ? { personalAccessToken } : {}),\n ...requestOptions,\n }\n}\n\nconst getApiKeyFromEnv = (\n options: SeamHttpOptions,\n): string | null | undefined => {\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n return null\n }\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n return null\n }\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n return null\n }\n return globalThis.process?.env?.SEAM_API_KEY\n}\n\nconst getPersonalAccessTokenFromEnv = (\n options: SeamHttpOptions,\n): string | null | undefined => {\n if ('apiKey' in options && options.apiKey != null) {\n return null\n }\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n return null\n }\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n return null\n }\n return globalThis.process?.env?.SEAM_PERSONAL_ACCESS_TOKEN\n}\n\nconst getWorkspaceIdFromEnv = (): string | null | undefined => {\n return globalThis.process?.env?.SEAM_WORKSPACE_ID\n}\n\nconst getEndpointFromEnv = (): string | null | undefined => {\n if (globalThis.process?.env?.SEAM_API_URL != null) {\n // eslint-disable-next-line no-console\n console.warn(\n 'Using the SEAM_API_URL environment variable is deprecated. Support will be remove in a later major version. Use SEAM_ENDPOINT instead.',\n )\n }\n\n if (\n globalThis.process?.env?.SEAM_API_URL != null &&\n globalThis.process?.env?.SEAM_ENDPOINT != null\n ) {\n // eslint-disable-next-line no-console\n console.warn(\n 'Detected both the SEAM_API_URL and SEAM_ENDPOINT environment variables. Using SEAM_ENDPOINT.',\n )\n }\n\n return (\n globalThis.process?.env?.SEAM_ENDPOINT ??\n globalThis.process?.env?.SEAM_API_URL\n )\n}\n\nexport const limitToSeamHttpRequestOptions = (\n options: Required<SeamHttpRequestOptions>,\n): Required<SeamHttpRequestOptions> => {\n return Object.keys(options)\n .filter(isSeamHttpRequestOption)\n .reduce(\n (obj, key) => ({\n ...obj,\n [key]: options[key],\n }),\n {},\n ) as Required<SeamHttpRequestOptions>\n}\n\nexport const isSeamHttpRequestOption = (\n key: string,\n): key is keyof SeamHttpRequestOptions => {\n const keys: Record<keyof SeamHttpRequestOptions, true> = {\n waitForActionAttempt: true,\n }\n return Object.keys(keys).includes(key)\n}\n","import type { Client, ClientOptions } from './client.js'\nimport { isSeamHttpRequestOption } from './parse-options.js'\nimport type { ResolveActionAttemptOptions } from './resolve-action-attempt.js'\n\nexport type SeamHttpMultiWorkspaceOptions =\n | SeamHttpMultiWorkspaceOptionsFromEnv\n | SeamHttpMultiWorkspaceOptionsWithClient\n | SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken\n | SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken\n\nexport type SeamHttpOptions =\n | SeamHttpOptionsFromEnv\n | SeamHttpOptionsWithClient\n | SeamHttpOptionsWithApiKey\n | SeamHttpOptionsWithClientSessionToken\n | SeamHttpOptionsWithConsoleSessionToken\n | SeamHttpOptionsWithPersonalAccessToken\n\ninterface SeamHttpCommonOptions extends ClientOptions, SeamHttpRequestOptions {\n endpoint?: string\n}\n\nexport interface SeamHttpRequestOptions {\n waitForActionAttempt?: boolean | ResolveActionAttemptOptions\n}\n\nexport interface SeamHttpFromPublishableKeyOptions\n extends SeamHttpCommonOptions {}\n\nexport interface SeamHttpOptionsFromEnv extends SeamHttpCommonOptions {}\n\nexport interface SeamHttpMultiWorkspaceOptionsFromEnv\n extends SeamHttpCommonOptions {}\n\nexport interface SeamHttpMultiWorkspaceOptionsWithClient\n extends SeamHttpRequestOptions {\n client: Client\n}\n\nexport const isSeamHttpMultiWorkspaceOptionsWithClient = (\n options: SeamHttpOptions,\n): options is SeamHttpMultiWorkspaceOptionsWithClient =>\n isSeamHttpOptionsWithClient(options)\n\nexport interface SeamHttpOptionsWithClient extends SeamHttpRequestOptions {\n client: Client\n}\n\nexport const isSeamHttpOptionsWithClient = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithClient => {\n if (!('client' in options)) return false\n if (options.client == null) return false\n\n const keys = Object.keys(options).filter((k) => k !== 'client')\n if (keys.filter((k) => !isSeamHttpRequestOption(k)).length > 0) {\n throw new SeamHttpInvalidOptionsError(\n `The client option cannot be used with any other option, but received: ${keys.join(\n ', ',\n )}`,\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithApiKey extends SeamHttpCommonOptions {\n apiKey: string\n}\n\nexport const isSeamHttpOptionsWithApiKey = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithApiKey => {\n if (!('apiKey' in options)) return false\n if (options.apiKey == null) return false\n\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The clientSessionToken option cannot be used with the apiKey option',\n )\n }\n\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The consoleSessionToken option cannot be used with the apiKey option',\n )\n }\n\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The personalAccessToken option cannot be used with the apiKey option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithClientSessionToken\n extends SeamHttpCommonOptions {\n clientSessionToken: string\n}\n\nexport const isSeamHttpOptionsWithClientSessionToken = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithClientSessionToken => {\n if (!('clientSessionToken' in options)) return false\n if (options.clientSessionToken == null) return false\n\n if ('apiKey' in options && options.apiKey != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The apiKey option cannot be used with the clientSessionToken option',\n )\n }\n\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The consoleSessionToken option cannot be used with the clientSessionToken option',\n )\n }\n\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The personalAccessToken option cannot be used with the clientSessionToken option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken\n extends SeamHttpCommonOptions {\n consoleSessionToken: string\n}\n\nexport const isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken = (\n options: SeamHttpOptions,\n): options is SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken => {\n if (!('consoleSessionToken' in options)) return false\n if (options.consoleSessionToken == null) return false\n\n if ('apiKey' in options && options.apiKey != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The apiKey option cannot be used with the consoleSessionToken option',\n )\n }\n\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The clientSessionToken option cannot be used with the consoleSessionToken option',\n )\n }\n\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The personalAccessToken option cannot be used with the consoleSessionToken option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithConsoleSessionToken\n extends SeamHttpCommonOptions {\n consoleSessionToken: string\n workspaceId: string\n}\n\nexport const isSeamHttpOptionsWithConsoleSessionToken = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithConsoleSessionToken => {\n if (!isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken(options)) {\n return false\n }\n\n if (!('workspaceId' in options) || options.workspaceId == null) {\n throw new SeamHttpInvalidOptionsError(\n 'Must pass a workspaceId when using a consoleSessionToken',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken\n extends SeamHttpCommonOptions {\n personalAccessToken: string\n}\n\nexport const isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken = (\n options: SeamHttpOptions,\n): options is SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken => {\n if (!('personalAccessToken' in options)) return false\n if (options.personalAccessToken == null) return false\n\n if ('apiKey' in options && options.apiKey != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The apiKey option cannot be used with the personalAccessToken option',\n )\n }\n\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The clientSessionToken option cannot be used with the personalAccessToken option',\n )\n }\n\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The consoleSessionToken option cannot be used with the personalAccessToken option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithPersonalAccessToken\n extends SeamHttpCommonOptions {\n personalAccessToken: string\n workspaceId: string\n}\n\nexport const isSeamHttpOptionsWithPersonalAccessToken = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithPersonalAccessToken => {\n if (!isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken(options)) {\n return false\n }\n\n if (!('workspaceId' in options) || options.workspaceId == null) {\n throw new SeamHttpInvalidOptionsError(\n 'Must pass a workspaceId when using a personalAccessToken',\n )\n }\n\n return true\n}\n\nexport class SeamHttpInvalidOptionsError extends Error {\n constructor(message: string) {\n super(`SeamHttp received invalid options: ${message}`)\n this.name = this.constructor.name\n }\n}\n\nexport class SeamHttpMultiWorkspaceInvalidOptionsError extends Error {\n constructor(message: string) {\n super(`SeamHttpMultiWorkspace received invalid options: ${message}`)\n this.name = this.constructor.name\n }\n}\n","export const tokenPrefix = 'seam_'\n\nexport const accessTokenPrefix = 'seam_at'\n\nexport const jwtPrefix = 'ey'\n\nexport const clientSessionTokenPrefix = 'seam_cst'\n\nexport const publishableKeyTokenPrefix = 'seam_pk'\n\nexport const isAccessToken = (token: string): boolean =>\n token.startsWith(accessTokenPrefix)\n\nexport const isJwt = (token: string): boolean => token.startsWith(jwtPrefix)\n\nexport const isSeamToken = (token: string): boolean =>\n token.startsWith(tokenPrefix)\n\nexport const isApiKey = (token: string): boolean =>\n !isClientSessionToken(token) &&\n !isJwt(token) &&\n !isAccessToken(token) &&\n !isPublishableKey(token) &&\n isSeamToken(token)\n\nexport const isClientSessionToken = (token: string): boolean =>\n token.startsWith(clientSessionTokenPrefix)\n\nexport const isPublishableKey = (token: string): boolean =>\n token.startsWith(publishableKeyTokenPrefix)\n\nexport const isConsoleSessionToken = (token: string): boolean => isJwt(token)\n\nexport const isPersonalAccessToken = (token: string): boolean =>\n isAccessToken(token)\n","import {\n isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n SeamHttpInvalidOptionsError,\n type SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n type SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n} from './options.js'\nimport type { Options } from './parse-options.js'\nimport {\n accessTokenPrefix,\n clientSessionTokenPrefix,\n isAccessToken,\n isClientSessionToken,\n isJwt,\n isPublishableKey,\n isSeamToken,\n jwtPrefix,\n publishableKeyTokenPrefix,\n tokenPrefix,\n} from './token.js'\n\ntype Headers = Record<string, string>\n\nexport const getAuthHeaders = (options: Options): Headers => {\n if ('publishableKey' in options && options.publishableKey != null) {\n return getAuthHeadersForPublishableKey(options.publishableKey)\n }\n\n if (isSeamHttpOptionsWithApiKey(options)) {\n return getAuthHeadersForApiKey(options)\n }\n\n if (isSeamHttpOptionsWithClientSessionToken(options)) {\n return getAuthHeadersForClientSessionToken(options)\n }\n\n if (\n isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken(options) ||\n isSeamHttpOptionsWithConsoleSessionToken(options)\n ) {\n return getAuthHeadersForConsoleSessionToken(options)\n }\n\n if (\n isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken(options) ||\n isSeamHttpOptionsWithPersonalAccessToken(options)\n ) {\n return getAuthHeadersForPersonalAccessToken(options)\n }\n\n throw new SeamHttpInvalidOptionsError(\n [\n 'Must specify',\n 'an apiKey,',\n 'clientSessionToken,',\n 'publishableKey,',\n 'consoleSessionToken',\n 'or personalAccessToken.',\n 'Attempted reading configuration from the environment, but the environment variable SEAM_API_KEY is not set.',\n ].join(' '),\n )\n}\n\nconst getAuthHeadersForApiKey = ({\n apiKey,\n}: SeamHttpOptionsWithApiKey): Headers => {\n if (isClientSessionToken(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token cannot be used as an apiKey',\n )\n }\n\n if (isJwt(apiKey)) {\n throw new SeamHttpInvalidTokenError('A JWT cannot be used as an apiKey')\n }\n\n if (isAccessToken(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as an apiKey',\n )\n }\n\n if (isPublishableKey(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as an apiKey',\n )\n }\n\n if (!isSeamToken(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid apiKey format, expected token to start with ${tokenPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${apiKey}`,\n }\n}\n\nexport const getAuthHeadersForClientSessionToken = ({\n clientSessionToken,\n}: SeamHttpOptionsWithClientSessionToken): Headers => {\n if (isJwt(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A JWT cannot be used as a clientSessionToken',\n )\n }\n\n if (isAccessToken(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as a clientSessionToken',\n )\n }\n\n if (isPublishableKey(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as a clientSessionToken',\n )\n }\n\n if (!isClientSessionToken(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid clientSessionToken format, expected token to start with ${clientSessionTokenPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${clientSessionToken}`,\n 'client-session-token': clientSessionToken,\n }\n}\n\nconst getAuthHeadersForConsoleSessionToken = ({\n consoleSessionToken,\n ...options\n}:\n | SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken\n | SeamHttpOptionsWithConsoleSessionToken): Headers => {\n const workspaceId = 'workspaceId' in options ? options.workspaceId : undefined\n\n if (isAccessToken(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as a consoleSessionToken',\n )\n }\n\n if (isClientSessionToken(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token cannot be used as a consoleSessionToken',\n )\n }\n\n if (isPublishableKey(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as a consoleSessionToken',\n )\n }\n\n if (!isJwt(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid consoleSessionToken format, expected a JWT which starts with ${jwtPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${consoleSessionToken}`,\n ...(workspaceId != null ? { 'seam-workspace': workspaceId } : {}),\n }\n}\n\nconst getAuthHeadersForPersonalAccessToken = ({\n personalAccessToken,\n ...options\n}:\n | SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken\n | SeamHttpOptionsWithPersonalAccessToken): Headers => {\n const workspaceId = 'workspaceId' in options ? options.workspaceId : undefined\n\n if (isJwt(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A JWT cannot be used as a personalAccessToken',\n )\n }\n\n if (isClientSessionToken(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token cannot be used as a personalAccessToken',\n )\n }\n\n if (isPublishableKey(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as a personalAccessToken',\n )\n }\n\n if (!isAccessToken(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid personalAccessToken format, expected token to start with ${accessTokenPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${personalAccessToken}`,\n ...(workspaceId != null ? { 'seam-workspace': workspaceId } : {}),\n }\n}\n\nconst getAuthHeadersForPublishableKey = (publishableKey: string): Headers => {\n if (isJwt(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A JWT cannot be used as a publishableKey',\n )\n }\n\n if (isAccessToken(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as a publishableKey',\n )\n }\n\n if (isClientSessionToken(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token Key cannot be used as a publishableKey',\n )\n }\n\n if (!isPublishableKey(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid publishableKey format, expected token to start with ${publishableKeyTokenPrefix}`,\n )\n }\n\n return {\n 'seam-publishable-key': publishableKey,\n }\n}\n\nexport class SeamHttpInvalidTokenError extends Error {\n constructor(message: string) {\n super(`SeamHttp received an invalid token: ${message}`)\n this.name = this.constructor.name\n }\n}\n\nexport const warnOnInsecureuserIdentifierKey = (\n userIdentifierKey: string,\n): void => {\n if (isEmail(userIdentifierKey)) {\n // eslint-disable-next-line no-console\n console.warn(\n ...[\n 'Using an email for the userIdentifierKey is insecure and may return an error in the future!',\n 'This is insecure because an email is common knowledge or easily guessed.',\n 'Use something with sufficient entropy known only to the owner of the client session.',\n 'For help choosing a user identifier key see',\n 'https://docs.seam.co/latest/seam-components/overview/get-started-with-client-side-components#3-select-a-user-identifier-key',\n ],\n )\n }\n}\n\n// SOURCE: https://stackoverflow.com/a/46181\nconst isEmail = (value: string): boolean => {\n if (value.includes('!')) return false\n // The regex may run slow on strings starting with '!@!.' and with many repetitions of '!.'.\n return /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/.test(value)\n}\n","import type { ApiError } from './api-error-types.js'\n\nexport class SeamHttpApiError extends Error {\n code: string\n statusCode: number\n requestId: string\n data?: unknown\n\n constructor(error: ApiError, statusCode: number, requestId: string) {\n const { type, message, data } = error\n super(message)\n this.name = this.constructor.name\n this.code = type\n this.statusCode = statusCode\n this.requestId = requestId\n if (data != null) this.data = data\n }\n}\n\nexport const isSeamHttpApiError = (\n error: unknown,\n): error is SeamHttpApiError => {\n return error instanceof SeamHttpApiError\n}\n\nexport class SeamHttpUnauthorizedError extends SeamHttpApiError {\n override code: 'unauthorized'\n override statusCode: 401\n\n constructor(requestId: string) {\n const type = 'unauthorized'\n const status = 401\n super({ type, message: 'Unauthorized' }, status, requestId)\n this.name = this.constructor.name\n this.code = type\n this.statusCode = status\n this.requestId = requestId\n }\n}\n\nexport const isSeamHttpUnauthorizedError = (\n error: unknown,\n): error is SeamHttpUnauthorizedError => {\n return error instanceof SeamHttpUnauthorizedError\n}\n\nexport class SeamHttpInvalidInputError extends SeamHttpApiError {\n override code: 'invalid_input'\n readonly #validationErrors: NonNullable<ApiError['validation_errors']>\n\n constructor(error: ApiError, statusCode: number, requestId: string) {\n super(error, statusCode, requestId)\n this.name = this.constructor.name\n this.code = 'invalid_input'\n this.#validationErrors = error.validation_errors ?? {}\n }\n\n getValidationErrorMessages(paramName: string): string[] {\n return this.#validationErrors[paramName]?._errors ?? []\n }\n}\n\nexport const isSeamHttpInvalidInputError = (\n error: unknown,\n): error is SeamHttpInvalidInputError => {\n return error instanceof SeamHttpInvalidInputError\n}\n","import { type AxiosError, isAxiosError } from 'axios'\n\nimport type { ApiErrorResponse } from './api-error-types.js'\nimport {\n SeamHttpApiError,\n SeamHttpInvalidInputError,\n SeamHttpUnauthorizedError,\n} from './seam-http-error.js'\n\nexport const errorInterceptor = async (err: unknown): Promise<void> => {\n if (!isAxiosError(err)) throw err\n\n const { response } = err\n const status = response?.status\n\n const requestId = getRequestId(err)\n\n if (status == null) throw err\n\n if (status === 401) {\n throw new SeamHttpUnauthorizedError(requestId)\n }\n\n if (!isApiErrorResponse(response)) throw err\n\n const { type } = response.data.error\n\n const args = [response.data.error, status, requestId] as const\n\n if (type === 'invalid_input') throw new SeamHttpInvalidInputError(...args)\n throw new SeamHttpApiError(...args)\n}\n\nconst isApiErrorResponse = (\n response: AxiosError['response'],\n): response is NonNullable<AxiosError<ApiErrorResponse>['response']> => {\n if (response == null) return false\n const { headers, data } = response\n\n if (headers == null) return false\n\n const contentType = headers['Content-Type']\n if (\n typeof contentType === 'string' &&\n !contentType.startsWith('application/json')\n ) {\n return false\n }\n\n if (typeof data === 'object' && data != null) {\n return (\n 'error' in data &&\n typeof data.error === 'object' &&\n data.error != null &&\n 'type' in data.error &&\n typeof data.error.type === 'string' &&\n 'message' in data.error &&\n typeof data.error.message === 'string'\n )\n }\n\n return false\n}\n\nconst getRequestId = (err: AxiosError): string => {\n const headers = err.response?.headers\n if (headers == null) return ''\n const requestId = headers['seam-request-id']\n if (requestId == null) return ''\n return requestId\n}\n","import { serializeUrlSearchParams } from '@seamapi/url-search-params-serializer'\nimport axios, { type AxiosInstance, type AxiosRequestConfig } from 'axios'\nimport axiosRetry, { type AxiosRetry, exponentialDelay } from 'axios-retry'\n\nimport { errorInterceptor } from './error-interceptor.js'\n\nexport type Client = AxiosInstance\n\nexport interface ClientOptions {\n axiosOptions?: AxiosRequestConfig\n axiosRetryOptions?: AxiosRetryConfig\n}\n\ntype AxiosRetryConfig = Parameters<AxiosRetry>[1]\n\nexport const createClient = (options: ClientOptions): AxiosInstance => {\n const client = axios.create({\n paramsSerializer: serializeUrlSearchParams,\n adapter: 'fetch',\n ...options.axiosOptions,\n })\n\n axiosRetry(client, {\n retries: 2,\n retryDelay: exponentialDelay,\n ...options.axiosRetryOptions,\n })\n\n client.interceptors.response.use(undefined, errorInterceptor)\n\n return client\n}\n","import type { openapi } from '@seamapi/types/connect'\n\nimport { createClient } from './client.js'\nimport { defaultEndpoint, sdkHeaders } from './parse-options.js'\n\nexport const getOpenapiSchema = async (\n endpoint = defaultEndpoint,\n): Promise<typeof openapi> => {\n const client = createClient({\n axiosOptions: {\n baseURL: endpoint,\n headers: sdkHeaders,\n },\n })\n const { data } = await client.get<typeof openapi>('/openapi.json')\n return data\n}\n","import type { ActionAttempt } from '@seamapi/types/connect'\n\nimport type { SeamHttpActionAttempts } from './routes/index.js'\n\nexport interface ResolveActionAttemptOptions {\n timeout?: number\n pollingInterval?: number\n}\n\nexport const resolveActionAttempt = async <T extends ActionAttempt>(\n actionAttempt: T,\n actionAttempts: SeamHttpActionAttempts,\n { timeout = 5000, pollingInterval = 500 }: ResolveActionAttemptOptions,\n): Promise<SucceededActionAttempt<T>> => {\n let timeoutRef\n const timeoutPromise = new Promise<SucceededActionAttempt<T>>(\n (_resolve, reject) => {\n timeoutRef = globalThis.setTimeout(() => {\n reject(new SeamActionAttemptTimeoutError<T>(actionAttempt, timeout))\n }, timeout)\n },\n )\n\n try {\n return await Promise.race([\n pollActionAttempt<T>(actionAttempt, actionAttempts, { pollingInterval }),\n timeoutPromise,\n ])\n } finally {\n if (timeoutRef != null) globalThis.clearTimeout(timeoutRef)\n }\n}\n\nconst pollActionAttempt = async <T extends ActionAttempt>(\n actionAttempt: T,\n actionAttempts: SeamHttpActionAttempts,\n options: Pick<ResolveActionAttemptOptions, 'pollingInterval'>,\n): Promise<SucceededActionAttempt<T>> => {\n if (isSuccessfulActionAttempt(actionAttempt)) {\n return actionAttempt\n }\n\n if (isFailedActionAttempt(actionAttempt)) {\n throw new SeamActionAttemptFailedError(actionAttempt)\n }\n\n await new Promise((resolve) => setTimeout(resolve, options.pollingInterval))\n\n const nextActionAttempt = await actionAttempts.get({\n action_attempt_id: actionAttempt.action_attempt_id,\n })\n\n return await pollActionAttempt(\n nextActionAttempt as unknown as T,\n actionAttempts,\n options,\n )\n}\n\nexport const isSeamActionAttemptError = <T extends ActionAttempt>(\n error: unknown,\n): error is SeamActionAttemptError<T> => {\n return error instanceof SeamActionAttemptError\n}\n\nexport class SeamActionAttemptError<T extends ActionAttempt> extends Error {\n actionAttempt: T\n\n constructor(message: string, actionAttempt: T) {\n super(message)\n this.name = this.constructor.name\n this.actionAttempt = actionAttempt\n }\n}\n\nexport const isSeamActionAttemptFailedError = <T extends ActionAttempt>(\n error: unknown,\n): error is SeamActionAttemptFailedError<T> => {\n return error instanceof SeamActionAttemptFailedError\n}\n\nexport class SeamActionAttemptFailedError<\n T extends ActionAttempt,\n> extends SeamActionAttemptError<T> {\n code: string\n\n constructor(actionAttempt: FailedActionAttempt<T>) {\n super(actionAttempt.error.message, actionAttempt)\n this.name = this.constructor.name\n this.code = actionAttempt.error.type\n }\n}\n\nexport const isSeamActionAttemptTimeoutError = <T extends ActionAttempt>(\n error: unknown,\n): error is SeamActionAttemptTimeoutError<T> => {\n return error instanceof SeamActionAttemptTimeoutError\n}\n\nexport class SeamActionAttemptTimeoutError<\n T extends ActionAttempt,\n> extends SeamActionAttemptError<T> {\n constructor(actionAttempt: T, timeout: number) {\n super(\n `Timed out waiting for action action attempt after ${timeout}ms`,\n actionAttempt,\n )\n this.name = this.constructor.name\n }\n}\n\nconst isSuccessfulActionAttempt = <T extends ActionAttempt>(\n actionAttempt: T,\n): actionAttempt is SucceededActionAttempt<T> =>\n actionAttempt.status === 'success'\n\nconst isFailedActionAttempt = <T extends ActionAttempt>(\n actionAttempt: T,\n): actionAttempt is FailedActionAttempt<T> => actionAttempt.status === 'error'\n\nexport type SucceededActionAttempt<T extends ActionAttempt> = Extract<\n T,\n { status: 'success' }\n>\n\nexport type FailedActionAttempt<T extends ActionAttempt> = Extract<\n T,\n { status: 'error' }\n>\n","import type { ActionAttempt } from '@seamapi/types/connect'\nimport { serializeUrlSearchParams } from '@seamapi/url-search-params-serializer'\nimport type { Method } from 'axios'\n\nimport type { Client } from './client.js'\nimport type { SeamHttpRequestOptions } from './options.js'\nimport { resolveActionAttempt } from './resolve-action-attempt.js'\nimport { SeamHttpActionAttempts } from './routes/index.js'\n\ninterface SeamHttpRequestParent {\n readonly client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n}\n\ninterface SeamHttpRequestConfig<TResponseKey> {\n readonly pathname: string\n readonly method: Method\n readonly body?: unknown\n readonly params?: undefined | Record<string, unknown>\n readonly responseKey: TResponseKey\n readonly options?: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'>\n}\n\nexport class SeamHttpRequest<\n const TResponse,\n const TResponseKey extends keyof TResponse | undefined,\n> implements\n Promise<\n TResponseKey extends keyof TResponse ? TResponse[TResponseKey] : undefined\n >\n{\n readonly [Symbol.toStringTag]: string = 'SeamHttpRequest'\n\n readonly #parent: SeamHttpRequestParent\n readonly #config: SeamHttpRequestConfig<TResponseKey>\n\n constructor(\n parent: SeamHttpRequestParent,\n config: SeamHttpRequestConfig<TResponseKey>,\n ) {\n this.#parent = parent\n this.#config = config\n }\n\n public get responseKey(): TResponseKey {\n return this.#config.responseKey\n }\n\n public get url(): URL {\n const { client } = this.#parent\n\n const serializer =\n typeof client.defaults.paramsSerializer === 'function'\n ? client.defaults.paramsSerializer\n : serializeUrlSearchParams\n\n const origin = getUrlPrefix(client.defaults.baseURL ?? '')\n\n const path =\n this.params == null\n ? this.pathname\n : `${this.pathname}?${serializer(this.params)}`\n\n return new URL(`${origin}${path}`)\n }\n\n public get pathname(): string {\n return this.#config.pathname.startsWith('/')\n ? this.#config.pathname\n : `/${this.#config.pathname}`\n }\n\n public get method(): Method {\n return this.#config.method\n }\n\n public get params(): undefined | Record<string, unknown> {\n return this.#config.params\n }\n\n public get body(): unknown {\n return this.#config.body\n }\n\n async execute(): Promise<\n TResponseKey extends keyof TResponse ? TResponse[TResponseKey] : undefined\n > {\n const response = await this.fetchResponse()\n\n type Response = TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined\n\n if (this.responseKey === undefined) {\n return undefined as Response\n }\n\n const data = response[this.responseKey] as unknown as Response\n\n if (this.responseKey === 'action_attempt') {\n const waitForActionAttempt =\n this.#config.options?.waitForActionAttempt ??\n this.#parent.defaults.waitForActionAttempt\n\n if (waitForActionAttempt !== false) {\n const actionAttempt = await resolveActionAttempt(\n data as unknown as ActionAttempt,\n SeamHttpActionAttempts.fromClient(this.#parent.client, {\n ...this.#parent.defaults,\n waitForActionAttempt: false,\n }),\n typeof waitForActionAttempt === 'boolean' ? {} : waitForActionAttempt,\n )\n return actionAttempt as Response\n }\n }\n\n return data\n }\n\n async fetchResponse(): Promise<TResponse> {\n const { client } = this.#parent\n const response = await client.request({\n url: this.pathname,\n method: this.method,\n data: this.body,\n params: this.params,\n })\n return response.data as unknown as TResponse\n }\n\n async then<\n TResult1 = TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined,\n TResult2 = never,\n >(\n onfulfilled?:\n | ((\n value: TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined,\n ) => TResult1 | PromiseLike<TResult1>)\n | null\n | undefined,\n onrejected?:\n | ((reason: unknown) => TResult2 | PromiseLike<TResult2>)\n | null\n | undefined,\n ): Promise<TResult1 | TResult2> {\n return await this.execute().then(onfulfilled, onrejected)\n }\n\n async catch<TResult = never>(\n onrejected?:\n | ((reason: unknown) => TResult | PromiseLike<TResult>)\n | null\n | undefined,\n ): Promise<\n | (TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined)\n | TResult\n > {\n return await this.execute().catch(onrejected)\n }\n\n async finally(\n onfinally?: (() => void) | null | undefined,\n ): Promise<\n TResponseKey extends keyof TResponse ? TResponse[TResponseKey] : undefined\n > {\n return await this.execute().finally(onfinally)\n }\n}\n\nconst getUrlPrefix = (input: string): string => {\n if (canParseUrl(input)) {\n const url = new URL(input).toString()\n if (url.endsWith('/')) return url.slice(0, -1)\n return url\n }\n if (globalThis.location != null) {\n const pathname = input.startsWith('/') ? input : `/${input}`\n return new URL(`${globalThis.location.origin}${pathname}`).toString()\n }\n throw new Error(\n `Cannot resolve origin from ${input} in a non-browser environment`,\n )\n}\n\n// UPSTREAM: Prefer URL.canParse when it has wider support.\n// https://caniuse.com/mdn-api_url_canparse_static\nconst canParseUrl = (input: string): boolean => {\n try {\n return new URL(input) != null\n } catch {\n return false\n }\n}\n","import type { Client } from './client.js'\nimport type { SeamHttpRequestOptions } from './options.js'\nimport { SeamHttpRequest } from './seam-http-request.js'\n\ninterface SeamPaginatorParent {\n readonly client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n}\n\ndeclare const $brand: unique symbol\n\ntype PageCursor = string & { [$brand]: 'SeamPageCursor' }\n\ninterface Pagination {\n readonly hasNextPage: boolean\n readonly nextPageCursor: PageCursor | null\n readonly nextPageUrl: string | null\n}\n\nexport class SeamPaginator<\n const TResponse,\n const TResponseKey extends keyof TResponse,\n> implements AsyncIterable<EnsureReadonlyArray<TResponse[TResponseKey]>>\n{\n readonly #request: SeamHttpRequest<TResponse, TResponseKey>\n readonly #parent: SeamPaginatorParent\n\n constructor(\n parent: SeamPaginatorParent,\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ) {\n if (request.responseKey == null) {\n throw new Error(\n `The ${request.pathname} endpoint does not support pagination`,\n )\n }\n this.#parent = parent\n this.#request = request\n }\n\n async firstPage(): Promise<\n [EnsureReadonlyArray<TResponse[TResponseKey]>, Pagination]\n > {\n return await this.#fetch()\n }\n\n async nextPage(\n nextPageCursor: Pagination['nextPageCursor'],\n ): Promise<[EnsureReadonlyArray<TResponse[TResponseKey]>, Pagination]> {\n if (nextPageCursor == null) {\n throw new Error('Cannot get the next page with a null nextPageCursor')\n }\n\n return await this.#fetch(nextPageCursor)\n }\n\n async #fetch(\n nextPageCursor?: Pagination['nextPageCursor'],\n ): Promise<[EnsureReadonlyArray<TResponse[TResponseKey]>, Pagination]> {\n const responseKey = this.#request.responseKey\n\n if (responseKey == null) {\n throw new Error('Cannot paginate a response without a responseKey')\n }\n\n const request = new SeamHttpRequest<TResponse, TResponseKey>(this.#parent, {\n pathname: this.#request.pathname,\n method: this.#request.method,\n responseKey,\n params:\n this.#request.params != null\n ? { ...this.#request.params, page_cursor: nextPageCursor }\n : undefined,\n body:\n this.#request.body != null\n ? { ...this.#request.body, page_cursor: nextPageCursor }\n : undefined,\n })\n\n const response = await request.fetchResponse()\n const data = response[responseKey]\n\n const paginationData =\n response != null &&\n typeof response === 'object' &&\n 'pagination' in response\n ? (response.pagination as PaginationData)\n : null\n\n const pagination: Pagination = {\n hasNextPage: paginationData?.has_next_page ?? false,\n nextPageCursor: paginationData?.next_page_cursor ?? null,\n nextPageUrl: paginationData?.next_page_url ?? null,\n }\n\n if (!Array.isArray(data)) {\n throw new Error(\n `Expected an array response for ${String(responseKey)} but got ${String(typeof data)}`,\n )\n }\n\n return [\n data as EnsureReadonlyArray<TResponse[TResponseKey]>,\n pagination,\n ] as const\n }\n\n async flattenToArray(): Promise<\n EnsureReadonlyArray<TResponse[TResponseKey]>\n > {\n const items = [] as EnsureMutableArray<TResponse[TResponseKey]>\n let [current, pagination] = await this.firstPage()\n items.push(...current)\n while (pagination.hasNextPage) {\n ;[current, pagination] = await this.nextPage(pagination.nextPageCursor)\n items.push(...current)\n }\n return items as EnsureReadonlyArray<TResponse[TResponseKey]>\n }\n\n async *flatten(): AsyncGenerator<\n EnsureReadonlyArray<TResponse[TResponseKey]>\n > {\n let [current, pagination] = await this.firstPage()\n for (const item of current) {\n yield item\n }\n while (pagination.hasNextPage) {\n ;[current, pagination] = await this.nextPage(pagination.nextPageCursor)\n for (const item of current) {\n yield item\n }\n }\n }\n\n async *[Symbol.asyncIterator](): AsyncGenerator<\n EnsureReadonlyArray<TResponse[TResponseKey]>\n > {\n let [current, pagination] = await this.firstPage()\n yield current\n while (pagination.hasNextPage) {\n ;[current, pagination] = await this.nextPage(pagination.nextPageCursor)\n yield current\n }\n }\n}\n\ntype EnsureReadonlyArray<T> = T extends readonly any[] ? T : never\ntype EnsureMutableArray<T> = T extends any[] ? T : never\n\ninterface PaginationData {\n has_next_page: boolean\n next_page_cursor: PageCursor | null\n next_page_url: string | null\n}\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpClientSessions {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpClientSessions> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpClientSessions.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ClientSessionsCreateBody,\n ): SeamHttpRequest<ClientSessionsCreateResponse, 'client_session'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/create',\n method: 'post',\n body,\n responseKey: 'client_session',\n })\n }\n\n delete(body?: ClientSessionsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: ClientSessionsGetParams,\n ): SeamHttpRequest<ClientSessionsGetResponse, 'client_session'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/get',\n method: 'post',\n body,\n responseKey: 'client_session',\n })\n }\n\n getOrCreate(\n body?: ClientSessionsGetOrCreateBody,\n ): SeamHttpRequest<ClientSessionsGetOrCreateResponse, 'client_session'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/get_or_create',\n method: 'post',\n body,\n responseKey: 'client_session',\n })\n }\n\n grantAccess(\n body?: ClientSessionsGrantAccessBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/grant_access',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n list(\n body?: ClientSessionsListParams,\n ): SeamHttpRequest<ClientSessionsListResponse, 'client_sessions'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/list',\n method: 'post',\n body,\n responseKey: 'client_sessions',\n })\n }\n\n revoke(body?: ClientSessionsRevokeParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/revoke',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ClientSessionsCreateBody =\n RouteRequestBody<'/client_sessions/create'>\n\nexport type ClientSessionsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/create'>>\n>\n\nexport type ClientSessionsCreateOptions = never\n\nexport type ClientSessionsDeleteParams =\n RouteRequestBody<'/client_sessions/delete'>\n\nexport type ClientSessionsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/delete'>>\n>\n\nexport type ClientSessionsDeleteOptions = never\n\nexport type ClientSessionsGetParams = RouteRequestBody<'/client_sessions/get'>\n\nexport type ClientSessionsGetResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/get'>>\n>\n\nexport type ClientSessionsGetOptions = never\n\nexport type ClientSessionsGetOrCreateBody =\n RouteRequestBody<'/client_sessions/get_or_create'>\n\nexport type ClientSessionsGetOrCreateResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/get_or_create'>>\n>\n\nexport type ClientSessionsGetOrCreateOptions = never\n\nexport type ClientSessionsGrantAccessBody =\n RouteRequestBody<'/client_sessions/grant_access'>\n\nexport type ClientSessionsGrantAccessResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/grant_access'>>\n>\n\nexport type ClientSessionsGrantAccessOptions = never\n\nexport type ClientSessionsListParams = RouteRequestBody<'/client_sessions/list'>\n\nexport type ClientSessionsListResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/list'>>\n>\n\nexport type ClientSessionsListOptions = never\n\nexport type ClientSessionsRevokeParams =\n RouteRequestBody<'/client_sessions/revoke'>\n\nexport type ClientSessionsRevokeResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/revoke'>>\n>\n\nexport type ClientSessionsRevokeOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAccessCodesSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessCodesSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessCodesSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n createUnmanagedAccessCode(\n body?: AccessCodesSimulateCreateUnmanagedAccessCodeBody,\n ): SeamHttpRequest<\n AccessCodesSimulateCreateUnmanagedAccessCodeResponse,\n 'access_code'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/simulate/create_unmanaged_access_code',\n method: 'post',\n body,\n responseKey: 'access_code',\n })\n }\n}\n\nexport type AccessCodesSimulateCreateUnmanagedAccessCodeBody =\n RouteRequestBody<'/access_codes/simulate/create_unmanaged_access_code'>\n\nexport type AccessCodesSimulateCreateUnmanagedAccessCodeResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/access_codes/simulate/create_unmanaged_access_code'>\n >\n >\n\nexport type AccessCodesSimulateCreateUnmanagedAccessCodeOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAccessCodesUnmanaged {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessCodesUnmanaged> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessCodesUnmanaged.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n convertToManaged(\n body?: AccessCodesUnmanagedConvertToManagedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/convert_to_managed',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n delete(\n body?: AccessCodesUnmanagedDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: AccessCodesUnmanagedGetParams,\n ): SeamHttpRequest<AccessCodesUnmanagedGetResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/get',\n method: 'post',\n body,\n responseKey: 'access_code',\n })\n }\n\n list(\n body?: AccessCodesUnmanagedListParams,\n ): SeamHttpRequest<AccessCodesUnmanagedListResponse, 'access_codes'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/list',\n method: 'post',\n body,\n responseKey: 'access_codes',\n })\n }\n\n update(\n body?: AccessCodesUnmanagedUpdateBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AccessCodesUnmanagedConvertToManagedBody =\n RouteRequestBody<'/access_codes/unmanaged/convert_to_managed'>\n\nexport type AccessCodesUnmanagedConvertToManagedResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/convert_to_managed'>>\n>\n\nexport type AccessCodesUnmanagedConvertToManagedOptions = never\n\nexport type AccessCodesUnmanagedDeleteParams =\n RouteRequestBody<'/access_codes/unmanaged/delete'>\n\nexport type AccessCodesUnmanagedDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/delete'>>\n>\n\nexport type AccessCodesUnmanagedDeleteOptions = never\n\nexport type AccessCodesUnmanagedGetParams =\n RouteRequestBody<'/access_codes/unmanaged/get'>\n\nexport type AccessCodesUnmanagedGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/get'>>\n>\n\nexport type AccessCodesUnmanagedGetOptions = never\n\nexport type AccessCodesUnmanagedListParams =\n RouteRequestBody<'/access_codes/unmanaged/list'>\n\nexport type AccessCodesUnmanagedListResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/list'>>\n>\n\nexport type AccessCodesUnmanagedListOptions = never\n\nexport type AccessCodesUnmanagedUpdateBody =\n RouteRequestBody<'/access_codes/unmanaged/update'>\n\nexport type AccessCodesUnmanagedUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/update'>>\n>\n\nexport type AccessCodesUnmanagedUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpAccessCodesSimulate } from './access-codes-simulate.js'\nimport { SeamHttpAccessCodesUnmanaged } from './access-codes-unmanaged.js'\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAccessCodes {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessCodes> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessCodes.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get unmanaged(): SeamHttpAccessCodesUnmanaged {\n return SeamHttpAccessCodesUnmanaged.fromClient(this.client, this.defaults)\n }\n\n get simulate(): SeamHttpAccessCodesSimulate {\n return SeamHttpAccessCodesSimulate.fromClient(this.client, this.defaults)\n }\n\n create(\n body?: AccessCodesCreateBody,\n ): SeamHttpRequest<AccessCodesCreateResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/create',\n method: 'post',\n body,\n responseKey: 'access_code',\n })\n }\n\n createMultiple(\n body?: AccessCodesCreateMultipleBody,\n ): SeamHttpRequest<AccessCodesCreateMultipleResponse, 'access_codes'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/create_multiple',\n method: 'post',\n body,\n responseKey: 'access_codes',\n })\n }\n\n delete(body?: AccessCodesDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n generateCode(\n body?: AccessCodesGenerateCodeBody,\n ): SeamHttpRequest<AccessCodesGenerateCodeResponse, 'generated_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/generate_code',\n method: 'post',\n body,\n responseKey: 'generated_code',\n })\n }\n\n get(\n body?: AccessCodesGetParams,\n ): SeamHttpRequest<AccessCodesGetResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/get',\n method: 'post',\n body,\n responseKey: 'access_code',\n })\n }\n\n list(\n body?: AccessCodesListParams,\n ): SeamHttpRequest<AccessCodesListResponse, 'access_codes'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/list',\n method: 'post',\n body,\n responseKey: 'access_codes',\n })\n }\n\n pullBackupAccessCode(\n body?: AccessCodesPullBackupAccessCodeBody,\n ): SeamHttpRequest<AccessCodesPullBackupAccessCodeResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/pull_backup_access_code',\n method: 'post',\n body,\n responseKey: 'access_code',\n })\n }\n\n reportDeviceConstraints(\n body?: AccessCodesReportDeviceConstraintsBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/report_device_constraints',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: AccessCodesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n updateMultiple(\n body?: AccessCodesUpdateMultipleBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/update_multiple',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AccessCodesCreateBody = RouteRequestBody<'/access_codes/create'>\n\nexport type AccessCodesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/create'>>\n>\n\nexport type AccessCodesCreateOptions = never\n\nexport type AccessCodesCreateMultipleBody =\n RouteRequestBody<'/access_codes/create_multiple'>\n\nexport type AccessCodesCreateMultipleResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/create_multiple'>>\n>\n\nexport type AccessCodesCreateMultipleOptions = never\n\nexport type AccessCodesDeleteParams = RouteRequestBody<'/access_codes/delete'>\n\nexport type AccessCodesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/delete'>>\n>\n\nexport type AccessCodesDeleteOptions = never\n\nexport type AccessCodesGenerateCodeBody =\n RouteRequestBody<'/access_codes/generate_code'>\n\nexport type AccessCodesGenerateCodeResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/generate_code'>>\n>\n\nexport type AccessCodesGenerateCodeOptions = never\n\nexport type AccessCodesGetParams = RouteRequestBody<'/access_codes/get'>\n\nexport type AccessCodesGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/get'>>\n>\n\nexport type AccessCodesGetOptions = never\n\nexport type AccessCodesListParams = RouteRequestBody<'/access_codes/list'>\n\nexport type AccessCodesListResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/list'>>\n>\n\nexport type AccessCodesListOptions = never\n\nexport type AccessCodesPullBackupAccessCodeBody =\n RouteRequestBody<'/access_codes/pull_backup_access_code'>\n\nexport type AccessCodesPullBackupAccessCodeResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/pull_backup_access_code'>>\n>\n\nexport type AccessCodesPullBackupAccessCodeOptions = never\n\nexport type AccessCodesReportDeviceConstraintsBody =\n RouteRequestBody<'/access_codes/report_device_constraints'>\n\nexport type AccessCodesReportDeviceConstraintsResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/report_device_constraints'>>\n>\n\nexport type AccessCodesReportDeviceConstraintsOptions = never\n\nexport type AccessCodesUpdateBody = RouteRequestBody<'/access_codes/update'>\n\nexport type AccessCodesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/update'>>\n>\n\nexport type AccessCodesUpdateOptions = never\n\nexport type AccessCodesUpdateMultipleBody =\n RouteRequestBody<'/access_codes/update_multiple'>\n\nexport type AccessCodesUpdateMultipleResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/update_multiple'>>\n>\n\nexport type AccessCodesUpdateMultipleOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAccessGrants {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessGrants> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessGrants.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: AccessGrantsCreateBody,\n ): SeamHttpRequest<AccessGrantsCreateResponse, 'access_grant'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/create',\n method: 'post',\n body,\n responseKey: 'access_grant',\n })\n }\n\n delete(body?: AccessGrantsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: AccessGrantsGetParams,\n ): SeamHttpRequest<AccessGrantsGetResponse, 'access_grant'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/get',\n method: 'post',\n body,\n responseKey: 'access_grant',\n })\n }\n\n list(\n body?: AccessGrantsListParams,\n ): SeamHttpRequest<AccessGrantsListResponse, 'access_grants'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/list',\n method: 'post',\n body,\n responseKey: 'access_grants',\n })\n }\n}\n\nexport type AccessGrantsCreateBody = RouteRequestBody<'/access_grants/create'>\n\nexport type AccessGrantsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/create'>>\n>\n\nexport type AccessGrantsCreateOptions = never\n\nexport type AccessGrantsDeleteParams = RouteRequestBody<'/access_grants/delete'>\n\nexport type AccessGrantsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/delete'>>\n>\n\nexport type AccessGrantsDeleteOptions = never\n\nexport type AccessGrantsGetParams = RouteRequestBody<'/access_grants/get'>\n\nexport type AccessGrantsGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/get'>>\n>\n\nexport type AccessGrantsGetOptions = never\n\nexport type AccessGrantsListParams = RouteRequestBody<'/access_grants/list'>\n\nexport type AccessGrantsListResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/list'>>\n>\n\nexport type AccessGrantsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAccessMethods {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessMethods> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessMethods.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n delete(body?: AccessMethodsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_methods/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: AccessMethodsGetParams,\n ): SeamHttpRequest<AccessMethodsGetResponse, 'access_method'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_methods/get',\n method: 'post',\n body,\n responseKey: 'access_method',\n })\n }\n\n list(\n body?: AccessMethodsListParams,\n ): SeamHttpRequest<AccessMethodsListResponse, 'access_methods'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_methods/list',\n method: 'post',\n body,\n responseKey: 'access_methods',\n })\n }\n}\n\nexport type AccessMethodsDeleteParams =\n RouteRequestBody<'/access_methods/delete'>\n\nexport type AccessMethodsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_methods/delete'>>\n>\n\nexport type AccessMethodsDeleteOptions = never\n\nexport type AccessMethodsGetParams = RouteRequestBody<'/access_methods/get'>\n\nexport type AccessMethodsGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_methods/get'>>\n>\n\nexport type AccessMethodsGetOptions = never\n\nexport type AccessMethodsListParams = RouteRequestBody<'/access_methods/list'>\n\nexport type AccessMethodsListResponse = SetNonNullable<\n Required<RouteResponse<'/access_methods/list'>>\n>\n\nexport type AccessMethodsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsAccessGroups {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsAccessGroups> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsAccessGroups.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n addUser(body?: AcsAccessGroupsAddUserBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/add_user',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: AcsAccessGroupsGetParams,\n ): SeamHttpRequest<AcsAccessGroupsGetResponse, 'acs_access_group'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/get',\n method: 'post',\n body,\n responseKey: 'acs_access_group',\n })\n }\n\n list(\n body?: AcsAccessGroupsListParams,\n ): SeamHttpRequest<AcsAccessGroupsListResponse, 'acs_access_groups'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/list',\n method: 'post',\n body,\n responseKey: 'acs_access_groups',\n })\n }\n\n listAccessibleEntrances(\n body?: AcsAccessGroupsListAccessibleEntrancesParams,\n ): SeamHttpRequest<\n AcsAccessGroupsListAccessibleEntrancesResponse,\n 'acs_entrances'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/list_accessible_entrances',\n method: 'post',\n body,\n responseKey: 'acs_entrances',\n })\n }\n\n listUsers(\n body?: AcsAccessGroupsListUsersParams,\n ): SeamHttpRequest<AcsAccessGroupsListUsersResponse, 'acs_users'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/list_users',\n method: 'post',\n body,\n responseKey: 'acs_users',\n })\n }\n\n removeUser(\n body?: AcsAccessGroupsRemoveUserParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/remove_user',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsAccessGroupsAddUserBody =\n RouteRequestBody<'/acs/access_groups/add_user'>\n\nexport type AcsAccessGroupsAddUserResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/add_user'>>\n>\n\nexport type AcsAccessGroupsAddUserOptions = never\n\nexport type AcsAccessGroupsGetParams =\n RouteRequestBody<'/acs/access_groups/get'>\n\nexport type AcsAccessGroupsGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/get'>>\n>\n\nexport type AcsAccessGroupsGetOptions = never\n\nexport type AcsAccessGroupsListParams =\n RouteRequestBody<'/acs/access_groups/list'>\n\nexport type AcsAccessGroupsListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/list'>>\n>\n\nexport type AcsAccessGroupsListOptions = never\n\nexport type AcsAccessGroupsListAccessibleEntrancesParams =\n RouteRequestBody<'/acs/access_groups/list_accessible_entrances'>\n\nexport type AcsAccessGroupsListAccessibleEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/list_accessible_entrances'>>\n>\n\nexport type AcsAccessGroupsListAccessibleEntrancesOptions = never\n\nexport type AcsAccessGroupsListUsersParams =\n RouteRequestBody<'/acs/access_groups/list_users'>\n\nexport type AcsAccessGroupsListUsersResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/list_users'>>\n>\n\nexport type AcsAccessGroupsListUsersOptions = never\n\nexport type AcsAccessGroupsRemoveUserParams =\n RouteRequestBody<'/acs/access_groups/remove_user'>\n\nexport type AcsAccessGroupsRemoveUserResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/remove_user'>>\n>\n\nexport type AcsAccessGroupsRemoveUserOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsCredentials {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsCredentials> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsCredentials.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n assign(body?: AcsCredentialsAssignBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/assign',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: AcsCredentialsCreateBody,\n ): SeamHttpRequest<AcsCredentialsCreateResponse, 'acs_credential'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/create',\n method: 'post',\n body,\n responseKey: 'acs_credential',\n })\n }\n\n delete(body?: AcsCredentialsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: AcsCredentialsGetParams,\n ): SeamHttpRequest<AcsCredentialsGetResponse, 'acs_credential'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/get',\n method: 'post',\n body,\n responseKey: 'acs_credential',\n })\n }\n\n list(\n body?: AcsCredentialsListParams,\n ): SeamHttpRequest<AcsCredentialsListResponse, 'acs_credentials'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/list',\n method: 'post',\n body,\n responseKey: 'acs_credentials',\n })\n }\n\n listAccessibleEntrances(\n body?: AcsCredentialsListAccessibleEntrancesParams,\n ): SeamHttpRequest<\n AcsCredentialsListAccessibleEntrancesResponse,\n 'acs_entrances'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/list_accessible_entrances',\n method: 'post',\n body,\n responseKey: 'acs_entrances',\n })\n }\n\n unassign(\n body?: AcsCredentialsUnassignBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/unassign',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: AcsCredentialsUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsCredentialsAssignBody =\n RouteRequestBody<'/acs/credentials/assign'>\n\nexport type AcsCredentialsAssignResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/assign'>>\n>\n\nexport type AcsCredentialsAssignOptions = never\n\nexport type AcsCredentialsCreateBody =\n RouteRequestBody<'/acs/credentials/create'>\n\nexport type AcsCredentialsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/create'>>\n>\n\nexport type AcsCredentialsCreateOptions = never\n\nexport type AcsCredentialsDeleteParams =\n RouteRequestBody<'/acs/credentials/delete'>\n\nexport type AcsCredentialsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/delete'>>\n>\n\nexport type AcsCredentialsDeleteOptions = never\n\nexport type AcsCredentialsGetParams = RouteRequestBody<'/acs/credentials/get'>\n\nexport type AcsCredentialsGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/get'>>\n>\n\nexport type AcsCredentialsGetOptions = never\n\nexport type AcsCredentialsListParams = RouteRequestBody<'/acs/credentials/list'>\n\nexport type AcsCredentialsListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/list'>>\n>\n\nexport type AcsCredentialsListOptions = never\n\nexport type AcsCredentialsListAccessibleEntrancesParams =\n RouteRequestBody<'/acs/credentials/list_accessible_entrances'>\n\nexport type AcsCredentialsListAccessibleEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/list_accessible_entrances'>>\n>\n\nexport type AcsCredentialsListAccessibleEntrancesOptions = never\n\nexport type AcsCredentialsUnassignBody =\n RouteRequestBody<'/acs/credentials/unassign'>\n\nexport type AcsCredentialsUnassignResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/unassign'>>\n>\n\nexport type AcsCredentialsUnassignOptions = never\n\nexport type AcsCredentialsUpdateBody =\n RouteRequestBody<'/acs/credentials/update'>\n\nexport type AcsCredentialsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/update'>>\n>\n\nexport type AcsCredentialsUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsEncodersSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsEncodersSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsEncodersSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n nextCredentialEncodeWillFail(\n body?: AcsEncodersSimulateNextCredentialEncodeWillFailBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_encode_will_fail',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n nextCredentialEncodeWillSucceed(\n body?: AcsEncodersSimulateNextCredentialEncodeWillSucceedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_encode_will_succeed',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n nextCredentialScanWillFail(\n body?: AcsEncodersSimulateNextCredentialScanWillFailBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_scan_will_fail',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n nextCredentialScanWillSucceed(\n body?: AcsEncodersSimulateNextCredentialScanWillSucceedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_scan_will_succeed',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillFailBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_encode_will_fail'>\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillFailResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_encode_will_fail'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillFailOptions = never\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillSucceedBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_encode_will_succeed'>\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillSucceedResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_encode_will_succeed'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillSucceedOptions = never\n\nexport type AcsEncodersSimulateNextCredentialScanWillFailBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_scan_will_fail'>\n\nexport type AcsEncodersSimulateNextCredentialScanWillFailResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_scan_will_fail'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialScanWillFailOptions = never\n\nexport type AcsEncodersSimulateNextCredentialScanWillSucceedBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_scan_will_succeed'>\n\nexport type AcsEncodersSimulateNextCredentialScanWillSucceedResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_scan_will_succeed'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialScanWillSucceedOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpAcsEncodersSimulate } from './acs-encoders-simulate.js'\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsEncoders {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsEncoders> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsEncoders.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get simulate(): SeamHttpAcsEncodersSimulate {\n return SeamHttpAcsEncodersSimulate.fromClient(this.client, this.defaults)\n }\n\n encodeAccessMethod(\n body?: AcsEncodersEncodeAccessMethodBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<AcsEncodersEncodeAccessMethodResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/encode_access_method',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n encodeCredential(\n body?: AcsEncodersEncodeCredentialBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<AcsEncodersEncodeCredentialResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/encode_credential',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n get(\n body?: AcsEncodersGetParams,\n ): SeamHttpRequest<AcsEncodersGetResponse, 'acs_encoder'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/get',\n method: 'post',\n body,\n responseKey: 'acs_encoder',\n })\n }\n\n list(\n body?: AcsEncodersListParams,\n ): SeamHttpRequest<AcsEncodersListResponse, 'acs_encoders'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/list',\n method: 'post',\n body,\n responseKey: 'acs_encoders',\n })\n }\n\n scanCredential(\n body?: AcsEncodersScanCredentialBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<AcsEncodersScanCredentialResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/scan_credential',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type AcsEncodersEncodeAccessMethodBody =\n RouteRequestBody<'/acs/encoders/encode_access_method'>\n\nexport type AcsEncodersEncodeAccessMethodResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/encode_access_method'>>\n>\n\nexport type AcsEncodersEncodeAccessMethodOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type AcsEncodersEncodeCredentialBody =\n RouteRequestBody<'/acs/encoders/encode_credential'>\n\nexport type AcsEncodersEncodeCredentialResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/encode_credential'>>\n>\n\nexport type AcsEncodersEncodeCredentialOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type AcsEncodersGetParams = RouteRequestBody<'/acs/encoders/get'>\n\nexport type AcsEncodersGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/get'>>\n>\n\nexport type AcsEncodersGetOptions = never\n\nexport type AcsEncodersListParams = RouteRequestBody<'/acs/encoders/list'>\n\nexport type AcsEncodersListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/list'>>\n>\n\nexport type AcsEncodersListOptions = never\n\nexport type AcsEncodersScanCredentialBody =\n RouteRequestBody<'/acs/encoders/scan_credential'>\n\nexport type AcsEncodersScanCredentialResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/scan_credential'>>\n>\n\nexport type AcsEncodersScanCredentialOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsEntrances {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsEntrances> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsEntrances.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n body?: AcsEntrancesGetParams,\n ): SeamHttpRequest<AcsEntrancesGetResponse, 'acs_entrance'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/get',\n method: 'post',\n body,\n responseKey: 'acs_entrance',\n })\n }\n\n grantAccess(\n body?: AcsEntrancesGrantAccessBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/grant_access',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n list(\n body?: AcsEntrancesListParams,\n ): SeamHttpRequest<AcsEntrancesListResponse, 'acs_entrances'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/list',\n method: 'post',\n body,\n responseKey: 'acs_entrances',\n })\n }\n\n listCredentialsWithAccess(\n body?: AcsEntrancesListCredentialsWithAccessParams,\n ): SeamHttpRequest<\n AcsEntrancesListCredentialsWithAccessResponse,\n 'acs_credentials'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/list_credentials_with_access',\n method: 'post',\n body,\n responseKey: 'acs_credentials',\n })\n }\n}\n\nexport type AcsEntrancesGetParams = RouteRequestBody<'/acs/entrances/get'>\n\nexport type AcsEntrancesGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/get'>>\n>\n\nexport type AcsEntrancesGetOptions = never\n\nexport type AcsEntrancesGrantAccessBody =\n RouteRequestBody<'/acs/entrances/grant_access'>\n\nexport type AcsEntrancesGrantAccessResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/grant_access'>>\n>\n\nexport type AcsEntrancesGrantAccessOptions = never\n\nexport type AcsEntrancesListParams = RouteRequestBody<'/acs/entrances/list'>\n\nexport type AcsEntrancesListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/list'>>\n>\n\nexport type AcsEntrancesListOptions = never\n\nexport type AcsEntrancesListCredentialsWithAccessParams =\n RouteRequestBody<'/acs/entrances/list_credentials_with_access'>\n\nexport type AcsEntrancesListCredentialsWithAccessResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/list_credentials_with_access'>>\n>\n\nexport type AcsEntrancesListCredentialsWithAccessOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsSystems {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsSystems> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsSystems.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n body?: AcsSystemsGetParams,\n ): SeamHttpRequest<AcsSystemsGetResponse, 'acs_system'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/systems/get',\n method: 'post',\n body,\n responseKey: 'acs_system',\n })\n }\n\n list(\n body?: AcsSystemsListParams,\n ): SeamHttpRequest<AcsSystemsListResponse, 'acs_systems'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/systems/list',\n method: 'post',\n body,\n responseKey: 'acs_systems',\n })\n }\n\n listCompatibleCredentialManagerAcsSystems(\n body?: AcsSystemsListCompatibleCredentialManagerAcsSystemsParams,\n ): SeamHttpRequest<\n AcsSystemsListCompatibleCredentialManagerAcsSystemsResponse,\n 'acs_systems'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/systems/list_compatible_credential_manager_acs_systems',\n method: 'post',\n body,\n responseKey: 'acs_systems',\n })\n }\n}\n\nexport type AcsSystemsGetParams = RouteRequestBody<'/acs/systems/get'>\n\nexport type AcsSystemsGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/systems/get'>>\n>\n\nexport type AcsSystemsGetOptions = never\n\nexport type AcsSystemsListParams = RouteRequestBody<'/acs/systems/list'>\n\nexport type AcsSystemsListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/systems/list'>>\n>\n\nexport type AcsSystemsListOptions = never\n\nexport type AcsSystemsListCompatibleCredentialManagerAcsSystemsParams =\n RouteRequestBody<'/acs/systems/list_compatible_credential_manager_acs_systems'>\n\nexport type AcsSystemsListCompatibleCredentialManagerAcsSystemsResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/systems/list_compatible_credential_manager_acs_systems'>\n >\n >\n\nexport type AcsSystemsListCompatibleCredentialManagerAcsSystemsOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcsUsers {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsUsers> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsUsers.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n addToAccessGroup(\n body?: AcsUsersAddToAccessGroupBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/add_to_access_group',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: AcsUsersCreateBody,\n ): SeamHttpRequest<AcsUsersCreateResponse, 'acs_user'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/create',\n method: 'post',\n body,\n responseKey: 'acs_user',\n })\n }\n\n delete(body?: AcsUsersDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: AcsUsersGetParams,\n ): SeamHttpRequest<AcsUsersGetResponse, 'acs_user'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/get',\n method: 'post',\n body,\n responseKey: 'acs_user',\n })\n }\n\n list(\n body?: AcsUsersListParams,\n ): SeamHttpRequest<AcsUsersListResponse, 'acs_users'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/list',\n method: 'post',\n body,\n responseKey: 'acs_users',\n })\n }\n\n listAccessibleEntrances(\n body?: AcsUsersListAccessibleEntrancesParams,\n ): SeamHttpRequest<AcsUsersListAccessibleEntrancesResponse, 'acs_entrances'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/list_accessible_entrances',\n method: 'post',\n body,\n responseKey: 'acs_entrances',\n })\n }\n\n removeFromAccessGroup(\n body?: AcsUsersRemoveFromAccessGroupParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/remove_from_access_group',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n revokeAccessToAllEntrances(\n body?: AcsUsersRevokeAccessToAllEntrancesParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/revoke_access_to_all_entrances',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n suspend(body?: AcsUsersSuspendBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/suspend',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n unsuspend(body?: AcsUsersUnsuspendBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/unsuspend',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: AcsUsersUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsUsersAddToAccessGroupBody =\n RouteRequestBody<'/acs/users/add_to_access_group'>\n\nexport type AcsUsersAddToAccessGroupResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/add_to_access_group'>>\n>\n\nexport type AcsUsersAddToAccessGroupOptions = never\n\nexport type AcsUsersCreateBody = RouteRequestBody<'/acs/users/create'>\n\nexport type AcsUsersCreateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/create'>>\n>\n\nexport type AcsUsersCreateOptions = never\n\nexport type AcsUsersDeleteParams = RouteRequestBody<'/acs/users/delete'>\n\nexport type AcsUsersDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/delete'>>\n>\n\nexport type AcsUsersDeleteOptions = never\n\nexport type AcsUsersGetParams = RouteRequestBody<'/acs/users/get'>\n\nexport type AcsUsersGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/get'>>\n>\n\nexport type AcsUsersGetOptions = never\n\nexport type AcsUsersListParams = RouteRequestBody<'/acs/users/list'>\n\nexport type AcsUsersListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/list'>>\n>\n\nexport type AcsUsersListOptions = never\n\nexport type AcsUsersListAccessibleEntrancesParams =\n RouteRequestBody<'/acs/users/list_accessible_entrances'>\n\nexport type AcsUsersListAccessibleEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/list_accessible_entrances'>>\n>\n\nexport type AcsUsersListAccessibleEntrancesOptions = never\n\nexport type AcsUsersRemoveFromAccessGroupParams =\n RouteRequestBody<'/acs/users/remove_from_access_group'>\n\nexport type AcsUsersRemoveFromAccessGroupResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/remove_from_access_group'>>\n>\n\nexport type AcsUsersRemoveFromAccessGroupOptions = never\n\nexport type AcsUsersRevokeAccessToAllEntrancesParams =\n RouteRequestBody<'/acs/users/revoke_access_to_all_entrances'>\n\nexport type AcsUsersRevokeAccessToAllEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/revoke_access_to_all_entrances'>>\n>\n\nexport type AcsUsersRevokeAccessToAllEntrancesOptions = never\n\nexport type AcsUsersSuspendBody = RouteRequestBody<'/acs/users/suspend'>\n\nexport type AcsUsersSuspendResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/suspend'>>\n>\n\nexport type AcsUsersSuspendOptions = never\n\nexport type AcsUsersUnsuspendBody = RouteRequestBody<'/acs/users/unsuspend'>\n\nexport type AcsUsersUnsuspendResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/unsuspend'>>\n>\n\nexport type AcsUsersUnsuspendOptions = never\n\nexport type AcsUsersUpdateBody = RouteRequestBody<'/acs/users/update'>\n\nexport type AcsUsersUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/update'>>\n>\n\nexport type AcsUsersUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport type { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\n\nimport { SeamHttpAcsAccessGroups } from './acs-access-groups.js'\nimport { SeamHttpAcsCredentials } from './acs-credentials.js'\nimport { SeamHttpAcsEncoders } from './acs-encoders.js'\nimport { SeamHttpAcsEntrances } from './acs-entrances.js'\nimport { SeamHttpAcsSystems } from './acs-systems.js'\nimport { SeamHttpAcsUsers } from './acs-users.js'\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpAcs {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcs> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcs.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get accessGroups(): SeamHttpAcsAccessGroups {\n return SeamHttpAcsAccessGroups.fromClient(this.client, this.defaults)\n }\n\n get credentials(): SeamHttpAcsCredentials {\n return SeamHttpAcsCredentials.fromClient(this.client, this.defaults)\n }\n\n get entrances(): SeamHttpAcsEntrances {\n return SeamHttpAcsEntrances.fromClient(this.client, this.defaults)\n }\n\n get encoders(): SeamHttpAcsEncoders {\n return SeamHttpAcsEncoders.fromClient(this.client, this.defaults)\n }\n\n get systems(): SeamHttpAcsSystems {\n return SeamHttpAcsSystems.fromClient(this.client, this.defaults)\n }\n\n get users(): SeamHttpAcsUsers {\n return SeamHttpAcsUsers.fromClient(this.client, this.defaults)\n }\n}\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpActionAttempts {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpActionAttempts> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpActionAttempts.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n body?: ActionAttemptsGetParams,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ActionAttemptsGetResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/action_attempts/get',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n list(\n body?: ActionAttemptsListParams,\n ): SeamHttpRequest<ActionAttemptsListResponse, 'action_attempts'> {\n return new SeamHttpRequest(this, {\n pathname: '/action_attempts/list',\n method: 'post',\n body,\n responseKey: 'action_attempts',\n })\n }\n}\n\nexport type ActionAttemptsGetParams = RouteRequestBody<'/action_attempts/get'>\n\nexport type ActionAttemptsGetResponse = SetNonNullable<\n Required<RouteResponse<'/action_attempts/get'>>\n>\n\nexport type ActionAttemptsGetOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ActionAttemptsListParams = RouteRequestBody<'/action_attempts/list'>\n\nexport type ActionAttemptsListResponse = SetNonNullable<\n Required<RouteResponse<'/action_attempts/list'>>\n>\n\nexport type ActionAttemptsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpConnectWebviews {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpConnectWebviews> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpConnectWebviews.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ConnectWebviewsCreateBody,\n ): SeamHttpRequest<ConnectWebviewsCreateResponse, 'connect_webview'> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/create',\n method: 'post',\n body,\n responseKey: 'connect_webview',\n })\n }\n\n delete(body?: ConnectWebviewsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: ConnectWebviewsGetParams,\n ): SeamHttpRequest<ConnectWebviewsGetResponse, 'connect_webview'> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/get',\n method: 'post',\n body,\n responseKey: 'connect_webview',\n })\n }\n\n list(\n body?: ConnectWebviewsListParams,\n ): SeamHttpRequest<ConnectWebviewsListResponse, 'connect_webviews'> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/list',\n method: 'post',\n body,\n responseKey: 'connect_webviews',\n })\n }\n}\n\nexport type ConnectWebviewsCreateBody =\n RouteRequestBody<'/connect_webviews/create'>\n\nexport type ConnectWebviewsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/create'>>\n>\n\nexport type ConnectWebviewsCreateOptions = never\n\nexport type ConnectWebviewsDeleteParams =\n RouteRequestBody<'/connect_webviews/delete'>\n\nexport type ConnectWebviewsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/delete'>>\n>\n\nexport type ConnectWebviewsDeleteOptions = never\n\nexport type ConnectWebviewsGetParams = RouteRequestBody<'/connect_webviews/get'>\n\nexport type ConnectWebviewsGetResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/get'>>\n>\n\nexport type ConnectWebviewsGetOptions = never\n\nexport type ConnectWebviewsListParams =\n RouteRequestBody<'/connect_webviews/list'>\n\nexport type ConnectWebviewsListResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/list'>>\n>\n\nexport type ConnectWebviewsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpConnectedAccounts {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpConnectedAccounts> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpConnectedAccounts.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n delete(\n body?: ConnectedAccountsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: ConnectedAccountsGetParams,\n ): SeamHttpRequest<ConnectedAccountsGetResponse, 'connected_account'> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/get',\n method: 'post',\n body,\n responseKey: 'connected_account',\n })\n }\n\n list(\n body?: ConnectedAccountsListParams,\n ): SeamHttpRequest<ConnectedAccountsListResponse, 'connected_accounts'> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/list',\n method: 'post',\n body,\n responseKey: 'connected_accounts',\n })\n }\n\n sync(body?: ConnectedAccountsSyncBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/sync',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: ConnectedAccountsUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ConnectedAccountsDeleteParams =\n RouteRequestBody<'/connected_accounts/delete'>\n\nexport type ConnectedAccountsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/delete'>>\n>\n\nexport type ConnectedAccountsDeleteOptions = never\n\nexport type ConnectedAccountsGetParams =\n RouteRequestBody<'/connected_accounts/get'>\n\nexport type ConnectedAccountsGetResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/get'>>\n>\n\nexport type ConnectedAccountsGetOptions = never\n\nexport type ConnectedAccountsListParams =\n RouteRequestBody<'/connected_accounts/list'>\n\nexport type ConnectedAccountsListResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/list'>>\n>\n\nexport type ConnectedAccountsListOptions = never\n\nexport type ConnectedAccountsSyncBody =\n RouteRequestBody<'/connected_accounts/sync'>\n\nexport type ConnectedAccountsSyncResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/sync'>>\n>\n\nexport type ConnectedAccountsSyncOptions = never\n\nexport type ConnectedAccountsUpdateBody =\n RouteRequestBody<'/connected_accounts/update'>\n\nexport type ConnectedAccountsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/update'>>\n>\n\nexport type ConnectedAccountsUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpDevicesSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpDevicesSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpDevicesSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n connect(body?: DevicesSimulateConnectBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/simulate/connect',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n disconnect(\n body?: DevicesSimulateDisconnectBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/simulate/disconnect',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n remove(body?: DevicesSimulateRemoveBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/simulate/remove',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type DevicesSimulateConnectBody =\n RouteRequestBody<'/devices/simulate/connect'>\n\nexport type DevicesSimulateConnectResponse = SetNonNullable<\n Required<RouteResponse<'/devices/simulate/connect'>>\n>\n\nexport type DevicesSimulateConnectOptions = never\n\nexport type DevicesSimulateDisconnectBody =\n RouteRequestBody<'/devices/simulate/disconnect'>\n\nexport type DevicesSimulateDisconnectResponse = SetNonNullable<\n Required<RouteResponse<'/devices/simulate/disconnect'>>\n>\n\nexport type DevicesSimulateDisconnectOptions = never\n\nexport type DevicesSimulateRemoveBody =\n RouteRequestBody<'/devices/simulate/remove'>\n\nexport type DevicesSimulateRemoveResponse = SetNonNullable<\n Required<RouteResponse<'/devices/simulate/remove'>>\n>\n\nexport type DevicesSimulateRemoveOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpDevicesUnmanaged {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpDevicesUnmanaged> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpDevicesUnmanaged.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n body?: DevicesUnmanagedGetParams,\n ): SeamHttpRequest<DevicesUnmanagedGetResponse, 'device'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/unmanaged/get',\n method: 'post',\n body,\n responseKey: 'device',\n })\n }\n\n list(\n body?: DevicesUnmanagedListParams,\n ): SeamHttpRequest<DevicesUnmanagedListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/unmanaged/list',\n method: 'post',\n body,\n responseKey: 'devices',\n })\n }\n\n update(body?: DevicesUnmanagedUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/unmanaged/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type DevicesUnmanagedGetParams =\n RouteRequestBody<'/devices/unmanaged/get'>\n\nexport type DevicesUnmanagedGetResponse = SetNonNullable<\n Required<RouteResponse<'/devices/unmanaged/get'>>\n>\n\nexport type DevicesUnmanagedGetOptions = never\n\nexport type DevicesUnmanagedListParams =\n RouteRequestBody<'/devices/unmanaged/list'>\n\nexport type DevicesUnmanagedListResponse = SetNonNullable<\n Required<RouteResponse<'/devices/unmanaged/list'>>\n>\n\nexport type DevicesUnmanagedListOptions = never\n\nexport type DevicesUnmanagedUpdateBody =\n RouteRequestBody<'/devices/unmanaged/update'>\n\nexport type DevicesUnmanagedUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/devices/unmanaged/update'>>\n>\n\nexport type DevicesUnmanagedUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\nimport { SeamHttpDevicesSimulate } from './devices-simulate.js'\nimport { SeamHttpDevicesUnmanaged } from './devices-unmanaged.js'\n\nexport class SeamHttpDevices {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpDevices> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpDevices.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get unmanaged(): SeamHttpDevicesUnmanaged {\n return SeamHttpDevicesUnmanaged.fromClient(this.client, this.defaults)\n }\n\n get simulate(): SeamHttpDevicesSimulate {\n return SeamHttpDevicesSimulate.fromClient(this.client, this.defaults)\n }\n\n get(body?: DevicesGetParams): SeamHttpRequest<DevicesGetResponse, 'device'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/get',\n method: 'post',\n body,\n responseKey: 'device',\n })\n }\n\n list(\n body?: DevicesListParams,\n ): SeamHttpRequest<DevicesListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/list',\n method: 'post',\n body,\n responseKey: 'devices',\n })\n }\n\n listDeviceProviders(\n body?: DevicesListDeviceProvidersParams,\n ): SeamHttpRequest<DevicesListDeviceProvidersResponse, 'device_providers'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/list_device_providers',\n method: 'post',\n body,\n responseKey: 'device_providers',\n })\n }\n\n update(body?: DevicesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type DevicesGetParams = RouteRequestBody<'/devices/get'>\n\nexport type DevicesGetResponse = SetNonNullable<\n Required<RouteResponse<'/devices/get'>>\n>\n\nexport type DevicesGetOptions = never\n\nexport type DevicesListParams = RouteRequestBody<'/devices/list'>\n\nexport type DevicesListResponse = SetNonNullable<\n Required<RouteResponse<'/devices/list'>>\n>\n\nexport type DevicesListOptions = never\n\nexport type DevicesListDeviceProvidersParams =\n RouteRequestBody<'/devices/list_device_providers'>\n\nexport type DevicesListDeviceProvidersResponse = SetNonNullable<\n Required<RouteResponse<'/devices/list_device_providers'>>\n>\n\nexport type DevicesListDeviceProvidersOptions = never\n\nexport type DevicesUpdateBody = RouteRequestBody<'/devices/update'>\n\nexport type DevicesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/devices/update'>>\n>\n\nexport type DevicesUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpEvents {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpEvents> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpEvents.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(body?: EventsGetParams): SeamHttpRequest<EventsGetResponse, 'event'> {\n return new SeamHttpRequest(this, {\n pathname: '/events/get',\n method: 'post',\n body,\n responseKey: 'event',\n })\n }\n\n list(body?: EventsListParams): SeamHttpRequest<EventsListResponse, 'events'> {\n return new SeamHttpRequest(this, {\n pathname: '/events/list',\n method: 'post',\n body,\n responseKey: 'events',\n })\n }\n}\n\nexport type EventsGetParams = RouteRequestBody<'/events/get'>\n\nexport type EventsGetResponse = SetNonNullable<\n Required<RouteResponse<'/events/get'>>\n>\n\nexport type EventsGetOptions = never\n\nexport type EventsListParams = RouteRequestBody<'/events/list'>\n\nexport type EventsListResponse = SetNonNullable<\n Required<RouteResponse<'/events/list'>>\n>\n\nexport type EventsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpLocks {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpLocks> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpLocks.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(body?: LocksGetParams): SeamHttpRequest<LocksGetResponse, 'device'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/get',\n method: 'post',\n body,\n responseKey: 'device',\n })\n }\n\n list(body?: LocksListParams): SeamHttpRequest<LocksListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/list',\n method: 'post',\n body,\n responseKey: 'devices',\n })\n }\n\n lockDoor(\n body?: LocksLockDoorBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<LocksLockDoorResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/lock_door',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n unlockDoor(\n body?: LocksUnlockDoorBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<LocksUnlockDoorResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/unlock_door',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type LocksGetParams = RouteRequestBody<'/locks/get'>\n\nexport type LocksGetResponse = SetNonNullable<\n Required<RouteResponse<'/locks/get'>>\n>\n\nexport type LocksGetOptions = never\n\nexport type LocksListParams = RouteRequestBody<'/locks/list'>\n\nexport type LocksListResponse = SetNonNullable<\n Required<RouteResponse<'/locks/list'>>\n>\n\nexport type LocksListOptions = never\n\nexport type LocksLockDoorBody = RouteRequestBody<'/locks/lock_door'>\n\nexport type LocksLockDoorResponse = SetNonNullable<\n Required<RouteResponse<'/locks/lock_door'>>\n>\n\nexport type LocksLockDoorOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type LocksUnlockDoorBody = RouteRequestBody<'/locks/unlock_door'>\n\nexport type LocksUnlockDoorResponse = SetNonNullable<\n Required<RouteResponse<'/locks/unlock_door'>>\n>\n\nexport type LocksUnlockDoorOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpNoiseSensorsNoiseThresholds {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpNoiseSensorsNoiseThresholds> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpNoiseSensorsNoiseThresholds.fromClientSessionToken(\n token,\n options,\n )\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: NoiseSensorsNoiseThresholdsCreateBody,\n ): SeamHttpRequest<\n NoiseSensorsNoiseThresholdsCreateResponse,\n 'noise_threshold'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/create',\n method: 'post',\n body,\n responseKey: 'noise_threshold',\n })\n }\n\n delete(\n body?: NoiseSensorsNoiseThresholdsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: NoiseSensorsNoiseThresholdsGetParams,\n ): SeamHttpRequest<\n NoiseSensorsNoiseThresholdsGetResponse,\n 'noise_threshold'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/get',\n method: 'post',\n body,\n responseKey: 'noise_threshold',\n })\n }\n\n list(\n body?: NoiseSensorsNoiseThresholdsListParams,\n ): SeamHttpRequest<\n NoiseSensorsNoiseThresholdsListResponse,\n 'noise_thresholds'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/list',\n method: 'post',\n body,\n responseKey: 'noise_thresholds',\n })\n }\n\n update(\n body?: NoiseSensorsNoiseThresholdsUpdateBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type NoiseSensorsNoiseThresholdsCreateBody =\n RouteRequestBody<'/noise_sensors/noise_thresholds/create'>\n\nexport type NoiseSensorsNoiseThresholdsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/create'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsCreateOptions = never\n\nexport type NoiseSensorsNoiseThresholdsDeleteParams =\n RouteRequestBody<'/noise_sensors/noise_thresholds/delete'>\n\nexport type NoiseSensorsNoiseThresholdsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/delete'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsDeleteOptions = never\n\nexport type NoiseSensorsNoiseThresholdsGetParams =\n RouteRequestBody<'/noise_sensors/noise_thresholds/get'>\n\nexport type NoiseSensorsNoiseThresholdsGetResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/get'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsGetOptions = never\n\nexport type NoiseSensorsNoiseThresholdsListParams =\n RouteRequestBody<'/noise_sensors/noise_thresholds/list'>\n\nexport type NoiseSensorsNoiseThresholdsListResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/list'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsListOptions = never\n\nexport type NoiseSensorsNoiseThresholdsUpdateBody =\n RouteRequestBody<'/noise_sensors/noise_thresholds/update'>\n\nexport type NoiseSensorsNoiseThresholdsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/update'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpNoiseSensorsSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpNoiseSensorsSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpNoiseSensorsSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n triggerNoiseThreshold(\n body?: NoiseSensorsSimulateTriggerNoiseThresholdBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/simulate/trigger_noise_threshold',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type NoiseSensorsSimulateTriggerNoiseThresholdBody =\n RouteRequestBody<'/noise_sensors/simulate/trigger_noise_threshold'>\n\nexport type NoiseSensorsSimulateTriggerNoiseThresholdResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/simulate/trigger_noise_threshold'>>\n>\n\nexport type NoiseSensorsSimulateTriggerNoiseThresholdOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\nimport { SeamHttpNoiseSensorsNoiseThresholds } from './noise-sensors-noise-thresholds.js'\nimport { SeamHttpNoiseSensorsSimulate } from './noise-sensors-simulate.js'\n\nexport class SeamHttpNoiseSensors {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpNoiseSensors> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpNoiseSensors.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get noiseThresholds(): SeamHttpNoiseSensorsNoiseThresholds {\n return SeamHttpNoiseSensorsNoiseThresholds.fromClient(\n this.client,\n this.defaults,\n )\n }\n\n get simulate(): SeamHttpNoiseSensorsSimulate {\n return SeamHttpNoiseSensorsSimulate.fromClient(this.client, this.defaults)\n }\n\n list(\n body?: NoiseSensorsListParams,\n ): SeamHttpRequest<NoiseSensorsListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/list',\n method: 'post',\n body,\n responseKey: 'devices',\n })\n }\n}\n\nexport type NoiseSensorsListParams = RouteRequestBody<'/noise_sensors/list'>\n\nexport type NoiseSensorsListResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/list'>>\n>\n\nexport type NoiseSensorsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpPhonesSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpPhonesSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpPhonesSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n createSandboxPhone(\n body?: PhonesSimulateCreateSandboxPhoneBody,\n ): SeamHttpRequest<PhonesSimulateCreateSandboxPhoneResponse, 'phone'> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/simulate/create_sandbox_phone',\n method: 'post',\n body,\n responseKey: 'phone',\n })\n }\n}\n\nexport type PhonesSimulateCreateSandboxPhoneBody =\n RouteRequestBody<'/phones/simulate/create_sandbox_phone'>\n\nexport type PhonesSimulateCreateSandboxPhoneResponse = SetNonNullable<\n Required<RouteResponse<'/phones/simulate/create_sandbox_phone'>>\n>\n\nexport type PhonesSimulateCreateSandboxPhoneOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\nimport { SeamHttpPhonesSimulate } from './phones-simulate.js'\n\nexport class SeamHttpPhones {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpPhones> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpPhones.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get simulate(): SeamHttpPhonesSimulate {\n return SeamHttpPhonesSimulate.fromClient(this.client, this.defaults)\n }\n\n deactivate(body?: PhonesDeactivateParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/deactivate',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(body?: PhonesGetParams): SeamHttpRequest<PhonesGetResponse, 'phone'> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/get',\n method: 'post',\n body,\n responseKey: 'phone',\n })\n }\n\n list(body?: PhonesListParams): SeamHttpRequest<PhonesListResponse, 'phones'> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/list',\n method: 'post',\n body,\n responseKey: 'phones',\n })\n }\n}\n\nexport type PhonesDeactivateParams = RouteRequestBody<'/phones/deactivate'>\n\nexport type PhonesDeactivateResponse = SetNonNullable<\n Required<RouteResponse<'/phones/deactivate'>>\n>\n\nexport type PhonesDeactivateOptions = never\n\nexport type PhonesGetParams = RouteRequestBody<'/phones/get'>\n\nexport type PhonesGetResponse = SetNonNullable<\n Required<RouteResponse<'/phones/get'>>\n>\n\nexport type PhonesGetOptions = never\n\nexport type PhonesListParams = RouteRequestBody<'/phones/list'>\n\nexport type PhonesListResponse = SetNonNullable<\n Required<RouteResponse<'/phones/list'>>\n>\n\nexport type PhonesListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpSpaces {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpSpaces> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpSpaces.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n addAcsEntrances(\n body?: SpacesAddAcsEntrancesBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/add_acs_entrances',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n addDevices(body?: SpacesAddDevicesBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/add_devices',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: SpacesCreateBody,\n ): SeamHttpRequest<SpacesCreateResponse, 'space'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/create',\n method: 'post',\n body,\n responseKey: 'space',\n })\n }\n\n delete(body?: SpacesDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(body?: SpacesGetParams): SeamHttpRequest<SpacesGetResponse, 'space'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/get',\n method: 'post',\n body,\n responseKey: 'space',\n })\n }\n\n list(body?: SpacesListParams): SeamHttpRequest<SpacesListResponse, 'spaces'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/list',\n method: 'post',\n body,\n responseKey: 'spaces',\n })\n }\n\n removeAcsEntrances(\n body?: SpacesRemoveAcsEntrancesParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/remove_acs_entrances',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n removeDevices(\n body?: SpacesRemoveDevicesParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/remove_devices',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(\n body?: SpacesUpdateBody,\n ): SeamHttpRequest<SpacesUpdateResponse, 'space'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/update',\n method: 'post',\n body,\n responseKey: 'space',\n })\n }\n}\n\nexport type SpacesAddAcsEntrancesBody =\n RouteRequestBody<'/spaces/add_acs_entrances'>\n\nexport type SpacesAddAcsEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/add_acs_entrances'>>\n>\n\nexport type SpacesAddAcsEntrancesOptions = never\n\nexport type SpacesAddDevicesBody = RouteRequestBody<'/spaces/add_devices'>\n\nexport type SpacesAddDevicesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/add_devices'>>\n>\n\nexport type SpacesAddDevicesOptions = never\n\nexport type SpacesCreateBody = RouteRequestBody<'/spaces/create'>\n\nexport type SpacesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/create'>>\n>\n\nexport type SpacesCreateOptions = never\n\nexport type SpacesDeleteParams = RouteRequestBody<'/spaces/delete'>\n\nexport type SpacesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/delete'>>\n>\n\nexport type SpacesDeleteOptions = never\n\nexport type SpacesGetParams = RouteRequestBody<'/spaces/get'>\n\nexport type SpacesGetResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/get'>>\n>\n\nexport type SpacesGetOptions = never\n\nexport type SpacesListParams = RouteRequestBody<'/spaces/list'>\n\nexport type SpacesListResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/list'>>\n>\n\nexport type SpacesListOptions = never\n\nexport type SpacesRemoveAcsEntrancesParams =\n RouteRequestBody<'/spaces/remove_acs_entrances'>\n\nexport type SpacesRemoveAcsEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/remove_acs_entrances'>>\n>\n\nexport type SpacesRemoveAcsEntrancesOptions = never\n\nexport type SpacesRemoveDevicesParams =\n RouteRequestBody<'/spaces/remove_devices'>\n\nexport type SpacesRemoveDevicesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/remove_devices'>>\n>\n\nexport type SpacesRemoveDevicesOptions = never\n\nexport type SpacesUpdateBody = RouteRequestBody<'/spaces/update'>\n\nexport type SpacesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/update'>>\n>\n\nexport type SpacesUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpThermostatsDailyPrograms {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostatsDailyPrograms> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostatsDailyPrograms.fromClientSessionToken(\n token,\n options,\n )\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ThermostatsDailyProgramsCreateBody,\n ): SeamHttpRequest<\n ThermostatsDailyProgramsCreateResponse,\n 'thermostat_daily_program'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/daily_programs/create',\n method: 'post',\n body,\n responseKey: 'thermostat_daily_program',\n })\n }\n\n delete(\n body?: ThermostatsDailyProgramsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/daily_programs/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(\n body?: ThermostatsDailyProgramsUpdateBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsDailyProgramsUpdateResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/daily_programs/update',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type ThermostatsDailyProgramsCreateBody =\n RouteRequestBody<'/thermostats/daily_programs/create'>\n\nexport type ThermostatsDailyProgramsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/daily_programs/create'>>\n>\n\nexport type ThermostatsDailyProgramsCreateOptions = never\n\nexport type ThermostatsDailyProgramsDeleteParams =\n RouteRequestBody<'/thermostats/daily_programs/delete'>\n\nexport type ThermostatsDailyProgramsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/daily_programs/delete'>>\n>\n\nexport type ThermostatsDailyProgramsDeleteOptions = never\n\nexport type ThermostatsDailyProgramsUpdateBody =\n RouteRequestBody<'/thermostats/daily_programs/update'>\n\nexport type ThermostatsDailyProgramsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/daily_programs/update'>>\n>\n\nexport type ThermostatsDailyProgramsUpdateOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpThermostatsSchedules {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostatsSchedules> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostatsSchedules.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ThermostatsSchedulesCreateBody,\n ): SeamHttpRequest<\n ThermostatsSchedulesCreateResponse,\n 'thermostat_schedule'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/create',\n method: 'post',\n body,\n responseKey: 'thermostat_schedule',\n })\n }\n\n delete(\n body?: ThermostatsSchedulesDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: ThermostatsSchedulesGetParams,\n ): SeamHttpRequest<ThermostatsSchedulesGetResponse, 'thermostat_schedule'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/get',\n method: 'post',\n body,\n responseKey: 'thermostat_schedule',\n })\n }\n\n list(\n body?: ThermostatsSchedulesListParams,\n ): SeamHttpRequest<ThermostatsSchedulesListResponse, 'thermostat_schedules'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/list',\n method: 'post',\n body,\n responseKey: 'thermostat_schedules',\n })\n }\n\n update(\n body?: ThermostatsSchedulesUpdateBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ThermostatsSchedulesCreateBody =\n RouteRequestBody<'/thermostats/schedules/create'>\n\nexport type ThermostatsSchedulesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/create'>>\n>\n\nexport type ThermostatsSchedulesCreateOptions = never\n\nexport type ThermostatsSchedulesDeleteParams =\n RouteRequestBody<'/thermostats/schedules/delete'>\n\nexport type ThermostatsSchedulesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/delete'>>\n>\n\nexport type ThermostatsSchedulesDeleteOptions = never\n\nexport type ThermostatsSchedulesGetParams =\n RouteRequestBody<'/thermostats/schedules/get'>\n\nexport type ThermostatsSchedulesGetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/get'>>\n>\n\nexport type ThermostatsSchedulesGetOptions = never\n\nexport type ThermostatsSchedulesListParams =\n RouteRequestBody<'/thermostats/schedules/list'>\n\nexport type ThermostatsSchedulesListResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/list'>>\n>\n\nexport type ThermostatsSchedulesListOptions = never\n\nexport type ThermostatsSchedulesUpdateBody =\n RouteRequestBody<'/thermostats/schedules/update'>\n\nexport type ThermostatsSchedulesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/update'>>\n>\n\nexport type ThermostatsSchedulesUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpThermostatsSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostatsSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostatsSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n hvacModeAdjusted(\n body?: ThermostatsSimulateHvacModeAdjustedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/simulate/hvac_mode_adjusted',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n temperatureReached(\n body?: ThermostatsSimulateTemperatureReachedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/simulate/temperature_reached',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ThermostatsSimulateHvacModeAdjustedBody =\n RouteRequestBody<'/thermostats/simulate/hvac_mode_adjusted'>\n\nexport type ThermostatsSimulateHvacModeAdjustedResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/simulate/hvac_mode_adjusted'>>\n>\n\nexport type ThermostatsSimulateHvacModeAdjustedOptions = never\n\nexport type ThermostatsSimulateTemperatureReachedBody =\n RouteRequestBody<'/thermostats/simulate/temperature_reached'>\n\nexport type ThermostatsSimulateTemperatureReachedResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/simulate/temperature_reached'>>\n>\n\nexport type ThermostatsSimulateTemperatureReachedOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\nimport { SeamHttpThermostatsDailyPrograms } from './thermostats-daily-programs.js'\nimport { SeamHttpThermostatsSchedules } from './thermostats-schedules.js'\nimport { SeamHttpThermostatsSimulate } from './thermostats-simulate.js'\n\nexport class SeamHttpThermostats {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostats> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostats.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get schedules(): SeamHttpThermostatsSchedules {\n return SeamHttpThermostatsSchedules.fromClient(this.client, this.defaults)\n }\n\n get simulate(): SeamHttpThermostatsSimulate {\n return SeamHttpThermostatsSimulate.fromClient(this.client, this.defaults)\n }\n\n get dailyPrograms(): SeamHttpThermostatsDailyPrograms {\n return SeamHttpThermostatsDailyPrograms.fromClient(\n this.client,\n this.defaults,\n )\n }\n\n activateClimatePreset(\n body?: ThermostatsActivateClimatePresetBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<\n ThermostatsActivateClimatePresetResponse,\n 'action_attempt'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/activate_climate_preset',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n cool(\n body?: ThermostatsCoolBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsCoolResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/cool',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n createClimatePreset(\n body?: ThermostatsCreateClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/create_climate_preset',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n deleteClimatePreset(\n body?: ThermostatsDeleteClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/delete_climate_preset',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n heat(\n body?: ThermostatsHeatBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsHeatResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/heat',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n heatCool(\n body?: ThermostatsHeatCoolBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsHeatCoolResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/heat_cool',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n list(\n body?: ThermostatsListParams,\n ): SeamHttpRequest<ThermostatsListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/list',\n method: 'post',\n body,\n responseKey: 'devices',\n })\n }\n\n off(\n body?: ThermostatsOffBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsOffResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/off',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n setFallbackClimatePreset(\n body?: ThermostatsSetFallbackClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_fallback_climate_preset',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n setFanMode(\n body?: ThermostatsSetFanModeBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsSetFanModeResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_fan_mode',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n setHvacMode(\n body?: ThermostatsSetHvacModeBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsSetHvacModeResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_hvac_mode',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n setTemperatureThreshold(\n body?: ThermostatsSetTemperatureThresholdBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_temperature_threshold',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n updateClimatePreset(\n body?: ThermostatsUpdateClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/update_climate_preset',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n updateWeeklyProgram(\n body?: ThermostatsUpdateWeeklyProgramBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<ThermostatsUpdateWeeklyProgramResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/update_weekly_program',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type ThermostatsActivateClimatePresetBody =\n RouteRequestBody<'/thermostats/activate_climate_preset'>\n\nexport type ThermostatsActivateClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/activate_climate_preset'>>\n>\n\nexport type ThermostatsActivateClimatePresetOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsCoolBody = RouteRequestBody<'/thermostats/cool'>\n\nexport type ThermostatsCoolResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/cool'>>\n>\n\nexport type ThermostatsCoolOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsCreateClimatePresetBody =\n RouteRequestBody<'/thermostats/create_climate_preset'>\n\nexport type ThermostatsCreateClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/create_climate_preset'>>\n>\n\nexport type ThermostatsCreateClimatePresetOptions = never\n\nexport type ThermostatsDeleteClimatePresetBody =\n RouteRequestBody<'/thermostats/delete_climate_preset'>\n\nexport type ThermostatsDeleteClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/delete_climate_preset'>>\n>\n\nexport type ThermostatsDeleteClimatePresetOptions = never\n\nexport type ThermostatsHeatBody = RouteRequestBody<'/thermostats/heat'>\n\nexport type ThermostatsHeatResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/heat'>>\n>\n\nexport type ThermostatsHeatOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsHeatCoolBody = RouteRequestBody<'/thermostats/heat_cool'>\n\nexport type ThermostatsHeatCoolResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/heat_cool'>>\n>\n\nexport type ThermostatsHeatCoolOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsListParams = RouteRequestBody<'/thermostats/list'>\n\nexport type ThermostatsListResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/list'>>\n>\n\nexport type ThermostatsListOptions = never\n\nexport type ThermostatsOffBody = RouteRequestBody<'/thermostats/off'>\n\nexport type ThermostatsOffResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/off'>>\n>\n\nexport type ThermostatsOffOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsSetFallbackClimatePresetBody =\n RouteRequestBody<'/thermostats/set_fallback_climate_preset'>\n\nexport type ThermostatsSetFallbackClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_fallback_climate_preset'>>\n>\n\nexport type ThermostatsSetFallbackClimatePresetOptions = never\n\nexport type ThermostatsSetFanModeBody =\n RouteRequestBody<'/thermostats/set_fan_mode'>\n\nexport type ThermostatsSetFanModeResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_fan_mode'>>\n>\n\nexport type ThermostatsSetFanModeOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsSetHvacModeBody =\n RouteRequestBody<'/thermostats/set_hvac_mode'>\n\nexport type ThermostatsSetHvacModeResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_hvac_mode'>>\n>\n\nexport type ThermostatsSetHvacModeOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsSetTemperatureThresholdBody =\n RouteRequestBody<'/thermostats/set_temperature_threshold'>\n\nexport type ThermostatsSetTemperatureThresholdResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_temperature_threshold'>>\n>\n\nexport type ThermostatsSetTemperatureThresholdOptions = never\n\nexport type ThermostatsUpdateClimatePresetBody =\n RouteRequestBody<'/thermostats/update_climate_preset'>\n\nexport type ThermostatsUpdateClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/update_climate_preset'>>\n>\n\nexport type ThermostatsUpdateClimatePresetOptions = never\n\nexport type ThermostatsUpdateWeeklyProgramBody =\n RouteRequestBody<'/thermostats/update_weekly_program'>\n\nexport type ThermostatsUpdateWeeklyProgramResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/update_weekly_program'>>\n>\n\nexport type ThermostatsUpdateWeeklyProgramOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport type { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpUnstablePartner {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpUnstablePartner {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpUnstablePartner(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpUnstablePartner {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpUnstablePartner(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpUnstablePartner {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpUnstablePartner(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpUnstablePartner> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpUnstablePartner.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpUnstablePartner {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpUnstablePartner(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpUnstablePartner {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpUnstablePartner(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n}\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpUserIdentitiesEnrollmentAutomations {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpUserIdentitiesEnrollmentAutomations> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpUserIdentitiesEnrollmentAutomations.fromClientSessionToken(\n token,\n options,\n )\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n delete(\n body?: UserIdentitiesEnrollmentAutomationsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: UserIdentitiesEnrollmentAutomationsGetParams,\n ): SeamHttpRequest<\n UserIdentitiesEnrollmentAutomationsGetResponse,\n 'enrollment_automation'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/get',\n method: 'post',\n body,\n responseKey: 'enrollment_automation',\n })\n }\n\n launch(\n body?: UserIdentitiesEnrollmentAutomationsLaunchBody,\n ): SeamHttpRequest<\n UserIdentitiesEnrollmentAutomationsLaunchResponse,\n 'enrollment_automation'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/launch',\n method: 'post',\n body,\n responseKey: 'enrollment_automation',\n })\n }\n\n list(\n body?: UserIdentitiesEnrollmentAutomationsListParams,\n ): SeamHttpRequest<\n UserIdentitiesEnrollmentAutomationsListResponse,\n 'enrollment_automations'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/list',\n method: 'post',\n body,\n responseKey: 'enrollment_automations',\n })\n }\n}\n\nexport type UserIdentitiesEnrollmentAutomationsDeleteParams =\n RouteRequestBody<'/user_identities/enrollment_automations/delete'>\n\nexport type UserIdentitiesEnrollmentAutomationsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/delete'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsDeleteOptions = never\n\nexport type UserIdentitiesEnrollmentAutomationsGetParams =\n RouteRequestBody<'/user_identities/enrollment_automations/get'>\n\nexport type UserIdentitiesEnrollmentAutomationsGetResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/get'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsGetOptions = never\n\nexport type UserIdentitiesEnrollmentAutomationsLaunchBody =\n RouteRequestBody<'/user_identities/enrollment_automations/launch'>\n\nexport type UserIdentitiesEnrollmentAutomationsLaunchResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/launch'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsLaunchOptions = never\n\nexport type UserIdentitiesEnrollmentAutomationsListParams =\n RouteRequestBody<'/user_identities/enrollment_automations/list'>\n\nexport type UserIdentitiesEnrollmentAutomationsListResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/list'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsListOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\nimport { SeamHttpUserIdentitiesEnrollmentAutomations } from './user-identities-enrollment-automations.js'\n\nexport class SeamHttpUserIdentities {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpUserIdentities> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpUserIdentities.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get enrollmentAutomations(): SeamHttpUserIdentitiesEnrollmentAutomations {\n return SeamHttpUserIdentitiesEnrollmentAutomations.fromClient(\n this.client,\n this.defaults,\n )\n }\n\n addAcsUser(\n body?: UserIdentitiesAddAcsUserBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/add_acs_user',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: UserIdentitiesCreateBody,\n ): SeamHttpRequest<UserIdentitiesCreateResponse, 'user_identity'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/create',\n method: 'post',\n body,\n responseKey: 'user_identity',\n })\n }\n\n delete(body?: UserIdentitiesDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n generateInstantKey(\n body?: UserIdentitiesGenerateInstantKeyBody,\n ): SeamHttpRequest<UserIdentitiesGenerateInstantKeyResponse, 'instant_key'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/generate_instant_key',\n method: 'post',\n body,\n responseKey: 'instant_key',\n })\n }\n\n get(\n body?: UserIdentitiesGetParams,\n ): SeamHttpRequest<UserIdentitiesGetResponse, 'user_identity'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/get',\n method: 'post',\n body,\n responseKey: 'user_identity',\n })\n }\n\n grantAccessToDevice(\n body?: UserIdentitiesGrantAccessToDeviceBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/grant_access_to_device',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n list(\n body?: UserIdentitiesListParams,\n ): SeamHttpRequest<UserIdentitiesListResponse, 'user_identities'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list',\n method: 'post',\n body,\n responseKey: 'user_identities',\n })\n }\n\n listAccessibleDevices(\n body?: UserIdentitiesListAccessibleDevicesParams,\n ): SeamHttpRequest<UserIdentitiesListAccessibleDevicesResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list_accessible_devices',\n method: 'post',\n body,\n responseKey: 'devices',\n })\n }\n\n listAcsSystems(\n body?: UserIdentitiesListAcsSystemsParams,\n ): SeamHttpRequest<UserIdentitiesListAcsSystemsResponse, 'acs_systems'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list_acs_systems',\n method: 'post',\n body,\n responseKey: 'acs_systems',\n })\n }\n\n listAcsUsers(\n body?: UserIdentitiesListAcsUsersParams,\n ): SeamHttpRequest<UserIdentitiesListAcsUsersResponse, 'acs_users'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list_acs_users',\n method: 'post',\n body,\n responseKey: 'acs_users',\n })\n }\n\n removeAcsUser(\n body?: UserIdentitiesRemoveAcsUserParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/remove_acs_user',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n revokeAccessToDevice(\n body?: UserIdentitiesRevokeAccessToDeviceParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/revoke_access_to_device',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: UserIdentitiesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type UserIdentitiesAddAcsUserBody =\n RouteRequestBody<'/user_identities/add_acs_user'>\n\nexport type UserIdentitiesAddAcsUserResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/add_acs_user'>>\n>\n\nexport type UserIdentitiesAddAcsUserOptions = never\n\nexport type UserIdentitiesCreateBody =\n RouteRequestBody<'/user_identities/create'>\n\nexport type UserIdentitiesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/create'>>\n>\n\nexport type UserIdentitiesCreateOptions = never\n\nexport type UserIdentitiesDeleteParams =\n RouteRequestBody<'/user_identities/delete'>\n\nexport type UserIdentitiesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/delete'>>\n>\n\nexport type UserIdentitiesDeleteOptions = never\n\nexport type UserIdentitiesGenerateInstantKeyBody =\n RouteRequestBody<'/user_identities/generate_instant_key'>\n\nexport type UserIdentitiesGenerateInstantKeyResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/generate_instant_key'>>\n>\n\nexport type UserIdentitiesGenerateInstantKeyOptions = never\n\nexport type UserIdentitiesGetParams = RouteRequestBody<'/user_identities/get'>\n\nexport type UserIdentitiesGetResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/get'>>\n>\n\nexport type UserIdentitiesGetOptions = never\n\nexport type UserIdentitiesGrantAccessToDeviceBody =\n RouteRequestBody<'/user_identities/grant_access_to_device'>\n\nexport type UserIdentitiesGrantAccessToDeviceResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/grant_access_to_device'>>\n>\n\nexport type UserIdentitiesGrantAccessToDeviceOptions = never\n\nexport type UserIdentitiesListParams = RouteRequestBody<'/user_identities/list'>\n\nexport type UserIdentitiesListResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list'>>\n>\n\nexport type UserIdentitiesListOptions = never\n\nexport type UserIdentitiesListAccessibleDevicesParams =\n RouteRequestBody<'/user_identities/list_accessible_devices'>\n\nexport type UserIdentitiesListAccessibleDevicesResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list_accessible_devices'>>\n>\n\nexport type UserIdentitiesListAccessibleDevicesOptions = never\n\nexport type UserIdentitiesListAcsSystemsParams =\n RouteRequestBody<'/user_identities/list_acs_systems'>\n\nexport type UserIdentitiesListAcsSystemsResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list_acs_systems'>>\n>\n\nexport type UserIdentitiesListAcsSystemsOptions = never\n\nexport type UserIdentitiesListAcsUsersParams =\n RouteRequestBody<'/user_identities/list_acs_users'>\n\nexport type UserIdentitiesListAcsUsersResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list_acs_users'>>\n>\n\nexport type UserIdentitiesListAcsUsersOptions = never\n\nexport type UserIdentitiesRemoveAcsUserParams =\n RouteRequestBody<'/user_identities/remove_acs_user'>\n\nexport type UserIdentitiesRemoveAcsUserResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/remove_acs_user'>>\n>\n\nexport type UserIdentitiesRemoveAcsUserOptions = never\n\nexport type UserIdentitiesRevokeAccessToDeviceParams =\n RouteRequestBody<'/user_identities/revoke_access_to_device'>\n\nexport type UserIdentitiesRevokeAccessToDeviceResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/revoke_access_to_device'>>\n>\n\nexport type UserIdentitiesRevokeAccessToDeviceOptions = never\n\nexport type UserIdentitiesUpdateBody =\n RouteRequestBody<'/user_identities/update'>\n\nexport type UserIdentitiesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/update'>>\n>\n\nexport type UserIdentitiesUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpWebhooks {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpWebhooks> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpWebhooks.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: WebhooksCreateBody,\n ): SeamHttpRequest<WebhooksCreateResponse, 'webhook'> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/create',\n method: 'post',\n body,\n responseKey: 'webhook',\n })\n }\n\n delete(body?: WebhooksDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/delete',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n body?: WebhooksGetParams,\n ): SeamHttpRequest<WebhooksGetResponse, 'webhook'> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/get',\n method: 'post',\n body,\n responseKey: 'webhook',\n })\n }\n\n list(\n body?: WebhooksListParams,\n ): SeamHttpRequest<WebhooksListResponse, 'webhooks'> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/list',\n method: 'post',\n body,\n responseKey: 'webhooks',\n })\n }\n\n update(body?: WebhooksUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type WebhooksCreateBody = RouteRequestBody<'/webhooks/create'>\n\nexport type WebhooksCreateResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/create'>>\n>\n\nexport type WebhooksCreateOptions = never\n\nexport type WebhooksDeleteParams = RouteRequestBody<'/webhooks/delete'>\n\nexport type WebhooksDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/delete'>>\n>\n\nexport type WebhooksDeleteOptions = never\n\nexport type WebhooksGetParams = RouteRequestBody<'/webhooks/get'>\n\nexport type WebhooksGetResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/get'>>\n>\n\nexport type WebhooksGetOptions = never\n\nexport type WebhooksListParams = RouteRequestBody<'/webhooks/list'>\n\nexport type WebhooksListResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/list'>>\n>\n\nexport type WebhooksListOptions = never\n\nexport type WebhooksUpdateBody = RouteRequestBody<'/webhooks/update'>\n\nexport type WebhooksUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/update'>>\n>\n\nexport type WebhooksUpdateOptions = never\n","/*\n * Automatically generated by generate-routes.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpClientSessions } from './client-sessions.js'\n\nexport class SeamHttpWorkspaces {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpWorkspaces> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpWorkspaces.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: WorkspacesCreateBody,\n ): SeamHttpRequest<WorkspacesCreateResponse, 'workspace'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/create',\n method: 'post',\n body,\n responseKey: 'workspace',\n })\n }\n\n get(\n body?: WorkspacesGetParams,\n ): SeamHttpRequest<WorkspacesGetResponse, 'workspace'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/get',\n method: 'post',\n body,\n responseKey: 'workspace',\n })\n }\n\n list(\n body?: WorkspacesListParams,\n ): SeamHttpRequest<WorkspacesListResponse, 'workspaces'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/list',\n method: 'post',\n body,\n responseKey: 'workspaces',\n })\n }\n\n resetSandbox(\n body?: WorkspacesResetSandboxBody,\n options: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'> = {},\n ): SeamHttpRequest<WorkspacesResetSandboxResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/reset_sandbox',\n method: 'post',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n update(body?: WorkspacesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/update',\n method: 'post',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type WorkspacesCreateBody = RouteRequestBody<'/workspaces/create'>\n\nexport type WorkspacesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/create'>>\n>\n\nexport type WorkspacesCreateOptions = never\n\nexport type WorkspacesGetParams = RouteRequestBody<'/workspaces/get'>\n\nexport type WorkspacesGetResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/get'>>\n>\n\nexport type WorkspacesGetOptions = never\n\nexport type WorkspacesListParams = RouteRequestBody<'/workspaces/list'>\n\nexport type WorkspacesListResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/list'>>\n>\n\nexport type WorkspacesListOptions = never\n\nexport type WorkspacesResetSandboxBody =\n RouteRequestBody<'/workspaces/reset_sandbox'>\n\nexport type WorkspacesResetSandboxResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/reset_sandbox'>>\n>\n\nexport type WorkspacesResetSandboxOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type WorkspacesUpdateBody = RouteRequestBody<'/workspaces/update'>\n\nexport type WorkspacesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/update'>>\n>\n\nexport type WorkspacesUpdateOptions = never\n","import { seamApiLtsVersion } from 'lib/lts-version.js'\n\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from './auth.js'\nimport { type Client, createClient } from './client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from './options.js'\nimport { limitToSeamHttpRequestOptions, parseOptions } from './parse-options.js'\nimport {\n SeamHttpAccessCodes,\n SeamHttpAccessGrants,\n SeamHttpAccessMethods,\n SeamHttpAcs,\n SeamHttpActionAttempts,\n SeamHttpClientSessions,\n SeamHttpConnectedAccounts,\n SeamHttpConnectWebviews,\n SeamHttpDevices,\n SeamHttpEvents,\n SeamHttpLocks,\n SeamHttpNoiseSensors,\n SeamHttpPhones,\n SeamHttpSpaces,\n SeamHttpThermostats,\n SeamHttpUserIdentities,\n SeamHttpWebhooks,\n SeamHttpWorkspaces,\n} from './routes/index.js'\nimport type { SeamHttpRequest } from './seam-http-request.js'\nimport { SeamPaginator } from './seam-paginator.js'\n\nexport class SeamHttp {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttp {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttp(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttp {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttp(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttp {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttp(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttp> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttp.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttp {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttp(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttp {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttp(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get accessCodes(): SeamHttpAccessCodes {\n return SeamHttpAccessCodes.fromClient(this.client, this.defaults)\n }\n\n get accessGrants(): SeamHttpAccessGrants {\n return SeamHttpAccessGrants.fromClient(this.client, this.defaults)\n }\n\n get accessMethods(): SeamHttpAccessMethods {\n return SeamHttpAccessMethods.fromClient(this.client, this.defaults)\n }\n\n get acs(): SeamHttpAcs {\n return SeamHttpAcs.fromClient(this.client, this.defaults)\n }\n\n get actionAttempts(): SeamHttpActionAttempts {\n return SeamHttpActionAttempts.fromClient(this.client, this.defaults)\n }\n\n get clientSessions(): SeamHttpClientSessions {\n return SeamHttpClientSessions.fromClient(this.client, this.defaults)\n }\n\n get connectedAccounts(): SeamHttpConnectedAccounts {\n return SeamHttpConnectedAccounts.fromClient(this.client, this.defaults)\n }\n\n get connectWebviews(): SeamHttpConnectWebviews {\n return SeamHttpConnectWebviews.fromClient(this.client, this.defaults)\n }\n\n get devices(): SeamHttpDevices {\n return SeamHttpDevices.fromClient(this.client, this.defaults)\n }\n\n get events(): SeamHttpEvents {\n return SeamHttpEvents.fromClient(this.client, this.defaults)\n }\n\n get locks(): SeamHttpLocks {\n return SeamHttpLocks.fromClient(this.client, this.defaults)\n }\n\n get noiseSensors(): SeamHttpNoiseSensors {\n return SeamHttpNoiseSensors.fromClient(this.client, this.defaults)\n }\n\n get phones(): SeamHttpPhones {\n return SeamHttpPhones.fromClient(this.client, this.defaults)\n }\n\n get spaces(): SeamHttpSpaces {\n return SeamHttpSpaces.fromClient(this.client, this.defaults)\n }\n\n get thermostats(): SeamHttpThermostats {\n return SeamHttpThermostats.fromClient(this.client, this.defaults)\n }\n\n get userIdentities(): SeamHttpUserIdentities {\n return SeamHttpUserIdentities.fromClient(this.client, this.defaults)\n }\n\n get webhooks(): SeamHttpWebhooks {\n return SeamHttpWebhooks.fromClient(this.client, this.defaults)\n }\n\n get workspaces(): Omit<SeamHttpWorkspaces, 'create'> {\n return SeamHttpWorkspaces.fromClient(this.client, this.defaults)\n }\n}\n","import { type Client, createClient } from './client.js'\nimport {\n isSeamHttpMultiWorkspaceOptionsWithClient,\n isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n SeamHttpMultiWorkspaceInvalidOptionsError,\n type SeamHttpMultiWorkspaceOptions,\n type SeamHttpMultiWorkspaceOptionsWithClient,\n type SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n type SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from './options.js'\nimport { limitToSeamHttpRequestOptions, parseOptions } from './parse-options.js'\nimport { SeamHttpWorkspaces } from './routes/index.js'\n\nexport class SeamHttpMultiWorkspace {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(options: SeamHttpMultiWorkspaceOptions = {}) {\n const opts = parseOptions(options)\n this.client = 'client' in opts ? opts.client : createClient(opts)\n this.defaults = limitToSeamHttpRequestOptions(opts)\n }\n\n static fromClient(\n client: SeamHttpMultiWorkspaceOptionsWithClient['client'],\n options: Omit<SeamHttpMultiWorkspaceOptionsWithClient, 'client'> = {},\n ): SeamHttpMultiWorkspace {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpMultiWorkspaceOptionsWithClient(constructorOptions)) {\n throw new SeamHttpMultiWorkspaceInvalidOptionsError('Missing client')\n }\n return new SeamHttpMultiWorkspace(constructorOptions)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken['consoleSessionToken'],\n options: Omit<\n SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n 'consoleSessionToken'\n > = {},\n ): SeamHttpMultiWorkspace {\n const constructorOptions = { ...options, consoleSessionToken }\n if (\n !isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken(\n constructorOptions,\n )\n ) {\n throw new SeamHttpMultiWorkspaceInvalidOptionsError(\n 'Missing consoleSessionToken',\n )\n }\n return new SeamHttpMultiWorkspace(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken['personalAccessToken'],\n options: Omit<\n SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n 'personalAccessToken'\n > = {},\n ): SeamHttpMultiWorkspace {\n const constructorOptions = { ...options, personalAccessToken }\n if (\n !isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken(\n constructorOptions,\n )\n ) {\n throw new SeamHttpMultiWorkspaceInvalidOptionsError(\n 'Missing personalAccessToken',\n )\n }\n return new SeamHttpMultiWorkspace(constructorOptions)\n }\n\n get workspaces(): Pick<SeamHttpWorkspaces, 'create' | 'list'> {\n return SeamHttpWorkspaces.fromClient(this.client, this.defaults)\n }\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/lib/lts-version.ts","../src/lib/version.ts","../src/lib/seam/connect/parse-options.ts","../src/lib/seam/connect/options.ts","../src/lib/seam/connect/token.ts","../src/lib/seam/connect/auth.ts","../src/lib/seam/connect/seam-http-error.ts","../src/lib/seam/connect/error-interceptor.ts","../src/lib/seam/connect/client.ts","../src/lib/seam/connect/openapi.ts","../src/lib/seam/connect/resolve-action-attempt.ts","../src/lib/seam/connect/seam-http-request.ts","../src/lib/seam/connect/seam-paginator.ts","../src/lib/seam/connect/routes/client-sessions/client-sessions.ts","../src/lib/seam/connect/routes/access-codes/simulate/simulate.ts","../src/lib/seam/connect/routes/access-codes/unmanaged/unmanaged.ts","../src/lib/seam/connect/routes/access-codes/access-codes.ts","../src/lib/seam/connect/routes/access-grants/access-grants.ts","../src/lib/seam/connect/routes/access-methods/access-methods.ts","../src/lib/seam/connect/routes/acs/access-groups/access-groups.ts","../src/lib/seam/connect/routes/acs/credentials/credentials.ts","../src/lib/seam/connect/routes/acs/encoders/simulate/simulate.ts","../src/lib/seam/connect/routes/acs/encoders/encoders.ts","../src/lib/seam/connect/routes/acs/entrances/entrances.ts","../src/lib/seam/connect/routes/acs/systems/systems.ts","../src/lib/seam/connect/routes/acs/users/users.ts","../src/lib/seam/connect/routes/acs/acs.ts","../src/lib/seam/connect/routes/action-attempts/action-attempts.ts","../src/lib/seam/connect/routes/connect-webviews/connect-webviews.ts","../src/lib/seam/connect/routes/connected-accounts/connected-accounts.ts","../src/lib/seam/connect/routes/devices/simulate/simulate.ts","../src/lib/seam/connect/routes/devices/unmanaged/unmanaged.ts","../src/lib/seam/connect/routes/devices/devices.ts","../src/lib/seam/connect/routes/events/events.ts","../src/lib/seam/connect/routes/locks/locks.ts","../src/lib/seam/connect/routes/noise-sensors/noise-thresholds/noise-thresholds.ts","../src/lib/seam/connect/routes/noise-sensors/simulate/simulate.ts","../src/lib/seam/connect/routes/noise-sensors/noise-sensors.ts","../src/lib/seam/connect/routes/phones/simulate/simulate.ts","../src/lib/seam/connect/routes/phones/phones.ts","../src/lib/seam/connect/routes/spaces/spaces.ts","../src/lib/seam/connect/routes/thermostats/daily-programs/daily-programs.ts","../src/lib/seam/connect/routes/thermostats/schedules/schedules.ts","../src/lib/seam/connect/routes/thermostats/simulate/simulate.ts","../src/lib/seam/connect/routes/thermostats/thermostats.ts","../src/lib/seam/connect/routes/user-identities/enrollment-automations/enrollment-automations.ts","../src/lib/seam/connect/routes/user-identities/user-identities.ts","../src/lib/seam/connect/routes/webhooks/webhooks.ts","../src/lib/seam/connect/routes/workspaces/workspaces.ts","../src/lib/seam/connect/routes/seam-http.ts","../src/lib/seam/connect/seam-http-multi-workspace.ts"],"names":["isAxiosError","axios","serializeUrlSearchParams","axiosRetry","exponentialDelay","_parent"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAO,IAAM,iBAAoB,GAAA,OAAA;;;ACAjC,IAAM,4BAA+B,GAAA,OAAA;AAErC,IAAO,eAAQ,GAAA,4BAAA;;;ACaR,IAAM,eAAkB,GAAA,6BAAA;AAExB,IAAM,UAAa,GAAA;AAAA,EACxB,eAAiB,EAAA,yBAAA;AAAA,EACjB,kBAAoB,EAAA,eAAA;AAAA,EACpB,kBAAoB,EAAA;AACtB,CAAA;AAUO,IAAM,YAAA,GAAe,CAC1B,eACkB,KAAA;AAClB,EAAM,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,8BAA8B,IAAI,CAAA;AAAA;AACpD,EAEA,OAAO,UAAA,CACL,MACA,EAAA,OAAA,GAAmE,EAC3C,EAAA;AACxB,IAAA,MAAM,kBAAqB,GAAA,EAAE,GAAG,OAAA,EAAS,MAAO,EAAA;AAChD,IAAI,IAAA,CAAC,yCAA0C,CAAA,kBAAkB,CAAG,EAAA;AAClE,MAAM,MAAA,IAAI,0CAA0C,gBAAgB,CAAA;AAAA;AAEtE,IAAO,OAAA,IAAI,wBAAuB,kBAAkB,CAAA;AAAA;AACtD,EAEA,OAAO,uBAAA,CACL,mBACA,EAAA,OAAA,GAGI,EACoB,EAAA;AACxB,IAAA,MAAM,kBAAqB,GAAA,EAAE,GAAG,OAAA,EAAS,mBAAoB,EAAA;AAC7D,IAAA,IACE,CAAC,sDAAA;AAAA,MACC;AAAA,KAEF,EAAA;AACA,MAAA,MAAM,IAAI,yCAAA;AAAA,QACR;AAAA,OACF;AAAA;AAEF,IAAO,OAAA,IAAI,wBAAuB,kBAAkB,CAAA;AAAA;AACtD,EAEA,OAAO,uBAAA,CACL,mBACA,EAAA,OAAA,GAGI,EACoB,EAAA;AACxB,IAAA,MAAM,kBAAqB,GAAA,EAAE,GAAG,OAAA,EAAS,mBAAoB,EAAA;AAC7D,IAAA,IACE,CAAC,sDAAA;AAAA,MACC;AAAA,KAEF,EAAA;AACA,MAAA,MAAM,IAAI,yCAAA;AAAA,QACR;AAAA,OACF;AAAA;AAEF,IAAO,OAAA,IAAI,wBAAuB,kBAAkB,CAAA;AAAA;AACtD,EAEA,IAAI,UAA0D,GAAA;AAC5D,IAAA,OAAO,kBAAmB,CAAA,UAAA,CAAW,IAAK,CAAA,MAAA,EAAQ,KAAK,QAAQ,CAAA;AAAA;AAEnE","file":"connect.cjs","sourcesContent":["export const seamApiLtsVersion = '1.0.0'\n","const seamapiJavascriptHttpVersion = '0.0.0'\n\nexport default seamapiJavascriptHttpVersion\n","import { seamApiLtsVersion } from 'lib/lts-version.js'\nimport version from 'lib/version.js'\n\nimport { getAuthHeaders } from './auth.js'\nimport type { Client, ClientOptions } from './client.js'\nimport {\n isSeamHttpMultiWorkspaceOptionsWithClient,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n SeamHttpInvalidOptionsError,\n type SeamHttpMultiWorkspaceOptions,\n type SeamHttpOptions,\n type SeamHttpRequestOptions,\n} from './options.js'\n\nexport const defaultEndpoint = 'https://connect.getseam.com'\n\nexport const sdkHeaders = {\n 'seam-sdk-name': 'seamapi/javascript-http',\n 'seam-sdk-version': version,\n 'seam-lts-version': seamApiLtsVersion,\n}\n\nexport type Options =\n | SeamHttpMultiWorkspaceOptions\n | (SeamHttpOptions & { publishableKey?: string })\n\ntype ParsedOptions = Required<\n (ClientOptions | { client: Client }) & SeamHttpRequestOptions\n>\n\nexport const parseOptions = (\n apiKeyOrOptions: string | Options,\n): ParsedOptions => {\n const options = getNormalizedOptions(apiKeyOrOptions)\n\n if (isSeamHttpOptionsWithClient(options)) return options\n if (isSeamHttpMultiWorkspaceOptionsWithClient(options)) return options\n\n return {\n ...options,\n axiosOptions: {\n baseURL: options.endpoint ?? getEndpointFromEnv() ?? defaultEndpoint,\n withCredentials: isSeamHttpOptionsWithClientSessionToken(options),\n ...options.axiosOptions,\n headers: {\n ...getAuthHeaders(options),\n ...options.axiosOptions?.headers,\n ...sdkHeaders,\n },\n },\n axiosRetryOptions: {\n ...options.axiosRetryOptions,\n },\n }\n}\n\nconst getNormalizedOptions = (\n apiKeyOrOptions: string | Options,\n): SeamHttpOptions & Required<SeamHttpRequestOptions> => {\n const options =\n typeof apiKeyOrOptions === 'string'\n ? { apiKey: apiKeyOrOptions }\n : apiKeyOrOptions\n\n const requestOptions = {\n waitForActionAttempt: options.waitForActionAttempt ?? true,\n }\n\n if (isSeamHttpOptionsWithClient(options)) {\n return {\n ...options,\n ...requestOptions,\n }\n }\n\n const apiKey =\n 'apiKey' in options ? options.apiKey : getApiKeyFromEnv(options)\n\n const personalAccessToken =\n 'personalAccessToken' in options\n ? options.personalAccessToken\n : getPersonalAccessTokenFromEnv(options)\n\n const workspaceId =\n 'workspaceId' in options ? options.workspaceId : getWorkspaceIdFromEnv()\n\n if (\n apiKey != null &&\n personalAccessToken != null &&\n !('apiKey' in options) &&\n !('personalAccessToken' in options)\n ) {\n throw new SeamHttpInvalidOptionsError(\n 'Both SEAM_API_KEY and SEAM_PERSONAL_ACCESS_TOKEN environment variables are defined. Please use only one authentication method.',\n )\n }\n\n return {\n ...options,\n ...(apiKey != null ? { apiKey } : {}),\n ...(workspaceId != null ? { workspaceId } : {}),\n ...(personalAccessToken != null ? { personalAccessToken } : {}),\n ...requestOptions,\n }\n}\n\nconst getApiKeyFromEnv = (\n options: SeamHttpOptions,\n): string | null | undefined => {\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n return null\n }\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n return null\n }\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n return null\n }\n return globalThis.process?.env?.SEAM_API_KEY\n}\n\nconst getPersonalAccessTokenFromEnv = (\n options: SeamHttpOptions,\n): string | null | undefined => {\n if ('apiKey' in options && options.apiKey != null) {\n return null\n }\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n return null\n }\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n return null\n }\n return globalThis.process?.env?.SEAM_PERSONAL_ACCESS_TOKEN\n}\n\nconst getWorkspaceIdFromEnv = (): string | null | undefined => {\n return globalThis.process?.env?.SEAM_WORKSPACE_ID\n}\n\nconst getEndpointFromEnv = (): string | null | undefined => {\n if (globalThis.process?.env?.SEAM_API_URL != null) {\n // eslint-disable-next-line no-console\n console.warn(\n 'Using the SEAM_API_URL environment variable is deprecated. Support will be remove in a later major version. Use SEAM_ENDPOINT instead.',\n )\n }\n\n if (\n globalThis.process?.env?.SEAM_API_URL != null &&\n globalThis.process?.env?.SEAM_ENDPOINT != null\n ) {\n // eslint-disable-next-line no-console\n console.warn(\n 'Detected both the SEAM_API_URL and SEAM_ENDPOINT environment variables. Using SEAM_ENDPOINT.',\n )\n }\n\n return (\n globalThis.process?.env?.SEAM_ENDPOINT ??\n globalThis.process?.env?.SEAM_API_URL\n )\n}\n\nexport const limitToSeamHttpRequestOptions = (\n options: Required<SeamHttpRequestOptions>,\n): Required<SeamHttpRequestOptions> => {\n return Object.keys(options)\n .filter(isSeamHttpRequestOption)\n .reduce(\n (obj, key) => ({\n ...obj,\n [key]: options[key],\n }),\n {},\n ) as Required<SeamHttpRequestOptions>\n}\n\nexport const isSeamHttpRequestOption = (\n key: string,\n): key is keyof SeamHttpRequestOptions => {\n const keys: Record<keyof SeamHttpRequestOptions, true> = {\n waitForActionAttempt: true,\n }\n return Object.keys(keys).includes(key)\n}\n","import type { Client, ClientOptions } from './client.js'\nimport { isSeamHttpRequestOption } from './parse-options.js'\nimport type { ResolveActionAttemptOptions } from './resolve-action-attempt.js'\n\nexport type SeamHttpMultiWorkspaceOptions =\n | SeamHttpMultiWorkspaceOptionsFromEnv\n | SeamHttpMultiWorkspaceOptionsWithClient\n | SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken\n | SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken\n\nexport type SeamHttpOptions =\n | SeamHttpOptionsFromEnv\n | SeamHttpOptionsWithClient\n | SeamHttpOptionsWithApiKey\n | SeamHttpOptionsWithClientSessionToken\n | SeamHttpOptionsWithConsoleSessionToken\n | SeamHttpOptionsWithPersonalAccessToken\n\ninterface SeamHttpCommonOptions extends ClientOptions, SeamHttpRequestOptions {\n endpoint?: string\n}\n\nexport interface SeamHttpRequestOptions {\n waitForActionAttempt?: boolean | ResolveActionAttemptOptions\n}\n\nexport interface SeamHttpFromPublishableKeyOptions\n extends SeamHttpCommonOptions {}\n\nexport interface SeamHttpOptionsFromEnv extends SeamHttpCommonOptions {}\n\nexport interface SeamHttpMultiWorkspaceOptionsFromEnv\n extends SeamHttpCommonOptions {}\n\nexport interface SeamHttpMultiWorkspaceOptionsWithClient\n extends SeamHttpRequestOptions {\n client: Client\n}\n\nexport const isSeamHttpMultiWorkspaceOptionsWithClient = (\n options: SeamHttpOptions,\n): options is SeamHttpMultiWorkspaceOptionsWithClient =>\n isSeamHttpOptionsWithClient(options)\n\nexport interface SeamHttpOptionsWithClient extends SeamHttpRequestOptions {\n client: Client\n}\n\nexport const isSeamHttpOptionsWithClient = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithClient => {\n if (!('client' in options)) return false\n if (options.client == null) return false\n\n const keys = Object.keys(options).filter((k) => k !== 'client')\n if (keys.filter((k) => !isSeamHttpRequestOption(k)).length > 0) {\n throw new SeamHttpInvalidOptionsError(\n `The client option cannot be used with any other option, but received: ${keys.join(\n ', ',\n )}`,\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithApiKey extends SeamHttpCommonOptions {\n apiKey: string\n}\n\nexport const isSeamHttpOptionsWithApiKey = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithApiKey => {\n if (!('apiKey' in options)) return false\n if (options.apiKey == null) return false\n\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The clientSessionToken option cannot be used with the apiKey option',\n )\n }\n\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The consoleSessionToken option cannot be used with the apiKey option',\n )\n }\n\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The personalAccessToken option cannot be used with the apiKey option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithClientSessionToken\n extends SeamHttpCommonOptions {\n clientSessionToken: string\n}\n\nexport const isSeamHttpOptionsWithClientSessionToken = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithClientSessionToken => {\n if (!('clientSessionToken' in options)) return false\n if (options.clientSessionToken == null) return false\n\n if ('apiKey' in options && options.apiKey != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The apiKey option cannot be used with the clientSessionToken option',\n )\n }\n\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The consoleSessionToken option cannot be used with the clientSessionToken option',\n )\n }\n\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The personalAccessToken option cannot be used with the clientSessionToken option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken\n extends SeamHttpCommonOptions {\n consoleSessionToken: string\n}\n\nexport const isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken = (\n options: SeamHttpOptions,\n): options is SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken => {\n if (!('consoleSessionToken' in options)) return false\n if (options.consoleSessionToken == null) return false\n\n if ('apiKey' in options && options.apiKey != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The apiKey option cannot be used with the consoleSessionToken option',\n )\n }\n\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The clientSessionToken option cannot be used with the consoleSessionToken option',\n )\n }\n\n if ('personalAccessToken' in options && options.personalAccessToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The personalAccessToken option cannot be used with the consoleSessionToken option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithConsoleSessionToken\n extends SeamHttpCommonOptions {\n consoleSessionToken: string\n workspaceId: string\n}\n\nexport const isSeamHttpOptionsWithConsoleSessionToken = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithConsoleSessionToken => {\n if (!isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken(options)) {\n return false\n }\n\n if (!('workspaceId' in options) || options.workspaceId == null) {\n throw new SeamHttpInvalidOptionsError(\n 'Must pass a workspaceId when using a consoleSessionToken',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken\n extends SeamHttpCommonOptions {\n personalAccessToken: string\n}\n\nexport const isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken = (\n options: SeamHttpOptions,\n): options is SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken => {\n if (!('personalAccessToken' in options)) return false\n if (options.personalAccessToken == null) return false\n\n if ('apiKey' in options && options.apiKey != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The apiKey option cannot be used with the personalAccessToken option',\n )\n }\n\n if ('clientSessionToken' in options && options.clientSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The clientSessionToken option cannot be used with the personalAccessToken option',\n )\n }\n\n if ('consoleSessionToken' in options && options.consoleSessionToken != null) {\n throw new SeamHttpInvalidOptionsError(\n 'The consoleSessionToken option cannot be used with the personalAccessToken option',\n )\n }\n\n return true\n}\n\nexport interface SeamHttpOptionsWithPersonalAccessToken\n extends SeamHttpCommonOptions {\n personalAccessToken: string\n workspaceId: string\n}\n\nexport const isSeamHttpOptionsWithPersonalAccessToken = (\n options: SeamHttpOptions,\n): options is SeamHttpOptionsWithPersonalAccessToken => {\n if (!isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken(options)) {\n return false\n }\n\n if (!('workspaceId' in options) || options.workspaceId == null) {\n throw new SeamHttpInvalidOptionsError(\n 'Must pass a workspaceId when using a personalAccessToken',\n )\n }\n\n return true\n}\n\nexport class SeamHttpInvalidOptionsError extends Error {\n constructor(message: string) {\n super(`SeamHttp received invalid options: ${message}`)\n this.name = this.constructor.name\n }\n}\n\nexport class SeamHttpMultiWorkspaceInvalidOptionsError extends Error {\n constructor(message: string) {\n super(`SeamHttpMultiWorkspace received invalid options: ${message}`)\n this.name = this.constructor.name\n }\n}\n","export const tokenPrefix = 'seam_'\n\nexport const accessTokenPrefix = 'seam_at'\n\nexport const jwtPrefix = 'ey'\n\nexport const clientSessionTokenPrefix = 'seam_cst'\n\nexport const publishableKeyTokenPrefix = 'seam_pk'\n\nexport const isAccessToken = (token: string): boolean =>\n token.startsWith(accessTokenPrefix)\n\nexport const isJwt = (token: string): boolean => token.startsWith(jwtPrefix)\n\nexport const isSeamToken = (token: string): boolean =>\n token.startsWith(tokenPrefix)\n\nexport const isApiKey = (token: string): boolean =>\n !isClientSessionToken(token) &&\n !isJwt(token) &&\n !isAccessToken(token) &&\n !isPublishableKey(token) &&\n isSeamToken(token)\n\nexport const isClientSessionToken = (token: string): boolean =>\n token.startsWith(clientSessionTokenPrefix)\n\nexport const isPublishableKey = (token: string): boolean =>\n token.startsWith(publishableKeyTokenPrefix)\n\nexport const isConsoleSessionToken = (token: string): boolean => isJwt(token)\n\nexport const isPersonalAccessToken = (token: string): boolean =>\n isAccessToken(token)\n","import {\n isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n SeamHttpInvalidOptionsError,\n type SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n type SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n} from './options.js'\nimport type { Options } from './parse-options.js'\nimport {\n accessTokenPrefix,\n clientSessionTokenPrefix,\n isAccessToken,\n isClientSessionToken,\n isJwt,\n isPublishableKey,\n isSeamToken,\n jwtPrefix,\n publishableKeyTokenPrefix,\n tokenPrefix,\n} from './token.js'\n\ntype Headers = Record<string, string>\n\nexport const getAuthHeaders = (options: Options): Headers => {\n if ('publishableKey' in options && options.publishableKey != null) {\n return getAuthHeadersForPublishableKey(options.publishableKey)\n }\n\n if (isSeamHttpOptionsWithApiKey(options)) {\n return getAuthHeadersForApiKey(options)\n }\n\n if (isSeamHttpOptionsWithClientSessionToken(options)) {\n return getAuthHeadersForClientSessionToken(options)\n }\n\n if (\n isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken(options) ||\n isSeamHttpOptionsWithConsoleSessionToken(options)\n ) {\n return getAuthHeadersForConsoleSessionToken(options)\n }\n\n if (\n isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken(options) ||\n isSeamHttpOptionsWithPersonalAccessToken(options)\n ) {\n return getAuthHeadersForPersonalAccessToken(options)\n }\n\n throw new SeamHttpInvalidOptionsError(\n [\n 'Must specify',\n 'an apiKey,',\n 'clientSessionToken,',\n 'publishableKey,',\n 'consoleSessionToken',\n 'or personalAccessToken.',\n 'Attempted reading configuration from the environment, but the environment variable SEAM_API_KEY is not set.',\n ].join(' '),\n )\n}\n\nconst getAuthHeadersForApiKey = ({\n apiKey,\n}: SeamHttpOptionsWithApiKey): Headers => {\n if (isClientSessionToken(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token cannot be used as an apiKey',\n )\n }\n\n if (isJwt(apiKey)) {\n throw new SeamHttpInvalidTokenError('A JWT cannot be used as an apiKey')\n }\n\n if (isAccessToken(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as an apiKey',\n )\n }\n\n if (isPublishableKey(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as an apiKey',\n )\n }\n\n if (!isSeamToken(apiKey)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid apiKey format, expected token to start with ${tokenPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${apiKey}`,\n }\n}\n\nexport const getAuthHeadersForClientSessionToken = ({\n clientSessionToken,\n}: SeamHttpOptionsWithClientSessionToken): Headers => {\n if (isJwt(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A JWT cannot be used as a clientSessionToken',\n )\n }\n\n if (isAccessToken(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as a clientSessionToken',\n )\n }\n\n if (isPublishableKey(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as a clientSessionToken',\n )\n }\n\n if (!isClientSessionToken(clientSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid clientSessionToken format, expected token to start with ${clientSessionTokenPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${clientSessionToken}`,\n 'client-session-token': clientSessionToken,\n }\n}\n\nconst getAuthHeadersForConsoleSessionToken = ({\n consoleSessionToken,\n ...options\n}:\n | SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken\n | SeamHttpOptionsWithConsoleSessionToken): Headers => {\n const workspaceId = 'workspaceId' in options ? options.workspaceId : undefined\n\n if (isAccessToken(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as a consoleSessionToken',\n )\n }\n\n if (isClientSessionToken(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token cannot be used as a consoleSessionToken',\n )\n }\n\n if (isPublishableKey(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as a consoleSessionToken',\n )\n }\n\n if (!isJwt(consoleSessionToken)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid consoleSessionToken format, expected a JWT which starts with ${jwtPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${consoleSessionToken}`,\n ...(workspaceId != null ? { 'seam-workspace': workspaceId } : {}),\n }\n}\n\nconst getAuthHeadersForPersonalAccessToken = ({\n personalAccessToken,\n ...options\n}:\n | SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken\n | SeamHttpOptionsWithPersonalAccessToken): Headers => {\n const workspaceId = 'workspaceId' in options ? options.workspaceId : undefined\n\n if (isJwt(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A JWT cannot be used as a personalAccessToken',\n )\n }\n\n if (isClientSessionToken(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token cannot be used as a personalAccessToken',\n )\n }\n\n if (isPublishableKey(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n 'A Publishable Key cannot be used as a personalAccessToken',\n )\n }\n\n if (!isAccessToken(personalAccessToken)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid personalAccessToken format, expected token to start with ${accessTokenPrefix}`,\n )\n }\n\n return {\n authorization: `Bearer ${personalAccessToken}`,\n ...(workspaceId != null ? { 'seam-workspace': workspaceId } : {}),\n }\n}\n\nconst getAuthHeadersForPublishableKey = (publishableKey: string): Headers => {\n if (isJwt(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A JWT cannot be used as a publishableKey',\n )\n }\n\n if (isAccessToken(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n 'An Access Token cannot be used as a publishableKey',\n )\n }\n\n if (isClientSessionToken(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n 'A Client Session Token Key cannot be used as a publishableKey',\n )\n }\n\n if (!isPublishableKey(publishableKey)) {\n throw new SeamHttpInvalidTokenError(\n `Unknown or invalid publishableKey format, expected token to start with ${publishableKeyTokenPrefix}`,\n )\n }\n\n return {\n 'seam-publishable-key': publishableKey,\n }\n}\n\nexport class SeamHttpInvalidTokenError extends Error {\n constructor(message: string) {\n super(`SeamHttp received an invalid token: ${message}`)\n this.name = this.constructor.name\n }\n}\n\nexport const warnOnInsecureuserIdentifierKey = (\n userIdentifierKey: string,\n): void => {\n if (isEmail(userIdentifierKey)) {\n // eslint-disable-next-line no-console\n console.warn(\n ...[\n 'Using an email for the userIdentifierKey is insecure and may return an error in the future!',\n 'This is insecure because an email is common knowledge or easily guessed.',\n 'Use something with sufficient entropy known only to the owner of the client session.',\n 'For help choosing a user identifier key see',\n 'https://docs.seam.co/latest/seam-components/overview/get-started-with-client-side-components#3-select-a-user-identifier-key',\n ],\n )\n }\n}\n\n// SOURCE: https://stackoverflow.com/a/46181\nconst isEmail = (value: string): boolean => {\n if (value.includes('!')) return false\n // The regex may run slow on strings starting with '!@!.' and with many repetitions of '!.'.\n return /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/.test(value)\n}\n","import type { ApiError } from './api-error-types.js'\n\nexport class SeamHttpApiError extends Error {\n code: string\n statusCode: number\n requestId: string\n data?: unknown\n\n constructor(error: ApiError, statusCode: number, requestId: string) {\n const { type, message, data } = error\n super(message)\n this.name = this.constructor.name\n this.code = type\n this.statusCode = statusCode\n this.requestId = requestId\n if (data != null) this.data = data\n }\n}\n\nexport const isSeamHttpApiError = (\n error: unknown,\n): error is SeamHttpApiError => {\n return error instanceof SeamHttpApiError\n}\n\nexport class SeamHttpUnauthorizedError extends SeamHttpApiError {\n override code: 'unauthorized'\n override statusCode: 401\n\n constructor(requestId: string) {\n const type = 'unauthorized'\n const status = 401\n super({ type, message: 'Unauthorized' }, status, requestId)\n this.name = this.constructor.name\n this.code = type\n this.statusCode = status\n this.requestId = requestId\n }\n}\n\nexport const isSeamHttpUnauthorizedError = (\n error: unknown,\n): error is SeamHttpUnauthorizedError => {\n return error instanceof SeamHttpUnauthorizedError\n}\n\nexport class SeamHttpInvalidInputError extends SeamHttpApiError {\n override code: 'invalid_input'\n readonly #validationErrors: NonNullable<ApiError['validation_errors']>\n\n constructor(error: ApiError, statusCode: number, requestId: string) {\n super(error, statusCode, requestId)\n this.name = this.constructor.name\n this.code = 'invalid_input'\n this.#validationErrors = error.validation_errors ?? {}\n }\n\n getValidationErrorMessages(paramName: string): string[] {\n return this.#validationErrors[paramName]?._errors ?? []\n }\n}\n\nexport const isSeamHttpInvalidInputError = (\n error: unknown,\n): error is SeamHttpInvalidInputError => {\n return error instanceof SeamHttpInvalidInputError\n}\n","import { type AxiosError, isAxiosError } from 'axios'\n\nimport type { ApiErrorResponse } from './api-error-types.js'\nimport {\n SeamHttpApiError,\n SeamHttpInvalidInputError,\n SeamHttpUnauthorizedError,\n} from './seam-http-error.js'\n\nexport const errorInterceptor = async (err: unknown): Promise<void> => {\n if (!isAxiosError(err)) throw err\n\n const { response } = err\n const status = response?.status\n\n const requestId = getRequestId(err)\n\n if (status == null) throw err\n\n if (status === 401) {\n throw new SeamHttpUnauthorizedError(requestId)\n }\n\n if (!isApiErrorResponse(response)) throw err\n\n const { type } = response.data.error\n\n const args = [response.data.error, status, requestId] as const\n\n if (type === 'invalid_input') throw new SeamHttpInvalidInputError(...args)\n throw new SeamHttpApiError(...args)\n}\n\nconst isApiErrorResponse = (\n response: AxiosError['response'],\n): response is NonNullable<AxiosError<ApiErrorResponse>['response']> => {\n if (response == null) return false\n const { headers, data } = response\n\n if (headers == null) return false\n\n const contentType = headers['Content-Type']\n if (\n typeof contentType === 'string' &&\n !contentType.startsWith('application/json')\n ) {\n return false\n }\n\n if (typeof data === 'object' && data != null) {\n return (\n 'error' in data &&\n typeof data.error === 'object' &&\n data.error != null &&\n 'type' in data.error &&\n typeof data.error.type === 'string' &&\n 'message' in data.error &&\n typeof data.error.message === 'string'\n )\n }\n\n return false\n}\n\nconst getRequestId = (err: AxiosError): string => {\n const headers = err.response?.headers\n if (headers == null) return ''\n const requestId = headers['seam-request-id']\n if (requestId == null) return ''\n return requestId\n}\n","import { serializeUrlSearchParams } from '@seamapi/url-search-params-serializer'\nimport axios, { type AxiosInstance, type AxiosRequestConfig } from 'axios'\nimport axiosRetry, { type AxiosRetry, exponentialDelay } from 'axios-retry'\n\nimport { errorInterceptor } from './error-interceptor.js'\n\nexport type Client = AxiosInstance\n\nexport interface ClientOptions {\n axiosOptions?: AxiosRequestConfig\n axiosRetryOptions?: AxiosRetryConfig\n}\n\ntype AxiosRetryConfig = Parameters<AxiosRetry>[1]\n\nexport const createClient = (options: ClientOptions): AxiosInstance => {\n const client = axios.create({\n paramsSerializer: serializeUrlSearchParams,\n adapter: 'fetch',\n ...options.axiosOptions,\n })\n\n axiosRetry(client, {\n retries: 2,\n retryDelay: exponentialDelay,\n ...options.axiosRetryOptions,\n })\n\n client.interceptors.response.use(undefined, errorInterceptor)\n\n return client\n}\n","import type { openapi } from '@seamapi/types/connect'\n\nimport { createClient } from './client.js'\nimport { defaultEndpoint, sdkHeaders } from './parse-options.js'\n\nexport const getOpenapiSchema = async (\n endpoint = defaultEndpoint,\n): Promise<typeof openapi> => {\n const client = createClient({\n axiosOptions: {\n baseURL: endpoint,\n headers: sdkHeaders,\n },\n })\n const { data } = await client.get<typeof openapi>('/openapi.json')\n return data\n}\n","import type { ActionAttempt } from '@seamapi/types/connect'\n\nimport type { SeamHttpActionAttempts } from './routes/index.js'\n\nexport interface ResolveActionAttemptOptions {\n timeout?: number\n pollingInterval?: number\n}\n\nexport const resolveActionAttempt = async <T extends ActionAttempt>(\n actionAttempt: T,\n actionAttempts: SeamHttpActionAttempts,\n { timeout = 5000, pollingInterval = 500 }: ResolveActionAttemptOptions,\n): Promise<SucceededActionAttempt<T>> => {\n let timeoutRef\n const timeoutPromise = new Promise<SucceededActionAttempt<T>>(\n (_resolve, reject) => {\n timeoutRef = globalThis.setTimeout(() => {\n reject(new SeamActionAttemptTimeoutError<T>(actionAttempt, timeout))\n }, timeout)\n },\n )\n\n try {\n return await Promise.race([\n pollActionAttempt<T>(actionAttempt, actionAttempts, { pollingInterval }),\n timeoutPromise,\n ])\n } finally {\n if (timeoutRef != null) globalThis.clearTimeout(timeoutRef)\n }\n}\n\nconst pollActionAttempt = async <T extends ActionAttempt>(\n actionAttempt: T,\n actionAttempts: SeamHttpActionAttempts,\n options: Pick<ResolveActionAttemptOptions, 'pollingInterval'>,\n): Promise<SucceededActionAttempt<T>> => {\n if (isSuccessfulActionAttempt(actionAttempt)) {\n return actionAttempt\n }\n\n if (isFailedActionAttempt(actionAttempt)) {\n throw new SeamActionAttemptFailedError(actionAttempt)\n }\n\n await new Promise((resolve) => setTimeout(resolve, options.pollingInterval))\n\n const nextActionAttempt = await actionAttempts.get({\n action_attempt_id: actionAttempt.action_attempt_id,\n })\n\n return await pollActionAttempt(\n nextActionAttempt as unknown as T,\n actionAttempts,\n options,\n )\n}\n\nexport const isSeamActionAttemptError = <T extends ActionAttempt>(\n error: unknown,\n): error is SeamActionAttemptError<T> => {\n return error instanceof SeamActionAttemptError\n}\n\nexport class SeamActionAttemptError<T extends ActionAttempt> extends Error {\n actionAttempt: T\n\n constructor(message: string, actionAttempt: T) {\n super(message)\n this.name = this.constructor.name\n this.actionAttempt = actionAttempt\n }\n}\n\nexport const isSeamActionAttemptFailedError = <T extends ActionAttempt>(\n error: unknown,\n): error is SeamActionAttemptFailedError<T> => {\n return error instanceof SeamActionAttemptFailedError\n}\n\nexport class SeamActionAttemptFailedError<\n T extends ActionAttempt,\n> extends SeamActionAttemptError<T> {\n code: string\n\n constructor(actionAttempt: FailedActionAttempt<T>) {\n super(actionAttempt.error.message, actionAttempt)\n this.name = this.constructor.name\n this.code = actionAttempt.error.type\n }\n}\n\nexport const isSeamActionAttemptTimeoutError = <T extends ActionAttempt>(\n error: unknown,\n): error is SeamActionAttemptTimeoutError<T> => {\n return error instanceof SeamActionAttemptTimeoutError\n}\n\nexport class SeamActionAttemptTimeoutError<\n T extends ActionAttempt,\n> extends SeamActionAttemptError<T> {\n constructor(actionAttempt: T, timeout: number) {\n super(\n `Timed out waiting for action action attempt after ${timeout}ms`,\n actionAttempt,\n )\n this.name = this.constructor.name\n }\n}\n\nconst isSuccessfulActionAttempt = <T extends ActionAttempt>(\n actionAttempt: T,\n): actionAttempt is SucceededActionAttempt<T> =>\n actionAttempt.status === 'success'\n\nconst isFailedActionAttempt = <T extends ActionAttempt>(\n actionAttempt: T,\n): actionAttempt is FailedActionAttempt<T> => actionAttempt.status === 'error'\n\nexport type SucceededActionAttempt<T extends ActionAttempt> = Extract<\n T,\n { status: 'success' }\n>\n\nexport type FailedActionAttempt<T extends ActionAttempt> = Extract<\n T,\n { status: 'error' }\n>\n","import type { ActionAttempt } from '@seamapi/types/connect'\nimport { serializeUrlSearchParams } from '@seamapi/url-search-params-serializer'\nimport type { Method } from 'axios'\n\nimport type { Client } from './client.js'\nimport type { SeamHttpRequestOptions } from './options.js'\nimport { resolveActionAttempt } from './resolve-action-attempt.js'\nimport { SeamHttpActionAttempts } from './routes/index.js'\n\ninterface SeamHttpRequestParent {\n readonly client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n}\n\ninterface SeamHttpRequestConfig<TResponseKey> {\n readonly pathname: string\n readonly method: Method\n readonly body?: unknown\n readonly params?: undefined | Record<string, unknown>\n readonly responseKey: TResponseKey\n readonly options?: Pick<SeamHttpRequestOptions, 'waitForActionAttempt'>\n}\n\nexport class SeamHttpRequest<\n const TResponse,\n const TResponseKey extends keyof TResponse | undefined,\n> implements\n Promise<\n TResponseKey extends keyof TResponse ? TResponse[TResponseKey] : undefined\n >\n{\n readonly [Symbol.toStringTag]: string = 'SeamHttpRequest'\n\n readonly #parent: SeamHttpRequestParent\n readonly #config: SeamHttpRequestConfig<TResponseKey>\n\n constructor(\n parent: SeamHttpRequestParent,\n config: SeamHttpRequestConfig<TResponseKey>,\n ) {\n this.#parent = parent\n this.#config = config\n }\n\n public get responseKey(): TResponseKey {\n return this.#config.responseKey\n }\n\n public get url(): URL {\n const { client } = this.#parent\n\n const serializer =\n typeof client.defaults.paramsSerializer === 'function'\n ? client.defaults.paramsSerializer\n : serializeUrlSearchParams\n\n const origin = getUrlPrefix(client.defaults.baseURL ?? '')\n\n const path =\n this.params == null\n ? this.pathname\n : `${this.pathname}?${serializer(this.params)}`\n\n return new URL(`${origin}${path}`)\n }\n\n public get pathname(): string {\n return this.#config.pathname.startsWith('/')\n ? this.#config.pathname\n : `/${this.#config.pathname}`\n }\n\n public get method(): Method {\n return this.#config.method\n }\n\n public get params(): undefined | Record<string, unknown> {\n return this.#config.params\n }\n\n public get body(): unknown {\n return this.#config.body\n }\n\n async execute(): Promise<\n TResponseKey extends keyof TResponse ? TResponse[TResponseKey] : undefined\n > {\n const response = await this.fetchResponse()\n\n type Response = TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined\n\n if (this.responseKey === undefined) {\n return undefined as Response\n }\n\n const data = response[this.responseKey] as unknown as Response\n\n if (this.responseKey === 'action_attempt') {\n const waitForActionAttempt =\n this.#config.options?.waitForActionAttempt ??\n this.#parent.defaults.waitForActionAttempt\n\n if (waitForActionAttempt !== false) {\n const actionAttempt = await resolveActionAttempt(\n data as unknown as ActionAttempt,\n SeamHttpActionAttempts.fromClient(this.#parent.client, {\n ...this.#parent.defaults,\n waitForActionAttempt: false,\n }),\n typeof waitForActionAttempt === 'boolean' ? {} : waitForActionAttempt,\n )\n return actionAttempt as Response\n }\n }\n\n return data\n }\n\n async fetchResponse(): Promise<TResponse> {\n const { client } = this.#parent\n const response = await client.request({\n url: this.pathname,\n method: this.method,\n data: this.body,\n params: this.params,\n })\n return response.data as unknown as TResponse\n }\n\n async then<\n TResult1 = TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined,\n TResult2 = never,\n >(\n onfulfilled?:\n | ((\n value: TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined,\n ) => TResult1 | PromiseLike<TResult1>)\n | null\n | undefined,\n onrejected?:\n | ((reason: unknown) => TResult2 | PromiseLike<TResult2>)\n | null\n | undefined,\n ): Promise<TResult1 | TResult2> {\n return await this.execute().then(onfulfilled, onrejected)\n }\n\n async catch<TResult = never>(\n onrejected?:\n | ((reason: unknown) => TResult | PromiseLike<TResult>)\n | null\n | undefined,\n ): Promise<\n | (TResponseKey extends keyof TResponse\n ? TResponse[TResponseKey]\n : undefined)\n | TResult\n > {\n return await this.execute().catch(onrejected)\n }\n\n async finally(\n onfinally?: (() => void) | null | undefined,\n ): Promise<\n TResponseKey extends keyof TResponse ? TResponse[TResponseKey] : undefined\n > {\n return await this.execute().finally(onfinally)\n }\n}\n\nconst getUrlPrefix = (input: string): string => {\n if (canParseUrl(input)) {\n const url = new URL(input).toString()\n if (url.endsWith('/')) return url.slice(0, -1)\n return url\n }\n if (globalThis.location != null) {\n const pathname = input.startsWith('/') ? input : `/${input}`\n return new URL(`${globalThis.location.origin}${pathname}`).toString()\n }\n throw new Error(\n `Cannot resolve origin from ${input} in a non-browser environment`,\n )\n}\n\n// UPSTREAM: Prefer URL.canParse when it has wider support.\n// https://caniuse.com/mdn-api_url_canparse_static\nconst canParseUrl = (input: string): boolean => {\n try {\n return new URL(input) != null\n } catch {\n return false\n }\n}\n","import type { Client } from './client.js'\nimport type { SeamHttpRequestOptions } from './options.js'\nimport { SeamHttpRequest } from './seam-http-request.js'\n\ninterface SeamPaginatorParent {\n readonly client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n}\n\ndeclare const $brand: unique symbol\n\ntype PageCursor = string & { [$brand]: 'SeamPageCursor' }\n\ninterface Pagination {\n readonly hasNextPage: boolean\n readonly nextPageCursor: PageCursor | null\n readonly nextPageUrl: string | null\n}\n\nexport class SeamPaginator<\n const TResponse,\n const TResponseKey extends keyof TResponse,\n> implements AsyncIterable<EnsureReadonlyArray<TResponse[TResponseKey]>>\n{\n readonly #request: SeamHttpRequest<TResponse, TResponseKey>\n readonly #parent: SeamPaginatorParent\n\n constructor(\n parent: SeamPaginatorParent,\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ) {\n if (request.responseKey == null) {\n throw new Error(\n `The ${request.pathname} endpoint does not support pagination`,\n )\n }\n this.#parent = parent\n this.#request = request\n }\n\n async firstPage(): Promise<\n [EnsureReadonlyArray<TResponse[TResponseKey]>, Pagination]\n > {\n return await this.#fetch()\n }\n\n async nextPage(\n nextPageCursor: Pagination['nextPageCursor'],\n ): Promise<[EnsureReadonlyArray<TResponse[TResponseKey]>, Pagination]> {\n if (nextPageCursor == null) {\n throw new Error('Cannot get the next page with a null nextPageCursor')\n }\n\n return await this.#fetch(nextPageCursor)\n }\n\n async #fetch(\n nextPageCursor?: Pagination['nextPageCursor'],\n ): Promise<[EnsureReadonlyArray<TResponse[TResponseKey]>, Pagination]> {\n const responseKey = this.#request.responseKey\n\n if (responseKey == null) {\n throw new Error('Cannot paginate a response without a responseKey')\n }\n\n const request = new SeamHttpRequest<TResponse, TResponseKey>(this.#parent, {\n pathname: this.#request.pathname,\n method: this.#request.method,\n responseKey,\n params:\n this.#request.params != null\n ? { ...this.#request.params, page_cursor: nextPageCursor }\n : undefined,\n body:\n this.#request.body != null\n ? { ...this.#request.body, page_cursor: nextPageCursor }\n : undefined,\n })\n\n const response = await request.fetchResponse()\n const data = response[responseKey]\n\n const paginationData =\n response != null &&\n typeof response === 'object' &&\n 'pagination' in response\n ? (response.pagination as PaginationData)\n : null\n\n const pagination: Pagination = {\n hasNextPage: paginationData?.has_next_page ?? false,\n nextPageCursor: paginationData?.next_page_cursor ?? null,\n nextPageUrl: paginationData?.next_page_url ?? null,\n }\n\n if (!Array.isArray(data)) {\n throw new Error(\n `Expected an array response for ${String(responseKey)} but got ${String(typeof data)}`,\n )\n }\n\n return [\n data as EnsureReadonlyArray<TResponse[TResponseKey]>,\n pagination,\n ] as const\n }\n\n async flattenToArray(): Promise<\n EnsureReadonlyArray<TResponse[TResponseKey]>\n > {\n const items = [] as EnsureMutableArray<TResponse[TResponseKey]>\n let [current, pagination] = await this.firstPage()\n items.push(...current)\n while (pagination.hasNextPage) {\n ;[current, pagination] = await this.nextPage(pagination.nextPageCursor)\n items.push(...current)\n }\n return items as EnsureReadonlyArray<TResponse[TResponseKey]>\n }\n\n async *flatten(): AsyncGenerator<\n EnsureReadonlyArray<TResponse[TResponseKey]>\n > {\n let [current, pagination] = await this.firstPage()\n for (const item of current) {\n yield item\n }\n while (pagination.hasNextPage) {\n ;[current, pagination] = await this.nextPage(pagination.nextPageCursor)\n for (const item of current) {\n yield item\n }\n }\n }\n\n async *[Symbol.asyncIterator](): AsyncGenerator<\n EnsureReadonlyArray<TResponse[TResponseKey]>\n > {\n let [current, pagination] = await this.firstPage()\n yield current\n while (pagination.hasNextPage) {\n ;[current, pagination] = await this.nextPage(pagination.nextPageCursor)\n yield current\n }\n }\n}\n\ntype EnsureReadonlyArray<T> = T extends readonly any[] ? T : never\ntype EnsureMutableArray<T> = T extends any[] ? T : never\n\ninterface PaginationData {\n has_next_page: boolean\n next_page_cursor: PageCursor | null\n next_page_url: string | null\n}\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpClientSessions {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpClientSessions> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpClientSessions.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpClientSessions.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpClientSessions {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpClientSessions(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ClientSessionsCreateBody,\n ): SeamHttpRequest<ClientSessionsCreateResponse, 'client_session'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/create',\n method: 'PUT',\n body,\n responseKey: 'client_session',\n })\n }\n\n delete(\n params?: ClientSessionsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: ClientSessionsGetParams,\n ): SeamHttpRequest<ClientSessionsGetResponse, 'client_session'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/get',\n method: 'POST',\n body: params,\n responseKey: 'client_session',\n })\n }\n\n getOrCreate(\n body?: ClientSessionsGetOrCreateBody,\n ): SeamHttpRequest<ClientSessionsGetOrCreateResponse, 'client_session'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/get_or_create',\n method: 'POST',\n body,\n responseKey: 'client_session',\n })\n }\n\n grantAccess(\n body?: ClientSessionsGrantAccessBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/grant_access',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n\n list(\n params?: ClientSessionsListParams,\n ): SeamHttpRequest<ClientSessionsListResponse, 'client_sessions'> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/list',\n method: 'POST',\n body: params,\n responseKey: 'client_sessions',\n })\n }\n\n revoke(body?: ClientSessionsRevokeBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/client_sessions/revoke',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ClientSessionsCreateBody =\n RouteRequestBody<'/client_sessions/create'>\n\nexport type ClientSessionsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/create'>>\n>\n\nexport type ClientSessionsCreateOptions = never\n\nexport type ClientSessionsDeleteParams =\n RouteRequestBody<'/client_sessions/delete'>\n\nexport type ClientSessionsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/delete'>>\n>\n\nexport type ClientSessionsDeleteOptions = never\n\nexport type ClientSessionsGetParams = RouteRequestBody<'/client_sessions/get'>\n\nexport type ClientSessionsGetResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/get'>>\n>\n\nexport type ClientSessionsGetOptions = never\n\nexport type ClientSessionsGetOrCreateBody =\n RouteRequestBody<'/client_sessions/get_or_create'>\n\nexport type ClientSessionsGetOrCreateResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/get_or_create'>>\n>\n\nexport type ClientSessionsGetOrCreateOptions = never\n\nexport type ClientSessionsGrantAccessBody =\n RouteRequestBody<'/client_sessions/grant_access'>\n\nexport type ClientSessionsGrantAccessResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/grant_access'>>\n>\n\nexport type ClientSessionsGrantAccessOptions = never\n\nexport type ClientSessionsListParams = RouteRequestBody<'/client_sessions/list'>\n\nexport type ClientSessionsListResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/list'>>\n>\n\nexport type ClientSessionsListOptions = never\n\nexport type ClientSessionsRevokeBody =\n RouteRequestBody<'/client_sessions/revoke'>\n\nexport type ClientSessionsRevokeResponse = SetNonNullable<\n Required<RouteResponse<'/client_sessions/revoke'>>\n>\n\nexport type ClientSessionsRevokeOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAccessCodesSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessCodesSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAccessCodesSimulate.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessCodesSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n createUnmanagedAccessCode(\n body?: AccessCodesSimulateCreateUnmanagedAccessCodeBody,\n ): SeamHttpRequest<\n AccessCodesSimulateCreateUnmanagedAccessCodeResponse,\n 'access_code'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/simulate/create_unmanaged_access_code',\n method: 'POST',\n body,\n responseKey: 'access_code',\n })\n }\n}\n\nexport type AccessCodesSimulateCreateUnmanagedAccessCodeBody =\n RouteRequestBody<'/access_codes/simulate/create_unmanaged_access_code'>\n\nexport type AccessCodesSimulateCreateUnmanagedAccessCodeResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/access_codes/simulate/create_unmanaged_access_code'>\n >\n >\n\nexport type AccessCodesSimulateCreateUnmanagedAccessCodeOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAccessCodesUnmanaged {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessCodesUnmanaged> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAccessCodesUnmanaged.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessCodesUnmanaged.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodesUnmanaged {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodesUnmanaged(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n convertToManaged(\n body?: AccessCodesUnmanagedConvertToManagedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/convert_to_managed',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n\n delete(\n params?: AccessCodesUnmanagedDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: AccessCodesUnmanagedGetParams,\n ): SeamHttpRequest<AccessCodesUnmanagedGetResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/get',\n method: 'POST',\n body: params,\n responseKey: 'access_code',\n })\n }\n\n list(\n params?: AccessCodesUnmanagedListParams,\n ): SeamHttpRequest<AccessCodesUnmanagedListResponse, 'access_codes'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/list',\n method: 'POST',\n body: params,\n responseKey: 'access_codes',\n })\n }\n\n update(\n body?: AccessCodesUnmanagedUpdateBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/unmanaged/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AccessCodesUnmanagedConvertToManagedBody =\n RouteRequestBody<'/access_codes/unmanaged/convert_to_managed'>\n\nexport type AccessCodesUnmanagedConvertToManagedResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/convert_to_managed'>>\n>\n\nexport type AccessCodesUnmanagedConvertToManagedOptions = never\n\nexport type AccessCodesUnmanagedDeleteParams =\n RouteRequestBody<'/access_codes/unmanaged/delete'>\n\nexport type AccessCodesUnmanagedDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/delete'>>\n>\n\nexport type AccessCodesUnmanagedDeleteOptions = never\n\nexport type AccessCodesUnmanagedGetParams =\n RouteRequestBody<'/access_codes/unmanaged/get'>\n\nexport type AccessCodesUnmanagedGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/get'>>\n>\n\nexport type AccessCodesUnmanagedGetOptions = never\n\nexport type AccessCodesUnmanagedListParams =\n RouteRequestBody<'/access_codes/unmanaged/list'>\n\nexport type AccessCodesUnmanagedListResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/list'>>\n>\n\nexport type AccessCodesUnmanagedListOptions = never\n\nexport type AccessCodesUnmanagedUpdateBody =\n RouteRequestBody<'/access_codes/unmanaged/update'>\n\nexport type AccessCodesUnmanagedUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/unmanaged/update'>>\n>\n\nexport type AccessCodesUnmanagedUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpAccessCodesSimulate } from './simulate/index.js'\nimport { SeamHttpAccessCodesUnmanaged } from './unmanaged/index.js'\n\nexport class SeamHttpAccessCodes {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessCodes> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAccessCodes.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessCodes.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessCodes {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessCodes(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get simulate(): SeamHttpAccessCodesSimulate {\n return SeamHttpAccessCodesSimulate.fromClient(this.client, this.defaults)\n }\n\n get unmanaged(): SeamHttpAccessCodesUnmanaged {\n return SeamHttpAccessCodesUnmanaged.fromClient(this.client, this.defaults)\n }\n\n create(\n body?: AccessCodesCreateBody,\n ): SeamHttpRequest<AccessCodesCreateResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/create',\n method: 'POST',\n body,\n responseKey: 'access_code',\n })\n }\n\n createMultiple(\n body?: AccessCodesCreateMultipleBody,\n ): SeamHttpRequest<AccessCodesCreateMultipleResponse, 'access_codes'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/create_multiple',\n method: 'PUT',\n body,\n responseKey: 'access_codes',\n })\n }\n\n delete(params?: AccessCodesDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n generateCode(\n params?: AccessCodesGenerateCodeParams,\n ): SeamHttpRequest<AccessCodesGenerateCodeResponse, 'generated_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/generate_code',\n method: 'POST',\n body: params,\n responseKey: 'generated_code',\n })\n }\n\n get(\n params?: AccessCodesGetParams,\n ): SeamHttpRequest<AccessCodesGetResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/get',\n method: 'POST',\n body: params,\n responseKey: 'access_code',\n })\n }\n\n list(\n params?: AccessCodesListParams,\n ): SeamHttpRequest<AccessCodesListResponse, 'access_codes'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/list',\n method: 'POST',\n body: params,\n responseKey: 'access_codes',\n })\n }\n\n pullBackupAccessCode(\n body?: AccessCodesPullBackupAccessCodeBody,\n ): SeamHttpRequest<AccessCodesPullBackupAccessCodeResponse, 'access_code'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/pull_backup_access_code',\n method: 'POST',\n body,\n responseKey: 'access_code',\n })\n }\n\n reportDeviceConstraints(\n body?: AccessCodesReportDeviceConstraintsBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/report_device_constraints',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: AccessCodesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/update',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n updateMultiple(\n body?: AccessCodesUpdateMultipleBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_codes/update_multiple',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AccessCodesCreateBody = RouteRequestBody<'/access_codes/create'>\n\nexport type AccessCodesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/create'>>\n>\n\nexport type AccessCodesCreateOptions = never\n\nexport type AccessCodesCreateMultipleBody =\n RouteRequestBody<'/access_codes/create_multiple'>\n\nexport type AccessCodesCreateMultipleResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/create_multiple'>>\n>\n\nexport type AccessCodesCreateMultipleOptions = never\n\nexport type AccessCodesDeleteParams = RouteRequestBody<'/access_codes/delete'>\n\nexport type AccessCodesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/delete'>>\n>\n\nexport type AccessCodesDeleteOptions = never\n\nexport type AccessCodesGenerateCodeParams =\n RouteRequestBody<'/access_codes/generate_code'>\n\nexport type AccessCodesGenerateCodeResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/generate_code'>>\n>\n\nexport type AccessCodesGenerateCodeOptions = never\n\nexport type AccessCodesGetParams = RouteRequestBody<'/access_codes/get'>\n\nexport type AccessCodesGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/get'>>\n>\n\nexport type AccessCodesGetOptions = never\n\nexport type AccessCodesListParams = RouteRequestBody<'/access_codes/list'>\n\nexport type AccessCodesListResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/list'>>\n>\n\nexport type AccessCodesListOptions = never\n\nexport type AccessCodesPullBackupAccessCodeBody =\n RouteRequestBody<'/access_codes/pull_backup_access_code'>\n\nexport type AccessCodesPullBackupAccessCodeResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/pull_backup_access_code'>>\n>\n\nexport type AccessCodesPullBackupAccessCodeOptions = never\n\nexport type AccessCodesReportDeviceConstraintsBody =\n RouteRequestBody<'/access_codes/report_device_constraints'>\n\nexport type AccessCodesReportDeviceConstraintsResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/report_device_constraints'>>\n>\n\nexport type AccessCodesReportDeviceConstraintsOptions = never\n\nexport type AccessCodesUpdateBody = RouteRequestBody<'/access_codes/update'>\n\nexport type AccessCodesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/update'>>\n>\n\nexport type AccessCodesUpdateOptions = never\n\nexport type AccessCodesUpdateMultipleBody =\n RouteRequestBody<'/access_codes/update_multiple'>\n\nexport type AccessCodesUpdateMultipleResponse = SetNonNullable<\n Required<RouteResponse<'/access_codes/update_multiple'>>\n>\n\nexport type AccessCodesUpdateMultipleOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAccessGrants {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessGrants> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAccessGrants.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessGrants.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessGrants {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessGrants(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: AccessGrantsCreateBody,\n ): SeamHttpRequest<AccessGrantsCreateResponse, 'access_grant'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/create',\n method: 'POST',\n body,\n responseKey: 'access_grant',\n })\n }\n\n delete(params?: AccessGrantsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: AccessGrantsGetParams,\n ): SeamHttpRequest<AccessGrantsGetResponse, 'access_grant'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/get',\n method: 'POST',\n body: params,\n responseKey: 'access_grant',\n })\n }\n\n list(\n params?: AccessGrantsListParams,\n ): SeamHttpRequest<AccessGrantsListResponse, 'access_grants'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/list',\n method: 'POST',\n body: params,\n responseKey: 'access_grants',\n })\n }\n\n update(body?: AccessGrantsUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_grants/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AccessGrantsCreateBody = RouteRequestBody<'/access_grants/create'>\n\nexport type AccessGrantsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/create'>>\n>\n\nexport type AccessGrantsCreateOptions = never\n\nexport type AccessGrantsDeleteParams = RouteRequestBody<'/access_grants/delete'>\n\nexport type AccessGrantsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/delete'>>\n>\n\nexport type AccessGrantsDeleteOptions = never\n\nexport type AccessGrantsGetParams = RouteRequestBody<'/access_grants/get'>\n\nexport type AccessGrantsGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/get'>>\n>\n\nexport type AccessGrantsGetOptions = never\n\nexport type AccessGrantsListParams = RouteRequestBody<'/access_grants/list'>\n\nexport type AccessGrantsListResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/list'>>\n>\n\nexport type AccessGrantsListOptions = never\n\nexport type AccessGrantsUpdateBody = RouteRequestBody<'/access_grants/update'>\n\nexport type AccessGrantsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/access_grants/update'>>\n>\n\nexport type AccessGrantsUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAccessMethods {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAccessMethods> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAccessMethods.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAccessMethods.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAccessMethods {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAccessMethods(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n delete(params?: AccessMethodsDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/access_methods/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: AccessMethodsGetParams,\n ): SeamHttpRequest<AccessMethodsGetResponse, 'access_method'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_methods/get',\n method: 'POST',\n body: params,\n responseKey: 'access_method',\n })\n }\n\n list(\n params?: AccessMethodsListParams,\n ): SeamHttpRequest<AccessMethodsListResponse, 'access_methods'> {\n return new SeamHttpRequest(this, {\n pathname: '/access_methods/list',\n method: 'POST',\n body: params,\n responseKey: 'access_methods',\n })\n }\n}\n\nexport type AccessMethodsDeleteParams =\n RouteRequestBody<'/access_methods/delete'>\n\nexport type AccessMethodsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/access_methods/delete'>>\n>\n\nexport type AccessMethodsDeleteOptions = never\n\nexport type AccessMethodsGetParams = RouteRequestBody<'/access_methods/get'>\n\nexport type AccessMethodsGetResponse = SetNonNullable<\n Required<RouteResponse<'/access_methods/get'>>\n>\n\nexport type AccessMethodsGetOptions = never\n\nexport type AccessMethodsListParams = RouteRequestBody<'/access_methods/list'>\n\nexport type AccessMethodsListResponse = SetNonNullable<\n Required<RouteResponse<'/access_methods/list'>>\n>\n\nexport type AccessMethodsListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAcsAccessGroups {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsAccessGroups> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsAccessGroups.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsAccessGroups.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsAccessGroups {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsAccessGroups(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n addUser(body?: AcsAccessGroupsAddUserBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/add_user',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n get(\n params?: AcsAccessGroupsGetParams,\n ): SeamHttpRequest<AcsAccessGroupsGetResponse, 'acs_access_group'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/get',\n method: 'POST',\n body: params,\n responseKey: 'acs_access_group',\n })\n }\n\n list(\n params?: AcsAccessGroupsListParams,\n ): SeamHttpRequest<AcsAccessGroupsListResponse, 'acs_access_groups'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/list',\n method: 'POST',\n body: params,\n responseKey: 'acs_access_groups',\n })\n }\n\n listAccessibleEntrances(\n params?: AcsAccessGroupsListAccessibleEntrancesParams,\n ): SeamHttpRequest<\n AcsAccessGroupsListAccessibleEntrancesResponse,\n 'acs_entrances'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/list_accessible_entrances',\n method: 'POST',\n body: params,\n responseKey: 'acs_entrances',\n })\n }\n\n listUsers(\n params?: AcsAccessGroupsListUsersParams,\n ): SeamHttpRequest<AcsAccessGroupsListUsersResponse, 'acs_users'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/list_users',\n method: 'POST',\n body: params,\n responseKey: 'acs_users',\n })\n }\n\n removeUser(\n params?: AcsAccessGroupsRemoveUserParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/access_groups/remove_user',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsAccessGroupsAddUserBody =\n RouteRequestBody<'/acs/access_groups/add_user'>\n\nexport type AcsAccessGroupsAddUserResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/add_user'>>\n>\n\nexport type AcsAccessGroupsAddUserOptions = never\n\nexport type AcsAccessGroupsGetParams =\n RouteRequestBody<'/acs/access_groups/get'>\n\nexport type AcsAccessGroupsGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/get'>>\n>\n\nexport type AcsAccessGroupsGetOptions = never\n\nexport type AcsAccessGroupsListParams =\n RouteRequestBody<'/acs/access_groups/list'>\n\nexport type AcsAccessGroupsListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/list'>>\n>\n\nexport type AcsAccessGroupsListOptions = never\n\nexport type AcsAccessGroupsListAccessibleEntrancesParams =\n RouteRequestBody<'/acs/access_groups/list_accessible_entrances'>\n\nexport type AcsAccessGroupsListAccessibleEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/list_accessible_entrances'>>\n>\n\nexport type AcsAccessGroupsListAccessibleEntrancesOptions = never\n\nexport type AcsAccessGroupsListUsersParams =\n RouteRequestBody<'/acs/access_groups/list_users'>\n\nexport type AcsAccessGroupsListUsersResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/list_users'>>\n>\n\nexport type AcsAccessGroupsListUsersOptions = never\n\nexport type AcsAccessGroupsRemoveUserParams =\n RouteRequestBody<'/acs/access_groups/remove_user'>\n\nexport type AcsAccessGroupsRemoveUserResponse = SetNonNullable<\n Required<RouteResponse<'/acs/access_groups/remove_user'>>\n>\n\nexport type AcsAccessGroupsRemoveUserOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAcsCredentials {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsCredentials> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsCredentials.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsCredentials.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsCredentials {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsCredentials(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n assign(body?: AcsCredentialsAssignBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/assign',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: AcsCredentialsCreateBody,\n ): SeamHttpRequest<AcsCredentialsCreateResponse, 'acs_credential'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/create',\n method: 'POST',\n body,\n responseKey: 'acs_credential',\n })\n }\n\n delete(\n params?: AcsCredentialsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: AcsCredentialsGetParams,\n ): SeamHttpRequest<AcsCredentialsGetResponse, 'acs_credential'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/get',\n method: 'POST',\n body: params,\n responseKey: 'acs_credential',\n })\n }\n\n list(\n params?: AcsCredentialsListParams,\n ): SeamHttpRequest<AcsCredentialsListResponse, 'acs_credentials'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/list',\n method: 'GET',\n params,\n responseKey: 'acs_credentials',\n })\n }\n\n listAccessibleEntrances(\n params?: AcsCredentialsListAccessibleEntrancesParams,\n ): SeamHttpRequest<\n AcsCredentialsListAccessibleEntrancesResponse,\n 'acs_entrances'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/list_accessible_entrances',\n method: 'POST',\n body: params,\n responseKey: 'acs_entrances',\n })\n }\n\n unassign(\n body?: AcsCredentialsUnassignBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/unassign',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: AcsCredentialsUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/credentials/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsCredentialsAssignBody =\n RouteRequestBody<'/acs/credentials/assign'>\n\nexport type AcsCredentialsAssignResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/assign'>>\n>\n\nexport type AcsCredentialsAssignOptions = never\n\nexport type AcsCredentialsCreateBody =\n RouteRequestBody<'/acs/credentials/create'>\n\nexport type AcsCredentialsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/create'>>\n>\n\nexport type AcsCredentialsCreateOptions = never\n\nexport type AcsCredentialsDeleteParams =\n RouteRequestBody<'/acs/credentials/delete'>\n\nexport type AcsCredentialsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/delete'>>\n>\n\nexport type AcsCredentialsDeleteOptions = never\n\nexport type AcsCredentialsGetParams = RouteRequestBody<'/acs/credentials/get'>\n\nexport type AcsCredentialsGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/get'>>\n>\n\nexport type AcsCredentialsGetOptions = never\n\nexport type AcsCredentialsListParams =\n RouteRequestParams<'/acs/credentials/list'>\n\nexport type AcsCredentialsListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/list'>>\n>\n\nexport type AcsCredentialsListOptions = never\n\nexport type AcsCredentialsListAccessibleEntrancesParams =\n RouteRequestBody<'/acs/credentials/list_accessible_entrances'>\n\nexport type AcsCredentialsListAccessibleEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/list_accessible_entrances'>>\n>\n\nexport type AcsCredentialsListAccessibleEntrancesOptions = never\n\nexport type AcsCredentialsUnassignBody =\n RouteRequestBody<'/acs/credentials/unassign'>\n\nexport type AcsCredentialsUnassignResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/unassign'>>\n>\n\nexport type AcsCredentialsUnassignOptions = never\n\nexport type AcsCredentialsUpdateBody =\n RouteRequestBody<'/acs/credentials/update'>\n\nexport type AcsCredentialsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/credentials/update'>>\n>\n\nexport type AcsCredentialsUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAcsEncodersSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsEncodersSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsEncodersSimulate.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsEncodersSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncodersSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncodersSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n nextCredentialEncodeWillFail(\n body?: AcsEncodersSimulateNextCredentialEncodeWillFailBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_encode_will_fail',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n nextCredentialEncodeWillSucceed(\n body?: AcsEncodersSimulateNextCredentialEncodeWillSucceedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_encode_will_succeed',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n nextCredentialScanWillFail(\n body?: AcsEncodersSimulateNextCredentialScanWillFailBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_scan_will_fail',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n nextCredentialScanWillSucceed(\n body?: AcsEncodersSimulateNextCredentialScanWillSucceedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/simulate/next_credential_scan_will_succeed',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillFailBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_encode_will_fail'>\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillFailResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_encode_will_fail'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillFailOptions = never\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillSucceedBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_encode_will_succeed'>\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillSucceedResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_encode_will_succeed'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialEncodeWillSucceedOptions = never\n\nexport type AcsEncodersSimulateNextCredentialScanWillFailBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_scan_will_fail'>\n\nexport type AcsEncodersSimulateNextCredentialScanWillFailResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_scan_will_fail'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialScanWillFailOptions = never\n\nexport type AcsEncodersSimulateNextCredentialScanWillSucceedBody =\n RouteRequestBody<'/acs/encoders/simulate/next_credential_scan_will_succeed'>\n\nexport type AcsEncodersSimulateNextCredentialScanWillSucceedResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/encoders/simulate/next_credential_scan_will_succeed'>\n >\n >\n\nexport type AcsEncodersSimulateNextCredentialScanWillSucceedOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpAcsEncodersSimulate } from './simulate/index.js'\n\nexport class SeamHttpAcsEncoders {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsEncoders> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsEncoders.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsEncoders.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEncoders {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsEncoders(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get simulate(): SeamHttpAcsEncodersSimulate {\n return SeamHttpAcsEncodersSimulate.fromClient(this.client, this.defaults)\n }\n\n encodeAccessMethod(\n body?: AcsEncodersEncodeAccessMethodBody,\n options: AcsEncodersEncodeAccessMethodOptions = {},\n ): SeamHttpRequest<AcsEncodersEncodeAccessMethodResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/encode_access_method',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n encodeCredential(\n body?: AcsEncodersEncodeCredentialBody,\n options: AcsEncodersEncodeCredentialOptions = {},\n ): SeamHttpRequest<AcsEncodersEncodeCredentialResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/encode_credential',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n get(\n params?: AcsEncodersGetParams,\n ): SeamHttpRequest<AcsEncodersGetResponse, 'acs_encoder'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/get',\n method: 'POST',\n body: params,\n responseKey: 'acs_encoder',\n })\n }\n\n list(\n params?: AcsEncodersListParams,\n ): SeamHttpRequest<AcsEncodersListResponse, 'acs_encoders'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/list',\n method: 'GET',\n params,\n responseKey: 'acs_encoders',\n })\n }\n\n scanCredential(\n body?: AcsEncodersScanCredentialBody,\n options: AcsEncodersScanCredentialOptions = {},\n ): SeamHttpRequest<AcsEncodersScanCredentialResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/encoders/scan_credential',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type AcsEncodersEncodeAccessMethodBody =\n RouteRequestBody<'/acs/encoders/encode_access_method'>\n\nexport type AcsEncodersEncodeAccessMethodResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/encode_access_method'>>\n>\n\nexport type AcsEncodersEncodeAccessMethodOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type AcsEncodersEncodeCredentialBody =\n RouteRequestBody<'/acs/encoders/encode_credential'>\n\nexport type AcsEncodersEncodeCredentialResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/encode_credential'>>\n>\n\nexport type AcsEncodersEncodeCredentialOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type AcsEncodersGetParams = RouteRequestBody<'/acs/encoders/get'>\n\nexport type AcsEncodersGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/get'>>\n>\n\nexport type AcsEncodersGetOptions = never\n\nexport type AcsEncodersListParams = RouteRequestParams<'/acs/encoders/list'>\n\nexport type AcsEncodersListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/list'>>\n>\n\nexport type AcsEncodersListOptions = never\n\nexport type AcsEncodersScanCredentialBody =\n RouteRequestBody<'/acs/encoders/scan_credential'>\n\nexport type AcsEncodersScanCredentialResponse = SetNonNullable<\n Required<RouteResponse<'/acs/encoders/scan_credential'>>\n>\n\nexport type AcsEncodersScanCredentialOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAcsEntrances {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsEntrances> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsEntrances.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsEntrances.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsEntrances {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsEntrances(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n params?: AcsEntrancesGetParams,\n ): SeamHttpRequest<AcsEntrancesGetResponse, 'acs_entrance'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/get',\n method: 'POST',\n body: params,\n responseKey: 'acs_entrance',\n })\n }\n\n grantAccess(\n body?: AcsEntrancesGrantAccessBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/grant_access',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n list(\n params?: AcsEntrancesListParams,\n ): SeamHttpRequest<AcsEntrancesListResponse, 'acs_entrances'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/list',\n method: 'POST',\n body: params,\n responseKey: 'acs_entrances',\n })\n }\n\n listCredentialsWithAccess(\n params?: AcsEntrancesListCredentialsWithAccessParams,\n ): SeamHttpRequest<\n AcsEntrancesListCredentialsWithAccessResponse,\n 'acs_credentials'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/entrances/list_credentials_with_access',\n method: 'POST',\n body: params,\n responseKey: 'acs_credentials',\n })\n }\n}\n\nexport type AcsEntrancesGetParams = RouteRequestBody<'/acs/entrances/get'>\n\nexport type AcsEntrancesGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/get'>>\n>\n\nexport type AcsEntrancesGetOptions = never\n\nexport type AcsEntrancesGrantAccessBody =\n RouteRequestBody<'/acs/entrances/grant_access'>\n\nexport type AcsEntrancesGrantAccessResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/grant_access'>>\n>\n\nexport type AcsEntrancesGrantAccessOptions = never\n\nexport type AcsEntrancesListParams = RouteRequestBody<'/acs/entrances/list'>\n\nexport type AcsEntrancesListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/list'>>\n>\n\nexport type AcsEntrancesListOptions = never\n\nexport type AcsEntrancesListCredentialsWithAccessParams =\n RouteRequestBody<'/acs/entrances/list_credentials_with_access'>\n\nexport type AcsEntrancesListCredentialsWithAccessResponse = SetNonNullable<\n Required<RouteResponse<'/acs/entrances/list_credentials_with_access'>>\n>\n\nexport type AcsEntrancesListCredentialsWithAccessOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAcsSystems {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsSystems> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsSystems.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsSystems.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsSystems {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsSystems(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n params?: AcsSystemsGetParams,\n ): SeamHttpRequest<AcsSystemsGetResponse, 'acs_system'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/systems/get',\n method: 'POST',\n body: params,\n responseKey: 'acs_system',\n })\n }\n\n list(\n params?: AcsSystemsListParams,\n ): SeamHttpRequest<AcsSystemsListResponse, 'acs_systems'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/systems/list',\n method: 'POST',\n body: params,\n responseKey: 'acs_systems',\n })\n }\n\n listCompatibleCredentialManagerAcsSystems(\n params?: AcsSystemsListCompatibleCredentialManagerAcsSystemsParams,\n ): SeamHttpRequest<\n AcsSystemsListCompatibleCredentialManagerAcsSystemsResponse,\n 'acs_systems'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/acs/systems/list_compatible_credential_manager_acs_systems',\n method: 'POST',\n body: params,\n responseKey: 'acs_systems',\n })\n }\n}\n\nexport type AcsSystemsGetParams = RouteRequestBody<'/acs/systems/get'>\n\nexport type AcsSystemsGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/systems/get'>>\n>\n\nexport type AcsSystemsGetOptions = never\n\nexport type AcsSystemsListParams = RouteRequestBody<'/acs/systems/list'>\n\nexport type AcsSystemsListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/systems/list'>>\n>\n\nexport type AcsSystemsListOptions = never\n\nexport type AcsSystemsListCompatibleCredentialManagerAcsSystemsParams =\n RouteRequestBody<'/acs/systems/list_compatible_credential_manager_acs_systems'>\n\nexport type AcsSystemsListCompatibleCredentialManagerAcsSystemsResponse =\n SetNonNullable<\n Required<\n RouteResponse<'/acs/systems/list_compatible_credential_manager_acs_systems'>\n >\n >\n\nexport type AcsSystemsListCompatibleCredentialManagerAcsSystemsOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpAcsUsers {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcsUsers> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcsUsers.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcsUsers.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcsUsers {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcsUsers(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n addToAccessGroup(\n body?: AcsUsersAddToAccessGroupBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/add_to_access_group',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: AcsUsersCreateBody,\n ): SeamHttpRequest<AcsUsersCreateResponse, 'acs_user'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/create',\n method: 'POST',\n body,\n responseKey: 'acs_user',\n })\n }\n\n delete(params?: AcsUsersDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: AcsUsersGetParams,\n ): SeamHttpRequest<AcsUsersGetResponse, 'acs_user'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/get',\n method: 'POST',\n body: params,\n responseKey: 'acs_user',\n })\n }\n\n list(\n params?: AcsUsersListParams,\n ): SeamHttpRequest<AcsUsersListResponse, 'acs_users'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/list',\n method: 'POST',\n body: params,\n responseKey: 'acs_users',\n })\n }\n\n listAccessibleEntrances(\n params?: AcsUsersListAccessibleEntrancesParams,\n ): SeamHttpRequest<AcsUsersListAccessibleEntrancesResponse, 'acs_entrances'> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/list_accessible_entrances',\n method: 'POST',\n body: params,\n responseKey: 'acs_entrances',\n })\n }\n\n removeFromAccessGroup(\n params?: AcsUsersRemoveFromAccessGroupParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/remove_from_access_group',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n revokeAccessToAllEntrances(\n body?: AcsUsersRevokeAccessToAllEntrancesBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/revoke_access_to_all_entrances',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n suspend(body?: AcsUsersSuspendBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/suspend',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n unsuspend(body?: AcsUsersUnsuspendBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/unsuspend',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: AcsUsersUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/acs/users/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type AcsUsersAddToAccessGroupBody =\n RouteRequestBody<'/acs/users/add_to_access_group'>\n\nexport type AcsUsersAddToAccessGroupResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/add_to_access_group'>>\n>\n\nexport type AcsUsersAddToAccessGroupOptions = never\n\nexport type AcsUsersCreateBody = RouteRequestBody<'/acs/users/create'>\n\nexport type AcsUsersCreateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/create'>>\n>\n\nexport type AcsUsersCreateOptions = never\n\nexport type AcsUsersDeleteParams = RouteRequestBody<'/acs/users/delete'>\n\nexport type AcsUsersDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/delete'>>\n>\n\nexport type AcsUsersDeleteOptions = never\n\nexport type AcsUsersGetParams = RouteRequestBody<'/acs/users/get'>\n\nexport type AcsUsersGetResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/get'>>\n>\n\nexport type AcsUsersGetOptions = never\n\nexport type AcsUsersListParams = RouteRequestBody<'/acs/users/list'>\n\nexport type AcsUsersListResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/list'>>\n>\n\nexport type AcsUsersListOptions = never\n\nexport type AcsUsersListAccessibleEntrancesParams =\n RouteRequestBody<'/acs/users/list_accessible_entrances'>\n\nexport type AcsUsersListAccessibleEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/list_accessible_entrances'>>\n>\n\nexport type AcsUsersListAccessibleEntrancesOptions = never\n\nexport type AcsUsersRemoveFromAccessGroupParams =\n RouteRequestBody<'/acs/users/remove_from_access_group'>\n\nexport type AcsUsersRemoveFromAccessGroupResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/remove_from_access_group'>>\n>\n\nexport type AcsUsersRemoveFromAccessGroupOptions = never\n\nexport type AcsUsersRevokeAccessToAllEntrancesBody =\n RouteRequestBody<'/acs/users/revoke_access_to_all_entrances'>\n\nexport type AcsUsersRevokeAccessToAllEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/revoke_access_to_all_entrances'>>\n>\n\nexport type AcsUsersRevokeAccessToAllEntrancesOptions = never\n\nexport type AcsUsersSuspendBody = RouteRequestBody<'/acs/users/suspend'>\n\nexport type AcsUsersSuspendResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/suspend'>>\n>\n\nexport type AcsUsersSuspendOptions = never\n\nexport type AcsUsersUnsuspendBody = RouteRequestBody<'/acs/users/unsuspend'>\n\nexport type AcsUsersUnsuspendResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/unsuspend'>>\n>\n\nexport type AcsUsersUnsuspendOptions = never\n\nexport type AcsUsersUpdateBody = RouteRequestBody<'/acs/users/update'>\n\nexport type AcsUsersUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/acs/users/update'>>\n>\n\nexport type AcsUsersUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport type { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\n\nimport { SeamHttpAcsAccessGroups } from './access-groups/index.js'\nimport { SeamHttpAcsCredentials } from './credentials/index.js'\nimport { SeamHttpAcsEncoders } from './encoders/index.js'\nimport { SeamHttpAcsEntrances } from './entrances/index.js'\nimport { SeamHttpAcsSystems } from './systems/index.js'\nimport { SeamHttpAcsUsers } from './users/index.js'\n\nexport class SeamHttpAcs {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpAcs> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpAcs.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpAcs.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpAcs {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpAcs(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get accessGroups(): SeamHttpAcsAccessGroups {\n return SeamHttpAcsAccessGroups.fromClient(this.client, this.defaults)\n }\n\n get credentials(): SeamHttpAcsCredentials {\n return SeamHttpAcsCredentials.fromClient(this.client, this.defaults)\n }\n\n get encoders(): SeamHttpAcsEncoders {\n return SeamHttpAcsEncoders.fromClient(this.client, this.defaults)\n }\n\n get entrances(): SeamHttpAcsEntrances {\n return SeamHttpAcsEntrances.fromClient(this.client, this.defaults)\n }\n\n get systems(): SeamHttpAcsSystems {\n return SeamHttpAcsSystems.fromClient(this.client, this.defaults)\n }\n\n get users(): SeamHttpAcsUsers {\n return SeamHttpAcsUsers.fromClient(this.client, this.defaults)\n }\n}\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpActionAttempts {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpActionAttempts> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpActionAttempts.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpActionAttempts.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpActionAttempts {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpActionAttempts(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n params?: ActionAttemptsGetParams,\n options: ActionAttemptsGetOptions = {},\n ): SeamHttpRequest<ActionAttemptsGetResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/action_attempts/get',\n method: 'POST',\n body: params,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n list(\n params?: ActionAttemptsListParams,\n ): SeamHttpRequest<ActionAttemptsListResponse, 'action_attempts'> {\n return new SeamHttpRequest(this, {\n pathname: '/action_attempts/list',\n method: 'POST',\n body: params,\n responseKey: 'action_attempts',\n })\n }\n}\n\nexport type ActionAttemptsGetParams = RouteRequestBody<'/action_attempts/get'>\n\nexport type ActionAttemptsGetResponse = SetNonNullable<\n Required<RouteResponse<'/action_attempts/get'>>\n>\n\nexport type ActionAttemptsGetOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ActionAttemptsListParams = RouteRequestBody<'/action_attempts/list'>\n\nexport type ActionAttemptsListResponse = SetNonNullable<\n Required<RouteResponse<'/action_attempts/list'>>\n>\n\nexport type ActionAttemptsListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpConnectWebviews {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpConnectWebviews> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpConnectWebviews.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpConnectWebviews.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectWebviews {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpConnectWebviews(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ConnectWebviewsCreateBody,\n ): SeamHttpRequest<ConnectWebviewsCreateResponse, 'connect_webview'> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/create',\n method: 'POST',\n body,\n responseKey: 'connect_webview',\n })\n }\n\n delete(\n params?: ConnectWebviewsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: ConnectWebviewsGetParams,\n ): SeamHttpRequest<ConnectWebviewsGetResponse, 'connect_webview'> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/get',\n method: 'POST',\n body: params,\n responseKey: 'connect_webview',\n })\n }\n\n list(\n params?: ConnectWebviewsListParams,\n ): SeamHttpRequest<ConnectWebviewsListResponse, 'connect_webviews'> {\n return new SeamHttpRequest(this, {\n pathname: '/connect_webviews/list',\n method: 'POST',\n body: params,\n responseKey: 'connect_webviews',\n })\n }\n}\n\nexport type ConnectWebviewsCreateBody =\n RouteRequestBody<'/connect_webviews/create'>\n\nexport type ConnectWebviewsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/create'>>\n>\n\nexport type ConnectWebviewsCreateOptions = never\n\nexport type ConnectWebviewsDeleteParams =\n RouteRequestBody<'/connect_webviews/delete'>\n\nexport type ConnectWebviewsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/delete'>>\n>\n\nexport type ConnectWebviewsDeleteOptions = never\n\nexport type ConnectWebviewsGetParams = RouteRequestBody<'/connect_webviews/get'>\n\nexport type ConnectWebviewsGetResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/get'>>\n>\n\nexport type ConnectWebviewsGetOptions = never\n\nexport type ConnectWebviewsListParams =\n RouteRequestBody<'/connect_webviews/list'>\n\nexport type ConnectWebviewsListResponse = SetNonNullable<\n Required<RouteResponse<'/connect_webviews/list'>>\n>\n\nexport type ConnectWebviewsListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpConnectedAccounts {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpConnectedAccounts> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpConnectedAccounts.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpConnectedAccounts.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpConnectedAccounts {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpConnectedAccounts(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n delete(\n params?: ConnectedAccountsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: ConnectedAccountsGetParams,\n ): SeamHttpRequest<ConnectedAccountsGetResponse, 'connected_account'> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/get',\n method: 'GET',\n params,\n responseKey: 'connected_account',\n })\n }\n\n list(\n params?: ConnectedAccountsListParams,\n ): SeamHttpRequest<ConnectedAccountsListResponse, 'connected_accounts'> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/list',\n method: 'POST',\n body: params,\n responseKey: 'connected_accounts',\n })\n }\n\n sync(body?: ConnectedAccountsSyncBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/sync',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n update(body?: ConnectedAccountsUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/connected_accounts/update',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ConnectedAccountsDeleteParams =\n RouteRequestBody<'/connected_accounts/delete'>\n\nexport type ConnectedAccountsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/delete'>>\n>\n\nexport type ConnectedAccountsDeleteOptions = never\n\nexport type ConnectedAccountsGetParams =\n RouteRequestParams<'/connected_accounts/get'>\n\nexport type ConnectedAccountsGetResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/get'>>\n>\n\nexport type ConnectedAccountsGetOptions = never\n\nexport type ConnectedAccountsListParams =\n RouteRequestBody<'/connected_accounts/list'>\n\nexport type ConnectedAccountsListResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/list'>>\n>\n\nexport type ConnectedAccountsListOptions = never\n\nexport type ConnectedAccountsSyncBody =\n RouteRequestBody<'/connected_accounts/sync'>\n\nexport type ConnectedAccountsSyncResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/sync'>>\n>\n\nexport type ConnectedAccountsSyncOptions = never\n\nexport type ConnectedAccountsUpdateBody =\n RouteRequestBody<'/connected_accounts/update'>\n\nexport type ConnectedAccountsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/connected_accounts/update'>>\n>\n\nexport type ConnectedAccountsUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpDevicesSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpDevicesSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpDevicesSimulate.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpDevicesSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpDevicesSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n connect(body?: DevicesSimulateConnectBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/simulate/connect',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n disconnect(\n body?: DevicesSimulateDisconnectBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/simulate/disconnect',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n remove(\n params?: DevicesSimulateRemoveParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/simulate/remove',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n}\n\nexport type DevicesSimulateConnectBody =\n RouteRequestBody<'/devices/simulate/connect'>\n\nexport type DevicesSimulateConnectResponse = SetNonNullable<\n Required<RouteResponse<'/devices/simulate/connect'>>\n>\n\nexport type DevicesSimulateConnectOptions = never\n\nexport type DevicesSimulateDisconnectBody =\n RouteRequestBody<'/devices/simulate/disconnect'>\n\nexport type DevicesSimulateDisconnectResponse = SetNonNullable<\n Required<RouteResponse<'/devices/simulate/disconnect'>>\n>\n\nexport type DevicesSimulateDisconnectOptions = never\n\nexport type DevicesSimulateRemoveParams =\n RouteRequestBody<'/devices/simulate/remove'>\n\nexport type DevicesSimulateRemoveResponse = SetNonNullable<\n Required<RouteResponse<'/devices/simulate/remove'>>\n>\n\nexport type DevicesSimulateRemoveOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpDevicesUnmanaged {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpDevicesUnmanaged> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpDevicesUnmanaged.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpDevicesUnmanaged.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevicesUnmanaged {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpDevicesUnmanaged(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(\n params?: DevicesUnmanagedGetParams,\n ): SeamHttpRequest<DevicesUnmanagedGetResponse, 'device'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/unmanaged/get',\n method: 'POST',\n body: params,\n responseKey: 'device',\n })\n }\n\n list(\n params?: DevicesUnmanagedListParams,\n ): SeamHttpRequest<DevicesUnmanagedListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/unmanaged/list',\n method: 'POST',\n body: params,\n responseKey: 'devices',\n })\n }\n\n update(body?: DevicesUnmanagedUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/unmanaged/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type DevicesUnmanagedGetParams =\n RouteRequestBody<'/devices/unmanaged/get'>\n\nexport type DevicesUnmanagedGetResponse = SetNonNullable<\n Required<RouteResponse<'/devices/unmanaged/get'>>\n>\n\nexport type DevicesUnmanagedGetOptions = never\n\nexport type DevicesUnmanagedListParams =\n RouteRequestBody<'/devices/unmanaged/list'>\n\nexport type DevicesUnmanagedListResponse = SetNonNullable<\n Required<RouteResponse<'/devices/unmanaged/list'>>\n>\n\nexport type DevicesUnmanagedListOptions = never\n\nexport type DevicesUnmanagedUpdateBody =\n RouteRequestBody<'/devices/unmanaged/update'>\n\nexport type DevicesUnmanagedUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/devices/unmanaged/update'>>\n>\n\nexport type DevicesUnmanagedUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpDevicesSimulate } from './simulate/index.js'\nimport { SeamHttpDevicesUnmanaged } from './unmanaged/index.js'\n\nexport class SeamHttpDevices {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpDevices> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpDevices.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpDevices.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpDevices {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpDevices(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get simulate(): SeamHttpDevicesSimulate {\n return SeamHttpDevicesSimulate.fromClient(this.client, this.defaults)\n }\n\n get unmanaged(): SeamHttpDevicesUnmanaged {\n return SeamHttpDevicesUnmanaged.fromClient(this.client, this.defaults)\n }\n\n get(\n params?: DevicesGetParams,\n ): SeamHttpRequest<DevicesGetResponse, 'device'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/get',\n method: 'POST',\n body: params,\n responseKey: 'device',\n })\n }\n\n list(\n params?: DevicesListParams,\n ): SeamHttpRequest<DevicesListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/list',\n method: 'POST',\n body: params,\n responseKey: 'devices',\n })\n }\n\n listDeviceProviders(\n params?: DevicesListDeviceProvidersParams,\n ): SeamHttpRequest<DevicesListDeviceProvidersResponse, 'device_providers'> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/list_device_providers',\n method: 'POST',\n body: params,\n responseKey: 'device_providers',\n })\n }\n\n update(body?: DevicesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/devices/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type DevicesGetParams = RouteRequestBody<'/devices/get'>\n\nexport type DevicesGetResponse = SetNonNullable<\n Required<RouteResponse<'/devices/get'>>\n>\n\nexport type DevicesGetOptions = never\n\nexport type DevicesListParams = RouteRequestBody<'/devices/list'>\n\nexport type DevicesListResponse = SetNonNullable<\n Required<RouteResponse<'/devices/list'>>\n>\n\nexport type DevicesListOptions = never\n\nexport type DevicesListDeviceProvidersParams =\n RouteRequestBody<'/devices/list_device_providers'>\n\nexport type DevicesListDeviceProvidersResponse = SetNonNullable<\n Required<RouteResponse<'/devices/list_device_providers'>>\n>\n\nexport type DevicesListDeviceProvidersOptions = never\n\nexport type DevicesUpdateBody = RouteRequestBody<'/devices/update'>\n\nexport type DevicesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/devices/update'>>\n>\n\nexport type DevicesUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpEvents {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpEvents> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpEvents.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpEvents.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpEvents {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpEvents(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(params?: EventsGetParams): SeamHttpRequest<EventsGetResponse, 'event'> {\n return new SeamHttpRequest(this, {\n pathname: '/events/get',\n method: 'POST',\n body: params,\n responseKey: 'event',\n })\n }\n\n list(\n params?: EventsListParams,\n ): SeamHttpRequest<EventsListResponse, 'events'> {\n return new SeamHttpRequest(this, {\n pathname: '/events/list',\n method: 'POST',\n body: params,\n responseKey: 'events',\n })\n }\n}\n\nexport type EventsGetParams = RouteRequestBody<'/events/get'>\n\nexport type EventsGetResponse = SetNonNullable<\n Required<RouteResponse<'/events/get'>>\n>\n\nexport type EventsGetOptions = never\n\nexport type EventsListParams = RouteRequestBody<'/events/list'>\n\nexport type EventsListResponse = SetNonNullable<\n Required<RouteResponse<'/events/list'>>\n>\n\nexport type EventsListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpLocks {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpLocks> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpLocks.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpLocks.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpLocks {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpLocks(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get(params?: LocksGetParams): SeamHttpRequest<LocksGetResponse, 'device'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/get',\n method: 'POST',\n body: params,\n responseKey: 'device',\n })\n }\n\n list(\n params?: LocksListParams,\n ): SeamHttpRequest<LocksListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/list',\n method: 'POST',\n body: params,\n responseKey: 'devices',\n })\n }\n\n lockDoor(\n body?: LocksLockDoorBody,\n options: LocksLockDoorOptions = {},\n ): SeamHttpRequest<LocksLockDoorResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/lock_door',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n unlockDoor(\n body?: LocksUnlockDoorBody,\n options: LocksUnlockDoorOptions = {},\n ): SeamHttpRequest<LocksUnlockDoorResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/locks/unlock_door',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type LocksGetParams = RouteRequestBody<'/locks/get'>\n\nexport type LocksGetResponse = SetNonNullable<\n Required<RouteResponse<'/locks/get'>>\n>\n\nexport type LocksGetOptions = never\n\nexport type LocksListParams = RouteRequestBody<'/locks/list'>\n\nexport type LocksListResponse = SetNonNullable<\n Required<RouteResponse<'/locks/list'>>\n>\n\nexport type LocksListOptions = never\n\nexport type LocksLockDoorBody = RouteRequestBody<'/locks/lock_door'>\n\nexport type LocksLockDoorResponse = SetNonNullable<\n Required<RouteResponse<'/locks/lock_door'>>\n>\n\nexport type LocksLockDoorOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type LocksUnlockDoorBody = RouteRequestBody<'/locks/unlock_door'>\n\nexport type LocksUnlockDoorResponse = SetNonNullable<\n Required<RouteResponse<'/locks/unlock_door'>>\n>\n\nexport type LocksUnlockDoorOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpNoiseSensorsNoiseThresholds {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpNoiseSensorsNoiseThresholds> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpNoiseSensorsNoiseThresholds.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpNoiseSensorsNoiseThresholds.fromClientSessionToken(\n token,\n options,\n )\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsNoiseThresholds {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsNoiseThresholds(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: NoiseSensorsNoiseThresholdsCreateBody,\n ): SeamHttpRequest<\n NoiseSensorsNoiseThresholdsCreateResponse,\n 'noise_threshold'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/create',\n method: 'POST',\n body,\n responseKey: 'noise_threshold',\n })\n }\n\n delete(\n params?: NoiseSensorsNoiseThresholdsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: NoiseSensorsNoiseThresholdsGetParams,\n ): SeamHttpRequest<\n NoiseSensorsNoiseThresholdsGetResponse,\n 'noise_threshold'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/get',\n method: 'POST',\n body: params,\n responseKey: 'noise_threshold',\n })\n }\n\n list(\n params?: NoiseSensorsNoiseThresholdsListParams,\n ): SeamHttpRequest<\n NoiseSensorsNoiseThresholdsListResponse,\n 'noise_thresholds'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/list',\n method: 'POST',\n body: params,\n responseKey: 'noise_thresholds',\n })\n }\n\n update(\n body?: NoiseSensorsNoiseThresholdsUpdateBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/noise_thresholds/update',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type NoiseSensorsNoiseThresholdsCreateBody =\n RouteRequestBody<'/noise_sensors/noise_thresholds/create'>\n\nexport type NoiseSensorsNoiseThresholdsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/create'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsCreateOptions = never\n\nexport type NoiseSensorsNoiseThresholdsDeleteParams =\n RouteRequestBody<'/noise_sensors/noise_thresholds/delete'>\n\nexport type NoiseSensorsNoiseThresholdsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/delete'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsDeleteOptions = never\n\nexport type NoiseSensorsNoiseThresholdsGetParams =\n RouteRequestBody<'/noise_sensors/noise_thresholds/get'>\n\nexport type NoiseSensorsNoiseThresholdsGetResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/get'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsGetOptions = never\n\nexport type NoiseSensorsNoiseThresholdsListParams =\n RouteRequestBody<'/noise_sensors/noise_thresholds/list'>\n\nexport type NoiseSensorsNoiseThresholdsListResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/list'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsListOptions = never\n\nexport type NoiseSensorsNoiseThresholdsUpdateBody =\n RouteRequestBody<'/noise_sensors/noise_thresholds/update'>\n\nexport type NoiseSensorsNoiseThresholdsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/noise_thresholds/update'>>\n>\n\nexport type NoiseSensorsNoiseThresholdsUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpNoiseSensorsSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpNoiseSensorsSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpNoiseSensorsSimulate.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpNoiseSensorsSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensorsSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensorsSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n triggerNoiseThreshold(\n body?: NoiseSensorsSimulateTriggerNoiseThresholdBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/simulate/trigger_noise_threshold',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type NoiseSensorsSimulateTriggerNoiseThresholdBody =\n RouteRequestBody<'/noise_sensors/simulate/trigger_noise_threshold'>\n\nexport type NoiseSensorsSimulateTriggerNoiseThresholdResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/simulate/trigger_noise_threshold'>>\n>\n\nexport type NoiseSensorsSimulateTriggerNoiseThresholdOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpNoiseSensorsNoiseThresholds } from './noise-thresholds/index.js'\nimport { SeamHttpNoiseSensorsSimulate } from './simulate/index.js'\n\nexport class SeamHttpNoiseSensors {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpNoiseSensors> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpNoiseSensors.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpNoiseSensors.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpNoiseSensors {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpNoiseSensors(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get noiseThresholds(): SeamHttpNoiseSensorsNoiseThresholds {\n return SeamHttpNoiseSensorsNoiseThresholds.fromClient(\n this.client,\n this.defaults,\n )\n }\n\n get simulate(): SeamHttpNoiseSensorsSimulate {\n return SeamHttpNoiseSensorsSimulate.fromClient(this.client, this.defaults)\n }\n\n list(\n params?: NoiseSensorsListParams,\n ): SeamHttpRequest<NoiseSensorsListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/noise_sensors/list',\n method: 'POST',\n body: params,\n responseKey: 'devices',\n })\n }\n}\n\nexport type NoiseSensorsListParams = RouteRequestBody<'/noise_sensors/list'>\n\nexport type NoiseSensorsListResponse = SetNonNullable<\n Required<RouteResponse<'/noise_sensors/list'>>\n>\n\nexport type NoiseSensorsListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpPhonesSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpPhonesSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpPhonesSimulate.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpPhonesSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhonesSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpPhonesSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n createSandboxPhone(\n params?: PhonesSimulateCreateSandboxPhoneParams,\n ): SeamHttpRequest<PhonesSimulateCreateSandboxPhoneResponse, 'phone'> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/simulate/create_sandbox_phone',\n method: 'POST',\n body: params,\n responseKey: 'phone',\n })\n }\n}\n\nexport type PhonesSimulateCreateSandboxPhoneParams =\n RouteRequestBody<'/phones/simulate/create_sandbox_phone'>\n\nexport type PhonesSimulateCreateSandboxPhoneResponse = SetNonNullable<\n Required<RouteResponse<'/phones/simulate/create_sandbox_phone'>>\n>\n\nexport type PhonesSimulateCreateSandboxPhoneOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpPhonesSimulate } from './simulate/index.js'\n\nexport class SeamHttpPhones {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpPhones> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpPhones.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpPhones.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpPhones {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpPhones(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get simulate(): SeamHttpPhonesSimulate {\n return SeamHttpPhonesSimulate.fromClient(this.client, this.defaults)\n }\n\n deactivate(\n params?: PhonesDeactivateParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/deactivate',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(params?: PhonesGetParams): SeamHttpRequest<PhonesGetResponse, 'phone'> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/get',\n method: 'POST',\n body: params,\n responseKey: 'phone',\n })\n }\n\n list(\n params?: PhonesListParams,\n ): SeamHttpRequest<PhonesListResponse, 'phones'> {\n return new SeamHttpRequest(this, {\n pathname: '/phones/list',\n method: 'POST',\n body: params,\n responseKey: 'phones',\n })\n }\n}\n\nexport type PhonesDeactivateParams = RouteRequestBody<'/phones/deactivate'>\n\nexport type PhonesDeactivateResponse = SetNonNullable<\n Required<RouteResponse<'/phones/deactivate'>>\n>\n\nexport type PhonesDeactivateOptions = never\n\nexport type PhonesGetParams = RouteRequestBody<'/phones/get'>\n\nexport type PhonesGetResponse = SetNonNullable<\n Required<RouteResponse<'/phones/get'>>\n>\n\nexport type PhonesGetOptions = never\n\nexport type PhonesListParams = RouteRequestBody<'/phones/list'>\n\nexport type PhonesListResponse = SetNonNullable<\n Required<RouteResponse<'/phones/list'>>\n>\n\nexport type PhonesListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpSpaces {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpSpaces> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpSpaces.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpSpaces.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpSpaces {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpSpaces(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n addAcsEntrances(\n body?: SpacesAddAcsEntrancesBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/add_acs_entrances',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n addDevices(body?: SpacesAddDevicesBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/add_devices',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: SpacesCreateBody,\n ): SeamHttpRequest<SpacesCreateResponse, 'space'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/create',\n method: 'POST',\n body,\n responseKey: 'space',\n })\n }\n\n delete(params?: SpacesDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(params?: SpacesGetParams): SeamHttpRequest<SpacesGetResponse, 'space'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/get',\n method: 'POST',\n body: params,\n responseKey: 'space',\n })\n }\n\n list(\n params?: SpacesListParams,\n ): SeamHttpRequest<SpacesListResponse, 'spaces'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/list',\n method: 'GET',\n params,\n responseKey: 'spaces',\n })\n }\n\n removeAcsEntrances(\n params?: SpacesRemoveAcsEntrancesParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/remove_acs_entrances',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n removeDevices(\n params?: SpacesRemoveDevicesParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/remove_devices',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n update(\n body?: SpacesUpdateBody,\n ): SeamHttpRequest<SpacesUpdateResponse, 'space'> {\n return new SeamHttpRequest(this, {\n pathname: '/spaces/update',\n method: 'PATCH',\n body,\n responseKey: 'space',\n })\n }\n}\n\nexport type SpacesAddAcsEntrancesBody =\n RouteRequestBody<'/spaces/add_acs_entrances'>\n\nexport type SpacesAddAcsEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/add_acs_entrances'>>\n>\n\nexport type SpacesAddAcsEntrancesOptions = never\n\nexport type SpacesAddDevicesBody = RouteRequestBody<'/spaces/add_devices'>\n\nexport type SpacesAddDevicesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/add_devices'>>\n>\n\nexport type SpacesAddDevicesOptions = never\n\nexport type SpacesCreateBody = RouteRequestBody<'/spaces/create'>\n\nexport type SpacesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/create'>>\n>\n\nexport type SpacesCreateOptions = never\n\nexport type SpacesDeleteParams = RouteRequestBody<'/spaces/delete'>\n\nexport type SpacesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/delete'>>\n>\n\nexport type SpacesDeleteOptions = never\n\nexport type SpacesGetParams = RouteRequestBody<'/spaces/get'>\n\nexport type SpacesGetResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/get'>>\n>\n\nexport type SpacesGetOptions = never\n\nexport type SpacesListParams = RouteRequestParams<'/spaces/list'>\n\nexport type SpacesListResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/list'>>\n>\n\nexport type SpacesListOptions = never\n\nexport type SpacesRemoveAcsEntrancesParams =\n RouteRequestBody<'/spaces/remove_acs_entrances'>\n\nexport type SpacesRemoveAcsEntrancesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/remove_acs_entrances'>>\n>\n\nexport type SpacesRemoveAcsEntrancesOptions = never\n\nexport type SpacesRemoveDevicesParams =\n RouteRequestBody<'/spaces/remove_devices'>\n\nexport type SpacesRemoveDevicesResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/remove_devices'>>\n>\n\nexport type SpacesRemoveDevicesOptions = never\n\nexport type SpacesUpdateBody = RouteRequestBody<'/spaces/update'>\n\nexport type SpacesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/spaces/update'>>\n>\n\nexport type SpacesUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpThermostatsDailyPrograms {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostatsDailyPrograms> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpThermostatsDailyPrograms.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostatsDailyPrograms.fromClientSessionToken(\n token,\n options,\n )\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsDailyPrograms {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsDailyPrograms(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ThermostatsDailyProgramsCreateBody,\n ): SeamHttpRequest<\n ThermostatsDailyProgramsCreateResponse,\n 'thermostat_daily_program'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/daily_programs/create',\n method: 'POST',\n body,\n responseKey: 'thermostat_daily_program',\n })\n }\n\n delete(\n params?: ThermostatsDailyProgramsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/daily_programs/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n update(\n body?: ThermostatsDailyProgramsUpdateBody,\n options: ThermostatsDailyProgramsUpdateOptions = {},\n ): SeamHttpRequest<ThermostatsDailyProgramsUpdateResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/daily_programs/update',\n method: 'PATCH',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type ThermostatsDailyProgramsCreateBody =\n RouteRequestBody<'/thermostats/daily_programs/create'>\n\nexport type ThermostatsDailyProgramsCreateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/daily_programs/create'>>\n>\n\nexport type ThermostatsDailyProgramsCreateOptions = never\n\nexport type ThermostatsDailyProgramsDeleteParams =\n RouteRequestBody<'/thermostats/daily_programs/delete'>\n\nexport type ThermostatsDailyProgramsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/daily_programs/delete'>>\n>\n\nexport type ThermostatsDailyProgramsDeleteOptions = never\n\nexport type ThermostatsDailyProgramsUpdateBody =\n RouteRequestBody<'/thermostats/daily_programs/update'>\n\nexport type ThermostatsDailyProgramsUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/daily_programs/update'>>\n>\n\nexport type ThermostatsDailyProgramsUpdateOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpThermostatsSchedules {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostatsSchedules> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpThermostatsSchedules.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostatsSchedules.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSchedules {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSchedules(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: ThermostatsSchedulesCreateBody,\n ): SeamHttpRequest<\n ThermostatsSchedulesCreateResponse,\n 'thermostat_schedule'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/create',\n method: 'POST',\n body,\n responseKey: 'thermostat_schedule',\n })\n }\n\n delete(\n params?: ThermostatsSchedulesDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: ThermostatsSchedulesGetParams,\n ): SeamHttpRequest<ThermostatsSchedulesGetResponse, 'thermostat_schedule'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/get',\n method: 'POST',\n body: params,\n responseKey: 'thermostat_schedule',\n })\n }\n\n list(\n params?: ThermostatsSchedulesListParams,\n ): SeamHttpRequest<ThermostatsSchedulesListResponse, 'thermostat_schedules'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/list',\n method: 'POST',\n body: params,\n responseKey: 'thermostat_schedules',\n })\n }\n\n update(\n body?: ThermostatsSchedulesUpdateBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/schedules/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ThermostatsSchedulesCreateBody =\n RouteRequestBody<'/thermostats/schedules/create'>\n\nexport type ThermostatsSchedulesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/create'>>\n>\n\nexport type ThermostatsSchedulesCreateOptions = never\n\nexport type ThermostatsSchedulesDeleteParams =\n RouteRequestBody<'/thermostats/schedules/delete'>\n\nexport type ThermostatsSchedulesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/delete'>>\n>\n\nexport type ThermostatsSchedulesDeleteOptions = never\n\nexport type ThermostatsSchedulesGetParams =\n RouteRequestBody<'/thermostats/schedules/get'>\n\nexport type ThermostatsSchedulesGetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/get'>>\n>\n\nexport type ThermostatsSchedulesGetOptions = never\n\nexport type ThermostatsSchedulesListParams =\n RouteRequestBody<'/thermostats/schedules/list'>\n\nexport type ThermostatsSchedulesListResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/list'>>\n>\n\nexport type ThermostatsSchedulesListOptions = never\n\nexport type ThermostatsSchedulesUpdateBody =\n RouteRequestBody<'/thermostats/schedules/update'>\n\nexport type ThermostatsSchedulesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/schedules/update'>>\n>\n\nexport type ThermostatsSchedulesUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpThermostatsSimulate {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostatsSimulate> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpThermostatsSimulate.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostatsSimulate.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostatsSimulate {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostatsSimulate(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n hvacModeAdjusted(\n body?: ThermostatsSimulateHvacModeAdjustedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/simulate/hvac_mode_adjusted',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n temperatureReached(\n body?: ThermostatsSimulateTemperatureReachedBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/simulate/temperature_reached',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type ThermostatsSimulateHvacModeAdjustedBody =\n RouteRequestBody<'/thermostats/simulate/hvac_mode_adjusted'>\n\nexport type ThermostatsSimulateHvacModeAdjustedResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/simulate/hvac_mode_adjusted'>>\n>\n\nexport type ThermostatsSimulateHvacModeAdjustedOptions = never\n\nexport type ThermostatsSimulateTemperatureReachedBody =\n RouteRequestBody<'/thermostats/simulate/temperature_reached'>\n\nexport type ThermostatsSimulateTemperatureReachedResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/simulate/temperature_reached'>>\n>\n\nexport type ThermostatsSimulateTemperatureReachedOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpThermostatsDailyPrograms } from './daily-programs/index.js'\nimport { SeamHttpThermostatsSchedules } from './schedules/index.js'\nimport { SeamHttpThermostatsSimulate } from './simulate/index.js'\n\nexport class SeamHttpThermostats {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpThermostats> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpThermostats.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpThermostats.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpThermostats {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpThermostats(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get dailyPrograms(): SeamHttpThermostatsDailyPrograms {\n return SeamHttpThermostatsDailyPrograms.fromClient(\n this.client,\n this.defaults,\n )\n }\n\n get schedules(): SeamHttpThermostatsSchedules {\n return SeamHttpThermostatsSchedules.fromClient(this.client, this.defaults)\n }\n\n get simulate(): SeamHttpThermostatsSimulate {\n return SeamHttpThermostatsSimulate.fromClient(this.client, this.defaults)\n }\n\n activateClimatePreset(\n body?: ThermostatsActivateClimatePresetBody,\n options: ThermostatsActivateClimatePresetOptions = {},\n ): SeamHttpRequest<\n ThermostatsActivateClimatePresetResponse,\n 'action_attempt'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/activate_climate_preset',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n cool(\n body?: ThermostatsCoolBody,\n options: ThermostatsCoolOptions = {},\n ): SeamHttpRequest<ThermostatsCoolResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/cool',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n createClimatePreset(\n body?: ThermostatsCreateClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/create_climate_preset',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n deleteClimatePreset(\n params?: ThermostatsDeleteClimatePresetParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/delete_climate_preset',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n heat(\n body?: ThermostatsHeatBody,\n options: ThermostatsHeatOptions = {},\n ): SeamHttpRequest<ThermostatsHeatResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/heat',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n heatCool(\n body?: ThermostatsHeatCoolBody,\n options: ThermostatsHeatCoolOptions = {},\n ): SeamHttpRequest<ThermostatsHeatCoolResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/heat_cool',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n list(\n params?: ThermostatsListParams,\n ): SeamHttpRequest<ThermostatsListResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/list',\n method: 'POST',\n body: params,\n responseKey: 'devices',\n })\n }\n\n off(\n body?: ThermostatsOffBody,\n options: ThermostatsOffOptions = {},\n ): SeamHttpRequest<ThermostatsOffResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/off',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n setFallbackClimatePreset(\n body?: ThermostatsSetFallbackClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_fallback_climate_preset',\n method: 'POST',\n body,\n responseKey: undefined,\n })\n }\n\n setFanMode(\n body?: ThermostatsSetFanModeBody,\n options: ThermostatsSetFanModeOptions = {},\n ): SeamHttpRequest<ThermostatsSetFanModeResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_fan_mode',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n setHvacMode(\n body?: ThermostatsSetHvacModeBody,\n options: ThermostatsSetHvacModeOptions = {},\n ): SeamHttpRequest<ThermostatsSetHvacModeResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_hvac_mode',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n setTemperatureThreshold(\n body?: ThermostatsSetTemperatureThresholdBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/set_temperature_threshold',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n\n updateClimatePreset(\n body?: ThermostatsUpdateClimatePresetBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/update_climate_preset',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n\n updateWeeklyProgram(\n body?: ThermostatsUpdateWeeklyProgramBody,\n options: ThermostatsUpdateWeeklyProgramOptions = {},\n ): SeamHttpRequest<ThermostatsUpdateWeeklyProgramResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/thermostats/update_weekly_program',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n}\n\nexport type ThermostatsActivateClimatePresetBody =\n RouteRequestBody<'/thermostats/activate_climate_preset'>\n\nexport type ThermostatsActivateClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/activate_climate_preset'>>\n>\n\nexport type ThermostatsActivateClimatePresetOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsCoolBody = RouteRequestBody<'/thermostats/cool'>\n\nexport type ThermostatsCoolResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/cool'>>\n>\n\nexport type ThermostatsCoolOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsCreateClimatePresetBody =\n RouteRequestBody<'/thermostats/create_climate_preset'>\n\nexport type ThermostatsCreateClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/create_climate_preset'>>\n>\n\nexport type ThermostatsCreateClimatePresetOptions = never\n\nexport type ThermostatsDeleteClimatePresetParams =\n RouteRequestBody<'/thermostats/delete_climate_preset'>\n\nexport type ThermostatsDeleteClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/delete_climate_preset'>>\n>\n\nexport type ThermostatsDeleteClimatePresetOptions = never\n\nexport type ThermostatsHeatBody = RouteRequestBody<'/thermostats/heat'>\n\nexport type ThermostatsHeatResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/heat'>>\n>\n\nexport type ThermostatsHeatOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsHeatCoolBody = RouteRequestBody<'/thermostats/heat_cool'>\n\nexport type ThermostatsHeatCoolResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/heat_cool'>>\n>\n\nexport type ThermostatsHeatCoolOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsListParams = RouteRequestBody<'/thermostats/list'>\n\nexport type ThermostatsListResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/list'>>\n>\n\nexport type ThermostatsListOptions = never\n\nexport type ThermostatsOffBody = RouteRequestBody<'/thermostats/off'>\n\nexport type ThermostatsOffResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/off'>>\n>\n\nexport type ThermostatsOffOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsSetFallbackClimatePresetBody =\n RouteRequestBody<'/thermostats/set_fallback_climate_preset'>\n\nexport type ThermostatsSetFallbackClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_fallback_climate_preset'>>\n>\n\nexport type ThermostatsSetFallbackClimatePresetOptions = never\n\nexport type ThermostatsSetFanModeBody =\n RouteRequestBody<'/thermostats/set_fan_mode'>\n\nexport type ThermostatsSetFanModeResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_fan_mode'>>\n>\n\nexport type ThermostatsSetFanModeOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsSetHvacModeBody =\n RouteRequestBody<'/thermostats/set_hvac_mode'>\n\nexport type ThermostatsSetHvacModeResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_hvac_mode'>>\n>\n\nexport type ThermostatsSetHvacModeOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type ThermostatsSetTemperatureThresholdBody =\n RouteRequestBody<'/thermostats/set_temperature_threshold'>\n\nexport type ThermostatsSetTemperatureThresholdResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/set_temperature_threshold'>>\n>\n\nexport type ThermostatsSetTemperatureThresholdOptions = never\n\nexport type ThermostatsUpdateClimatePresetBody =\n RouteRequestBody<'/thermostats/update_climate_preset'>\n\nexport type ThermostatsUpdateClimatePresetResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/update_climate_preset'>>\n>\n\nexport type ThermostatsUpdateClimatePresetOptions = never\n\nexport type ThermostatsUpdateWeeklyProgramBody =\n RouteRequestBody<'/thermostats/update_weekly_program'>\n\nexport type ThermostatsUpdateWeeklyProgramResponse = SetNonNullable<\n Required<RouteResponse<'/thermostats/update_weekly_program'>>\n>\n\nexport type ThermostatsUpdateWeeklyProgramOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type { RouteRequestBody, RouteResponse } from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpUserIdentitiesEnrollmentAutomations {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpUserIdentitiesEnrollmentAutomations> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpUserIdentitiesEnrollmentAutomations.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpUserIdentitiesEnrollmentAutomations.fromClientSessionToken(\n token,\n options,\n )\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentitiesEnrollmentAutomations {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentitiesEnrollmentAutomations(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n delete(\n params?: UserIdentitiesEnrollmentAutomationsDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: UserIdentitiesEnrollmentAutomationsGetParams,\n ): SeamHttpRequest<\n UserIdentitiesEnrollmentAutomationsGetResponse,\n 'enrollment_automation'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/get',\n method: 'POST',\n body: params,\n responseKey: 'enrollment_automation',\n })\n }\n\n launch(\n body?: UserIdentitiesEnrollmentAutomationsLaunchBody,\n ): SeamHttpRequest<\n UserIdentitiesEnrollmentAutomationsLaunchResponse,\n 'enrollment_automation'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/launch',\n method: 'POST',\n body,\n responseKey: 'enrollment_automation',\n })\n }\n\n list(\n params?: UserIdentitiesEnrollmentAutomationsListParams,\n ): SeamHttpRequest<\n UserIdentitiesEnrollmentAutomationsListResponse,\n 'enrollment_automations'\n > {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/enrollment_automations/list',\n method: 'POST',\n body: params,\n responseKey: 'enrollment_automations',\n })\n }\n}\n\nexport type UserIdentitiesEnrollmentAutomationsDeleteParams =\n RouteRequestBody<'/user_identities/enrollment_automations/delete'>\n\nexport type UserIdentitiesEnrollmentAutomationsDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/delete'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsDeleteOptions = never\n\nexport type UserIdentitiesEnrollmentAutomationsGetParams =\n RouteRequestBody<'/user_identities/enrollment_automations/get'>\n\nexport type UserIdentitiesEnrollmentAutomationsGetResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/get'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsGetOptions = never\n\nexport type UserIdentitiesEnrollmentAutomationsLaunchBody =\n RouteRequestBody<'/user_identities/enrollment_automations/launch'>\n\nexport type UserIdentitiesEnrollmentAutomationsLaunchResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/launch'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsLaunchOptions = never\n\nexport type UserIdentitiesEnrollmentAutomationsListParams =\n RouteRequestBody<'/user_identities/enrollment_automations/list'>\n\nexport type UserIdentitiesEnrollmentAutomationsListResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/enrollment_automations/list'>>\n>\n\nexport type UserIdentitiesEnrollmentAutomationsListOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nimport { SeamHttpUserIdentitiesEnrollmentAutomations } from './enrollment-automations/index.js'\n\nexport class SeamHttpUserIdentities {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpUserIdentities> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpUserIdentities.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpUserIdentities.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpUserIdentities {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpUserIdentities(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get enrollmentAutomations(): SeamHttpUserIdentitiesEnrollmentAutomations {\n return SeamHttpUserIdentitiesEnrollmentAutomations.fromClient(\n this.client,\n this.defaults,\n )\n }\n\n addAcsUser(\n body?: UserIdentitiesAddAcsUserBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/add_acs_user',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n create(\n body?: UserIdentitiesCreateBody,\n ): SeamHttpRequest<UserIdentitiesCreateResponse, 'user_identity'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/create',\n method: 'POST',\n body,\n responseKey: 'user_identity',\n })\n }\n\n delete(\n params?: UserIdentitiesDeleteParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n generateInstantKey(\n body?: UserIdentitiesGenerateInstantKeyBody,\n ): SeamHttpRequest<UserIdentitiesGenerateInstantKeyResponse, 'instant_key'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/generate_instant_key',\n method: 'POST',\n body,\n responseKey: 'instant_key',\n })\n }\n\n get(\n params?: UserIdentitiesGetParams,\n ): SeamHttpRequest<UserIdentitiesGetResponse, 'user_identity'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/get',\n method: 'GET',\n params,\n responseKey: 'user_identity',\n })\n }\n\n grantAccessToDevice(\n body?: UserIdentitiesGrantAccessToDeviceBody,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/grant_access_to_device',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n\n list(\n params?: UserIdentitiesListParams,\n ): SeamHttpRequest<UserIdentitiesListResponse, 'user_identities'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list',\n method: 'POST',\n body: params,\n responseKey: 'user_identities',\n })\n }\n\n listAccessibleDevices(\n params?: UserIdentitiesListAccessibleDevicesParams,\n ): SeamHttpRequest<UserIdentitiesListAccessibleDevicesResponse, 'devices'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list_accessible_devices',\n method: 'POST',\n body: params,\n responseKey: 'devices',\n })\n }\n\n listAcsSystems(\n params?: UserIdentitiesListAcsSystemsParams,\n ): SeamHttpRequest<UserIdentitiesListAcsSystemsResponse, 'acs_systems'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list_acs_systems',\n method: 'POST',\n body: params,\n responseKey: 'acs_systems',\n })\n }\n\n listAcsUsers(\n params?: UserIdentitiesListAcsUsersParams,\n ): SeamHttpRequest<UserIdentitiesListAcsUsersResponse, 'acs_users'> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/list_acs_users',\n method: 'POST',\n body: params,\n responseKey: 'acs_users',\n })\n }\n\n removeAcsUser(\n params?: UserIdentitiesRemoveAcsUserParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/remove_acs_user',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n revokeAccessToDevice(\n params?: UserIdentitiesRevokeAccessToDeviceParams,\n ): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/revoke_access_to_device',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n update(body?: UserIdentitiesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/user_identities/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type UserIdentitiesAddAcsUserBody =\n RouteRequestBody<'/user_identities/add_acs_user'>\n\nexport type UserIdentitiesAddAcsUserResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/add_acs_user'>>\n>\n\nexport type UserIdentitiesAddAcsUserOptions = never\n\nexport type UserIdentitiesCreateBody =\n RouteRequestBody<'/user_identities/create'>\n\nexport type UserIdentitiesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/create'>>\n>\n\nexport type UserIdentitiesCreateOptions = never\n\nexport type UserIdentitiesDeleteParams =\n RouteRequestBody<'/user_identities/delete'>\n\nexport type UserIdentitiesDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/delete'>>\n>\n\nexport type UserIdentitiesDeleteOptions = never\n\nexport type UserIdentitiesGenerateInstantKeyBody =\n RouteRequestBody<'/user_identities/generate_instant_key'>\n\nexport type UserIdentitiesGenerateInstantKeyResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/generate_instant_key'>>\n>\n\nexport type UserIdentitiesGenerateInstantKeyOptions = never\n\nexport type UserIdentitiesGetParams = RouteRequestParams<'/user_identities/get'>\n\nexport type UserIdentitiesGetResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/get'>>\n>\n\nexport type UserIdentitiesGetOptions = never\n\nexport type UserIdentitiesGrantAccessToDeviceBody =\n RouteRequestBody<'/user_identities/grant_access_to_device'>\n\nexport type UserIdentitiesGrantAccessToDeviceResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/grant_access_to_device'>>\n>\n\nexport type UserIdentitiesGrantAccessToDeviceOptions = never\n\nexport type UserIdentitiesListParams = RouteRequestBody<'/user_identities/list'>\n\nexport type UserIdentitiesListResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list'>>\n>\n\nexport type UserIdentitiesListOptions = never\n\nexport type UserIdentitiesListAccessibleDevicesParams =\n RouteRequestBody<'/user_identities/list_accessible_devices'>\n\nexport type UserIdentitiesListAccessibleDevicesResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list_accessible_devices'>>\n>\n\nexport type UserIdentitiesListAccessibleDevicesOptions = never\n\nexport type UserIdentitiesListAcsSystemsParams =\n RouteRequestBody<'/user_identities/list_acs_systems'>\n\nexport type UserIdentitiesListAcsSystemsResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list_acs_systems'>>\n>\n\nexport type UserIdentitiesListAcsSystemsOptions = never\n\nexport type UserIdentitiesListAcsUsersParams =\n RouteRequestBody<'/user_identities/list_acs_users'>\n\nexport type UserIdentitiesListAcsUsersResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/list_acs_users'>>\n>\n\nexport type UserIdentitiesListAcsUsersOptions = never\n\nexport type UserIdentitiesRemoveAcsUserParams =\n RouteRequestBody<'/user_identities/remove_acs_user'>\n\nexport type UserIdentitiesRemoveAcsUserResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/remove_acs_user'>>\n>\n\nexport type UserIdentitiesRemoveAcsUserOptions = never\n\nexport type UserIdentitiesRevokeAccessToDeviceParams =\n RouteRequestBody<'/user_identities/revoke_access_to_device'>\n\nexport type UserIdentitiesRevokeAccessToDeviceResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/revoke_access_to_device'>>\n>\n\nexport type UserIdentitiesRevokeAccessToDeviceOptions = never\n\nexport type UserIdentitiesUpdateBody =\n RouteRequestBody<'/user_identities/update'>\n\nexport type UserIdentitiesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/user_identities/update'>>\n>\n\nexport type UserIdentitiesUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpWebhooks {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpWebhooks> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpWebhooks.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpWebhooks.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpWebhooks {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpWebhooks(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: WebhooksCreateBody,\n ): SeamHttpRequest<WebhooksCreateResponse, 'webhook'> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/create',\n method: 'POST',\n body,\n responseKey: 'webhook',\n })\n }\n\n delete(params?: WebhooksDeleteParams): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/delete',\n method: 'POST',\n body: params,\n responseKey: undefined,\n })\n }\n\n get(\n params?: WebhooksGetParams,\n ): SeamHttpRequest<WebhooksGetResponse, 'webhook'> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/get',\n method: 'POST',\n body: params,\n responseKey: 'webhook',\n })\n }\n\n list(\n params?: WebhooksListParams,\n ): SeamHttpRequest<WebhooksListResponse, 'webhooks'> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/list',\n method: 'GET',\n params,\n responseKey: 'webhooks',\n })\n }\n\n update(body?: WebhooksUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/webhooks/update',\n method: 'PUT',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type WebhooksCreateBody = RouteRequestBody<'/webhooks/create'>\n\nexport type WebhooksCreateResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/create'>>\n>\n\nexport type WebhooksCreateOptions = never\n\nexport type WebhooksDeleteParams = RouteRequestBody<'/webhooks/delete'>\n\nexport type WebhooksDeleteResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/delete'>>\n>\n\nexport type WebhooksDeleteOptions = never\n\nexport type WebhooksGetParams = RouteRequestBody<'/webhooks/get'>\n\nexport type WebhooksGetResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/get'>>\n>\n\nexport type WebhooksGetOptions = never\n\nexport type WebhooksListParams = RouteRequestParams<'/webhooks/list'>\n\nexport type WebhooksListResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/list'>>\n>\n\nexport type WebhooksListOptions = never\n\nexport type WebhooksUpdateBody = RouteRequestBody<'/webhooks/update'>\n\nexport type WebhooksUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/webhooks/update'>>\n>\n\nexport type WebhooksUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport type {\n RouteRequestBody,\n RouteRequestParams,\n RouteResponse,\n} from '@seamapi/types/connect'\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport { SeamHttpClientSessions } from 'lib/seam/connect/routes/client-sessions/index.js'\nimport { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\nimport type { SetNonNullable } from 'lib/types.js'\n\nexport class SeamHttpWorkspaces {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttpWorkspaces> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttpWorkspaces.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttpWorkspaces.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttpWorkspaces {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttpWorkspaces(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n create(\n body?: WorkspacesCreateBody,\n ): SeamHttpRequest<WorkspacesCreateResponse, 'workspace'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/create',\n method: 'POST',\n body,\n responseKey: 'workspace',\n })\n }\n\n get(\n params?: WorkspacesGetParams,\n ): SeamHttpRequest<WorkspacesGetResponse, 'workspace'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/get',\n method: 'GET',\n params,\n responseKey: 'workspace',\n })\n }\n\n list(\n params?: WorkspacesListParams,\n ): SeamHttpRequest<WorkspacesListResponse, 'workspaces'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/list',\n method: 'GET',\n params,\n responseKey: 'workspaces',\n })\n }\n\n resetSandbox(\n body?: WorkspacesResetSandboxBody,\n options: WorkspacesResetSandboxOptions = {},\n ): SeamHttpRequest<WorkspacesResetSandboxResponse, 'action_attempt'> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/reset_sandbox',\n method: 'POST',\n body,\n responseKey: 'action_attempt',\n options,\n })\n }\n\n update(body?: WorkspacesUpdateBody): SeamHttpRequest<void, undefined> {\n return new SeamHttpRequest(this, {\n pathname: '/workspaces/update',\n method: 'PATCH',\n body,\n responseKey: undefined,\n })\n }\n}\n\nexport type WorkspacesCreateBody = RouteRequestBody<'/workspaces/create'>\n\nexport type WorkspacesCreateResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/create'>>\n>\n\nexport type WorkspacesCreateOptions = never\n\nexport type WorkspacesGetParams = RouteRequestParams<'/workspaces/get'>\n\nexport type WorkspacesGetResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/get'>>\n>\n\nexport type WorkspacesGetOptions = never\n\nexport type WorkspacesListParams = RouteRequestParams<'/workspaces/list'>\n\nexport type WorkspacesListResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/list'>>\n>\n\nexport type WorkspacesListOptions = never\n\nexport type WorkspacesResetSandboxBody =\n RouteRequestBody<'/workspaces/reset_sandbox'>\n\nexport type WorkspacesResetSandboxResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/reset_sandbox'>>\n>\n\nexport type WorkspacesResetSandboxOptions = Pick<\n SeamHttpRequestOptions,\n 'waitForActionAttempt'\n>\n\nexport type WorkspacesUpdateBody = RouteRequestBody<'/workspaces/update'>\n\nexport type WorkspacesUpdateResponse = SetNonNullable<\n Required<RouteResponse<'/workspaces/update'>>\n>\n\nexport type WorkspacesUpdateOptions = never\n","/*\n * Automatically generated by codegen/smith.ts.\n * Do not edit this file or add other files to this directory.\n */\n\nimport { seamApiLtsVersion } from 'lib/lts-version.js'\nimport {\n getAuthHeadersForClientSessionToken,\n warnOnInsecureuserIdentifierKey,\n} from 'lib/seam/connect/auth.js'\nimport { type Client, createClient } from 'lib/seam/connect/client.js'\nimport {\n isSeamHttpOptionsWithApiKey,\n isSeamHttpOptionsWithClient,\n isSeamHttpOptionsWithClientSessionToken,\n isSeamHttpOptionsWithConsoleSessionToken,\n isSeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpFromPublishableKeyOptions,\n SeamHttpInvalidOptionsError,\n type SeamHttpOptions,\n type SeamHttpOptionsWithApiKey,\n type SeamHttpOptionsWithClient,\n type SeamHttpOptionsWithClientSessionToken,\n type SeamHttpOptionsWithConsoleSessionToken,\n type SeamHttpOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from 'lib/seam/connect/options.js'\nimport {\n limitToSeamHttpRequestOptions,\n parseOptions,\n} from 'lib/seam/connect/parse-options.js'\nimport type { SeamHttpRequest } from 'lib/seam/connect/seam-http-request.js'\nimport { SeamPaginator } from 'lib/seam/connect/seam-paginator.js'\n\nimport { SeamHttpAccessCodes } from './access-codes/index.js'\nimport { SeamHttpAccessGrants } from './access-grants/index.js'\nimport { SeamHttpAccessMethods } from './access-methods/index.js'\nimport { SeamHttpAcs } from './acs/index.js'\nimport { SeamHttpActionAttempts } from './action-attempts/index.js'\nimport { SeamHttpClientSessions } from './client-sessions/index.js'\nimport { SeamHttpConnectWebviews } from './connect-webviews/index.js'\nimport { SeamHttpConnectedAccounts } from './connected-accounts/index.js'\nimport { SeamHttpDevices } from './devices/index.js'\nimport { SeamHttpEvents } from './events/index.js'\nimport { SeamHttpLocks } from './locks/index.js'\nimport { SeamHttpNoiseSensors } from './noise-sensors/index.js'\nimport { SeamHttpPhones } from './phones/index.js'\nimport { SeamHttpSpaces } from './spaces/index.js'\nimport { SeamHttpThermostats } from './thermostats/index.js'\nimport { SeamHttpUserIdentities } from './user-identities/index.js'\nimport { SeamHttpWebhooks } from './webhooks/index.js'\nimport { SeamHttpWorkspaces } from './workspaces/index.js'\n\nexport class SeamHttp {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n readonly ltsVersion = seamApiLtsVersion\n static ltsVersion = seamApiLtsVersion\n\n constructor(apiKeyOrOptions: string | SeamHttpOptions = {}) {\n const options = parseOptions(apiKeyOrOptions)\n this.client = 'client' in options ? options.client : createClient(options)\n this.defaults = limitToSeamHttpRequestOptions(options)\n }\n\n static fromClient(\n client: SeamHttpOptionsWithClient['client'],\n options: Omit<SeamHttpOptionsWithClient, 'client'> = {},\n ): SeamHttp {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpOptionsWithClient(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing client')\n }\n return new SeamHttp(constructorOptions)\n }\n\n static fromApiKey(\n apiKey: SeamHttpOptionsWithApiKey['apiKey'],\n options: Omit<SeamHttpOptionsWithApiKey, 'apiKey'> = {},\n ): SeamHttp {\n const constructorOptions = { ...options, apiKey }\n if (!isSeamHttpOptionsWithApiKey(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing apiKey')\n }\n return new SeamHttp(constructorOptions)\n }\n\n static fromClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n options: Omit<\n SeamHttpOptionsWithClientSessionToken,\n 'clientSessionToken'\n > = {},\n ): SeamHttp {\n const constructorOptions = { ...options, clientSessionToken }\n if (!isSeamHttpOptionsWithClientSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError('Missing clientSessionToken')\n }\n return new SeamHttp(constructorOptions)\n }\n\n static async fromPublishableKey(\n publishableKey: string,\n userIdentifierKey: string,\n options: SeamHttpFromPublishableKeyOptions = {},\n ): Promise<SeamHttp> {\n warnOnInsecureuserIdentifierKey(userIdentifierKey)\n const clientOptions = parseOptions({ ...options, publishableKey })\n if (isSeamHttpOptionsWithClient(clientOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'The client option cannot be used with SeamHttp.fromPublishableKey',\n )\n }\n const client = createClient(clientOptions)\n const clientSessions = SeamHttpClientSessions.fromClient(client)\n const { token } = await clientSessions.getOrCreate({\n user_identifier_key: userIdentifierKey,\n })\n return SeamHttp.fromClientSessionToken(token, options)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpOptionsWithConsoleSessionToken['consoleSessionToken'],\n workspaceId: SeamHttpOptionsWithConsoleSessionToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithConsoleSessionToken,\n 'consoleSessionToken' | 'workspaceId'\n > = {},\n ): SeamHttp {\n const constructorOptions = { ...options, consoleSessionToken, workspaceId }\n if (!isSeamHttpOptionsWithConsoleSessionToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing consoleSessionToken or workspaceId',\n )\n }\n return new SeamHttp(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpOptionsWithPersonalAccessToken['personalAccessToken'],\n workspaceId: SeamHttpOptionsWithPersonalAccessToken['workspaceId'],\n options: Omit<\n SeamHttpOptionsWithPersonalAccessToken,\n 'personalAccessToken' | 'workspaceId'\n > = {},\n ): SeamHttp {\n const constructorOptions = { ...options, personalAccessToken, workspaceId }\n if (!isSeamHttpOptionsWithPersonalAccessToken(constructorOptions)) {\n throw new SeamHttpInvalidOptionsError(\n 'Missing personalAccessToken or workspaceId',\n )\n }\n return new SeamHttp(constructorOptions)\n }\n\n createPaginator<const TResponse, const TResponseKey extends keyof TResponse>(\n request: SeamHttpRequest<TResponse, TResponseKey>,\n ): SeamPaginator<TResponse, TResponseKey> {\n return new SeamPaginator<TResponse, TResponseKey>(this, request)\n }\n\n async updateClientSessionToken(\n clientSessionToken: SeamHttpOptionsWithClientSessionToken['clientSessionToken'],\n ): Promise<void> {\n const { headers } = this.client.defaults\n const authHeaders = getAuthHeadersForClientSessionToken({\n clientSessionToken,\n })\n for (const key of Object.keys(authHeaders)) {\n if (headers[key] == null) {\n throw new Error(\n 'Cannot update a clientSessionToken on a client created without a clientSessionToken',\n )\n }\n }\n this.client.defaults.headers = { ...headers, ...authHeaders }\n const clientSessions = SeamHttpClientSessions.fromClient(this.client)\n await clientSessions.get()\n }\n\n get accessCodes(): SeamHttpAccessCodes {\n return SeamHttpAccessCodes.fromClient(this.client, this.defaults)\n }\n\n get accessGrants(): SeamHttpAccessGrants {\n return SeamHttpAccessGrants.fromClient(this.client, this.defaults)\n }\n\n get accessMethods(): SeamHttpAccessMethods {\n return SeamHttpAccessMethods.fromClient(this.client, this.defaults)\n }\n\n get acs(): SeamHttpAcs {\n return SeamHttpAcs.fromClient(this.client, this.defaults)\n }\n\n get actionAttempts(): SeamHttpActionAttempts {\n return SeamHttpActionAttempts.fromClient(this.client, this.defaults)\n }\n\n get clientSessions(): SeamHttpClientSessions {\n return SeamHttpClientSessions.fromClient(this.client, this.defaults)\n }\n\n get connectWebviews(): SeamHttpConnectWebviews {\n return SeamHttpConnectWebviews.fromClient(this.client, this.defaults)\n }\n\n get connectedAccounts(): SeamHttpConnectedAccounts {\n return SeamHttpConnectedAccounts.fromClient(this.client, this.defaults)\n }\n\n get devices(): SeamHttpDevices {\n return SeamHttpDevices.fromClient(this.client, this.defaults)\n }\n\n get events(): SeamHttpEvents {\n return SeamHttpEvents.fromClient(this.client, this.defaults)\n }\n\n get locks(): SeamHttpLocks {\n return SeamHttpLocks.fromClient(this.client, this.defaults)\n }\n\n get noiseSensors(): SeamHttpNoiseSensors {\n return SeamHttpNoiseSensors.fromClient(this.client, this.defaults)\n }\n\n get phones(): SeamHttpPhones {\n return SeamHttpPhones.fromClient(this.client, this.defaults)\n }\n\n get spaces(): SeamHttpSpaces {\n return SeamHttpSpaces.fromClient(this.client, this.defaults)\n }\n\n get thermostats(): SeamHttpThermostats {\n return SeamHttpThermostats.fromClient(this.client, this.defaults)\n }\n\n get userIdentities(): SeamHttpUserIdentities {\n return SeamHttpUserIdentities.fromClient(this.client, this.defaults)\n }\n\n get webhooks(): SeamHttpWebhooks {\n return SeamHttpWebhooks.fromClient(this.client, this.defaults)\n }\n\n get workspaces(): SeamHttpWorkspaces {\n return SeamHttpWorkspaces.fromClient(this.client, this.defaults)\n }\n}\n","import { type Client, createClient } from './client.js'\nimport {\n isSeamHttpMultiWorkspaceOptionsWithClient,\n isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n SeamHttpMultiWorkspaceInvalidOptionsError,\n type SeamHttpMultiWorkspaceOptions,\n type SeamHttpMultiWorkspaceOptionsWithClient,\n type SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n type SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n type SeamHttpRequestOptions,\n} from './options.js'\nimport { limitToSeamHttpRequestOptions, parseOptions } from './parse-options.js'\nimport { SeamHttpWorkspaces } from './routes/index.js'\n\nexport class SeamHttpMultiWorkspace {\n client: Client\n readonly defaults: Required<SeamHttpRequestOptions>\n\n constructor(options: SeamHttpMultiWorkspaceOptions = {}) {\n const opts = parseOptions(options)\n this.client = 'client' in opts ? opts.client : createClient(opts)\n this.defaults = limitToSeamHttpRequestOptions(opts)\n }\n\n static fromClient(\n client: SeamHttpMultiWorkspaceOptionsWithClient['client'],\n options: Omit<SeamHttpMultiWorkspaceOptionsWithClient, 'client'> = {},\n ): SeamHttpMultiWorkspace {\n const constructorOptions = { ...options, client }\n if (!isSeamHttpMultiWorkspaceOptionsWithClient(constructorOptions)) {\n throw new SeamHttpMultiWorkspaceInvalidOptionsError('Missing client')\n }\n return new SeamHttpMultiWorkspace(constructorOptions)\n }\n\n static fromConsoleSessionToken(\n consoleSessionToken: SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken['consoleSessionToken'],\n options: Omit<\n SeamHttpMultiWorkspaceOptionsWithConsoleSessionToken,\n 'consoleSessionToken'\n > = {},\n ): SeamHttpMultiWorkspace {\n const constructorOptions = { ...options, consoleSessionToken }\n if (\n !isSeamHttpMultiWorkspaceOptionsWithConsoleSessionToken(\n constructorOptions,\n )\n ) {\n throw new SeamHttpMultiWorkspaceInvalidOptionsError(\n 'Missing consoleSessionToken',\n )\n }\n return new SeamHttpMultiWorkspace(constructorOptions)\n }\n\n static fromPersonalAccessToken(\n personalAccessToken: SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken['personalAccessToken'],\n options: Omit<\n SeamHttpMultiWorkspaceOptionsWithPersonalAccessToken,\n 'personalAccessToken'\n > = {},\n ): SeamHttpMultiWorkspace {\n const constructorOptions = { ...options, personalAccessToken }\n if (\n !isSeamHttpMultiWorkspaceOptionsWithPersonalAccessToken(\n constructorOptions,\n )\n ) {\n throw new SeamHttpMultiWorkspaceInvalidOptionsError(\n 'Missing personalAccessToken',\n )\n }\n return new SeamHttpMultiWorkspace(constructorOptions)\n }\n\n get workspaces(): Pick<SeamHttpWorkspaces, 'create' | 'list'> {\n return SeamHttpWorkspaces.fromClient(this.client, this.defaults)\n }\n}\n"]}
|