Make Call
    • Dark
      Light

    Make Call

    • Dark
      Light

    Article summary

    This API allows an Agent to make a call.

    Pre-requisite

    The agent must be in the LoggedIn state.

    Sequence Diagram

    The following figure illustrates the workflow of make call API:

    Message Structure

    Request Parameters (Phone number as input)

    Value

    channel

    Amazon

    topic

    InboundCall

    subtopic

    SetMakeCall

    source

    «app-name-broadcasting-this-message»

    data

    «Phone number in E.164 format»

    Request Parameters (Direct connect as input)

    Value

    channel

    Amazon

    topic

    InboundCall

    subtopic

    SetMakeCall

    source

    «app-name-broadcasting-this-message»

    data

    Refer Direct Connect Parameters

    Response Parameters

    Value

    channel

    Amazon

    topic

    InboundCall

    subtopic

    InboundCallStateChange

    source

    Refer Call Event Parameters

    Possible Error Codes

    Error Type

    Code

    Error Message

    MAKE_CALL_FAILED

    Amazon Connect Failure Error Message.

    Make call failed.

    Sample Request - Phone Number as Input

    {
        "channel": "Amazon",
        "topic": "InboundCall",
        "subtopic": "SetMakeCall",
        "source": "myapp",
        "data": "+16013261548"
    }

    Sample Request - Direct Connect as Input

    {
        "channel": "Amazon",
        "topic": "InboundCall",
        "subtopic": "SetMakeCall",
        "source": "myapp",
        "data": {
            "endpointARN": "arn:aws:connect:us-east-1:975419294579:instance/edf7c3f1-015b-  
        4cbb-9902-93f 8b293cbec/transfer-destination/dfa1e3e3-5262-46c8-bbee-
        21df70a9eec6",
            "endpointId": "arn:aws:connect:us-east-1:975419294579:instance/edf7c3f1-015b-
        4cbb-9902-93f8b 293cbec/transfer-destination/dfa1e3e3-5262-46c8-bbee-
        21df70a9eec6",
            "type": "phone_number",
            "name": "TestExternal",
            "phoneNumber": "+16013261548",
            "agentLogin": null,
            "queue": null
        }
    }

    Sample Response - Call Type: Agent

    {
        "channel": "Amazon",
        "topic": "InboundCall",
        "subtopic": "InboundCallStateChange",
        "message": {
            "call": {
                "ButtonStates": {
                    "items": {
                        "answer": "Hide",
                        "reject": "Hide",
                        "disconnect": "Hide",
                        "hold": "Hide",
                        "resume": "Hide",
                        "clearContact": "Hide",
                        "consult": "Hide",
                        "numberpad": "Hide",
                        "swap": "Hide"
                 "transfer": "Hide",
                        "conference": "Hide"
                    },
                    "count": 11
                },
                "ActionsAllowed": null,
                "ResponseType": 0,
                "ResponseText": "Success",
                "ResponseActual": {
                    "connectionId": "6c87f81e-9add-4360-87bf-9c0f2211acf7",
                    "contactId": "f242e8f2-035e-4859-b1bf-2b819a25d41d",
                    "phoneNumber": null,
                    "status": "connecting",
                    "statusTimestamp": "2020-04-09T13:14:45.311Z",
                    "type": "agent",
                    "buttonStates": {
                        "answer": false,
                        "reject": false,
                        "disconnect": false,
                        "hold": false,
                        "resume": false,
                        "clearContact": false,
                        "consult": false,
                        "numberpad": false,
                        "swap": false,
                        "transfer": false,
                        "conference": false
                    }
                },
                "CallVariables": {},
                "ExtendedCallVariables": null,
                "ResponseFields": {
                    "Participants": [],
                    "MediaProperties": {
                        "callType": "agent",
                        "queueName": "BasicQueue",
                        "queueTimestamp": "2020-04-09T13:14:45.312Z"
                    },
                    "fromAddress": null,
                    "CallState": "connecting",
                    "Type": "agent",
                    "CurrentStateTime": "2020-04-09T13:14:45.311Z",
                    "Campaign": "",
                    "DN": "BasicQueue"
                },
                "id": "6c87f81e-9add-4360-87bf-9c0f2211acf7",
                "event": "connecting",
                "CallType": "agent"
            },
            "source": "event"
        }
    }

    Sample Response - Call Type: Outbound

    {
        "channel": "Amazon",
        "topic": "InboundCall",
        "subtopic": "InboundCallStateChange",
        "message": {
            "call": {
                "ButtonStates": {
                    "items": {
                        "answer": "Hide",
                        "reject": "Hide",
                        "disconnect": "Enable",
                        "hold": "Hide",
                        "resume": "Hide",
                        "clearContact": "Hide",
                        "consult": "Hide",
                        "numberpad": "Hide",
                        "swap": "Hide",
                        "transfer": "Hide",
                        "conference": "Hide"
                    },
                    "count": 11
                },
                "ActionsAllowed": null,
                "ResponseType": 0,
                "ResponseText": "Success",
                "ResponseActual": {
                    "connectionId": "f242e8f2-035e-4859-b1bf-2b819a25d41d",
                    "contactId": "f242e8f2-035e-4859-b1bf-2b819a25d41d",
                    "phoneNumber": "sip:+16013261548@lily-outbound",
                    "status": "connecting",
                    "statusTimestamp": "2020-04-09T13:14:45.312Z",
                    "type": "outbound",
                    "buttonStates": {
                        "answer": false,
                        "reject": false,
                        "disconnect": true,
                        "hold": false,
                        "resume": false,
                        "clearContact": false,
                        "consult": false,
                        "numberpad": false,
                        "swap": false,
                        "transfer": false,
                        "conference": false
                    }
                },
                "CallVariables": {},
                "ExtendedCallVariables": null,
                "ResponseFields": {
                    "Participants": [],
                    "MediaProperties": {
                        "callType": "outbound",
                        "queueName": "BasicQueue",
                        "queueTimestamp": "2020-04-09T13:14:45.312Z"
                    },
                    "fromAddress": "sip:+16013261548@lily-outbound",
                    "CallState": "connecting",
                    "Type": "outbound",
                    "CurrentStateTime": "2020-04-09T13:14:45.312Z",
                    "Campaign": "",
                    "DN": "BasicQueue"
                },
                "id": "f242e8f2-035e-4859-b1bf-2b819a25d41d",
                "event": "connecting",
                "CallType": "outbound"
            },
            "source": "event"    
           }
        }


    Was this article helpful?

    What's Next
    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.