Downloading statistics via API

Downloading statistics via API


Oct8ne allows you to download information from all sessions stored on the platform to facilitate external data processing.


To do this, you need to submit a request to Oct8ne’s servers with a security code and an

identifier that our technical team will provide. In this request, you can include a range of dates,

though it cannot exceed a maximum of 31 days or include dates before the last year, as well as some additional filter criteria.



NotesNote: For performance reasons, the use of this api is limited to one request per minute.



The data can be obtained in CSV or JSON format.


URL

https://[OCT8NE-SERVER-HERE]/apidata/export/v2/sessions/[FORMAT]?apiToken=[YOUR- APIKEY-HERE]&domainId=[YOUR-DOMAIN-

ID]&startTime=[DATE]&endTime=[DATE]&utcOffset=[UTC_OFFSET]


Parámetros de entrada

[FORMAT]

Format in which the data will be obtained

  1. csv
  2. json

apiToken

Domain security code, provided by the technical team.

domainId

Domain ID, provided by the technical team.

startTime

Required. Start date of the sessions to be exported. The

format should be: mm/dd/yyyy.

endTime

Required. End date of the sessions to be exported. The

format should be: mm/dd/yyyy and cannot exceed 31

days from the start date.

agentFilter

ID of the agent you want to filter the data through.

Optional field; all agents are shown by default.

deptFilter

Department ID. Optional field; all departments are

displayed by default.

attentionFilter

Numeric value indicating the filter to apply, in terms of the

level of the customer service in the session.

  1. Sessions attended by an agent.
  2. Sessions where the visitor has asked for assistance.
  3. Sessions where the visitor has asked for assistance but was not attended.

utcOffset

Local time difference in terms of UTC+0, in hours (for

example, if we’re in UTC+1, the value would be 1)

sale

Optional field: Numerical value that indicates the filter to be applied depending on whether a sale has been registered in the session:

  1. 0: All sessions, regardless of whether or not a sale has been registered.
  2. 1: Sessions in which sales have been registered.
  3. 2: Sessions in which no sales have been registered.


If this field is not sent, all sessions will be downloaded, regardless of whether or not a sale has been registered.

durationFormat

Optional field: Numeric value indicating the format of the duration fields. Default value 0.

  1. 0: time format (hh:mm:ss)
  2. 1: total seconds

agentType

Optional field: Numerical value that indicates the filter to apply depending on whether the last person who attended is Human or is the Bot:

  1. 0: All sessions, regardless of whether the agent is a Bot or a Human.
  2. 1: Sessions in which the agent is Human
  3. 2: Sessions in which the agent is a Bot.


If this field is not sent, all sessions will be downloaded, regardless of agent type.

Ejemplo de petición

GET https://backoffice-eu.oct8ne.com/apidata/export/v2/sessions/csv

?apiToken=AAAF80D2A39A53A2899175156FE5E67

&domainId=123 &startTime=01/01/2020 &endTime=01/15/2020 &utcOffset=1

&attentionFilter=2


GET https://backoffice-eu.oct8ne.com/apidata/export/v2/sessions/json

?apiToken=AAAF80D2A39A53A2899175156FE5E67

&domainId=123 &startTime=01/01/2020 &endTime=01/15/2020 &utcOffset=1

&attentionFilter=2



Notes

Note: The variable [OCT8NE-SERVER-HERE] refers to the Oct8ne server in which it is registered. Oct8ne works with different servers, in the USA and in the EU.

Once inside the Oct8ne control panel, look at the address (url) of the browser:

If it is of the type 'backoffice.oct8ne.com', it corresponds to the USA server. If, on the contrary, it is 'backoffice-eu.oct8ne.com', the server is EU.

 

The value of the variable depending on the server is

In EU [OCT8NE-SERVER-HERE] à
backoffice-eu.oct8ne.com

In USA [OCT8NE-SERVER-HERE] à backoffice.oct8ne.com




You can also download the contacts generated in Oct8ne


URL

https://[OCT8NE-SERVER-HERE]/apidata/export/v2/leads/[FORMAT]?apiToken=[YOUR- APIKEY-HERE]&domainId=[YOUR-DOMAIN-

ID]&startTime=[DATE]&endTime=[DATE]&utcOffset=[UTC_OFFSET]


Parámetros de entrada

[FORMAT]

Format in which the data will be obtained

  1. csv
  2. json

apiToken

Domain security code, provided by the technical team.

domainId

Domain ID, provided by the technical team.

startTime

Required. Start date of the sessions to be exported. The

format should be: mm/dd/yyyy.

endTime

Required. End date of the sessions to be exported. The

format should be: mm/dd/yyyy and cannot exceed 31

days from the start date.

utcOffset

Local time difference in terms of UTC+0, in hours (for

example, if we’re in UTC+1, the value would be 1)

Ejemplo de petición

GET https://backoffice-eu.oct8ne.com/apidata/export/v2/leads/csv

?apiToken=AAAF80D2A39A53A2899175156FE5E67

&domainId=123 &startTime=01/01/2020 &endTime=01/15/2020 &utcOffset=1


GET https://backoffice-eu.oct8ne.com/apidata/export/v2/leads/json

?apiToken=AAAF80D2A39A53A2899175156FE5E67

&domainId=123 &startTime=01/01/2020 &endTime=01/15/2020 &utcOffset=1




Notes
The variable [OCT8NE-SERVER-HERE] refers to the Oct8ne server in which it is registered. Oct8ne works with different servers, in the USA and in the EU.
Once inside the Oct8ne control panel, look at the address (url) of the browser:
If it is of the type 'backoffice.oct8ne.com', it corresponds to the USA server. If, on the contrary, it is 'backoffice-eu.oct8ne.com', the server is EU.

The value of the variable depending on the server is
In EU [OCT8NE-SERVER-HERE]  backoffice-eu.oct8ne.com
In USA [OCT8NE-SERVER-HERE]  backoffice.oct8ne.com






    • Related Articles

    • Oct8ne API for custom CSM integration

      Oct8ne API documentation API version 2.4 Contents 1. Introduction 2. Architecture 3. Overview 3.1. Downloading and installing plug-ins and extensions 3.2. Registering as a developer and enabling the platform 3.3. Inserting the oct8ne widget 3.4. ...
    • API for sending transactional or bulk messages from WhatsApp

      Introduction WhatsApp Delivery API allows you to automate the delivery of WhatsApp templates via Oct8ne. The following operations are available: Send template to WhatsApp Get delivery status Get deliveries Get message details Security All API calls ...
    • Catalog upload via Feed

      1. INTRODUCTION One of the main features of Oct8ne is its integrated viewer. The viewer is an interactive space shared by agents and customers, within the chat, to view images and videos of the products in your catalog. Simultaneously, you can zoom ...
    • CONFIGURING PERMISSIONS WHEN INSTALLING MESSENGER AND INSTAGRAM (VIA ONE-CLICK)

      The issue arises when, upon initiating the one-click process, the user receives a message indicating they are not an admin of the page, causing the process to be canceled. Often, the user asserts that they are indeed an admin and demonstrates that ...
    • How to Get an OpenAI API Key

      QUICK SHORTCUT 1.- Go to OpenAI's Platform website at platform.openai.com and sign in with an OpenAI account. 2.- Once you are in your profile (you can check it in the top left corner), click on the ‘Dashboard’ section in the top right corner of the ...