The API detects only the Telnyx watermark. Speech from other text-to-speech services, from third-party voices offered through Telnyx, and from Telnyx models that do not embed the watermark carries no Telnyx watermark: the result is
watermark_detected: false. A false result does not prove that the speech is human.Quickstart
Send the audio as amultipart/form-data part named file:
Reading the result
A
true result is very unlikely to be wrong: the watermark carries a checksum, and the API reports a detection only when the checksum matches. A false result means that no watermark read; the audio can still be synthetic, or watermarked audio can be too damaged to read (see What affects detection).
Confidence
When a watermark is detected,confidence is that of the best channel. Otherwise it is that of the least certain channel.
Treat
false with low confidence as inconclusive. If you have a longer or less compressed copy of the audio, check that copy.
Channels
Every channel is read on its own. In a call recorded with one channel per leg, the Telnyx text-to-speech audio is on one channel and the other party on the other;channels shows which leg carries it. Send the separate channels when you have them: in a mono mix of both parties, the other voice masks the watermark, and detection is less reliable.
What affects detection
Detection needs a few seconds of the synthesized speech. The figures below are approximate, measured on Telnyx text-to-speech output across many voices:- Low-bitrate codecs remove the watermark. AMR-NB at 7.95 kbit/s or lower, Opus at 8 kbit/s or lower, and MP3 at 16 kbit/s are not read reliably.
- Edited audio reads less well. A recording assembled from pieces, such as a clip looped or spliced, can fail to read even when each piece is watermarked.
- Repeated prompts in a call read less well. In a call with several utterances, a prompt that is replayed rather than synthesized fresh, for example from a cache, can fail to read. Freshly synthesized utterances read as one stream.
- Less than 2 seconds of audio cannot be read.
Supported audio
AAC/M4A and video containers are not supported. Convert them first, for example:
Limits and access
- The audio is held in memory for the read only. Telnyx does not store it.
- Pretrial and everroam accounts cannot use the API. Requests from those accounts fail with
403. - When detection is busy, requests fail with
503and aRetry-Afterheader. Retry after that many seconds.
Next steps
- Streaming detection: detect the watermark in a live stream, with Python and Node.js examples.
- Errors: HTTP error codes, WebSocket error frames, and close codes.