Download OpenAPI specification:Download
OpenAPI specification (OAS) for the ChatKitty Platform API. See the Interactive Docs to try ChatKitty API methods without writing code, and get the complete schema of resources exposed by the API.
Batch export message analytics data
{- "id": 203,
- "type": "MESSAGE_IMPORT",
- "state": "PENDING",
- "createdTime": "2022-04-28T05:30:44.265Z",
- "endedTime": "2022-04-28T05:30:44.692Z",
- "_links": {
}
}
Returns the ChatKitty application associated with the authentication credentials used.
You must use an OAuth V2 Bearer token to access this endpoint.
curl -X 'GET' \ 'https://api.chatkitty.com/v1/application' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "key": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "properties": { },
- "created_time": "2020-10-02T20:29:25.316Z",
}
Returns the current settings configuring this application
curl -X 'GET' \ 'https://api.chatkitty.com/v1/application/settings' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "features": {
- "guest_users": "ENABLED",
- "user_created_channels": "DISABLED"
}
}
Update the settings configuring this application
guest_users required | string Enum: "DISABLED" "ENABLED" Toggle state of this settings option |
user_created_channels required | string Enum: "DISABLED" "ENABLED" Toggle state of this settings option |
{- "guest_users": "DISABLED",
- "user_created_channels": "DISABLED"
}
{- "features": {
- "guest_users": "ENABLED",
- "user_created_channels": "DISABLED"
}
}
Returns a page of channels belonging to this application
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
type | string Enum: "DIRECT" "PUBLIC" "PRIVATE" Filters by channel type |
members | Array of strings unique Filters by channel members using their usernames |
startTime | string <date-time> Filters for channels created within a time range: start time |
endTime | string <date-time> Filters for channels created within a time range: end time |
properties | string Filters by channel custom properties |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels?page=0&size=5' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "channels": [
- {
- "id": 15252,
- "type": "DIRECT",
- "creator": {
- "id": 19652,
- "type": "PERSON",
- "name": "rexyfexy@gmail.com",
- "displayName": "doark",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "members": [
- {
- "id": 19652,
- "type": "PERSON",
- "name": "rexyfexy@gmail.com",
- "displayName": "doark",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - {
- "id": 19452,
- "type": "PERSON",
- "name": "aa",
- "displayName": "emra",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}
], - "properties": { },
- "createdTime": "2021-05-05T00:38:24.888Z",
- "_links": {
- "participants": {
},
}
}, - {
- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}, - {
- "id": 2402,
- "type": "PUBLIC",
- "name": "#test",
- "displayName": "Test Channel",
- "creator": {
- "id": 4153,
- "type": "PERSON",
- "name": "test@mail.com",
- "displayName": "mridx",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "properties": { },
- "createdTime": "2020-12-13T21:12:09.195Z",
- "_links": {
}
}, - {
- "id": 856,
- "type": "PUBLIC",
- "name": "mkm",
- "displayName": "Meme Channel",
- "creator": {
- "id": 1504,
- "type": "PERSON",
- "name": "njnj@vghf.jk",
- "displayName": "mkm",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "lastReceivedMessage": {
- "id": 17654,
- "type": "TEXT",
- "channelId": 856,
- "user": {
- "id": 15402,
- "type": "PERSON",
- "name": "paras@code.co",
- "displayName": "Paras",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "body": "ghk",
- "properties": { },
- "createdTime": "2021-03-31T06:00:28.680Z"
}, - "properties": { },
- "createdTime": "2020-11-25T07:46:45.775Z",
- "_links": {
}
}, - {
- "id": 1302,
- "type": "PUBLIC",
- "name": "SONU KUMAR",
- "displayName": "SONU KUMAR",
- "creator": {
- "id": 2302,
- "type": "PERSON",
- "name": "852122",
- "displayName": "SONU KUMAR",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "lastReceivedMessage": {
- "id": 44530,
- "type": "TEXT",
- "channelId": 1302,
- "user": {
- "id": 39826,
- "type": "PERSON",
- "name": "steve@innersync.com",
- "displayName": "Steve Williams",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "body": "Checking out",
- "properties": { },
- "createdTime": "2021-09-14T18:02:56.066Z"
}, - "properties": { },
- "createdTime": "2020-12-02T05:10:01.260Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 2020,
- "totalPages": 404,
- "number": 0
}
}
Creates a new channel or returns an equivalent existing channel
type required | string |
creator | object Reference to a user |
members | Array of objects unique List of user references of members of this channel |
object Custom data associated with this channel | |
name | string The unique name of this channel used to reference the channel. If absent defaults to a random UUID |
display_name | string Human readable name of this channel shown to users. If absent defaults to the channel name |
{- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7"
}
{- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}
Returns a channel by ID
id required | integer <int64> Channel ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/55913' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}
Deletes a channel by ID
id required | integer <int64> Channel ID |
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/channels/55913' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "key": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "properties": { },
- "created_time": "2020-10-02T20:29:25.316Z",
}
Updates a channel properties
id required | integer <int64> Channel ID |
{ }
{- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}
Sends a custom channel event
id required | integer <int64> Channel ID |
type required | string Custom type of this event |
required | object Custom data associated with this event |
{- "type": "My Custom Event",
- "properties": {
- "payload": "Boom!",
- "stuff": {
- "favoriteNumber": 42,
- "favoriteMovie": "Lilo and Stitch"
}
}
}
{- "type": "My Custom Event",
- "properties": {
- "payload": "Boom!",
- "stuff": {
- "favoriteNumber": 42,
- "favoriteMovie": "Lilo and Stitch"
}
},
}
Returns a page of invites sent to join this channel
id required | integer <int64> Channel ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/67026/invites?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "invites": [
- {
- "createdTime": "2022-06-02T16:51:03.206366Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 25,
- "totalElements": 1,
- "totalPages": 1,
- "number": 0
}
}
Sends a channel invite to user
id required | integer <int64> Channel ID |
user required | object (ChatUserReference) Reference to a user |
{- "user": {
- "username": "jane@chatkitty.com"
}
}
{- "createdTime": "2022-06-02T16:51:03.206366286Z",
- "_links": {
}
}
Sends keystrokes in this channel on behalf of a user
id required | integer <int64> |
keys required | string |
user required | object (ChatUserReference) Reference to a user |
{- "keys": "string",
- "user": {
- "username": "jane@chatkitty.com"
}
}
{- "keys": "string",
- "username": "string",
- "_links": [
- {
- "href": "string",
- "hreflang": "string",
- "title": "string",
- "type": "string",
- "deprecation": "string",
- "profile": "string",
- "name": "string",
- "templated": true
}
]
}
Returns a page of channel members
id required | integer <int64> Channel ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/67026/members?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "users": [
- {
- "id": 14503,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3004,
- "type": "PERSON",
- "name": "1",
- "displayName": "ChatKittyUser",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6152,
- "type": "PERSON",
- "name": "10zxc13@gmail.com",
- "displayName": "Jack",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3353,
- "type": "PERSON",
- "name": "12121",
- "displayName": "12121",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6602,
- "type": "PERSON",
- "name": "123",
- "displayName": "123",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 571,
- "totalPages": 115,
- "number": 0
}
}
Makes a user a group channel member
id required | integer <int64> Channel ID |
Reference to a user
{- "username": "jane@chatkitty.com"
}
{- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}
Removes a member from a group channel
id required | integer <int64> Channel ID |
user_id required | integer <int64> User ID of member to be removed |
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/channels/55913/members/14503' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}
Returns a page of channel membership info for this channel
id required | integer <int64> Channel ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/702/memberships?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "memberships": [
- {
- "createdTime": "2020-12-02T21:52:33.976Z",
- "_links": {
}
}, - {
- "createdTime": "2020-12-02T22:03:28.742Z",
- "_links": {
}
}, - {
- "createdTime": "2020-11-23T13:03:17.433Z",
- "_links": {
}
}, - {
- "createdTime": "2020-12-07T22:28:47.620Z",
- "_links": {
}
}, - {
- "createdTime": "2020-11-23T14:34:29.580Z",
- "_links": {
}
}
]
}, - "_links": {
- "first": {
}, - "self": {
}, - "next": {
},
}, - "page": {
- "size": 5,
- "totalElements": 537,
- "totalPages": 108,
- "number": 0
}
}
Returns a page of messages sent in this channel
id required | integer <int64> Channel ID |
size | integer <int32> The size of the page to be returned |
start | integer <int64> Start cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
next | integer <int64> Next page cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch subsequent pages |
relation | string Enum: "SELF" "PREVIOUS" "NEXT" Page cursor relation. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
username | string |
query | string |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/702/messages' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "messages": [
- {
- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}, - {
- "id": 44701,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "test",
- "properties": { },
- "createdTime": "2021-09-16T14:57:55.903Z",
- "_links": {
}
}, - {
- "id": 44700,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "hi",
- "properties": { },
- "createdTime": "2021-09-16T14:57:46.056Z",
- "_links": {
}
}, - {
- "id": 44760,
- "type": "TEXT",
- "channelId": 1255,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "do?",
- "properties": { },
- "createdTime": "2021-09-16T09:14:09.585Z",
- "_links": {
}
}, - {
- "id": 44759,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "ok",
- "properties": { },
- "createdTime": "2021-09-16T09:13:48.030Z",
- "_links": {
}
}
]
}, - "page": {
- "size": 5
}
}
Sends a message in this channel as the system or on behalf of a user
id required | integer <int64> Channel ID |
type required | string |
group_tag | string Optional string to associate this message with other messages. Can be used to group messages into a gallery |
object Custom data associated with this message | |
user | object (ChatUserReference) Reference to a user |
body required | string The text body of this message |
{- "type": "TEXT",
- "body": "Hello, World!"
}
{- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}
Returns a page of channel moderators
id required | integer <int64> Channel ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/67026/moderators?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "users": [
- {
- "id": 14503,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3004,
- "type": "PERSON",
- "name": "1",
- "displayName": "ChatKittyUser",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6152,
- "type": "PERSON",
- "name": "10zxc13@gmail.com",
- "displayName": "Jack",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3353,
- "type": "PERSON",
- "name": "12121",
- "displayName": "12121",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6602,
- "type": "PERSON",
- "name": "123",
- "displayName": "123",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 571,
- "totalPages": 115,
- "number": 0
}
}
Makes a user a group channel moderator
id required | integer <int64> Channel ID |
Reference to a user
{- "username": "jane@chatkitty.com"
}
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}
Removes a moderator from a group channel
id required | integer <int64> Channel ID |
user_id required | integer <int64> User ID of moderator to be removed |
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/channels/55913/moderators/14503' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}
Returns a page of channel active participants: members that currently online
id required | integer <int64> Channel ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/channels/702/participants?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "users": [
- {
- "id": 14503,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3004,
- "type": "PERSON",
- "name": "1",
- "displayName": "ChatKittyUser",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6152,
- "type": "PERSON",
- "name": "10zxc13@gmail.com",
- "displayName": "Jack",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3353,
- "type": "PERSON",
- "name": "12121",
- "displayName": "12121",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6602,
- "type": "PERSON",
- "name": "123",
- "displayName": "123",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 571,
- "totalPages": 115,
- "number": 0
}
}
Returns a page of reported messages in this channel
id required | integer <int64> Channel ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
{- "_embedded": {
- "messages": [
- {
- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}
]
}, - "page": {
- "number": 0,
- "size": 0,
- "total_elements": 0,
- "total_pages": 0
}, - "_links": [
- {
- "href": "string",
- "hreflang": "string",
- "title": "string",
- "type": "string",
- "deprecation": "string",
- "profile": "string",
- "name": "string",
- "templated": true
}
]
}
Returns a page of chat sessions belonging to this application
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
state | string Enum: "ACTIVE" "ENDED" Filters by state |
{- "_embedded": {
- "sessions": [
- {
- "id": 1480794,
- "session": {
- "id": 544188,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-09-19T04:35:43.576Z",
- "createdTime": "2021-09-19T04:28:48.442Z"
}, - "state": "ENDED",
- "endTime": "2021-09-19T04:33:41.677Z",
- "createdTime": "2021-09-19T04:33:40.657Z",
- "_links": {
}
}, - {
- "id": 1480795,
- "session": {
- "id": 544188,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-09-19T04:35:43.576Z",
- "createdTime": "2021-09-19T04:28:48.442Z"
}, - "state": "ENDED",
- "endTime": "2021-09-19T04:35:43.597Z",
- "createdTime": "2021-09-19T04:33:41.710Z",
- "_links": {
}
}, - {
- "id": 1480731,
- "session": {
- "id": 544216,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-09-19T04:38:45.272Z",
- "createdTime": "2021-09-19T04:35:45.028Z"
}, - "state": "ENDED",
- "endTime": "2021-09-19T04:35:55.360Z",
- "createdTime": "2021-09-19T04:35:45.685Z",
- "_links": {
}
}, - {
- "id": 1481281,
- "session": {
- "id": 545001,
- "user": {
- "id": 39806,
- "type": "PERSON",
- "name": "c6f75947-af48-4893-a78e-0e0b9bd68580",
- "displayName": "Julie Jaxton",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-09-20T12:13:12.242Z",
- "createdTime": "2021-09-20T12:13:09.900Z"
}, - "state": "ENDED",
- "endTime": "2021-09-20T12:13:12.255Z",
- "createdTime": "2021-09-20T12:13:10.352Z",
- "_links": {
}
}, - {
- "id": 1481282,
- "session": {
- "id": 545052,
- "user": {
- "id": 39807,
- "type": "PERSON",
- "name": "8fadc920-f3e6-49ff-9398-1e58b3dc44dd",
- "displayName": "Zaria Bria",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-09-20T12:13:22.564Z",
- "createdTime": "2021-09-20T12:13:20.105Z"
}, - "state": "ENDED",
- "endTime": "2021-09-20T12:13:22.575Z",
- "createdTime": "2021-09-20T12:13:20.553Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 5190,
- "totalPages": 1038,
- "number": 0
}
}
Returns a chat function version by ID
id required | integer <int64> Chat function version ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/function-versions/13515' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 13515,
- "versionNumber": 34,
- "handlerScript": "const logs = [];\n\nasync function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n logs.push('Hello ' + event.username);\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return logs;\n}",
- "_links": {
}
}
Returns a chat function by ID
id required | integer <int64> Chat function ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/functions/1' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "type": "user.attempted.start_session",
- "runtime": {
- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29"
}, - "name": "User Attempted Start Session",
- "enabled": true,
- "currentVersionNumber": 34,
- "_links": {
- "currentVersion": {
},
}
}
Returns the version of this chat function currently deployed
id required | integer <int64> Chat function ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/functions/13515/current-version' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 13515,
- "versionNumber": 34,
- "handlerScript": "const logs = [];\n\nasync function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n logs.push('Hello ' + event.username);\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return logs;\n}",
- "_links": {
}
}
Returns a page of invocations of this chat function. A log of previous runs of the function
id required | integer <int64> Chat function ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/functions/1/invocations?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "invocations": [
- {
- "id": 468510,
- "versionNumber": 34,
- "args": {
- "authParams": {
- "displayName": "Niyati"
}, - "username": "asac@sfas.com"
}, - "status": "SUCCEEDED",
- "result": {
- "payload": [
- "Hello asac@sfas.com"
]
}, - "createdTime": "2021-09-20T06:37:01.766Z",
}, - {
- "id": 468453,
- "versionNumber": 34,
- "args": {
- "authParams": {
- "displayName": ""
}, - "username": ""
}, - "status": "SUCCEEDED",
- "result": {
- "payload": [
- "Hello ",
- "Hello "
]
}, - "createdTime": "2021-09-19T09:34:40.190Z",
}, - {
- "id": 468452,
- "versionNumber": 34,
- "args": {
- "authParams": {
- "displayName": ""
}, - "username": ""
}, - "status": "SUCCEEDED",
- "result": {
- "payload": [
- "Hello "
]
}, - "createdTime": "2021-09-19T09:34:26.890Z",
}, - {
- "id": 467243,
- "versionNumber": 34,
- "args": {
- "authParams": {
- "displayName": ""
}, - "username": "aaron"
}, - "status": "SUCCEEDED",
- "result": {
- "payload": [
- "Hello aaron"
]
}, - "createdTime": "2021-09-17T17:00:31.396Z",
}, - {
- "id": 467162,
- "versionNumber": 34,
- "args": {
- "authParams": {
- "displayName": "bob"
}, - "username": "fwfe@efw.com"
}, - "status": "SUCCEEDED",
- "result": {
- "payload": [
- "Hello fwfe@efw.com"
]
}, - "createdTime": "2021-09-17T09:15:50.072Z",
}
]
}, - "_links": {
- "first": {
}, - "self": {
}, - "next": {
},
}, - "page": {
- "size": 5,
- "totalElements": 7578,
- "totalPages": 1516,
- "number": 0
}
}
Returns a page of versions of this chat function
id required | integer <int64> Chat function ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/functions/1/versions?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "versions": [
- {
- "id": 13515,
- "versionNumber": 34,
- "handlerScript": "const logs = [];\n\nasync function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n logs.push('Hello ' + event.username);\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return logs;\n}",
- "_links": {
}
}, - {
- "id": 13461,
- "versionNumber": 33,
- "handlerScript": "const logs = [];\n\nasync function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n logs.push('Hello!');\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return logs;\n}",
- "_links": {
}
}, - {
- "id": 4802,
- "versionNumber": 32,
- "handlerScript": "async function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return {payload: true};\n}",
- "_links": {
}
}, - {
- "id": 4652,
- "versionNumber": 31,
- "handlerScript": "async function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return true;\n}",
- "_links": {
}
}, - {
- "id": 4555,
- "versionNumber": 30,
- "handlerScript": "async function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return {\n status: \"SUCCESS\"\n };\n}",
- "_links": {
}
}
]
}, - "_links": {
- "first": {
},
}, - "page": {
- "size": 5,
- "totalElements": 35,
- "totalPages": 7,
- "number": 0
}
}
Creates a new version of this chat function
id required | integer <int64> Chat function ID |
handler_script required | string JavaScript/TypeScript code that runs when this function is executed |
{- "handlerScript": "const logs = [];\n\nasync function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n logs.push('Hello ' + event.username);\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return logs;\n}"
}
{- "id": 13515,
- "versionNumber": 34,
- "handlerScript": "const logs = [];\n\nasync function handleEvent(event: UserAttemptedStartSessionEvent, context: Context) {\n let email = event.username;\n let displayName = event.authParams.displayName || email;\n\n let userApi = context.getUserApi();\n\n logs.push('Hello ' + event.username);\n\n await userApi.getUserExists(email)\n .catch(async () => {\n let user = await userApi.createUser(\n {\n 'name': email,\n 'displayName': displayName\n }\n );\n\n let channelApi = context.getChannelApi();\n\n await channelApi.createChannelMember(702, { 'id': user.data.id });\n });\n\n return logs;\n}",
- "_links": {
}
}
Batch imports channels from a JSON array file
file required | string <binary> JSON array file with channels |
curl --location --request 'POST' \ 'https://api.chatkitty.com/v1/imports/channels' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN' \ -H 'Content-Type: multipart/form-data' \ -F 'file=@channels_import_file.json;type=application/json
{- "id": 53,
- "type": "CHANNEL_IMPORT",
- "state": "PENDING",
- "createdTime": "2021-09-28T05:30:44.265Z",
- "endedTime": "2021-09-28T05:30:44.692Z",
- "_links": {
}
}
Batch imports channel members from a JSON array file
id required | integer <int64> |
file required | string <binary> JSON array file with user references to be added as members |
curl --location --request 'POST' \ 'https://api.chatkitty.com/v1/imports/channels/1/members' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN' \ -H 'Content-Type: multipart/form-data' \ -F 'file=@members_import_file.json;type=application/json
{- "id": 205,
- "type": "CHANNEL_MEMBERS_IMPORT",
- "state": "PENDING",
- "createdTime": "2022-05-28T05:30:44.265Z",
- "endedTime": "2022-05-28T05:30:44.692Z",
- "_links": {
}
}
Batch imports messages from a JSON array file
file required | string <binary> JSON array file with messages |
curl --location --request 'POST' \ 'https://api.chatkitty.com/v1/imports/messages' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN' \ -H 'Content-Type: multipart/form-data' \ -F 'file=@messages_import_file.json;type=application/json
{- "id": 203,
- "type": "MESSAGE_IMPORT",
- "state": "PENDING",
- "createdTime": "2022-04-28T05:30:44.265Z",
- "endedTime": "2022-04-28T05:30:44.692Z",
- "_links": {
}
}
Batch imports users from a JSON array file
file required | string <binary> JSON array file with users |
curl --location --request 'POST' \ 'https://api.chatkitty.com/v1/imports/users' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN' \ -H 'Content-Type: multipart/form-data' \ -F 'file=@users_import_file.json;type=application/json
{- "id": 202,
- "type": "USER_IMPORT",
- "state": "PENDING",
- "createdTime": "2022-03-28T05:30:44.265Z",
- "endedTime": "2022-03-28T05:30:44.692Z",
- "_links": {
}
}
Returns a page of jobs created for this application
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
running | boolean Filters for jobs currently running |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/jobs' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "jobs": [
- {
- "id": 1,
- "type": "CHANNEL_IMPORT",
- "state": "FAILED",
- "createdTime": "2021-09-28T04:19:41.255Z",
- "endedTime": "2021-09-28T04:19:42.230Z",
- "_links": {
}
}, - {
- "id": 52,
- "type": "CHANNEL_IMPORT",
- "state": "FAILED",
- "createdTime": "2021-09-28T05:30:08.902Z",
- "endedTime": "2021-09-28T05:30:09.571Z",
- "_links": {
}
}, - {
- "id": 53,
- "type": "CHANNEL_IMPORT",
- "state": "FINISHED",
- "createdTime": "2021-09-28T05:30:44.265Z",
- "endedTime": "2021-09-28T05:30:44.692Z",
- "_links": {
}
}, - {
- "id": 54,
- "type": "CHANNEL_IMPORT",
- "state": "FINISHED",
- "createdTime": "2021-09-28T05:35:35.075Z",
- "endedTime": "2021-09-28T05:36:15.755Z",
- "_links": {
}
}, - {
- "id": 102,
- "type": "CHANNEL_MEMBERS_IMPORT",
- "state": "FINISHED",
- "createdTime": "2021-09-29T04:52:22.895Z",
- "endedTime": "2021-09-29T04:52:58.941Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 25,
- "totalElements": 5,
- "totalPages": 1,
- "number": 0
}
}
Returns a job by ID
id required | integer <int64> Job ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/jobs/1' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 53,
- "type": "CHANNEL_IMPORT",
- "state": "PENDING",
- "createdTime": "2021-09-28T05:30:44.265Z",
- "endedTime": "2021-09-28T05:30:44.692Z",
- "_links": {
}
}
Returns a page of messages belonging to this application
size | integer <int32> The size of the page to be returned |
start | integer <int64> Start cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
next | integer <int64> Next page cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch subsequent pages |
relation | string Enum: "SELF" "PREVIOUS" "NEXT" Page cursor relation. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
username | string Filters messages by a sender's username |
query | string Filters text messages by text contained in the message body |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/messages' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "messages": [
- {
- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}, - {
- "id": 44701,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "test",
- "properties": { },
- "createdTime": "2021-09-16T14:57:55.903Z",
- "_links": {
}
}, - {
- "id": 44700,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "hi",
- "properties": { },
- "createdTime": "2021-09-16T14:57:46.056Z",
- "_links": {
}
}, - {
- "id": 44760,
- "type": "TEXT",
- "channelId": 1255,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "do?",
- "properties": { },
- "createdTime": "2021-09-16T09:14:09.585Z",
- "_links": {
}
}, - {
- "id": 44759,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "ok",
- "properties": { },
- "createdTime": "2021-09-16T09:13:48.030Z",
- "_links": {
}
}
]
}, - "page": {
- "size": 5
}
}
Deletes all messages belonging to this application
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/messages' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "key": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "properties": { },
- "created_time": "2020-10-02T20:29:25.316Z",
}
Returns a message by ID
id required | integer <int64> Message ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/messages/44902' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}
Deletes a message by ID
id required | integer <int64> Message ID |
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/messages/67528' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 67528,
- "type": "MAIN",
- "properties": { },
- "createdTime": "2022-02-04T13:19:06.764939Z",
- "_links": {
}
}
Updates a message properties
id required | integer <int64> Message ID |
{ }
{- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}
Returns a page of read receipts for this message
id required | integer <int64> |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/messages/1/read-receipts?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "receipts": [
- {
- "user": {
- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "createdTime": "2022-06-02T16:51:03.206366286Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 1,
- "totalElements": 1,
- "totalPages": 1,
- "number": 0
}
}
Return this application's NodeJS chat runtime
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/runtimes/nodejs' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29",
- "dependencies": [
- {
- "name": "axios",
- "version": "^0.19.2",
- "defaultDependency": true
}, - {
- "name": "axios-token-interceptor",
- "version": "^0.2.0",
- "defaultDependency": true
}, - {
- "name": "chatkitty-platform-sdk",
- "version": "1.0.1",
- "defaultDependency": true
}, - {
- "name": "qs",
- "version": "6.9.4",
- "defaultDependency": true
}, - {
- "name": "firebase",
- "version": "^9.8.2",
- "defaultDependency": false
}
], - "initializationScript": {
- "script": "var foo = 8;"
}, - "environmentVariables": {
- "CHATKITTY_CLIENT_SECRET": "34e65736-70c2-4d30-b80a-8ad9887c860b",
- "CHATKITTY_CLIENT_ID": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "CHATKITTY_APPLICATION_ID": "1",
}, - "_links": {
- "dependencies": {
}, - "initializationScript": {
},
}
}
Updates the NPM dependencies for this application's NodeJS chat runtime
default_dependency required | boolean True if this NPM package is automatically installed by ChatKitty and available by default in your chat functions |
name required | string The name of the dependency NPM package |
version required | string The version of the NPM package |
[- {
- "name": "firebase",
- "version": "^9.8.2"
}
]
{- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29",
- "dependencies": [
- {
- "name": "axios",
- "version": "^0.19.2",
- "defaultDependency": true
}, - {
- "name": "axios-token-interceptor",
- "version": "^0.2.0",
- "defaultDependency": true
}, - {
- "name": "chatkitty-platform-sdk",
- "version": "1.0.1",
- "defaultDependency": true
}, - {
- "name": "qs",
- "version": "6.9.4",
- "defaultDependency": true
}, - {
- "name": "firebase",
- "version": "^9.8.2",
- "defaultDependency": false
}
], - "initializationScript": {
- "script": "var foo = 8;"
}, - "environmentVariables": {
- "CHATKITTY_CLIENT_SECRET": "34e65736-70c2-4d30-b80a-8ad9887c860b",
- "CHATKITTY_CLIENT_ID": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "CHATKITTY_APPLICATION_ID": "1",
}, - "_links": {
- "dependencies": {
}, - "initializationScript": {
},
}
}
Updates the runtime environment variables of this application's NodeJS chat runtime
property name* additional property | string Environment variable set for this runtime. Accessible in the initialization script and chat functions associated with this runtime |
{- "CUSTOM_ENV_AWS_REGION": "us-east-1"
}
{- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29",
- "dependencies": [
- {
- "name": "axios",
- "version": "^0.19.2",
- "defaultDependency": true
}, - {
- "name": "axios-token-interceptor",
- "version": "^0.2.0",
- "defaultDependency": true
}, - {
- "name": "chatkitty-platform-sdk",
- "version": "1.0.1",
- "defaultDependency": true
}, - {
- "name": "qs",
- "version": "6.9.4",
- "defaultDependency": true
}, - {
- "name": "firebase",
- "version": "^9.8.2",
- "defaultDependency": false
}
], - "initializationScript": {
- "script": "var foo = 8;"
}, - "environmentVariables": {
- "CHATKITTY_CLIENT_SECRET": "34e65736-70c2-4d30-b80a-8ad9887c860b",
- "CHATKITTY_CLIENT_ID": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "CHATKITTY_APPLICATION_ID": "1",
}, - "_links": {
- "dependencies": {
}, - "initializationScript": {
},
}
}
Returns a page of functions for this application's NodeJS chat runtime
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/runtimes/nodejs/functions?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "functions": [
- {
- "id": 202,
- "type": "user.received.notification",
- "runtime": {
- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29"
}, - "name": "User Received Notification",
- "enabled": true,
- "currentVersionNumber": 5,
- "_links": {
- "currentVersion": {
},
}
}, - {
- "id": 4552,
- "type": "user.sent.message",
- "runtime": {
- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29"
}, - "name": "User Sent Message",
- "enabled": false,
- "currentVersionNumber": 0,
- "_links": {
- "currentVersion": {
},
}
}, - {
- "id": 6152,
- "type": "user.started.chat_session",
- "runtime": {
- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29"
}, - "name": "User Started Chat Session",
- "enabled": false,
- "currentVersionNumber": 0,
- "_links": {
- "currentVersion": {
},
}
}, - {
- "id": 1,
- "type": "user.attempted.start_session",
- "runtime": {
- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29"
}, - "name": "User Attempted Start Session",
- "enabled": true,
- "currentVersionNumber": 34,
- "_links": {
- "currentVersion": {
},
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 4,
- "totalPages": 1,
- "number": 0
}
}
Creates a NodeJS chat function for this runtime
type required | string |
description | string |
initialize_asynchronously required | boolean |
name required | string |
{- "type": "user.attempted.start_session",
- "name": "User Attempted Start Session"
}
{- "id": 1,
- "type": "user.attempted.start_session",
- "runtime": {
- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29"
}, - "name": "User Attempted Start Session",
- "enabled": true,
- "currentVersionNumber": 34,
- "_links": {
- "currentVersion": {
},
}
}
Updates the initialization script for this application's NodeJS chat runtime
script required | string The JavaScript/TypeScript source of this script |
{- "script": "import firebase from 'firebase';\r\nimport '@firebase/auth';\r\nimport '@firebase/firestore';\r\n\r\nconst firebaseConfig = {\r\n apiKey: 'AIzaSyBEqSZdB3qTeSTyycvYDgJ5qG-5Xg9rQZY',\r\n authDomain: 'chatkitty-example.firebaseapp.com',\r\n databaseURL: 'https://chatkitty-example.firebaseio.com',\r\n projectId: 'chatkitty-example',\r\n storageBucket: 'chatkitty-example.appspot.com',\r\n messagingSenderId: '540634290949',\r\n appId: '1:540634290949:web:cd754ff7e98087230ff56c',\r\n measurementId: 'G-BB7Q5DRQK6',\r\n};\r\n\r\nif (!firebase.apps.length) {\r\n firebase.initializeApp(firebaseConfig);\r\n}\r\n\r\nexport { firebase };"
}
{- "id": 1,
- "type": "NODEJS",
- "version": "v0.0.29",
- "dependencies": [
- {
- "name": "axios",
- "version": "^0.19.2",
- "defaultDependency": true
}, - {
- "name": "axios-token-interceptor",
- "version": "^0.2.0",
- "defaultDependency": true
}, - {
- "name": "chatkitty-platform-sdk",
- "version": "1.0.1",
- "defaultDependency": true
}, - {
- "name": "qs",
- "version": "6.9.4",
- "defaultDependency": true
}, - {
- "name": "firebase",
- "version": "^9.8.2",
- "defaultDependency": false
}
], - "initializationScript": {
- "script": "var foo = 8;"
}, - "environmentVariables": {
- "CHATKITTY_CLIENT_SECRET": "34e65736-70c2-4d30-b80a-8ad9887c860b",
- "CHATKITTY_CLIENT_ID": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "CHATKITTY_APPLICATION_ID": "1",
}, - "_links": {
- "dependencies": {
}, - "initializationScript": {
},
}
}
Returns a thread by ID
id required | integer <int64> Reply thread ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/threads/67528' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 67528,
- "type": "MAIN",
- "properties": { },
- "createdTime": "2022-02-04T13:19:06.764939Z",
- "_links": {
}
}
Sends keystrokes in this thread on behalf of a user
id required | integer <int64> |
keys required | string |
user required | object (ChatUserReference) Reference to a user |
{- "keys": "string",
- "user": {
- "username": "jane@chatkitty.com"
}
}
{- "keys": "string",
- "username": "string",
- "_links": [
- {
- "href": "string",
- "hreflang": "string",
- "title": "string",
- "type": "string",
- "deprecation": "string",
- "profile": "string",
- "name": "string",
- "templated": true
}
]
}
Returns a page of replies sent in this thread
id required | integer <int64> |
size | integer <int32> The size of the page to be returned |
start | integer <int64> Start cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
next | integer <int64> Next page cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch subsequent pages |
relation | string Enum: "SELF" "PREVIOUS" "NEXT" Page cursor relation. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/threads/1/messages' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "messages": [
- {
- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}, - {
- "id": 44701,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "test",
- "properties": { },
- "createdTime": "2021-09-16T14:57:55.903Z",
- "_links": {
}
}, - {
- "id": 44700,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "hi",
- "properties": { },
- "createdTime": "2021-09-16T14:57:46.056Z",
- "_links": {
}
}, - {
- "id": 44760,
- "type": "TEXT",
- "channelId": 1255,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "do?",
- "properties": { },
- "createdTime": "2021-09-16T09:14:09.585Z",
- "_links": {
}
}, - {
- "id": 44759,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "ok",
- "properties": { },
- "createdTime": "2021-09-16T09:13:48.030Z",
- "_links": {
}
}
]
}, - "page": {
- "size": 5
}
}
Sends a reply message in this thread as the system or on behalf of a user
id required | integer <int64> |
type required | string |
group_tag | string Optional string to associate this message with other messages. Can be used to group messages into a gallery |
object Custom data associated with this message | |
user | object (ChatUserReference) Reference to a user |
body required | string The text body of this message |
{- "type": "TEXT",
- "body": "Hello, World!"
}
{- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}
Returns a page of user sessions belonging to this application
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
state | string Enum: "ACTIVE" "ENDED" Filters by state |
{- "_embedded": {
- "sessions": [
- {
- "id": 635627,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-11-12T08:25:27.253Z",
- "createdTime": "2021-11-12T08:02:34.122Z",
- "_links": {
}
}, - {
- "id": 635641,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-11-12T08:35:08.587Z",
- "createdTime": "2021-11-12T08:25:33.885Z",
- "_links": {
}
}, - {
- "id": 635669,
- "user": {
- "id": 39806,
- "type": "PERSON",
- "name": "c6f75947-af48-4893-a78e-0e0b9bd68580",
- "displayName": "Julie Jaxton",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-11-12T08:55:36.282Z",
- "createdTime": "2021-11-12T08:38:54.982Z",
- "_links": {
}
}, - {
- "id": 635644,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-11-12T08:54:48.309Z",
- "createdTime": "2021-11-12T08:45:13.682Z",
- "_links": {
}
}, - {
- "id": 635651,
- "user": {
- "id": 39805,
- "type": "PERSON",
- "name": "b2a6da08-88bf-4778-b993-7234e6d8a3ff",
- "displayName": "Joni Jordyn",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "state": "ENDED",
- "userAgent": "ChatKitty-JS/1.50.0",
- "endTime": "2021-11-12T09:06:40.409Z",
- "createdTime": "2021-11-12T09:04:53.490Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 1645,
- "totalPages": 329,
- "number": 0
}
}
Returns a page of users belonging to this application
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
name | string Filters by username |
properties | string Filters by user custom properties |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/users?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "users": [
- {
- "id": 14503,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3004,
- "type": "PERSON",
- "name": "1",
- "displayName": "ChatKittyUser",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6152,
- "type": "PERSON",
- "name": "10zxc13@gmail.com",
- "displayName": "Jack",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 3353,
- "type": "PERSON",
- "name": "12121",
- "displayName": "12121",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}, - {
- "id": 6602,
- "type": "PERSON",
- "name": "123",
- "displayName": "123",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
- "displayPicture": {
},
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 571,
- "totalPages": 115,
- "number": 0
}
}
Creates a new user
display_name required | string Human readable name of this user. Shown to other users |
is_guest required | boolean True if this user was created by a guest user session |
name required | string The unique name used to identify this user across ChatKitty. Also known as username |
object Custom data associated with this user |
{- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "isGuest": false,
- "properties": {
- "favoriteNumber": 42
}
}
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}
Checks if a user exists
name required | string Username of the user |
curl --location --request 'HEAD' \ 'https://api.chatkitty.com/v1/users?name=Jane%20Doe' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{ }
Returns a user by ID
id required | integer <int64> User ID |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/users/1' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}
Delets a user
id required | integer <int64> User ID |
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/users/1' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "key": "19b458d0-2b50-491c-8f13-65ec12f3978e",
- "properties": { },
- "created_time": "2020-10-02T20:29:25.316Z",
}
Updates a user
id required | integer <int64> User ID |
{ }
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}
Returns a page of channels for this user created or joined
id required | integer <int64> User ID |
page | integer >= 0 Default: 0 Zero-based page index (0..N) |
size | integer >= 1 Default: 25 The size of the page to be returned |
sort | Array of strings Sorting criteria in the format: property,(asc|desc). Default sort order is ascending. Multiple sort criteria are supported. |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/users/1/channels?page=0&size=25' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "channels": [
- {
- "id": 15252,
- "type": "DIRECT",
- "creator": {
- "id": 19652,
- "type": "PERSON",
- "name": "rexyfexy@gmail.com",
- "displayName": "doark",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "members": [
- {
- "id": 19652,
- "type": "PERSON",
- "name": "rexyfexy@gmail.com",
- "displayName": "doark",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - {
- "id": 19452,
- "type": "PERSON",
- "name": "aa",
- "displayName": "emra",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}
], - "properties": { },
- "createdTime": "2021-05-05T00:38:24.888Z",
- "_links": {
- "participants": {
},
}
}, - {
- "id": 55913,
- "type": "PUBLIC",
- "name": "b0a0bd55-921a-4f72-8ee3-f26c6fda0bb7",
- "displayName": "Our public channel",
- "properties": { },
- "createdTime": "2021-09-28T01:35:40.967Z",
- "_links": {
- "participants": {
},
}
}, - {
- "id": 2402,
- "type": "PUBLIC",
- "name": "#test",
- "displayName": "Test Channel",
- "creator": {
- "id": 4153,
- "type": "PERSON",
- "name": "test@mail.com",
- "displayName": "mridx",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "properties": { },
- "createdTime": "2020-12-13T21:12:09.195Z",
- "_links": {
}
}, - {
- "id": 856,
- "type": "PUBLIC",
- "name": "mkm",
- "displayName": "Meme Channel",
- "creator": {
- "id": 1504,
- "type": "PERSON",
- "name": "njnj@vghf.jk",
- "displayName": "mkm",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "lastReceivedMessage": {
- "id": 17654,
- "type": "TEXT",
- "channelId": 856,
- "user": {
- "id": 15402,
- "type": "PERSON",
- "name": "paras@code.co",
- "displayName": "Paras",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "body": "ghk",
- "properties": { },
- "createdTime": "2021-03-31T06:00:28.680Z"
}, - "properties": { },
- "createdTime": "2020-11-25T07:46:45.775Z",
- "_links": {
}
}, - {
- "id": 1302,
- "type": "PUBLIC",
- "name": "SONU KUMAR",
- "displayName": "SONU KUMAR",
- "creator": {
- "id": 2302,
- "type": "PERSON",
- "name": "852122",
- "displayName": "SONU KUMAR",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "lastReceivedMessage": {
- "id": 44530,
- "type": "TEXT",
- "channelId": 1302,
- "user": {
- "id": 39826,
- "type": "PERSON",
- "name": "steve@innersync.com",
- "displayName": "Steve Williams",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "callStatus": "AVAILABLE",
- "properties": { }
}, - "body": "Checking out",
- "properties": { },
- "createdTime": "2021-09-14T18:02:56.066Z"
}, - "properties": { },
- "createdTime": "2020-12-02T05:10:01.260Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5,
- "totalElements": 2020,
- "totalPages": 404,
- "number": 0
}
}
Updates a user's display picture
id required | integer <int64> User ID |
content_type required | string File MIME content type |
name required | string File name |
size required | integer <int64> File size in bytes |
url required | string External file URL |
{- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}
Returns a page of messages sent by this user
id required | integer <int64> User ID |
size | integer <int32> The size of the page to be returned |
start | integer <int64> Start cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
next | integer <int64> Next page cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch subsequent pages |
relation | string Enum: "SELF" "PREVIOUS" "NEXT" Page cursor relation. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
unread | boolean Filters by returning unread messages |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/users/1/messages' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "messages": [
- {
- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T20:45:33.696Z",
- "_links": {
}
}, - {
- "id": 44701,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "test",
- "properties": { },
- "createdTime": "2021-09-16T14:57:55.903Z",
- "_links": {
}
}, - {
- "id": 44700,
- "type": "TEXT",
- "channelId": 802,
- "user": {
- "id": 39906,
- "type": "PERSON",
- "name": "sean.donald@gmail.com",
- "displayName": "zolo",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "hi",
- "properties": { },
- "createdTime": "2021-09-16T14:57:46.056Z",
- "_links": {
}
}, - {
- "id": 44760,
- "type": "TEXT",
- "channelId": 1255,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "do?",
- "properties": { },
- "createdTime": "2021-09-16T09:14:09.585Z",
- "_links": {
}
}, - {
- "id": 44759,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "ok",
- "properties": { },
- "createdTime": "2021-09-16T09:13:48.030Z",
- "_links": {
}
}
]
}, - "page": {
- "size": 5
}
}
Returns a page of notifications received by this user
id required | integer <int64> User ID |
size | integer <int32> The size of the page to be returned |
start | integer <int64> Start cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
next | integer <int64> Next page cursor value. Do not set manually. Provided by the Platform API pagination engine to fetch subsequent pages |
relation | string Enum: "SELF" "PREVIOUS" "NEXT" Page cursor relation. Do not set manually. Provided by the Platform API pagination engine to fetch previous or next pages |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/users/1/notifications' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "_embedded": {
- "notifications": [
- {
- "id": 3256308,
- "title": "System message sent",
- "body": "File attachment",
- "channel": {
- "id": 702,
- "type": "PUBLIC",
- "name": "Your Awesome Chat Room",
- "displayName": "Your Awesome Chat Room",
- "creator": {
- "id": 352,
- "type": "PERSON",
- "name": "aaron.nwabuoku@chatkitty.com",
- "displayName": "aaron.nwabuoku@chatkitty.com",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "lastReceivedMessage": {
- "id": 85103,
- "type": "SYSTEM_FILE",
- "channelId": 702,
- "file": {
- "type": "EXTERNAL",
- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}, - "properties": { },
- "createdTime": "2022-06-02T16:36:39.169379Z"
}, - "properties": { },
- "createdTime": "2020-11-23T13:03:17.292Z",
- "_links": {
}
}, - "data": {
- "message": {
- "id": 85103,
- "type": "SYSTEM_FILE",
- "channelId": 702,
- "file": {
- "type": "EXTERNAL",
- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}, - "properties": { },
- "createdTime": "2022-06-02T16:36:39.169379Z",
- "_links": {
}
}, - "channelId": 702,
- "type": "SYSTEM:SENT:MESSAGE",
- "_relays": {
- "message": "/application/v1/messages/85103.relay"
}
}, - "createdTime": "2022-06-02T16:36:54.356152Z",
- "_links": {
}
}, - {
- "id": 3255805,
- "title": "System message sent",
- "body": "Hello, World!",
- "channel": {
- "id": 702,
- "type": "PUBLIC",
- "name": "Your Awesome Chat Room",
- "displayName": "Your Awesome Chat Room",
- "creator": {
- "id": 352,
- "type": "PERSON",
- "name": "aaron.nwabuoku@chatkitty.com",
- "displayName": "aaron.nwabuoku@chatkitty.com",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "lastReceivedMessage": {
- "id": 85103,
- "type": "SYSTEM_FILE",
- "channelId": 702,
- "file": {
- "type": "EXTERNAL",
- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}, - "properties": { },
- "createdTime": "2022-06-02T16:36:39.169379Z"
}, - "properties": { },
- "createdTime": "2020-11-23T13:03:17.292Z",
- "_links": {
}
}, - "data": {
- "message": {
- "id": 85216,
- "type": "SYSTEM_TEXT",
- "channelId": 702,
- "body": "Hello, World!",
- "properties": { },
- "createdTime": "2022-06-02T16:34:58.871950Z",
- "_links": {
}
}, - "channelId": 702,
- "type": "SYSTEM:SENT:MESSAGE",
- "_relays": {
- "message": "/application/v1/messages/85216.relay"
}
}, - "createdTime": "2022-06-02T16:35:14.296158Z",
- "_links": {
}
}, - {
- "id": 1750641,
- "title": "hey sent a message",
- "body": "🌞",
- "channel": {
- "id": 702,
- "type": "PUBLIC",
- "name": "Your Awesome Chat Room",
- "displayName": "Your Awesome Chat Room",
- "creator": {
- "id": 352,
- "type": "PERSON",
- "name": "aaron.nwabuoku@chatkitty.com",
- "displayName": "aaron.nwabuoku@chatkitty.com",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "lastReceivedMessage": {
- "id": 85103,
- "type": "SYSTEM_FILE",
- "channelId": 702,
- "file": {
- "type": "EXTERNAL",
- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}, - "properties": { },
- "createdTime": "2022-06-02T16:36:39.169379Z"
}, - "properties": { },
- "createdTime": "2020-11-23T13:03:17.292Z",
- "_links": {
}
}, - "data": {
- "message": {
- "id": 44902,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39953,
- "type": "PERSON",
- "name": "hey@mailinator.com",
- "displayName": "hey",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "🌞",
- "properties": { },
- "createdTime": "2021-09-16T16:45:33.696Z",
- "_links": {
}
}, - "channelId": 702,
- "type": "USER:SENT:MESSAGE",
- "_relays": {
- "message": "/application/v1/messages/44902.relay"
}
}, - "createdTime": "2021-09-16T16:45:48.351Z",
- "_links": {
}
}, - {
- "id": 1749995,
- "title": "ho sent a message",
- "body": "ok",
- "channel": {
- "id": 702,
- "type": "PUBLIC",
- "name": "Your Awesome Chat Room",
- "displayName": "Your Awesome Chat Room",
- "creator": {
- "id": 352,
- "type": "PERSON",
- "name": "aaron.nwabuoku@chatkitty.com",
- "displayName": "aaron.nwabuoku@chatkitty.com",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "lastReceivedMessage": {
- "id": 85103,
- "type": "SYSTEM_FILE",
- "channelId": 702,
- "file": {
- "type": "EXTERNAL",
- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}, - "properties": { },
- "createdTime": "2022-06-02T16:36:39.169379Z"
}, - "properties": { },
- "createdTime": "2020-11-23T13:03:17.292Z",
- "_links": {
}
}, - "data": {
- "message": {
- "id": 44759,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39841,
- "type": "PERSON",
- "name": "ho@mailinator.com",
- "displayName": "ho",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "ok",
- "properties": { },
- "createdTime": "2021-09-16T05:13:48.030Z",
- "_links": {
}
}, - "channelId": 702,
- "type": "USER:SENT:MESSAGE",
- "_relays": {
- "message": "/application/v1/messages/44759.relay"
}
}, - "createdTime": "2021-09-16T05:14:00.993Z",
- "_links": {
}
}, - {
- "id": 1749225,
- "title": "Nisar sent a message",
- "body": "hi",
- "channel": {
- "id": 702,
- "type": "PUBLIC",
- "name": "Your Awesome Chat Room",
- "displayName": "Your Awesome Chat Room",
- "creator": {
- "id": 352,
- "type": "PERSON",
- "name": "aaron.nwabuoku@chatkitty.com",
- "displayName": "aaron.nwabuoku@chatkitty.com",
- "isGuest": true,
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "lastReceivedMessage": {
- "id": 85103,
- "type": "SYSTEM_FILE",
- "channelId": 702,
- "file": {
- "type": "EXTERNAL",
- "name": "jane.png",
- "contentType": "image/png",
- "size": 32768
}, - "properties": { },
- "createdTime": "2022-06-02T16:36:39.169379Z"
}, - "properties": { },
- "createdTime": "2020-11-23T13:03:17.292Z",
- "_links": {
}
}, - "data": {
- "message": {
- "id": 44559,
- "type": "TEXT",
- "channelId": 702,
- "user": {
- "id": 39827,
- "type": "PERSON",
- "name": "ss@dd.com",
- "displayName": "Nisar",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { }
}, - "body": "hi",
- "properties": { },
- "createdTime": "2021-09-14T20:13:37.357Z",
- "_links": {
}
}, - "channelId": 702,
- "type": "USER:SENT:MESSAGE",
- "_relays": {
- "message": "/application/v1/messages/44559.relay"
}
}, - "createdTime": "2021-09-14T20:13:49.998Z",
- "_links": {
}
}
]
}, - "_links": {
}, - "page": {
- "size": 5
}
}
Returns a user secret
id required | integer <int64> User ID |
name required | string The secret's name |
curl --location --request 'GET' \ 'https://api.chatkitty.com/v1/users/1/secrets/Secret%20Name' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "secret": "My secret is... well, I'd never tell."
}
Sets a user secret's value
id required | integer <int64> User ID |
name required | string The secret's name |
secret | object Secret value |
{- "secret": "My secret is... well, I'd never tell."
}
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}
Removes a user secret's value
id required | integer <int64> User ID |
name required | string The secret's name |
curl --location --request 'DELETE' \ 'https://api.chatkitty.com/v1/users/1/secrets/Secret%20Name' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS-TOKEN'
{- "id": 1,
- "type": "PERSON",
- "name": "jane@chatkitty.com",
- "displayName": "Jane Doe",
- "presence": {
- "status": "UNAVAILABLE",
- "online": false
}, - "properties": { },
- "_links": {
}
}