APOB_GRAPHQL_URL with
Authorization: Bearer <APOB_API_KEY>. Mutations use the verified account;
private-channel reads and owner controls require the owner. Public channels can be
read without login. See API authentication.
Channel is the product term. The GraphQL contract keeps its existing
names:
LiveRoom, createLiveRoom, liveRoom, roomId, and
sourceLiveRoomId. Use these names exactly as shown in requests and selections.Operations
These signatures show public arguments only:Create a channel
CreateLiveRoomInput
Supply at most one source. Omit every source for text-only generation. Select
only media you may access; the source’s type, metadata, and moderation checks
still apply. For file preparation see prepare your media.
MCP’s narrower upload objects contain only
url; do not copy their shape into a
GraphQL uploadedImage without its required dimensions.
A video source is inserted as the first ready scene. initialLength pays for
newly generated continuation, excluding that source’s duration. A source channel
uses its latest usable ready scene, if one exists; otherwise it falls back to
text-only generation. Referencing another channel creates a separate channel.
id. Channel creation and prepaid generation are asynchronous;
LIVE is not a claim that a viewer can already play the stream. The GraphQL
LiveRoom selection does not expose initialLength; MCP includes it in its
own creation receipt.
Read playback and scene state
Poll the saved channel with spaced reads and a bounded waiting policy. Display a
preparing state while the HLS player waits. A URL, successful generation, or
runtime timestamp alone is insufficient proof that the viewer’s player is
playing. Channels can close after inactivity; plan for
ENDED rather than assuming
an indefinite stream.
Discover channels and reconcile a lost receipt
listPersonalLiveRooms requires authentication and returns the caller’s channels.
listPublicLiveRooms uses the same page input and return shape for public channels.
Page size is 1–100, default 30. Use either pageNumber (starting at 1) or
previousId, not both. For cursor continuation, pass the last returned channel ID
with pageSize and omit pageNumber. Check hasMore.
For an uncertain creation, inspect the same account’s channel history by time and
prompt before submitting again. A similar prompt alone is not proof that two
requests are the same operation. Preserve the approximate request time and any
receipt or error for investigation.
Add scenes and vote
roomId, nonblank prompt, and integer creditAmount are required. Zero makes
a candidate without an initial vote. Positive amounts charge eligible credits.
Use your own channel or a public channel. It must be live; audience proposals require
the channel’s audience policy to permit them. Owner requests funding more than 15 seconds can
create a batch of 5–15 second scenes, at most 1000. The response contains the
first scene; inspect channel scene lists for the rest.
roomId, sceneId, and integer creditAmount are required. Amounts must be
nonnegative and fit GraphQL Int (0–2147483647). A zero vote uses the account’s
one free vote per scene, adding 100 weight. A positive vote charges that many
eligible credits and adds equal weight. useFreeVote: true means this caller
has already used the free vote. creditAmount in the vote receipt records what
that vote charged; votedCreditAmount is total vote weight, including free votes.
Selection requires enough vote weight to fund at least ten seconds. A candidate
or a free vote does not guarantee selection, generation, or playback. Invalid
channel/scene relationships, ended channels, ineligible scenes, moderation rejection,
and insufficient credits remain errors.
Owner controls
Only the channel owner can change audience creation, stop, or reopen. Run each mutation separately with the appropriate variables.initialPrompt to reuse the old prompt.
Store the new ID; the previous channel remains ended.
Credits and duration planning
Read current configured rates rather than hard-coding prices:live480PVideoContentGeneration and
live768PVideoContentGeneration. For Live, unitAmount is milliseconds.
Initial generation splits the normalized duration into segments of at most
15 seconds, with a minimum five-second tail. Each segment costs
ceil(segmentDurationMs / unitAmount) * cost credits under its configured rate.
For example, initialLength: 16000 plans a 15-second segment plus a five-second
segment. The duration requested is not an exact price or output-duration guarantee.
Initial generation uses the rate’s configured eligible credit categories.
Positive scene creation and paid voting use common (general-purpose) credits.
A total balance can include ineligible credits. Automatic reload can have separate
payment effects according to the account and connection’s policy; inspect
credits and billing.
Handle errors without duplicating work
Read GraphQLerrors even on HTTP 200, and retain any returned channel/scene IDs
when the response is partial. A timeout, field error, or lost response can occur
after a write was accepted. Create, reopen, scene, and paid-vote operations can
spend credits again if repeated. There is no create idempotency key in these
public operations.
Reconcile existing channels, scenes, votes, and account activity before considering
another write. Retry reads using the same ID. Do not bypass access, moderation,
audience, lifecycle, or credit rejection by switching from API to MCP. See
Live troubleshooting.