Quick start

Create and retrieve your first Tikdek video generation task.

Create an API key

Open the API key console, create a key, and store it in a server-side environment variable.

export TIKDEK_API_KEY="YOUR_API_KEY"

Create a video task

curl -X POST https://sora2-api.com/api/v1/video/sora-video \
  -H "Authorization: Bearer $TIKDEK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "sora-2",
    "prompt": "A slow tracking shot through a rain-lit city street",
    "aspectRatio": "16:9",
    "webHook": "-1",
    "isPublic": false
  }'

Save data.id from the response.

Retrieve the result

curl -X POST https://sora2-api.com/api/video-generations/check-result \
  -H "Authorization: Bearer $TIKDEK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "taskId": "TASK_ID" }'

Poll every 3-5 seconds until status is succeeded or failed. Use result_url when the task succeeds.