Direxion v0.1.3 Client.Custom View Source

A Microsoft Directline Client

Link to this section Summary

Functions

Get the authorization token for bots request

Send an activity through our response handler the response is the Directline reponse

Send an activity to a conversation and return its the Directline reponse

Receive the response from a bot response service

Link to this section Functions

Link to this function get_authorization_token() View Source
get_authorization_token() :: tuple()

Get the authorization token for bots request

Returns a tuple containing the status of request and the conversation ID

Link to this function message(activity) View Source
message(map()) :: map()

Send an activity through our response handler the response is the Directline reponse.

Parameters:

  • input_token - Directline Token to be used, Will be overridden by DIRECTLINE_TOKEN in path if found
  • activity - The activity to send

Returns a Directline Response

Link to this function message_bot(access_token, activity) View Source
message_bot(String.t(), map()) :: map()

Send an activity to a conversation and return its the Directline reponse.

Parameters:

  • access_token - Microsoft Bot framework access token
  • activity - The activity to send

Returns the bot Response

Link to this function receive_response(activity_id) View Source
receive_response(String.t()) :: tuple()

Receive the response from a bot response service.

Parameters:

  • activity_id - The Activity ID we want reponse to

Returns a Response object.

Link to this function send_activity_to_bot(access_token, activity) View Source
send_activity_to_bot(String.t(), map()) :: tuple()

Send an activity to a bot

Parameters:

  • access_token - Microsoft bot authorization token
  • activity - The activity we want reponse to send

Returns the assigned activity id.