Skip to content

Click2CallGetDialRules

GET click2call/dialRules/list

Returns the dial rules of the brand. For the rules a specific manager can actually use, see Click2CallGetMyProfiles — it returns them already grouped by profile.

Access Control

Allowed role: admin, within the brand of the caller.

Request

GET request
GET https://{broker_domain}/click2call/dialRules/list?limit=50&where=%7B%22profileId%22%3A3%7D
Authorization: <JWT_TOKEN>
{
  "command": "Click2CallGetDialRules",
  "extID": "1",
  "data": {
    "limit": 50,
    "where": {
      "profileId": 3
    }
  }
}
const res = await platform.Click2CallGetDialRules({
  limit: 50,
  where: {
    profileId: 3
  }
});

Request Data

Field Type Required Description
limit int No Page size, 1..1000, default 100
offset int No Rows to skip
orderBy array No Sorting, for example ["id", "DESC"]
count array No Row count aggregate, ["id"]
where object No Filters, see Table filter syntax

Response Data

{
  "rows": [
    {
      "id": 7,
      "brand": "default",
      "profileId": 3,
      "countryCode": "380",
      "countryName": "Ukraine",
      "name": "UA outside line",
      "dialPrefix": "9",
      "dialPostfix": null,
      "status": "ENABLED"
    }
  ]
}

Errors

Code Error Description
401 PERMISSION_DENIED Not an admin session