Atmee.aiDocs

Generation

Make what an avatar or a video needs: portraits from a description, an enhanced or restyled photo, a designed voice, or a short video clip. Paid per call, charged only when something comes back.

Four calls make media for you. Each one is paid, and charged only when at least one result comes back.

CallYou sendYou get backGuide
POST /v1/generation/portraitsA description of an invented characterUp to four portraitsPortraits and enhancement
POST /v1/generation/enhancementsA photo, and optionally how to restyle itUp to four portraits of the same personPortraits and enhancement
POST /v1/generation/voicesA description of how the voice should soundVoice previews of 10 to 60 secondsVoice design
POST /v1/generation/clipsAn image and a prompt, audio optionalAn mp4 of up to 15 secondsVideo generation

Portraits, enhancements and voices make what an avatar is built from; pass the result straight to Create an avatar. A clip needs no avatar at all.

What every call has in common

  • A key with two scopes: generation:write and avatars:write. Without both, the call answers 403 insufficient_scope. See API keys.
  • An Idempotency-Key header with a new UUID for each new request. Sending the same request again with the same key never charges twice: it returns the first result with replayed: true. Reuse a key only to retry identical inputs; any change needs a new key.
  • Results come back as uploads. Each output is upload:<uploadId>, which works once, for one avatar, and expires 24 hours after it was made, with a short-lived url to view, play or download it. Save what you want to keep straight away.
  • You pay only for results. A flagged, failed or refused call costs nothing, and so does a replay. Each answer's microcreditsCharged says what the call cost, in hundredths of a credit (100 is 1 credit), and GET /v1/account lists each call's price under pricing.generation.
  • Inputs are moderated first. Descriptions, prompts, sample text and photos are checked before anything is made; a flagged input answers moderation_flagged and costs nothing.
  • Never make a real person from a description. For a real person, enhance their own photo, with their permission.

Errors

StatuserrorWhat to do
400invalid_inputFix the field it names. Also an Idempotency-Key that isn't a UUID, or was used with other inputs.
400moderation_flaggedChange the input, and send it with a new key. Nothing was charged.
402insufficient_credits, api_key_spend_cap_reachedBuy an add-on credit pack, or raise the key's cap. Don't retry until you have.
403insufficient_scopeUse a key with generation:write and avatars:write.
409request_in_progressStill running. Wait Retry-After seconds and send the same request with the same key.
429rate_limitedToo many calls running or in the last minute. Wait Retry-After, then retry with the same key.
502provider_failedNothing usable came back, and nothing was charged. Retrying with the same key is safe.
503generation_unavailableGeneration isn't offered here.
Generation — Atmee Docs