Delen via


CallAutomationClient class

Een CallAutomationClient vertegenwoordigt een client naar de Azure Communication CallAutomation-service.

Constructors

CallAutomationClient(string, CallAutomationClientOptions)

Initialiseert een nieuw exemplaar van de klasse CallAutomationClient.

CallAutomationClient(string, TokenCredential | KeyCredential, CallAutomationClientOptions)

Initialiseert een nieuw exemplaar van de klasse CallAutomationClient met behulp van een TokenCredential of KeyCredential.

Methoden

answerCall(string, string, AnswerCallOptions)

Beantwoord het gesprek.

connectCall(CallLocator, string, ConnectCallOptions)

Maak verbinding met een ruimtegesprek.

createCall(CallInvite, string, CreateCallOptions)

Maak een uitgaande aanroep van de bron naar een doelidentiteit.

createGroupCall(CommunicationIdentifier[], string, CreateCallOptions)

Maak een uitgaande aanroep van de bron naar een groep doelenidentiteiten.

getCallConnection(string)

Initialiseert een nieuw exemplaar van CallConnection.

getCallRecording()

Initialiseert een nieuw exemplaar van CallRecording.

getSourceIdentity()

Bronidentiteit ophalen die wordt gebruikt voor het maken en beantwoorden van oproepen

redirectCall(string, CallInvite, OperationOptions)

De oproep omleiden.

rejectCall(string, RejectCallOptions)

Wijs het gesprek af.

Constructordetails

CallAutomationClient(string, CallAutomationClientOptions)

Initialiseert een nieuw exemplaar van de klasse CallAutomationClient.

new CallAutomationClient(connectionString: string, options?: CallAutomationClientOptions)

Parameters

connectionString

string

Verbindingsreeks om verbinding te maken met een Azure Communication Service-resource. Voorbeeld: "endpoint=https://contoso.eastus.communications.azure.net/; accesskey=secret";

options
CallAutomationClientOptions

Facultatief. Opties voor het configureren van de HTTP-pijplijn.

CallAutomationClient(string, TokenCredential | KeyCredential, CallAutomationClientOptions)

Initialiseert een nieuw exemplaar van de klasse CallAutomationClient met behulp van een TokenCredential of KeyCredential.

new CallAutomationClient(endpoint: string, credential: TokenCredential | KeyCredential, options?: CallAutomationClientOptions)

Parameters

endpoint

string

Het eindpunt van de service (bijvoorbeeld: https://contoso.eastus.communications.azure.net).

credential

TokenCredential | KeyCredential

TokenCredential of KeyCredential die wordt gebruikt voor het verifiëren van aanvragen voor de service.

options
CallAutomationClientOptions

Facultatief. Opties voor het configureren van de HTTP-pijplijn.

Methodedetails

answerCall(string, string, AnswerCallOptions)

Beantwoord het gesprek.

function answerCall(incomingCallContext: string, callbackUrl: string, options?: AnswerCallOptions): Promise<CallResult>

Parameters

incomingCallContext

string

De context die aan de aanroep is gekoppeld.

callbackUrl

string

De callback-URL.

options
AnswerCallOptions

Aanvullende aanvraagopties bevatten antwoordCall-API-opties.

Retouren

Promise<CallResult>

connectCall(CallLocator, string, ConnectCallOptions)

Maak verbinding met een ruimtegesprek.

function connectCall(callLocator: CallLocator, callbackUrl: string, options?: ConnectCallOptions): Promise<CallResult>

Parameters

callLocator
CallLocator

Roep locator aan om verbinding te maken.

callbackUrl

string

De callback-URL

options
ConnectCallOptions

Aanvullende aanvraagopties bevatten api-opties voor verbinding maken.

Retouren

Promise<CallResult>

createCall(CallInvite, string, CreateCallOptions)

Maak een uitgaande aanroep van de bron naar een doelidentiteit.

function createCall(targetParticipant: CallInvite, callbackUrl: string, options?: CreateCallOptions): Promise<CallResult>

Parameters

targetParticipant
CallInvite

Eén doel.

callbackUrl

string

De callback-URL.

options
CreateCallOptions

Aanvullende aanvraagopties bevatten api-opties voor createCallConnection.

Retouren

Promise<CallResult>

createGroupCall(CommunicationIdentifier[], string, CreateCallOptions)

Maak een uitgaande aanroep van de bron naar een groep doelenidentiteiten.

function createGroupCall(targetParticipants: CommunicationIdentifier[], callbackUrl: string, options?: CreateCallOptions): Promise<CallResult>

Parameters

targetParticipants

CommunicationIdentifier[]

Een groep doelenidentiteiten.

callbackUrl

string

De callback-URL.

options
CreateCallOptions

Aanvullende aanvraagopties bevatten api-opties voor createCallConnection.

Retouren

Promise<CallResult>

getCallConnection(string)

Initialiseert een nieuw exemplaar van CallConnection.

function getCallConnection(callConnectionId: string): CallConnection

Parameters

callConnectionId

string

De CallConnection-id voor het CallConnection-exemplaar. (bijvoorbeeld: 421CONTOSO-cRD6-4RDc-a078-99dRANDOMf).

Retouren

getCallRecording()

Initialiseert een nieuw exemplaar van CallRecording.

function getCallRecording(): CallRecording

Retouren

getSourceIdentity()

Bronidentiteit ophalen die wordt gebruikt voor het maken en beantwoorden van oproepen

function getSourceIdentity(): undefined | CommunicationUserIdentifier

Retouren

redirectCall(string, CallInvite, OperationOptions)

De oproep omleiden.

function redirectCall(incomingCallContext: string, targetParticipant: CallInvite, options?: OperationOptions): Promise<void>

Parameters

incomingCallContext

string

De context die aan de aanroep is gekoppeld.

targetParticipant
CallInvite

De doelidentiteit om de aanroep om te leiden.

options
OperationOptions

Aanvullende aanvraagopties bevatten omleidings-API-opties.

Retouren

Promise<void>

rejectCall(string, RejectCallOptions)

Wijs het gesprek af.

function rejectCall(incomingCallContext: string, options?: RejectCallOptions): Promise<void>

Parameters

incomingCallContext

string

De context die aan de aanroep is gekoppeld.

options
RejectCallOptions

Aanvullende aanvraagopties bevatten opties voor de rejectCall-API.

Retouren

Promise<void>