14.2
On June 5th, 2021, Help Lightning released version 14.2 of its server software. This version contains several enhancements to our API that will be of interest to integrators.
Many of Help Lightning’s RESTful APIs take a filter parameter. We have
introduced a new operator: the IN operator, which is defined using
|=
. This operator allows you to specify a list of values, and if the
key is any of those values, it will be included in the results.
For example, consider an example where you want any user whose name is John, Mary, OR Sue:
(Remember to URL encode everything and quote the filter)
GET /api/v1r1/enterprise/users?filter=%22name%7C%3DJohn%2CMary%2CSue%22
Help Lightning has also added some additional keys that can be used to filter out call data. These new keys are:
- tag.id :: Only return calls that have a tag that matches this id
- tag.name :: Only return calls that have a tag that matches this string name
- session.call_id :: Only return calls that match this id
For example, if you want to return all calls that have
avoided-rollout
as the tag, you can query:
GET /api/v1/enterprise/calls?filter=tag.name%3Davoided-rollout
You can also mix this with the new IN operator. So if you want all calls that have either the avoided-rollout, firsttime-fix, or needs-callback tags, you can query:
GET /api/v1/enterprise/calls?filter=%22tag.name%7C%3Davoided-rollout%2Cfirsttime-fix%2Cneeds-callback%22
Help Lightning already supports several webhooks primary for
integrators to utilize Help Lightning’s call signalling and push
notifications. These were all of the session
category.
In this release, we have added a new category: call
. These webhooks
relate to events that happen during a video call. The exact events
received are:
- started :: A new video call has started
- ended :: A video call has completed
- participant_joined :: A participant has joined a video call
- participant_left :: A participant has left a video call
- attachment_created :: An attachment has been created. This can currently be either a screen capture or a recording of the call
You can register your webhook either through the API or in the Developer Tools in your Help Lightning site.
Here are the full payloads for each object type:
call started
{
type: "call",
category: "started",
version: 1,
data: {
session_id: ""::string,
call_id: ""::string
},
timestamp: 0::unix_timestamp
}
call ended
{
type: "call",
category: "ended",
version: 1,
data: {
session_id: ""::string,
call_id: ""::string
},
timestamp: 0::unix_timestamp
}
call participant_joined
{
type: "call",
category: "participant_joined",
version: 1,
data: {
session_id: ""::string,
call_id: ""::string,
participant: %{
id: ""::string,
name: ""::string,
email: ""::string,
avatar: ""::string,
enterprise_id: 0::integer,
anonymous: false::boolean
}
},
timestamp: 0::unix_timestamp
}
call participant_left
{
type: "call",
category: "participant_left",
version: 1,
data: {
session_id: ""::string,
call_id: ""::string,
participant: %{
id: ""::string,
name: ""::string,
email: ""::string,
avatar: ""::string,
enterprise_id: 0::integer,
anonymous: false::boolean
}
},
timestamp: 0::unix_timestamp
}
call attachment_created
{
type: "call",
category: "attachment_created",
version: 1,
data: {
session_id: ""::string,
call_id: ""::string,
attachment: {
id: ""::string,
name: ""::string,
type: ""::string
}
},
timestamp: 0::unix_timestamp
}