● nureta
Docs

Script

Turn a one-line idea into a structured adult storyboard: title, characters, per-scene setting, beat and duration. Flat $0.01 per script, no render.

Script generation shares the authentication, task routes, callbacks and errors documented in the Overview.

Create a script task

Generate a text storyboard only. The price is reserved from your balance.

POST /api/v3/contents/scripts

A script task uses the same v3 director as the video path, but it stops after writing the script. It makes no character/background images and no video render. The price is a flat $0.01 per script, regardless of length. duration scales how many scenes the script has.

curl -s -X POST "$NURETA_URL/api/v3/contents/scripts" \
  -H "Authorization: Bearer sk-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seahorse-script",
    "content": [
      {"type": "text", "text": "a lonely lighthouse keeper finds a message in a bottle"}
    ],
    "duration": 30,
    "callback_url": "https://example.com/webhooks/nureta-developer"
  }'
# => HTTP 201 with the task view (see Retrieve a script task)

Fields

FieldRequiredNotes
modelyesseahorse-script (see Script models & pricing).
contentyesExactly one text item (the story idea).
durationnoAn integer, 5–180 seconds (default 30). It scales the scene count but not the price.
callback_url, callback_secretnoThey work as elsewhere.

Response

201 with the task view. On success the task carries content.script: the title, the lead character's name, and per-scene setting / beat / durationSeconds.

Errors

CodeHTTPWhen
InvalidParameter400A field is missing or invalid.
AccountOverdueError403Your balance cannot cover the task.
ModelNotFound404Unknown model id.

All codes are in Errors.

Retrieve a script task

Poll one script task until status is succeeded or failed.

GET /api/v3/contents/scripts/:id

curl -s "$NURETA_URL/api/v3/contents/scripts/cgt-..." \
  -H "Authorization: Bearer sk-..."
# => {"id":"cgt-...","model":"seahorse-script","status":"succeeded","duration":30,
#      "created_at":1781220000,"updated_at":1781220045,
#      "prompt":"a lonely lighthouse keeper finds a message in a bottle",
#      "usage":{"price_usd":0.01,"refunded":false},
#      "step":{"code":"done"},
#      "content":{"script":{
#      "title":"The Bottle","characters":["Elias"],
#      "scenes":[{"index":1,"setting":"A storm-lashed lighthouse",
#                 "beat":"Elias spots a bottle bobbing in the surf","durationSeconds":8}]}}}

Response

The task view. On success it carries content.script. On failure it carries an error, and the $0.01 is refunded automatically.

FieldNotes
id, model, statusTask id, model id and status.
prompt, durationYour inputs.
created_at, updated_atUnix timestamps in seconds.
usageprice_usd charged and whether it was refunded.
stepThe current phase ({"code": "done"} on success).
content.scriptOnly on success: title, characters (the lead character's name: an array with zero or one name), and scenes[] with index, setting, beat and durationSeconds.
errorOnly on failure, instead of content: {"code", "message"}.

Errors

CodeHTTPWhen
NotFound404Unknown task id, or a task of another kind.

List script tasks

List your script tasks, newest first.

GET /api/v3/contents/scripts?limit=20&offset=0

curl -s "$NURETA_URL/api/v3/contents/scripts?limit=20&offset=0" \
  -H "Authorization: Bearer sk-..."
# => {"items": [task, ...], "total": N}
Query parameterNotes
limit1–100 (default 20).
offsetThe number of tasks to skip.

Response

{"items": [task, ...], "total": N}. Each item has the task view shape.

Errors

The shared codes in Errors.

Delete a script task

Delete a finished task (succeeded or failed).

DELETE /api/v3/contents/scripts/:id

curl -s -X DELETE "$NURETA_URL/api/v3/contents/scripts/cgt-..." \
  -H "Authorization: Bearer sk-..."
# => {}

Response

200 {}.

Errors

CodeHTTPWhen
NotFound404Unknown task id, or a task of another kind.
Conflict409The task is not finished.
RateLimitExceeded429Your account already deleted 10 tasks in the last 60 seconds. Deletions on the website count too.

Script models & pricing

GET /api/v3/scripts/models (public) returns the script model and its flat per-script price.

ModelUSD / script
seahorse-script$0.01

Guides