Skip to documentation
Open dashboard
On this page

Animate image

Use IMAGE_TO_VIDEO to animate an owned image. Discover a compatible model, quote its exact configuration, then submit and track the saved operation.

Prepare the image#

Replace example model IDs, reference fields and capability revisions with values from current discovery. Reference support varies by model and workflow.

Quote the animation#

curl -X POST 'https://platform.tongai.io/v1/tools/tong_generation_quote/operations' \  -H "Authorization: Bearer $TONG_API_KEY" \  -H "Content-Type: application/json" \  -H "Idempotency-Key: 45be69f1-c266-4a09-a82c-bf3c6303eb03" \  -d '{  "input": {    "body": {      "operation": "IMAGE_TO_VIDEO",      "model": "MODEL_ID_FROM_DISCOVERY",      "resolution": "720p",      "durationSeconds": 5,      "inputAssetIds": [        "aaaaaaaaaaaaaaaaaaaaaaaa"      ],      "routingParameters": {        "ratio": "16:9"      }    }  }}'
Configuration
curl --version

Submit the animation#

curl -X POST 'https://platform.tongai.io/v1/tools/tong_generation_submit/operations' \  -H "Authorization: Bearer $TONG_API_KEY" \  -H "Content-Type: application/json" \  -H "Idempotency-Key: 45be69f1-c266-4a09-a82c-bf3c6303eb03" \  -d '{  "input": {    "params": {      "id": "cccccccccccccccccccccccc"    },    "body": {      "operation": "IMAGE_TO_VIDEO",      "quoteId": "QUOTE_SUBMIT_VALUE",      "prompt": "Animate the supplied image with a slow camera push.",      "inputAssetIds": [        "aaaaaaaaaaaaaaaaaaaaaaaa"      ],      "parameters": {        "videoModel": "MODEL_ID_FROM_DISCOVERY",        "resolution": "720p",        "durationSeconds": 5,        "ratio": "16:9"      }    }  }}'
Configuration
curl --version

Follow the result#

An accepted request is not a finished generation. Track the saved job until its output is ready.

curl 'https://platform.tongai.io/v1/operations/e8aa0a87-6cd9-42eb-975a-b72bf43218c8' \  -H "Authorization: Bearer $TONG_API_KEY"
Configuration
curl --version