Yay.com loading

Loading

Call us on 0330 122 6000

Login to Yay.com

Phone Calls & CDR Data

API Access

Build custom apps using our JSON API

FREE
Get your free API Key

Phone Call History

Commands to get the history of calls made on an account

Get your free API Key

Filter:

  • All
  • GET
  • POST
  • PUT
  • DELETE
  • Chargeable *

* You will be charged every time this command is run.

  • GET/voip/call?start={start}&end={end}&call_type={call_type}&answered={answered}&recording={recording}&limit={limit}&page={page}&include_cdr={include_cdr}&include_count={include_count}&include_legs={include_legs}

    Gets a paged history of calls made on an account

    Back to top

    Request Details

    Response Details

    Request Details

    URL and Query String Parameters

    • Name

    • Type

    • Required

      • start

      • Date

      • True

      The start of the date range to search on, e.g. 2015-01-31T9:00:00

      • end

      • Date

      • True

      The end of the date range to search on, e.g. 2015-01-3T17:00:00

      • call_type

      • String

      • False

      Filter on the call type ('inbound', 'outbound', or 'internal')

      • answered

      • Boolean

      • False

      Filter on whether or not the call was answered

      • recording

      • Boolean

      • False

      Filter on whether or not the call has a recording

      • limit

      • String

      • False

      How many results to return per page: default 10

      • page

      • String

      • False

      Which page of results to return: default 1

      • include_cdr

      • String

      • False

      Indicates if the call records should be returned with the response, valid values are 'yes' and 'no',' default is 'yes'

      • include_count

      • String

      • False

      Indicates if the total number of calls should be returned, valid values are 'yes' and 'no', default is 'yes'

      • include_legs

      • String

      • False

      Should the call history include a breakdown of each leg of a call (e.g. when they are transferred between users), valid values are 'yes' and 'no', default is 'no'

    Response Details

    200 Response

    {
        "result" : [
            {
                "uuid" : "40c6614b-8c5d-48a0-ab6d-cdc4d47f914d",
                "call_start_time" : 1448457130,
                "call_duration" : 152,
                "status" : "COMPLETE",
                "created_on" : "2018-01-17",
                "call_type" : "OUTBOUND",
                "answered" : true,
                "has_recording" : true,
                "parent_uuid" : "eedf0ea9-94f2-4370-9712-f9c4d0f7035c",
                "child_uuid" : "360f1ead-3264-4f03-8c7a-1079aab59568",
                "next_leg" : {}
            }
        ],
        "status_code" : 200,
        "status_message" : "OK"
    }
  • GET/voip/call/{uuid}

    Gets the details of a specific call

    Back to top

    Request Details

    Response Details

    Request Details

    URL and Query String Parameters

    • Name

    • Type

    • Required

      • uuid

      • String

      • True

      The UUID of the Call to be queried

    Response Details

    200 Response

    {
        "result" : {
            "uuid" : "40c6614b-8c5d-48a0-ab6d-cdc4d47f914d",
            "call_start_time" : 1448457130,
            "call_duration" : 152,
            "status" : "COMPLETE",
            "created_on" : "2018-01-17",
            "call_type" : "OUTBOUND",
            "answered" : true,
            "has_recording" : true,
            "parent_uuid" : "eedf0ea9-94f2-4370-9712-f9c4d0f7035c",
            "child_uuid" : "360f1ead-3264-4f03-8c7a-1079aab59568",
            "next_leg" : {}
        },
        "status_code" : 200,
        "status_message" : "OK"
    }

    404 Response

    {
        "result" : {},
        "status_code" : 404,
        "status_message" : "Not Found"
    }
  • GET/voip/call/{uuid}/audio

    Generates a temporary URL to the call recording audio

    Back to top

    Request Details

    Response Details

    Request Details

    URL and Query String Parameters

    • Name

    • Type

    • Required

      • uuid

      • String

      • True

      The UUID of the Call to get the recording URL for

    Response Details

    200 Response

    {
        "result" : {
            "recording" : "http://recordings.yay.com/40c6614b-8c5d-48a0-ab6d-cdc4d47f914d"
        },
        "status_code" : 200,
        "status_message" : "OK"
    }

    404 Response

    {
        "result" : {},
        "status_code" : 404,
        "status_message" : "Not Found"
    }
View Desktop Site