Links

Get an SLA

Get details of an SLA policy.
You are required to have the manage-livechat-sla or view-l-room permission.
URL
Requires Auth
HTTP Method
api/v1/livechat/sla/:slaId
YES
GET

Headers

Argument
Example
Required
Description
X-User-Id
myuser-name
Required
The authenticated user ID.
X-Auth-Token
myauth-token
Required
Auth token.

Path Parameters

Argument
Example
Required
Description
slaId
641daf3d7718f90c810429c8
Required
The Id of the SLA to fetch.

Example Call

curl --location 'http://localhost:3000/api/v1/livechat/sla/641daf3d7718f90c810429c8' \
--header 'X-Auth-Token: q2zjkgQt_OmYaBY4nEp50-r7yUAqVIoAqgo0jjBIws5' \
--header 'X-User-Id: rYhzFRd2QZjNwAAXX'

Example Result

Success

{
"_id": "641daf3d7718f90c810429c8",
"name": "Minimal",
"description": "2m UI creat",
"dueTimeInMinutes": 2,
"_updatedAt": "2023-03-24T14:10:05.063Z",
"success": true
}

Error

Any of the following errors can occur on the endpoint.
  • Authorization: Requires an authentication token for the request to be made.
  • No Permission: This occurs when the authenticated user doesn't have manage-livechat-sla or view-l-room permission.
  • Not Found: This error gets returned when no SLA is found with the Id provided.
Authorization
No Permission
Not Found
{
"status": "error",
"message": "You must be logged in to do this."
}
{
"success": false,
"error": "error-not-authorized"
}
{
"success": false,
"error": "SLA with id gfgfg56g429c8 not found"
}

Change Log

Version
Description
6.0.0
Added
Last modified 2mo ago
Deprecation for cloud services and apps is now extended to November 20, 2023. Rocket.Chat versions receive support for six months after release.