ZUJONOW
Book a demo
Book a demo
    Realtime communication
  • →   Tutorial

APIs

  1. Create new encoding job
  2. List all encoding jobs
  3. Show encoding job details
  4. Delete encoding

1. Create new encoding

Body parameters (JSON)

  • videoId: id recevied after uplaoding the file.
  • presets: your desired file format and resolution.
  • thumbnails: your desired thumbnail timestamp, resolution, filter, format.
  • webhookUrl: your app server url to ger notify when encoding job is done.
curl --L --X POST 'https://api.zujonow.com/api/encoder/jobs' \
--header 'Authorization: `your token goes here`' \
--header 'Content-Type: application/json' \
--data-raw '
{
"videoId": "6053115ebba24b4d700c8c49",
"presets": [
{
"resolutions": ["240", "360", "480"],
"format": "hls"
}, {
"resolutions": ["360"],
"format": "mp4"
}
],
"thumbnails": [
{
"timestamp": "00:00:03",
"resolutions": ["360"],
"formats": ["jpg", "webp"],
"filters": ["none", "blur"]
}
],
"webhookUrl":"https://<your-website-address>/<path>"
}'

Response

{
"status": "queued",
"videoId": "6053115ebba24b4d700c8c49",
"presets": [
{
"resolutions": ["240", "360", "480"],
"id": "605311c86efd284e474c5c77",
"format": "hls"
},
{
"resolutions": ["360"],
"id": "605311c86efd284e474c5c78",
"format": "mp4"
}
],
"webhookUrl": "https://<your-website-address>/<path>",
"thumbnails": [
{
"resolutions": ["360"],
"formats": ["jpg", "webp"],
"filters": ["none", "blur"],
"id": "605311c86efd284e474c5c79",
"timestamp": "00:00:03"
}
],
"createdAt": "2021-03-18T08:39:36.764Z",
"updatedAt": "2021-03-18T08:39:36.764Z",
"id": "605311c86efd284e474c5c76"
}

2. List all encodings

Query parameters

  • page: Current page you are on
  • perPage: Number of record you want on per page.
curl --L --X GET 'https://api.zujonow.com/api/encoder/jobs' \
--header 'Authorization: `jwt token goes here`'

Response

{
"pageInfo": {
"currentPage": 1,
"perPage": 20,
"lastPage": 11
},
"data": [
{
"status": "completed",
"videoId": "604efc059036d077e3bd03bc",
"presets": [
{
"resolutions": ["240", "360", "480"],
"id": "604efc0bf2bfa894b27133a0",
"format": "hls"
},
{
"resolutions": ["360"],
"id": "604efc0bf2bfa894b27133a1",
"format": "mp4"
}
],
"webhookUrl": "https://<your-website-address>/<path>",
"thumbnails": [
{
"resolutions": ["360"],
"formats": ["jpg", "webp"],
"filters": ["none", "blur"],
"id": "604efc0bf2bfa894b27133a2",
"timestamp": "00:00:03"
}
],
"createdAt": "2021-03-15T06:17:47.622Z",
"updatedAt": "2021-03-15T06:18:06.873Z",
"startedAt": "2021-03-15T06:17:50.626Z",
"finishedAt": "2021-03-15T06:18:06.871Z",
"files": [
{
"meta": {
"resolution": {
"width": 360,
"height": 640
},
"format": "mov,mp4,m4a,3gp,3g2,mj2",
"duration": 20.04
},
"jobId": "604efc0bf2bfa894b271339f",
"filePath": "files/videos/604efc189036d077e3bd03bd.mp4",
"size": 1572953,
"type": "video",
"createdAt": "2021-03-15T06:18:00.306Z",
"updatedAt": "2021-03-15T06:18:00.306Z",
"fileUrl": "https://cdn.zujonow.com/files/videos/604efc189036d077e3bd03bd.mp4",
"id": "604efc189036d077e3bd03be"
},
{
"meta": {
"resolution": {
"width": 480,
"height": 854
},
"format": "hls",
"duration": 20.04
},
"jobId": "604efc0bf2bfa894b271339f",
"filePath": "files/videos/604efc199036d077e3bd03c0",
"size": 5755392,
"type": "x-tar",
"createdAt": "2021-03-15T06:18:01.455Z",
"updatedAt": "2021-03-15T06:18:01.455Z",
"fileUrl": "https://cdn.zujonow.com/files/videos/604efc199036d077e3bd03c0/index.m3u8",
"id": "604efc199036d077e3bd03c1"
},
{
"jobId": "604efc0bf2bfa894b271339f",
"filePath": "files/images/604efc1a9036d077e3bd03c2.jpg",
"size": 24155,
"type": "image",
"createdAt": "2021-03-15T06:18:02.966Z",
"updatedAt": "2021-03-15T06:18:02.966Z",
"fileUrl": "https://cdn.zujonow.com/files/images/604efc1a9036d077e3bd03c2.jpg",
"id": "604efc1a9036d077e3bd03c3"
},
{
"jobId": "604efc0bf2bfa894b271339f",
"filePath": "files/images/604efc1b9036d077e3bd03c4.jpg",
"size": 3647,
"type": "image",
"createdAt": "2021-03-15T06:18:03.810Z",
"updatedAt": "2021-03-15T06:18:03.810Z",
"fileUrl": "https://cdn.zujonow.com/files/images/604efc1b9036d077e3bd03c4.jpg",
"id": "604efc1b9036d077e3bd03c5"
},
{
"jobId": "604efc0bf2bfa894b271339f",
"filePath": "files/images/604efc1d9036d077e3bd03c6.webp",
"size": 14976,
"type": "image",
"createdAt": "2021-03-15T06:18:05.896Z",
"updatedAt": "2021-03-15T06:18:05.896Z",
"fileUrl": "https://cdn.zujonow.com/files/images/604efc1d9036d077e3bd03c6.webp",
"id": "604efc1d9036d077e3bd03c7"
},
{
"jobId": "604efc0bf2bfa894b271339f",
"filePath": "files/images/604efc1e9036d077e3bd03c8.webp",
"size": 1296,
"type": "image",
"createdAt": "2021-03-15T06:18:06.711Z",
"updatedAt": "2021-03-15T06:18:06.711Z",
"fileUrl": "https://cdn.zujonow.com/files/images/604efc1e9036d077e3bd03c8.webp",
"id": "604efc1e9036d077e3bd03c9"
}
],
"id": "604efc0bf2bfa894b271339f"
}
...
]
}

3. Show encoding details

Path parameters

  • id : The unique identifier for the encoding (id from encode object).
curl --L --X GET 'https://api.zujonow.com/api/encoder/jobs/{id}' \
--header 'Authorization: `your token goes here`'

Response

{
"status": "completed",
"videoId": "6053115ebba24b4d700c8c49",
"presets": [
{
"resolutions": ["240", "360", "480"],
"id": "605311c86efd284e474c5c77",
"format": "hls"
},
{
"resolutions": ["360"],
"id": "605311c86efd284e474c5c78",
"format": "mp4"
}
],
"webhookUrl": "https://<your-website-address>/<path>",
"thumbnails": [
{
"resolutions": ["360"],
"formats": ["jpg", "webp"],
"filters": ["none", "blur"],
"id": "605311c86efd284e474c5c79",
"timestamp": "00:00:03"
}
],
"createdAt": "2021-03-18T08:39:36.764Z",
"updatedAt": "2021-03-18T08:39:55.069Z",
"startedAt": "2021-03-18T08:39:38.147Z",
"finishedAt": "2021-03-18T08:39:55.057Z",
"files": [
{
"meta": {
"resolution": {
"width": 360,
"height": 640
},
"format": "mov,mp4,m4a,3gp,3g2,mj2",
"duration": 20.04
},
"jobId": "605311c86efd284e474c5c76",
"filePath": "files/videos/605311d8bba24b4d700c8c4a.mp4",
"size": 1572953,
"type": "video",
"createdAt": "2021-03-18T08:39:52.743Z",
"updatedAt": "2021-03-18T08:39:52.743Z",
"fileUrl": "https://cdn.zujonow.com/files/videos/604efc189036d077e3bd03bd.mp4",
"id": "605311d8bba24b4d700c8c4b"
},
{
"meta": {
"resolution": {
"width": 480,
"height": 854
},
"format": "hls",
"duration": 20.04
},
"jobId": "605311c86efd284e474c5c76",
"filePath": "files/videos/605311d9bba24b4d700c8c4d",
"size": 5755392,
"type": "x-tar",
"createdAt": "2021-03-18T08:39:53.446Z",
"updatedAt": "2021-03-18T08:39:53.446Z",
"fileUrl": "https://cdn.zujonow.com/files/videos/605311d9bba24b4d700c8c4d/index.m3u8",
"id": "605311d9bba24b4d700c8c4e"
},
{
"jobId": "605311c86efd284e474c5c76",
"filePath": "files/images/605311d9bba24b4d700c8c4f.jpg",
"size": 24155,
"type": "image",
"createdAt": "2021-03-18T08:39:53.830Z",
"updatedAt": "2021-03-18T08:39:53.830Z",
"fileUrl": "https://cdn.zujonow.com/files/images/605311d9bba24b4d700c8c4f.jpg",
"id": "605311d9bba24b4d700c8c50"
},
{
"jobId": "605311c86efd284e474c5c76",
"filePath": "files/images/605311dabba24b4d700c8c51.jpg",
"size": 3647,
"type": "image",
"createdAt": "2021-03-18T08:39:54.140Z",
"updatedAt": "2021-03-18T08:39:54.140Z",
"fileUrl": "https://cdn.zujonow.com/files/images/605311dabba24b4d700c8c51.jpg",
"id": "605311dabba24b4d700c8c52"
},
{
"jobId": "605311c86efd284e474c5c76",
"filePath": "files/images/605311dabba24b4d700c8c53.webp",
"size": 14976,
"type": "image",
"createdAt": "2021-03-18T08:39:54.455Z",
"updatedAt": "2021-03-18T08:39:54.455Z",
"fileUrl": "https://cdn.zujonow.com/files/images/605311dabba24b4d700c8c53.webp",
"id": "605311dabba24b4d700c8c54"
},
{
"jobId": "605311c86efd284e474c5c76",
"filePath": "files/images/605311dabba24b4d700c8c55.webp",
"size": 1296,
"type": "image",
"createdAt": "2021-03-18T08:39:54.868Z",
"updatedAt": "2021-03-18T08:39:54.868Z",
"fileUrl": "https://cdn.zujonow.com/files/images/605311dabba24b4d700c8c55.webp",
"id": "605311dabba24b4d700c8c56"
}
],
"id": "605311c86efd284e474c5c76"
}

5. Delete encoding

Path parameters

  • id : The unique identifier for the encoding (id from encode object).

Note: only queued jobs can be removed, once entered into proccesing it can not be removed.

curl --L --X DELETE 'https://api.zujonow.com/api/encoder/jobs/60531471e32e8e4eaea094fe' \
--header 'Authorization: `your token goes here`'

Response

{
"status": "queued",
"videoId": "6053115ebba24b4d700c8c49",
"presets": [
{
"resolutions": ["240", "360", "480"],
"id": "60531471e32e8e4eaea094ff",
"format": "hls"
},
{
"resolutions": ["360"],
"id": "60531471e32e8e4eaea09500",
"format": "mp4"
}
],
"webhookUrl": "https://<your-website-address>/<path>",
"thumbnails": [
{
"resolutions": ["360"],
"formats": ["jpg", "webp"],
"filters": ["none", "blur"],
"id": "60531471e32e8e4eaea09501",
"timestamp": "00:00:03"
}
],
"createdAt": "2021-03-18T08:50:57.438Z",
"updatedAt": "2021-03-18T08:50:57.438Z",
"id": "60531471e32e8e4eaea094fe"
}

ZUJONOW

Make your app engaging.

+918401688331

API/SDKRealtime communicationLive streamingOn Demand VideoContent delivery

Copyright © 2021 ZUJONOW