Query AI clear AD task status and results
Name | Description |
---|---|
*taskIdString | AI clear AD task ID |
Name | Description |
---|---|
codeInteger | Status code |
messageString | Operational information |
dataObject | Return data |
taskIdString | AI clear AD task ID |
statusInteger | Status:
0(not started)
1(in progress)
2(Successful)
3(failure) |
outputString | New video ID |
Error code(code) | Description(message) | HTTP status | Semantic |
---|---|---|---|
1000 | Parameter error | 200 | Parameter error |
1000 | The task does not exist or has no permission | 200 | The task does not exist or has no permission |
#!/bin/bash username='example_username' apiKey='example_apiKey' date=`env LANG="en_US.UTF-8" date -u "+%a, %d %b %Y %H:%M:%S GMT"` password=`echo -en "$date" | openssl dgst -sha1 -hmac $apiKey -binary | openssl enc -base64` curl -i --url "https://api.cdnetworks.com/vod/ai/clearAdTaskQuery" \ -X "POST" \ -u "$username:$password" \ -H "Date: $date" \ -H "x-cnc-auth-method: BASIC" \ -H "Accept: application/json" \ -H "Content-Type: application/json" \ -d '{ "taskId": "idxxxxxx" }'
{ "code": 200, "data": { "output": "ab02dc9dca2a11eaab73c5d6f877d847", "status": 2, "taskId": "4ced37bc-ca2a-11ea-8653-ac61753fd979" }, "message": "Operation succeeded" }