Skip to content
Lumean API

Descriptions are in English

The section interface is translated into your language, but descriptions of operations, schemas and errors exist only in Russian and English — the English version is shown here.
GET/orders/{order}/items/{item}/text

Get Order Item Text

Returns the text the chunk was generated from.

The main use is fixing a policy_flagged chunk: the provider rejected the content, and retrying the same text will be rejected again. The sequence is: fetch the text here → rephrase the problematic part → send POST /orders/{order}/items/{item}/retry with a text field.

The API does not report why the content was rejected — there is no such field. Edit the text at your own judgement.

If the text was deleted with the order's storage retention, you get 422 with reason: input_expired. It cannot be restored: create the order anew (a retry with a new text still works).

Required key permission: orders.read.

On this page(4)

Parameters

The inputs live inside the request line: fill in a value and you get a ready URL. Below are the type, whether it is required and the allowed values of every parameter.

GEThttps://api.lumean.app/api/public/orders//items//text
  • stringin pathrequired

    Order UUID — 36 characters shaped like 9f8b2c1a-4d3e-4f5a-8b9c-0d1e2f3a4b5c, not a number.

    Take it from the id field: POST /orders returns it on creation and GET /orders lists it. Someone else’s order will not open with your key — you get a 404.

    The value goes straight into the request line above.

  • stringin pathrequired

    Order chunk UUID — 36 characters; neither a number nor a position.

    Take it from an item’s id field: GET /orders/{order}/items returns the list, and the same set sits in items[] of the detailed order response. The chunk’s position is the neighbouring chunk_index field, which does not go into the path.

    The value goes straight into the request line above.

Possible responses

200

Success. The payload is in data.

Body example
{
  "success": true,
  "message": "Success",
  "data": {
    "text": "Welcome to our platform! This narration greets every new listener.",
    "length": 66,
    "original_text_length": 240
  }
}
Response fields
successrequired

Success flag. Branch on the HTTP status code instead: any 2xx response carries true here, while an error comes back in a different shape that need not contain this field at all.

boolean
messagerequired

A human-readable note in the account language. Fine to show to a user; do not parse it — the wording changes without notice and is not an error code.

string
datarequired

The response payload.

object
textrequired

The fragment’s text verbatim — all tags included. This is what you send to regenerate after editing.

string
lengthrequired

Full text length in characters, tags included.

integer
original_text_lengthrequired

Alias of free_length, kept for backward compatibility.

integer
free_lengthrequired

The largest already-paid length of the fragment: retries within it are free, beyond it a surcharge applies.

integer
billable_lengthrequired

How many characters of the current text are billed. Only our own pause tags {{pause=2s}} are free; [whisper] and <break/> reach the provider and are charged.

integer
max_raw_lengthrequired

Technical cap on the fragment length — how much the system will hand the worker in one piece, measured in capacity_unit. Exceeding it yields 422.

integer
max_billable_lengthrequired

Cap on billable characters. Going over makes the regeneration more expensive or unavailable.

integer
surcharge_appliesrequired

true means excess length carries a surcharge. Check it before calling regenerate so the charge is no surprise.

string
capacity_unitrequired

Unit of max_raw_length and raw_length: chars — characters, utf8_bytes — UTF-8 bytes (Fish Audio caps a request in bytes: a Cyrillic letter is 2 bytes, a Latin one is 1).

string
raw_lengthrequired

Length of the current text in capacity_unit — the value compared against max_raw_length.

integer
401

The key is missing, unknown, disabled or expired.

Analyse this response
Body example
{
  "success": false,
  "message": "API key is missing. Provide it in the X-API-KEY header.",
  "data": null
}
Response fields
successrequired

Always false in error responses.

boolean
messagerequired

Error text in the key's language (set through the X-Locale header).

string
datarequired

Always null when the request is rejected before processing.

nullable
null
403

The key lacks the required permission, or the object belongs to another user.

Analyse this response
Body example
{
  "success": false,
  "message": "This API key does not have permission to perform this action."
}
Response fields
messagerequired

Error overview.

string
404

Not found, or not reachable with this key.

Analyse this response
Body example
{
  "success": false,
  "message": "Resource not found."
}
Response fields
messagerequired

Error overview.

string
422

Validation error. Offending fields are listed in errors.

Analyse this response
Body example
{
  "success": true,
  "message": "string",
  "reason": "string",
  "error_code": "string"
}
Response fields
successrequired

Always false in error responses.

boolean
messagerequired

The reason for the rejection in words, in the account language. Meant for display; do not branch on it, the wording changes.

string
reasonrequired

Machine-readable reason of a business refusal (for example, input_expired, insufficient_balance). Branch on it, not on the message text.

string
error_coderequired

The same machine-readable code as in reason — a second name for the field. The values always match.

string

Events this produces

Progress arrives over WebSocket: polling the order in a loop is not required. Subscribing needs the same scope as reading orders.

Feed this page to an AI

Open .mdllm.md

spec 0.0.1