Encoding JobsQuery Encoding Jobs

Query Encoding Jobs

Multi-purpose POST endpoint. Behaviour depends on body content: - No body + query string r / r&i: filter jobs by date range and optionally zone. - Body view=job: get single job details by jobid and index (form-encoded). - Body view=new: get new / polling jobs (form-encoded).

curl -X POST "https://api.5centscdn.com/v2/transcoding?r=2024-01-15%2000%3A00%20-%202024-01-31%2023%3A59&i=5678" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_API_KEY" \
  -d '{
  "view": "job",
  "jobid": 12345,
  "index": 0,
  "jobids": [
    101,
    102
  ]
}'
{
  "zonesInRange": [
    12345,
    67890,
    11111
  ],
  "logsInRange": [],
  "billed": {
    "jobs": 0,
    "secs": 0,
    "mins": "0 mins",
    "sourceMins": "0 mins",
    "completed": 0,
    "active": 0
  }
}
POST
/transcoding
POST
Base URLstring

Target server for requests. Edit to use your own host.

API Key (header: X-API-Key)
X-API-Keystring
Required

API key (sent in header)

query
rstring

Date-time range filter. Format: YYYY-MM-DD HH:mm - YYYY-MM-DD HH:mm. Maximum span is 31 days; time component is required.

query
iinteger

Optional integer filter to restrict results to a specific zone or profile.

Content-Typestring
Required

The media type of the request body

Options: application/json
viewstring

Switches the query operation. job = fetch paginated job list filtered by date range. new = poll for status updates on specific job IDs (requires jobids[]).

Options: job, new
jobidinteger

Job ID. Required when view=job.

indexinteger

Job index. Required when view=job.

jobidsarray

Array of job IDs to check for status updates. Required when view=new. Sent as repeated URL-encoded params (e.g. jobids[]=101&jobids[]=102).

Request Preview
Response

Response will appear here after sending the request

Authentication

header
X-API-Keystring
Required

API Key for authentication. Provide your API key in the header.

Query Parameters

rstring

Date-time range filter. Format: YYYY-MM-DD HH:mm - YYYY-MM-DD HH:mm. Maximum span is 31 days; time component is required.

Example:
2024-01-15 00:00 - 2024-01-31 23:59
iinteger

Optional integer filter to restrict results to a specific zone or profile.

Example:
5678

Body

application/json
viewstring

Switches the query operation. job = fetch paginated job list filtered by date range. new = poll for status updates on specific job IDs (requires jobids[]).

Allowed values:jobnew
jobidinteger

Job ID. Required when view=job.

Example:
12345
indexinteger

Job index. Required when view=job.

Example:
0
jobidsarray

Array of job IDs to check for status updates. Required when view=new. Sent as repeated URL-encoded params (e.g. jobids[]=101&jobids[]=102).

Example:
[101,102]

Responses

zonesInRangeinteger[]

Array of zone IDs that have encoding jobs within the queried date range.

logsInRangestring[]

Array of encoding job log entries within the queried date range.

billedobject

Billing summary for encoding jobs in the queried period.