API


The complete technical documentation for our API will be available soon

Mass-export


To perform a mass export of your conversational data, please this consult this technical documentation:

https://api.satisfaction.ai/documentation/mass-export/ .


- JSON output file


The output is available via a JSON file such as for example this one:

export.json


If you cannot open easily this JSON file, you can see below its content and the definition (in the text below, on the right side after the character “//”) of all the data that can be exported:

For one api query with theses parameters

timeZone=Europe/Paris

app_id=instance_app_id

start=Start date for the export

end=End date for the export

from=offset of export

all dates are UTC defined

{

"total": 11, // Total of sessions contained in the time range
"start": 1528149600000, // Start date for the export (Unix epoch millisecond format)
"end": 1528235999999, // End date for the export, Unix epoch millisecond format, The end date can't be today date
"sessions": [ // Transcripts belonging to the time range and the step defined

    {

        "Channel": "web", // The communication channel used by the client
        "Duration": 17858, // Time of the discussion between client and agent. expressed in milliseconds
        "End": "2018-06-05T21:23:20.725Z", // Last message received date
        "Received": 1, // Number of client messages received on our platform
        "Sent": 8, // Numer of agent messages sent
        "Start": "2018-06-05T21:23:02.867Z", // First message sent or received date
        "Step": 4.5, // the number of exchanges that have taken
        "Total": 9, // Number of messages exchanged
        "UniqueId": "bf1aad6c-338a-40c9-8385-e0d154622bee", // Unique identifier of this transcript
        "ExternalUserId": "5c6e22db-0fc1-4a9f-9242-12beaf4eb852", // External Client Identifier, client dependant
        "Atmosphere": "unknown", // Global atmosphere of the discussion. atmosphere can be one of: positive, neutral_positive, neutral_negative and negative
        "Waiting": false, // true if the session was waiting at the end of the conversation, false otherwise
        "Handled": false, // True if the session has been handled, false otherwise
        "Messages": [ // List of all messages between client and agent
            {
                "Date": "2018-06-05T21:23:02.866Z", // Date of the message
                "Type": "text", // Type of the message one of text, button
                "From": "bot", // Who sent the message, one of user, bot
                "Message": "Bonjour, je suis un assistant virtuel spécialiste des questions sur l'assurance.",
                "Atmosphere": "unknown", // Atmosphere of the current message, one of : positive, neutral_positive, neutral_negative and negative
                "AthenaElection": "", // DialogManager election based on user input, one of : "", default, intent_name, keyword matching, click_button, data extract or off topic, disambiguation
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:04.882Z",
                "Type": "text",
                "From": "bot",
                "Message": "Pour revenir au menu, veuillez écrire \"retour\" dans la zone de saisie \"Poser ma question\".",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:07.899Z",
                "Type": "text",
                "From": "bot",
                "Message": "En quoi puis-je vous aider ? :)",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:08.914Z",
                "Type": "text",
                "From": "bot",
                "Message": "[button title=\"M'informer sur l'assurance habitation\"]INFORMER[/button][button title=\"Faire un devis rapide\"]DEVIS[/button][button title=\"Déclarer un sinistre\"]CLA[/button][button title=\"Souscrire une assurance habitation\"]SOUSCRIRE[/button][button title=\"J'ai besoin d'une autre information\"]AUTRE[/button]",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:14.672Z",
                "Type": "button",
                "From": "user",
                "Message": "DEVIS",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:14.688Z",
                "Type": "text",
                "From": "bot",
                "Message": "Je suis heureux que vous pensiez à nous pour votre habitation !",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:16.690Z",
                "Type": "text",
                "From": "bot",
                "Message": "Obtenez un tarif habitation personnalisé à votre besoin [url=https://caassure.fr/tarif-express-habitation/#/]en cliquant ici[/url].",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:18.708Z",
                "Type": "text",
                "From": "bot",
                "Message": "Dîtes-nous si l'assistant virtuel a bien répondu à vos questions :",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            },
            {
                "Date": "2018-06-05T21:23:20.724Z",
                "Type": "text",
                "From": "bot",
                "Message": "[button type=\"url\" title=\"Donner mon avis\"]https://caassure.eu./jfe/form/9[/button]",
                "Atmosphere": "unknown",
                "AthenaElection": "",
                "AthenaExtraction":[]
            }
        ]
    }
]
}

For more information on what is a JSON file, please consult this external documentation: https://www.wikihow.com/Use-JSON


- Entities extraction


Once the export done, the entity (if detected in the sentence) can be identified via the following data:

"AthenaExtraction":[]

NB:

In order to comply with the EU’s General Data Protection Regulation (GDPR), an export will contain all data only for the first 28 days following the conversation with the xBot.

After 28 days, the export will still contain the typology of the extracted entity (= for example Date, Time, Name, FirstName) but some extracted data will be anonymized according to our data anonymization process.


- Metadata Export


A Metadata is data that is used to define or describe another data.

To extract the metadata of your choice, you need to find the corresponding Event / CustomMessage names in the transcript page after clicking on “Show all events”. The information to identify is in red in the details of the transcript and can be introduced for example by this:

KeysCapture


Then once this message key event is exactly identified, you need have to add at the end of the url of the extraction request the additional parameter keys= to obtain the desired metadata.

Example:

By using exactly the same example listed in our technical documentation , for a metadata whose event is named for example eventmetadata in the transcript, the extraction url is:

https://api.satisfaction.ai/reporting/transcripts/export?app_id=5463060b-3db7-4282-91cf-667491fec492&start=1528149600000&end=1528235999999&from=10&keys=eventmetadata  

Documented/reviewed 01/04/2019 7:12:55 AM