Live Photo Pack

Upload a photo and a video to get an Android motion photo and an Apple Live Photo.

This API only packages your files. It does not generate any footage: the photo is the photo you sent and the video is the video you sent. Use it when you already have the material and want it to move on long press in a phone gallery. If you only have a photo and want it animated, use Image to Live Photo.

Choose the delivery platform with target: Android, Apple, or both (the default).

Create Task

Basic Information

ItemValue
MethodPOST
Path/task/live_photo_pack
Content-Typeapplication/json
AuthenticationAuthorization header (pass the API Key directly)

Request Parameters (Body)

NameTypeRequiredDefaultDescription
file_idstringYes—File ID of the uploaded photo: jpg / jpeg / png / webp / bmp
video_file_idstringYes—File ID of the uploaded video. Up to 1 GB and 2 hours
targetstringNobothDelivery platform: android / ios / both. Unrecognized values are treated as both
mutebooleanNofalseRemove the sound from the video

Request Example

curl -X POST https://api.ai-mcn.tv:10000/task/live_photo_pack \
  -H "Authorization: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"file_id": "537489015178246", "video_file_id": "537489015178250"}'

Apple Live Photo only, without sound:

curl -X POST https://api.ai-mcn.tv:10000/task/live_photo_pack \
  -H "Authorization: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"file_id": "537489015178246", "video_file_id": "537489015178250", "target": "ios", "mute": true}'

Success Response Example

{
  "code": 200,
  "msg": "success",
  "data": {
    "task_id": "537489015178247",
    "task_type": "live_photo_pack",
    "status": "queued"
  }
}

Query Task Result

Basic Information

ItemValue
MethodGET
Path/task/live_photo_pack/{task_id}
AuthenticationAuthorization header (pass the API Key directly)

Response Parameters (output_result)

NameTypeReturnedDescription
targetstringAlwaysThe delivery platform actually applied
file_idstringAlwaysMain product. An Android motion photo when target is android or both; the still image of the Apple Live Photo when target is ios
download_urlstringAlwaysDownload path of the main product
ios_photo_file_idstringtarget=both onlyStill image of the Apple Live Photo (.jpg)
ios_photo_download_urlstringtarget=both onlyDownload path of the above
ios_video_file_idstringtarget is ios or bothVideo of the Apple Live Photo (.mov)
ios_video_download_urlstringtarget is ios or bothDownload path of the above

Success Response Example

target=both (default):

{
  "code": 200,
  "msg": "success",
  "data": {
    "task_id": "537489015178247",
    "status": "completed",
    "progress": 100,
    "output_result": {
      "target": "both",
      "file_id": "537489015178248",
      "download_url": "/download/a1/output.jpg",
      "ios_photo_file_id": "537489015178249",
      "ios_photo_download_url": "/download/a1/output.jpg",
      "ios_video_file_id": "537489015178251",
      "ios_video_download_url": "/download/a1/output.mov"
    },
    "create_time": "2026-09-15T08:00:00Z",
    "update_time": "2026-09-15T08:00:12Z"
  }
}

target=ios:

{
  "code": 200,
  "msg": "success",
  "data": {
    "task_id": "537489015178247",
    "status": "completed",
    "progress": 100,
    "output_result": {
      "target": "ios",
      "file_id": "537489015178248",
      "download_url": "/download/a1/output.jpg",
      "ios_video_file_id": "537489015178251",
      "ios_video_download_url": "/download/a1/output.mov"
    },
    "create_time": "2026-09-15T08:00:00Z",
    "update_time": "2026-09-15T08:00:12Z"
  }
}

Output Specification

Android Motion Photo

The main product is a single .jpg file: your video is embedded after the still image, and metadata inside the image declares where it is. It is also an ordinary image that any viewer can open; Android galleries that support the standard recognize it as a motion photo and play it on long press.

ItemDescription
ContainerJPEG (still image + embedded MP4, single file)
Still imageKeeps the original resolution, center-cropped to the video aspect ratio so the still and the motion match
Embedded videoH.264 / HEVC picture is not re-encoded; if you uploaded a standard MP4, the embedded video is your original file
File sizeRoughly the photo plus the video

Apple Live Photo

An Apple Live Photo is a pair of files: a .jpg still image and a .mov video, paired by the same identifier embedded in both.

ItemDescription
Still imageJPEG, original resolution, center-cropped to the video aspect ratio; shooting metadata of the original photo is kept
VideoMOV; H.264 / HEVC picture is not re-encoded
PairingEvery task generates a new identifier, so submitting the same files twice gives two unrelated Live Photos

Video Handling

  • H.264 or HEVC video is not re-encoded; only the container changes.
  • Video in any other codec is transcoded to H.264 first, with a slight quality loss.
  • If the file has several picture streams (for example a cover image), only the real video is kept.
  • With mute=true the sound is removed for both platforms; sound is kept by default.

Compatibility

Please confirm your target scenario before integrating:

Apple

  • The still image and the video must be imported together in the same import to be recognized as a Live Photo. Working options: select both files and import them in the Photos app on a Mac (it syncs to iPhone via iCloud), or save both files at once through the system photo library API in your own app.
  • Downloading the two files on an iPhone and saving them to the gallery one by one does not pair them; you get a photo and a video.
  • Programmatically created Live Photos cannot be set as a live wallpaper. This is a system limitation.

Android

  • Galleries on Pixel, Xiaomi, Samsung and other devices that support the standard recognize and play it.
  • Implementations differ between vendors; a few devices may show only the still image.
  • The iOS gallery does not recognize Android motion photos and shows a plain still image.

Processing Time

Standard H.264 / HEVC video usually finishes within seconds to a minute. Videos that need transcoding take longer the longer they are. The task runs asynchronously; poll status through the query API after submitting.

Tips

  • Aspect ratio: the still image is cropped to the video aspect ratio. To keep the photo composition, make the video and the photo the same aspect ratio.
  • Video length: native Live Photos are about 3 seconds. Very long videos load slowly in some galleries or show only the still image; keeping it under a dozen or so seconds is recommended.
  • Billing: charged per task, regardless of video length or size. See Pricing for the actual price.

Error Codes

CodeHTTP StatusDescriptionSolution
6013400file_id or video_file_id is missingBoth parameters are required
6014400File type does not match the parameterPass a photo as file_id and a video as video_file_id
6004404File not foundCheck the file IDs
6002413Video larger than 1 GBCompress or trim the video and upload again
6019400Video duration is 0 or longer than 2 hoursTrim the video and upload again
6017400Video cannot be parsedCheck whether the video is damaged, or export it in another format
6502401Authentication failedCheck the Authorization header
6202402Insufficient balanceTop up in the dashboard