export type VagaroCommonModelRequestCustomerRequest = {businessID?: number | undefined, loginUserID?: number | undefined, device?: string | undefined, version?: string | undefined, pageIndex?: number | undefined, pageSize?: number | undefined, deviceID?: string | undefined, osVersion?: string | undefined, groupId?: string | undefined, isGroupWiseCall?: boolean | undefined, isReadOnly?: boolean | undefined, clientId?: string | undefined, clientSecret?: string | undefined, vbi?: string | undefined, vui?: string | undefined, strLoginUserId?: string | undefined, strBusinessId?: string | undefined, enc_BusinessID?: string | undefined, enc_LoginUserID?: string | undefined, userID?: number | undefined, firstName?: string | undefined, lastName?: string | undefined, emailId?: string | undefined, username?: string | undefined, password?: string | undefined, questionId?: number | undefined, answer?: string | undefined, street?: string | undefined, streetNo?: string | undefined, stateID?: number | undefined, city?: string | undefined, zip?: string | undefined, gender?: number | undefined, birthDate?: string | undefined, photo?: string | undefined, dayPhone?: string | undefined, nightPhone?: string | undefined, cell?: string | undefined, userType?: string | undefined, isNotifyBySMS?: boolean | undefined, isNotifyByEmail?: boolean | undefined, isNotifyByBusinessEmail?: boolean | undefined, isNotifyByAllBusinessEmail?: boolean | undefined, isNotifyByPushNotification?: boolean | undefined, businessSummary?: string | undefined, isActive?: boolean | undefined, isFirstTimeCustomer?: boolean | undefined, isEmailSent?: boolean | undefined, mobileProviderID?: number | undefined, showContactInfo?: boolean | undefined, referredBy?: string | undefined, generalTag?: string | undefined, ccUserID?: number | undefined, isSoftDelete?: boolean | undefined, swipeCardID?: string | undefined, countryID?: number | undefined, fbUserID?: string | undefined, createdBy?: number | undefined, createdDate?: string | undefined, modifiedBy?: number | undefined, modifiedDate?: string | undefined, isConsiderForUserBusiness?: boolean | undefined, loginDuration?: number | undefined, adminRoleId?: number | undefined, ipAddress?: string | undefined, containerName?: string | undefined, cdnUrl?: string | undefined, googleUserID?: string | undefined, isFromYelp?: boolean | undefined, height?: number | undefined, width?: number | undefined, isNotifyByAdminEmail?: boolean | undefined, isNotifyByAdminText?: boolean | undefined, isStopNotifyByAdminTextFromTwilio?: boolean | undefined, isFromClass?: boolean | undefined, onlineBookType?: number | undefined, isCellValid?: boolean | undefined, isNotifyByPromotionText?: boolean | undefined, appleUserID?: string | undefined, isNewCustomer?: boolean | undefined, dialingCode?: string | undefined, cellCountryID?: number | undefined, dayPhoneCountryID?: number | undefined, nightPhoneCountryID?: number | undefined, onlineBookTypeAtLocation?: number | undefined, isEmailChecked?: boolean | undefined, userJsonForMasterUser?: string | undefined, patientId?: number | undefined, isScriptSureEnabled?: boolean | undefined}; export type CreateApiGroupApiVVersionCustomerAddupdateusernewArgs = {group: string, version: string, body: VagaroCommonModelRequestCustomerRequest}; export type CreateApiGroupApiVVersionCustomerAddupdateusernewOptions = {baseUrl: string, fetch?: typeof fetch | undefined}; /** * POST /{group}/api/v{version}/customer/addupdateusernew */ export const createApiGroupApiVVersionCustomerAddupdateusernew = async (args: CreateApiGroupApiVVersionCustomerAddupdateusernewArgs, options: CreateApiGroupApiVVersionCustomerAddupdateusernewOptions) => { const {baseUrl, fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() headers.set('content-type', "application/json") const url = `${baseUrl.replace(/\/+$/, '')}/${encodeURIComponent(String(args.group))}/api/v${encodeURIComponent(String(args.version))}/customer/addupdateusernew${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "POST", headers, body: JSON.stringify(args.body)}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return undefined };