question

tomas-kratochvil avatar image
tomas-kratochvil asked ·

Export conversation

Hello,

Is it possible to export glip conversation? To TXT or in any other way?

topic-default
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

· Write an Answer
ak avatar image
ak answered ·
In Order to retrieve the conversations inside a Group, you would need to make two API calls to get :
  1. Group ID 
  2. Get Posts for the Group ID
                 

Group ID

In order to retrieve the  groupID, please use the  GET Groups List  endpoint to list all the available groups for the User / Extension

A sample response would look like this:

{
                 
      "id": "groupID1",
      "name": null,
      "description": null,
      "type": "Group",
      "members": [
        "memberID1",
        "memberID2",
        "memberID3"
      ],
      "isPublic": null,
      "creationTime": "2017-04-03T17:30:21.729Z",
      "lastModifiedTime": "2017-04-03T17:30:21.729Z"
    },
    {
      "id": "groupID2",
      "name": null,
      "description": null,
      "type": "PrivateChat",
      "members": [
        "memberID1",
        "memberID2"
      ],
      "isPublic": null,
      "creationTime": "2016-05-26T02:31:54.822Z",
      "lastModifiedTime": "2016-05-26T02:31:54.822Z"
    },
    {
      "id": "groupID3",
      "name": null,
      "description": null,
      "type": "PrivateChat",
      "members": [
        "memberID10",
        "memberID2"
      ],
      "isPublic": null,
      "creationTime": "2017-03-22T23:06:29.353Z",
      "lastModifiedTime": "2017-03-22T23:06:29.353Z"
    }
}
Get Posts for the Group ID

Once you have the groupID from the above API call, you could use the  GET Posts by GroupID and filter the posts by groupID

A sample response would look like this:

[
   {
      "id": "1384680292356",
      "groupId": "groupID1",
      "type": "TextMessage",
      "text": "Hi team, customer is unable to access their Sandbox account. I searched for their account details on DPW and there were no results. User ID Blah Blah Blah .\n\nHow can we enable this account so they may access it again? Thanks.",
      "creatorId": "glip-1271750659",
      "addedPersonIds": null,
      "creationTime": "2017-01-26T22:53:03.426Z",
      "lastModifiedTime": "2017-01-26T22:53:03.426Z"
    },
    {
      "id": "1335248527364",
      "groupId": "groupID1",
      "type": "TextMessage",
      "text": "**Team, this is now our Glip Group to communicate between people**",
      "creatorId": "630769004",
      "addedPersonIds": null,
      "creationTime": "2017-01-16T18:27:05.697Z",
      "lastModifiedTime": "2017-01-26T23:01:17.291Z"
    }
Boom ! you have the conversations for the Group. 

You could take a look at our API endpoints for Glip within our API Explorer 

Share
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.