API
Account
Download
Upload
Remote Upload
File/Folder Management
Converting files
General Information
Base-URL for our API is https://api.openload.co/1 (note the 1 for version 1 behind the /)
All requests to the API shall be HTTP/1.1 GET
Please make sure to use the API with https only.
Most requests require a API Login & API Key, you can find both in the User Panel at the "User Settings" Tab.
Response is json, structure is as follows:
{
"status": <status-code>,
"msg": "<informational message. might vary, use the status code in your code!>",
"result": <result of the request. varies depending on the request>
}
status
200: Everything is OK. Request succeeded
400: Bad request (e.g. wrong parameters)
403: Permission denied (wrong api login/key, action on a file which does not belong to you, ...)
404: File not found
451: Unavailable For Legal Reasons
509: Bandwidth usage exceeded. Please try again later or use Browser Download. (you might see this during peak hours)
50x: Server errors. You should not see this, but be prepared.
msg
This message gives more detailed information in case there is an error.
You can use this for displaying it to the user, but please don't use it for checking if the request succeeded. That's what the status code is for.
result
holds the response of the request if succeeded. Might hold an array of data or just a boolean true/false, depending on the request
Account Infos
Everything account related (total used storage, reward, ...)
Request
https://api.openload.co/1/account/info?login={login}&key={key}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"extid": "extuserid",
"email": "[email protected]",
"signup_at": "2015-01-09 23:59:54",
"storage_left": -1,
"storage_used": "32922117680",
"traffic": {
"left": -1,
"used_24h": 0
},
"balance": 0
}
}
Download Ticket
preparing a Download
Request
https://api.openload.co/1/file/dlticket?file={file}&login={login}&key={key}
Parameters
Name | Description | Example | Required |
---|---|---|---|
file | File-ID | 72fA-_Lq8Ak | yes |
login | API-Login | 5147a8f8e924bc82 | no |
key | API-Key / API-Password | Fa89_X13-37a8CKR | no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"ticket": "72fA-_Lq8Ak~~1440353112~n~~0~nXtN3RI-nsEa28Iq",
"captcha_url": "https://openload.co/dlcaptcha/b92eY_nfjV4.png",
"captcha_w": 140,
"captcha_h": 70,
"wait_time": 10,
"valid_until": "2015-08-23 18:20:13"
}
}
Download Link
get a download link by using download ticket
Request
https://api.openload.co/1/file/dl?file={file}&ticket={ticket}&captcha_response={captcha_response}
Parameters
Name | Description | Example | Required |
---|---|---|---|
file | File-ID | 72fA-_Lq8Ak | yes |
ticket | previously generated download ticket | 72fA-_Lq8Ak~~1440353112~n~~0~nXtN3RI-nsEa28Iq | yes |
captcha_response | result of the captcha, if any | captchas suck | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"name": "The quick brown fox.txt",
"size": 12345,
"sha1": "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12",
"content_type": "plain/text",
"upload_at": "2011-01-26 13:33:37",
"url": "https://abvzps.example.com/dl/l/4spxX_-cSO4/The+quick+brown+fox.txt",
"token": "4spxX_-cSO4"
}
}
File Info
check the status of a file, e.g. if the file exists
Request
https://api.openload.co/1/file/info?file={file}&login={login}&key={key}
Parameters
Name | Description | Example | Required |
---|---|---|---|
file | File-ID(s), single file or comma-separated (max. 50) | 72fA-_Lq8Ak,72fA-_Lq8Ak4,72fA-_Lq8Ak5,72fA-_Lq8Ak6 | yes |
login | API-Login | 5147a8f8e924bc82 | no |
key | API-Key / API-Password | Fa89_X13-37a8CKR | no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"72fA-_Lq8Ak3": {
"id": "72fA-_Lq8Ak3",
"status": 200,
"name": "The quick brown fox.txt",
"size": 123456789012,
"sha1": "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12",
"content_type": "plain/text",
},
"72fA-_Lq8Ak4": {
"id": "72fA-_Lq8Ak4",
"status": 500,
"name": "The quick brown fox.txt",
"size": false,
"sha1": "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12",
"content_type": "plain/text",
},
"72fA-_Lq8Ak5": {
"id": "72fA-_Lq8Ak5",
"status": 404,
"name": false,
"size": false,
"sha1": false,
"content_type": false,
},
"72fA-_Lq8Ak6": {
"id": "72fA-_Lq8Ak6",
"status": 451,
"name": "The quick brown fox.txt",
"size": 123456789012,
"sha1": "2fd4e1c67a2d28fced849ee1bb76e7391b93eb12",
"content_type": "plain/text",
}
}
}
Upload
Get an Upload URL
Uploads shall be POSTed to the upload URL returned by our API and shall be multipart/form-data encoded. Example with curl:
curl -F [email protected]/path/to/file.txt https://13abc37.example.com/ul/jAZUhVzeU78
Request
https://api.openload.co/1/file/ul?login={login}&key={key}&folder={folder}&sha1={sha1}&httponly={httponly}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | no |
key | API-Key / API-Password | Fa89_X13-37a8CKR | no |
folder | Folder-ID to upload to | 1234 | no |
sha1 | Expected sha1 If sha1 of uploaded file doesn't match this value, upload fails |
2fd4e1c67a2d28fced849ee1bb76e7391b93eb12 | no |
httponly | If this is set to true, use only http upload links | 2fd4e1c67a2d28fced849ee1bb76e7391b93eb12 | no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"url": "https://13abc37.example.com/ul/fCgaPthr_ys",
"valid_until": "2015-01-09 00:02:50"
}
}
Add Remote Upload
Remote Uploading a file
Request
https://api.openload.co/1/remotedl/add?login={login}&key={key}&url={url}&folder={folder}&headers={headers}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
url | Remote URL | http://google.com/favicon.ico | yes |
folder | Folder-ID to upload to | 1234 | no |
headers | additional HTTP headers, separated by newline (e.g. Cookies or HTTP Basic-Auth) | User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:35.0) Gecko/20100101 Firefox/35.0 Cookie: auth=1234; |
no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"id": "12",
"folderid": "4248"
}
}
Check Remote Upload Status
Check Status of Remote Upload
Request
https://api.openload.co/1/remotedl/status?login={login}&key={key}&limit={limit}&id={id}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
limit | Maximum number of results (Default: 5, Maximum: 100) | 5 | no |
id | Remote Upload ID | 1234 | no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
24: {
"id": 24,
"remoteurl": "http://proof.ovh.net/files/100Mio.dat",
"status": "new",
"bytes_loaded": null,
"bytes_total": null,
"folderid": "4248",
"added": "2015-02-21 09:20:26",
"last_update": "2015-02-21 09:20:26",
"extid": false,
"url": false
},
22: {
"id": 22,
"remoteurl": "http://proof.ovh.net/files/1Gio.dat",
"status": "downloading",
"bytes_loaded": "823997062",
"bytes_total": "1073741824",
"folderid": "4248",
"added": "2015-02-21 09:20:26",
"last_update": "2015-02-21 09:21:56",
"extid": false,
"url": false
},
20: {
"id": 20,
"remoteurl": "http://google.de/favicon.ico",
"status": "finished",
"bytes_loaded": "229",
"bytes_total": "229",
"folderid": "4248",
"added": "2015-02-21 09:03:47",
"last_update": "2015-02-21 09:04:04",
"extid": "ANAaeBZus-Q",
"url": "https://openload.co/f/ANAaeBZus-Q"
},
3: {
"id": 3,
"remoteurl": "http://127.0.0.1/",
"status": "error",
"bytes_loaded": "162",
"bytes_total": "162",
"folderid": "4",
"added": "2015-02-17 18:58:11",
"last_update": "2015-02-19 18:07:45",
"extid": false,
"url": false
}
}
}
List Folder
Shows the content of your folders
Request
https://api.openload.co/1/file/listfolder?login={login}&key={key}&folder={folder}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
folder | Folder-ID | 5 | no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": {
"folders": [
{
"id": "5144",
"name": ".videothumb"
},
{
"id": "5792",
"name": ".subtitles"
},
{
"id": "6272",
"name": "test"
},
{
"id": "6288",
"name": "video"
},
{
"id": "6396",
"name": "images"
},
{
"id": "6990",
"name": "tmp"
}
],
"files": [
{
"name": "big_buck_bunny.mp4.mp4",
"sha1": "c6531f5ce9669d6547023d92aea4805b7c45d133",
"folderid": "4258",
"upload_at": "1419791256",
"status": "active",
"size": "5114011",
"content_type": "video/mp4",
"download_count": "48",
"cstatus": "ok",
"link": "https://openload.co/f/UPPjeAk--30/big_buck_bunny.mp4.mp4",
"linkextid": "UPPjeAk--30"
},
{
"name": "Sintel.2010.1080p.mkv.mp4",
"sha1": "7ca6da73b4f0881bd8dca78e9059e2e6830acce6",
"folderid": "4258",
"upload_at": "1426534681",
"status": "active",
"size": "1116102098",
"content_type": "video/mp4",
"download_count": "37",
"cstatus": "ok",
"link": "https://openload.co/f/AYgHe95d1E4/Sintel.2010.1080p.mkv.mp4",
"linkextid": "AYgHe95d1E4"
}
]
}
}
Rename Folder
Set a new name for a folders
Request
https://api.openload.co/1/file/renamefolder?login={login}&key={key}&folder={folder}&name={name}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
folder | Folder-ID | 5 | yes |
name | new Folder-Name | my%20new%20foldername | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": true
}
Rename File
Set a new name for a file
Request
https://api.openload.co/1/file/rename?login={login}&key={key}&file={file}&name={name}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
file | File ID | UPPjeAk--30 | yes |
name | new File-Name | My%20File%20Backup_2017.zip | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": true
}
Delete File
Remove one of your files
Request
https://api.openload.co/1/file/delete?login={login}&key={key}&file={file}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
file | File ID | UPPjeAk--30 | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": true
}
Converting Files
Convert previously uploaded files to a browser-streamable format (mp4 / h.264)
Request
https://api.openload.co/1/file/convert?login={login}&key={key}&file={file}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
file | File-ID | UPPjeAk--30 | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": true
}
Show running file converts
Shows running file converts by folder
Request
https://api.openload.co/1/file/runningconverts?login={login}&key={key}&folder={folder}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
folder | Folder-ID | 5 | no |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": [
{
"name": "Geysir.AVI",
"id": "3565411",
"status": "pending",
"last_update": "2015-08-23 19:41:40",
"progress": 0.32,
"retries": "0",
"link": "https://openload.co/f/f02JFG293J8/Geysir.AVI",
"linkextid": "f02JFG293J8"
}
]
}
Show failed file converts
Coming soon ...
Get splash image
Shows the video splash image (thumbnail)
Request
https://api.openload.co/1/file/getsplash?login={login}&key={key}&file={file}
Parameters
Name | Description | Example | Required |
---|---|---|---|
login | API-Login | 5147a8f8e924bc82 | yes |
key | API-Key / API-Password | Fa89_X13-37a8CKR | yes |
file | File-ID | AYgHe95d1E4 | yes |
Response
200 (OK)
Content-Type: application/json
{
"status": 200,
"msg": "OK",
"result": "https://openload.co/splash/AYgHe95d1E4/zt8uSEmk56s.jpg"
}