Create Byte-Range Patch URL
curl --request POST \
--url https://api.zerodrive.dev/v1/files/patch-url \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"path": "<string>",
"drive_id": "primary",
"offset": 0,
"truncate": false
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({path: '<string>', drive_id: 'primary', offset: 0, truncate: false})
};
fetch('https://api.zerodrive.dev/v1/files/patch-url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.zerodrive.dev/v1/files/patch-url"
payload = {
"path": "<string>",
"drive_id": "primary",
"offset": 0,
"truncate": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){}Create Byte-Range Patch URL
Generate a signed headerless HTTP PATCH URL supporting offset, append, and truncate up to 64 MiB.
POST
https://api.zerodrive.dev
/
v1
/
files
/
patch-url
Create Byte-Range Patch URL
curl --request POST \
--url https://api.zerodrive.dev/v1/files/patch-url \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"path": "<string>",
"drive_id": "primary",
"offset": 0,
"truncate": false
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({path: '<string>', drive_id: 'primary', offset: 0, truncate: false})
};
fetch('https://api.zerodrive.dev/v1/files/patch-url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.zerodrive.dev/v1/files/patch-url"
payload = {
"path": "<string>",
"drive_id": "primary",
"offset": 0,
"truncate": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){}Authorizations
Body
application/json
Response
Signed PATCH URL and expiration
The response is of type object.

