Create an upload
curl --request POST \
--url https://api.hooper.gg/v1/uploads \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"size": 2147483648,
"content_type": "video/mp4",
"filename": "<string>"
}
'import requests
url = "https://api.hooper.gg/v1/uploads"
payload = {
"size": 2147483648,
"content_type": "video/mp4",
"filename": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({size: 2147483648, content_type: 'video/mp4', filename: '<string>'})
};
fetch('https://api.hooper.gg/v1/uploads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "up_3f9a1c2b7e5d4a08",
"object": "upload",
"upload_url": "<string>",
"content_type": "<string>",
"size": 123,
"expires_in_seconds": 604800
}{
"error": {
"type": "invalid_request_error",
"code": "parameter_invalid",
"message": "<string>",
"param": "source.url"
}
}{
"error": {
"type": "invalid_request_error",
"code": "parameter_invalid",
"message": "<string>",
"param": "source.url"
}
}Uploads
Create an upload
Returns a resumable upload URL. PUT the file bytes directly to upload_url (GCS resumable protocol), then submit a session with source: { type: "upload", upload_id }.
Files must be MP4 or MOV, at most 10 GB and 1080p — the same envelope a mobile recording produces.
POST
/
v1
/
uploads
Create an upload
curl --request POST \
--url https://api.hooper.gg/v1/uploads \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"size": 2147483648,
"content_type": "video/mp4",
"filename": "<string>"
}
'import requests
url = "https://api.hooper.gg/v1/uploads"
payload = {
"size": 2147483648,
"content_type": "video/mp4",
"filename": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({size: 2147483648, content_type: 'video/mp4', filename: '<string>'})
};
fetch('https://api.hooper.gg/v1/uploads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "up_3f9a1c2b7e5d4a08",
"object": "upload",
"upload_url": "<string>",
"content_type": "<string>",
"size": 123,
"expires_in_seconds": 604800
}{
"error": {
"type": "invalid_request_error",
"code": "parameter_invalid",
"message": "<string>",
"param": "source.url"
}
}{
"error": {
"type": "invalid_request_error",
"code": "parameter_invalid",
"message": "<string>",
"param": "source.url"
}
}Authorizations
API key issued by Hooper for your organization. Keys are environment-tagged: hk_prod_ keys work against production, hk_stg_ keys against staging.
Body
application/json