Newsletter to audio: a 2,000-word issue costs about $0.57

A 2,000-word newsletter is about 12,000 characters, which fits one Sume TTS request under the 20,000 limit and bills $0.57. When to split, and a Python loop.

3 min readSume
All posts

A 2,000-word newsletter issue turns into audio for about $0.57 on Sume TTS. At a rough six characters per word including spaces (my planning assumption), the issue is around 12,000 characters, under the 20,000-character limit per request, so it is one job.

Issue size to bill

Sume billed price at $0.0475 per 1,000 characters
WordsCharacters (assumed)RequestsSume TTS
5003,0001$0.1425
200012,0001$0.57
350021,0002$0.9975
500030,0002$1.425

Splitting longer pieces

Above 20,000 characters, split on paragraph boundaries, not mid-sentence, so each file starts clean. Then join the files without a gap using Timeline audio concat, which accepts 1 to 20 ordered parts and joins in the sample domain with no re-synthesis.

import os, re, requests

text = open("issue.txt", encoding="utf-8").read()
chunks, cur = [], ""
for para in re.split(r"\n\s*\n", text):
    if len(cur) + len(para) + 2 > 18000 and cur:
        chunks.append(cur); cur = ""
    cur += para + "\n\n"
if cur.strip():
    chunks.append(cur)
for i, c in enumerate(chunks):
    r = requests.post("https://api.sume.com/v1/tts-1.0/generate",
        headers={"Authorization": "Bearer " + os.environ["SUME_API_KEY"],
                 "Idempotency-Key": f"nl-issue-12-part-{i}"},
        json={"transcript": c.strip(), "voice": {"id": os.environ["VOICE_ID"]}})
    print(i, len(c), r.status_code)

Practical notes

A single TTS job that would run longer than 1,200 seconds of audio fails with tts_duration_exceeded, so keep very dense parts well under the 20,000-character cap. TTS is an asynchronous job; poll the job or take a webhook, then read the mirrored audio artifact. A stable Idempotency-Key per part means a retry returns the first job instead of charging twice.

Weekly for a year is $29.64 of voice at the 12,000-character size. The recurring cost is the human review of how it reads aloud, not the API.

Related posts

More in Use cases

All Use cases posts

Written by Sume