/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import { onboardingCreateInvite } from "../funcs/onboardingCreateInvite.js"; import { onboardingGetInvite } from "../funcs/onboardingGetInvite.js"; import { onboardingListInvites } from "../funcs/onboardingListInvites.js"; import { onboardingRevokeInvite } from "../funcs/onboardingRevokeInvite.js"; import { ClientSDK, RequestOptions } from "../lib/sdks.js"; import * as components from "../models/components/index.js"; import * as operations from "../models/operations/index.js"; import { unwrapAsync } from "../types/fp.js"; export class Onboarding extends ClientSDK { /** * Create an invitation containing a unique link that allows the recipient to onboard their organization with Moov. * * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) * you'll need to specify the `/accounts.write` scope. */ async createInvite( request: components.OnboardingInviteRequest, options?: RequestOptions, ): Promise { return unwrapAsync(onboardingCreateInvite( this, request, options, )); } /** * List all the onboarding invites created by the caller's account. * * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) * you'll need to specify the `/accounts.read` scope. */ async listInvites( request: operations.ListOnboardingInvitesRequest, options?: RequestOptions, ): Promise { return unwrapAsync(onboardingListInvites( this, request, options, )); } /** * Retrieve details about an onboarding invite. * * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) * you'll need to specify the `/accounts.read` scope. */ async getInvite( request: operations.GetOnboardingInviteRequest, options?: RequestOptions, ): Promise { return unwrapAsync(onboardingGetInvite( this, request, options, )); } /** * Revoke an onboarding invite, rendering the invitation link unusable. * * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/) * you'll need to specify the `/accounts.write` scope. */ async revokeInvite( request: operations.RevokeOnboardingInviteRequest, options?: RequestOptions, ): Promise { return unwrapAsync(onboardingRevokeInvite( this, request, options, )); } }