Build your bot using ChatBot API

API Version

Reports

Reports give an insight into your bots’ performance. With the data in hands, you can get a better understanding of what parts of the stories work and what interactions require additional improvements.

Available reports

Conversations report

Returns list of data points.

GET https://api.chatbot.com/reports/conversations

Properties

parameter type required default
from Date optional 1974-1-1
to Date optional NOW
period Enum(Period) optional last30days
dimension Enum(Dimension) optional day
group Enum(storyId, source) optional
source Enum(Source) Enum(Source)[] optional
storyId String(24) String(24)[] optional

Available periods: today, yesterday, last7days, last30days, thisMonth, lastMonth, last3Months, thisYear, lastYear

Available dimensions: auto, year, month, day, hour

Available sources: messenger, livechat, livechat3, slack, widget, app, custom

Request URL

curl --request GET \
	--url https://api.chatbot.com/reports/conversations \
	--header 'authorization: Bearer ${DEVELOPER_ACCESS_TOKEN}'

Response example**

    {
      "data": [
        {
          "date": "2019-03-17T00:00:00.000Z",
          "value": 1
        },
        {
          "date": "2019-03-18T00:00:00.000Z",
          "value": 2
        },
        {
          "date": "2019-03-19T00:00:00.000Z",
          "value": 3
        },
        {
          "date": "2019-03-20T00:00:00.000Z",
          "value": 4
        },
        {
          "date": "2019-03-21T00:00:00.000Z",
          "value": 5
        },
        {
          "date": "2019-03-22T00:00:00.000Z",
          "value": 6
        },
        {
          "date": "2019-03-23T00:00:00.000Z",
          "value": 7
        },
        {
          "date": "2019-03-24T00:00:00.000Z",
          "value": 0
        },
        {
          "date": "2019-03-25T00:00:00.000Z",
          "value": 0
        },
        {
          "date": "2019-03-26T00:00:00.000Z",
          "value": 0
        },
        {
          "date": "2019-03-27T00:00:00.000Z",
          "value": 0
        }
      ],
      "summary": {
        "total": 28,
        "min": 0,
        "max": 7,
        "avg": 1.04
      }
    }

Returns list of data points.

GET https://api.chatbot.com/reports/conversations.paid

Properties

parameter type required default
from Date optional 1974-1-1
to Date optional NOW
period Enum(Period) optional last30days
dimension Enum(Dimension) optional day
group Enum(storyId, source) optional
source Enum(Source) Enum(Source)[] optional
storyId String(24) String(24)[] optional

Available periods: today, yesterday, last7days, last30days, thisMonth, lastMonth, last3Months, thisYear, lastYear

Available dimensions: auto, year, month, day, hour

Available sources: messenger, livechat, livechat3, slack, widget, app, custom

Request URL

curl --request GET \
	--url https://api.chatbot.com/reports/conversations.paid \
	--header 'authorization: Bearer ${DEVELOPER_ACCESS_TOKEN}'

Response example

{
  "data": [
    {
      "date": "2019-03-17T00:00:00.000Z",
      "value": 1
    },
    {
      "date": "2019-03-18T00:00:00.000Z",
      "value": 2
    },
    {
      "date": "2019-03-19T00:00:00.000Z",
      "value": 3
    },
    {
      "date": "2019-03-20T00:00:00.000Z",
      "value": 4
    },
    {
      "date": "2019-03-21T00:00:00.000Z",
      "value": 5
    },
    {
      "date": "2019-03-22T00:00:00.000Z",
      "value": 6
    },
    {
      "date": "2019-03-23T00:00:00.000Z",
      "value": 7
    },
    {
      "date": "2019-03-24T00:00:00.000Z",
      "value": 0
    },
    {
      "date": "2019-03-25T00:00:00.000Z",
      "value": 0
    },
    {
      "date": "2019-03-26T00:00:00.000Z",
      "value": 0
    },
    {
      "date": "2019-03-27T00:00:00.000Z",
      "value": 0
    }
  ],
  "summary": {
    "total": 28,
    "min": 0,
    "max": 7,
    "avg": 1.04
  }
}

Conversations messages report

Returns list of data points.

GET https://api.chatbot.com/reports/conversations.messages

Properties

parameter type required default
from Date optional 1974-1-1
to Date optional NOW
period Enum(Period) optional last30days
dimension Enum(Dimension) optional day
group Enum(storyId, source) optional
source Enum(Source) Enum(Source)[] optional
storyId String(24) String(24)[] optional

Available periods: today, yesterday, last7days, last30days, thisMonth, lastMonth, last3Months, thisYear, lastYear

Available dimensions: auto, year, month, day, hour

Available sources: messenger, livechat, livechat3, slack, widget, app, custom

Request URL

curl --request GET \
	--url https://api.chatbot.com/reports/conversations.messages \
	--header 'authorization: Bearer ${DEVELOPER_ACCESS_TOKEN}'

Response example

{
  "data": [
    {
      "date": "2019-03-17T00:00:00.000Z",
      "value": 1
    },
    {
      "date": "2019-03-18T00:00:00.000Z",
      "value": 2
    },
    {
      "date": "2019-03-19T00:00:00.000Z",
      "value": 3
    },
    {
      "date": "2019-03-20T00:00:00.000Z",
      "value": 4
    },
    {
      "date": "2019-03-21T00:00:00.000Z",
      "value": 5
    },
    {
      "date": "2019-03-22T00:00:00.000Z",
      "value": 6
    },
    {
      "date": "2019-03-23T00:00:00.000Z",
      "value": 7
    },
    {
      "date": "2019-03-24T00:00:00.000Z",
      "value": 0
    },
    {
      "date": "2019-03-25T00:00:00.000Z",
      "value": 0
    },
    {
      "date": "2019-03-26T00:00:00.000Z",
      "value": 0
    },
    {
      "date": "2019-03-27T00:00:00.000Z",
      "value": 0
    }
  ],
  "summary": {
    "total": 28,
    "min": 0,
    "max": 7,
    "avg": 1.04
  }
}

Average conversations report

Returns list of data points.

GET https://api.chatbot.com/reports/conversations.avg

Properties

parameter type required default
from Date optional 1974-1-1
to Date optional NOW
period Enum(Period) optional last30days
dimension Enum(Dimension) optional day
group Enum(storyId, source) optional
source Enum(Source) Enum(Source)[] optional
storyId String(24) String(24)[] optional

Available periods: today, yesterday, last7days, last30days, thisMonth, lastMonth, last3Months, thisYear, lastYear

Available dimensions: auto, year, month, day, hour

Available sources: messenger, livechat, livechat3, slack, widget, app, custom

Request URL

curl --request GET \
	--url https://api.chatbot.com/reports/conversations.avg \
	--header 'authorization: Bearer ${DEVELOPER_ACCESS_TOKEN}'

Response example

   {
     "data": [
       {
         "date": "2019-03-17T00:00:00.000Z",
         "value": 1
       },
       {
         "date": "2019-03-18T00:00:00.000Z",
         "value": 2
       },
       {
         "date": "2019-03-19T00:00:00.000Z",
         "value": 3
       },
       {
         "date": "2019-03-20T00:00:00.000Z",
         "value": 4
       },
       {
         "date": "2019-03-21T00:00:00.000Z",
         "value": 5
       },
       {
         "date": "2019-03-22T00:00:00.000Z",
         "value": 6
       },
       {
         "date": "2019-03-23T00:00:00.000Z",
         "value": 7
       },
       {
         "date": "2019-03-24T00:00:00.000Z",
         "value": 0
       },
       {
         "date": "2019-03-25T00:00:00.000Z",
         "value": 0
       },
       {
         "date": "2019-03-26T00:00:00.000Z",
         "value": 0
       },
       {
         "date": "2019-03-27T00:00:00.000Z",
         "value": 0
       }
     ],
     "summary": {
       "total": 28,
       "min": 0,
       "max": 7,
       "avg": 1.04
     }
   }

Busiest period report

Returns list of data points.

GET https://api.chatbot.com/reports/conversations.heatmap

Properties

parameter type required default
from Date optional 1974-1-1
to Date optional NOW
period Enum(Period) optional last30days
offset Number(-720, 720) optional 0
source Enum(Source) optional
storyId String(24) optional

Available periods: today, yesterday, last7days, last30days, thisMonth, lastMonth, last3Months, thisYear, lastYear

Available sources: messenger, livechat, livechat3, slack, widget, app, custom

Request URL

curl --request GET \
	--url https://api.chatbot.com/reports/conversations.heatmap \
	--header 'authorization: Bearer ${DEVELOPER_ACCESS_TOKEN}'

Response example

[
  [
    {
      "day": 0,
      "hour": 0,
      "value": 1,
      "usage": 100
    },
    {
       "day": 0,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ],
  [
    {
      "day": 1,
      "hour": 0,
      "value": 0,
      "usage": 0
    },
    {
       "day": 1,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ],
  [
    {
      "day": 2,
      "hour": 0,
      "value": 0,
      "usage": 0
    },
    {
       "day": 2,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ],
  [
    {
      "day": 3,
      "hour": 0,
      "value": 0,
      "usage": 0
    },
    {
       "day": 3,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ],
  [
    {
      "day": 4,
      "hour": 0,
      "value": 0,
      "usage": 0
    },
    {
       "day": 4,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ],
  [
    {
      "day": 5,
      "hour": 0,
      "value": 0,
      "usage": 0
    },
    {
       "day": 5,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ],
  [
    {
      "day": 6,
      "hour": 0,
      "value": 0,
      "usage": 0
    },
    {
       "day": 6,
       "hour": 1,
       "value": 0,
       "usage": 0
    }
  ]
]

Interactions popularity report

Returns list of interactions with usage.

GET https://api.chatbot.com/reports/conversations.interactions

Properties

parameter type required default
from Date optional 1974-1-1
to Date optional NOW
period Enum(Period) optional last30days
storyId String(24) optional

Available periods: today, yesterday, last7days, last30days, thisMonth, lastMonth, last3Months, thisYear, lastYear

Available dimensions: auto, year, month, day, hour

Request URL

curl --request GET \
	--url https://api.chatbot.com/reports/conversations.interactions \
	--header 'authorization: Bearer ${DEVELOPER_ACCESS_TOKEN}'

Response example

[
    {
        "name": "bar",
        "id": "5b07ffafc2376e30306d9b16",
        "usage": 66.67,
        "value": 2
    },
    {
        "parentId": "5b07ffafc2376e30306d9b16",
        "type": "contextFallback",
        "name": "Fallback Interaction",
        "usage": 33.33,
        "value": 1
    },
    {
        "name": "foo",
        "id": "5b07ff77c2376e30306d9b12",
        "usage": 0,
        "value": 0
    },
    {
        "type": "fallback",
        "name": "Fallback Interaction",
        "usage": 0,
        "value": 0
    },
    {
        "type": "welcome",
        "name": "Welcome Interaction",
        "usage": 0,
        "value": 0
    }
]

Start a free ChatBot trial
and build your first chatbot today!

Free 14-day trial No credit card required

Discover our other products