Name speakers
curl --request PATCH \
--url https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"names": {
"S01": "John F. Kennedy"
}
}
'import requests
url = "https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers"
payload = { "names": { "S01": "John F. Kennedy" } }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({names: {S01: 'John F. Kennedy'}})
};
fetch('https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers', 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.eesi.ai/v1/speech/transcriptions/{session_id}/speakers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'names' => [
'S01' => 'John F. Kennedy'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers"
payload := strings.NewReader("{\n \"names\": {\n \"S01\": \"John F. Kennedy\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"names\": {\n \"S01\": \"John F. Kennedy\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"names\": {\n \"S01\": \"John F. Kennedy\"\n }\n}"
response = http.request(request)
puts response.read_body{
"speaker_names": {
"S01": "John F. Kennedy"
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Audio intelligence
Name speakers
Name the voices in one recording ({"names": {"S01": "Ada"}}). For
recordings in a project, name the project speaker instead, so the name shows in
every clip: PATCH /v1/speech/projects/{project}/speakers/{speaker_id}.
PATCH
/
v1
/
speech
/
transcriptions
/
{session_id}
/
speakers
Name speakers
curl --request PATCH \
--url https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"names": {
"S01": "John F. Kennedy"
}
}
'import requests
url = "https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers"
payload = { "names": { "S01": "John F. Kennedy" } }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({names: {S01: 'John F. Kennedy'}})
};
fetch('https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers', 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.eesi.ai/v1/speech/transcriptions/{session_id}/speakers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'names' => [
'S01' => 'John F. Kennedy'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers"
payload := strings.NewReader("{\n \"names\": {\n \"S01\": \"John F. Kennedy\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"names\": {\n \"S01\": \"John F. Kennedy\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eesi.ai/v1/speech/transcriptions/{session_id}/speakers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"names\": {\n \"S01\": \"John F. Kennedy\"\n }\n}"
response = http.request(request)
puts response.read_body{
"speaker_names": {
"S01": "John F. Kennedy"
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
BearerAuthApiKeyHeader
Your EESI API key, sk-eesi-....
Path Parameters
Body
application/json
Names by the recording's own speaker labels, such as S01. An empty name clears it.
Show child attributes
Show child attributes
Response
Successful Response
The response is of type Response Rename Speakers V1 Speech Transcriptions Session Id Speakers Patch · object.