Audio Emotion API

Update Speaker Roles

Changed on

Set declared speaker roles (agent, customer, system, or media) by speaker_id.

system and media mark known non-human audio, such as a voice assistant or music. They are not a party. Send null to clear.

Merge-by-id: a role write does not clobber name, and a rename does not clobber role. Unknown ids 422 the whole batch. Audio must be completed. Owner or media:write.

A re-diarising reprocess, a trim, or a transcript replace drops these roles (#1361 writes a role-less speakers list before dispatch). Re-apply them afterwards.

The names PUT response is still {speaker_id, name} only — if D1 refreshes local state from it, role chips vanish until reload. This response returns the full speaker list including role.

put/v1/audios/{audio_id}/speakers/roles

Request

  • Base URL
    https://api.imentiv.ai (the document declares no server; this is the origin it was published from)
  • Auth
    • API key in header X-API-Key
    • or HTTP bearer

Path parameters

audio_idstring required

Unique identifier of the audio file

Request body

speaker_idinteger required
role'agent' | 'customer' | 'system' | 'media' nullable required

Response

Successful Response

speakersobject[] required

Changes