poddub docs

edit_turn

Edit a turn

Rewrites one turn of the script by hand, in place, on the version under review. Any member who can see the episode can use it. It never changes who speaks the turn, never touches turn 0, the disclosure every episode opens with, and never edits a version after approval.

What the server says

The description an agent is given, word for word. This tool makes changes.

Rewrite one turn's text by hand, in place, on the version under review. The speaker stays. Refused with script_version_conflict (with the latest version) when version is not the latest: read the script again.

Input

FieldTypeRequiredWhat it takes
versionwhole numberyes1 or more
texttextyes1 to 800 characters
episodeIdtextyesnot empty; The episode's id, as list_episodes or create_episode answers it.
indexwhole numberyes0 or more; The turn's index in the script's turns, from 0; turn 0 is the narrator's disclosure.

Refusals

A refusal comes back as the tool's result, marked as an error, with the code and what explains it.

CodeWhat it means
episode_not_foundNo such episode among the ones the person can see.
episode_state_conflictThe episode is not in a state that allows this: a script no longer in review, or a retry of an episode that has not failed. The refusal says the state it is in.
script_not_foundThe episode has no script yet: poddub is still writing it.
script_version_conflictThe version named is not the latest, because the script changed since it was read. The refusal carries the latest version: read the script again.
turn_lockedTurn 0 is the disclosure every episode opens with, and it cannot be changed.
turn_not_foundThe script has no turn at that index.
invalid_bodyWhat was sent breaks a rule the input table cannot show: a new text that would break the script, or a fallback for a step that is not the audio, or an engine the show does not offer.

Every tool can also answer rate_limited and not_a_member: see Limits and Keys.

On this page