Skip to Content
Anuma SDKReactHooksusePhoneCalls

usePhoneCalls

usePhoneCalls(options: object): UsePhoneCallsResult

Defined in: src/react/usePhoneCalls.ts:146 

React hook for phone calling: checking availability, creating calls, fetching their status, and polling for completion.

Parameters

ParameterTypeDescription

options

object

options.autoFetchAvailability?

boolean

Whether to fetch feature availability automatically on mount (default: true)

options.baseUrl?

string

Optional base URL for the API requests.

options.getToken?

() => Promise<string | null>

Custom function to get auth token for API calls

options.onError?

(error: Error) => void

Optional callback for error handling

Returns

UsePhoneCallsResult

Last updated on