Skip to main content
GET
/
v1
/
{account_id}
/
{project_id}
/
conversations
/
concurrency
Get distribution of the maximum number of concurrent conversations
curl --request GET \
  --url https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency \
  --header 'x-api-key: <api-key>'
import requests

url = "https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency"

headers = {"x-api-key": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};

fetch('https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "x-api-key: <api-key>"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("x-api-key", "<api-key>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency")
  .header("x-api-key", "<api-key>")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.us-1.platform.polyai.app/v1/{account_id}/{project_id}/conversations/concurrency")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'

response = http.request(request)
puts response.read_body
{
  "account_id": "ACCOUNT-t53y16r3",
  "project_id": "PROJECT-f76d75c2",
  "intervals": [
    {
      "variant_id": "satdt",
      "variant_name": "variant_1",
      "language": "en-GB",
      "time": "2022-04-01T16:35:00Z",
      "max_concurrent_conversations": 25
    },
    {
      "variant_id": "satdt",
      "variant_name": "variant_1",
      "language": "en-US",
      "time": "2022-04-01T16:40:00Z",
      "max_concurrent_conversations": 20
    },
    {
      "variant_id": "satdc",
      "variant_name": "variant_2",
      "language": "en-GB",
      "time": "2022-04-01T16:35:00Z",
      "max_concurrent_conversations": 5
    }
  ]
}
{
  "error_message": "<string>"
}
{
  "error_message": "<string>"
}
{
  "error_message": "<string>"
}
{
  "error_message": "<string>"
}
{
  "error_message": "<string>"
}

Authorizations

x-api-key
string
header
required

Path Parameters

account_id
string
required

Account ID.

Example:

"ACCOUNT-t53y16r3"

project_id
string
required

Project ID.

Example:

"PROJECT-f76d75c2"

Query Parameters

start_time
string<date-time>
required

Start of the time range in ISO8601 format. Rounded down to the nearest 5-minute datetime. start_time and end_time must be no more than 1 week apart.

end_time
string<date-time>
required

End of the time range in ISO8601 format. Rounded up to the nearest 5-minute datetime. start_time and end_time must be no more than 1 week apart.

client_env
enum<string>
default:live

If set, only include conversations in this environment. Can be sandbox, pre-release or live.

Available options:
sandbox,
pre-release,
live
variant_name
string

If set, only include conversations under this variant name. You may specify either variant_id or variant_name, not both. Encode spaces as "%20".

variant_id
string

If set, only include conversations under this variant ID. You may specify either variant_id or variant_name, not both.

language
string

If set, only include conversations in this language.

phone_number
string

If set, only include conversations for this phone number.

slice_by
string

If set, slice the result intervals based on this parameter. You can slice by variant, language or phone_number. Currently language and phone_number slicing are not implemented (501).

Response

OK.

account_id
string
required

Customer PolyAI Account ID.

Example:

"ACCOUNT-t53y16r3"

project_id
string
required

Customer PolyAI Project ID.

Example:

"PROJECT-f76d75c2"

intervals
object[]
required

Array of intervals returned in ascending chronological order.

Last modified on December 10, 2025