Get file upload URL
curl --request POST \
--url https://staging.api.us.aptlydone.com/document/v1/files/presigned-url \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"filename": "company-logo.jpg",
"type": "logos",
"container": "publicAssetsContainer",
"contentType": "image/jpeg"
}
'import requests
url = "https://staging.api.us.aptlydone.com/document/v1/files/presigned-url"
payload = {
"filename": "company-logo.jpg",
"type": "logos",
"container": "publicAssetsContainer",
"contentType": "image/jpeg"
}
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({
filename: 'company-logo.jpg',
type: 'logos',
container: 'publicAssetsContainer',
contentType: 'image/jpeg'
})
};
fetch('https://staging.api.us.aptlydone.com/document/v1/files/presigned-url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://staging.api.us.aptlydone.com/document/v1/files/presigned-url",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'filename' => 'company-logo.jpg',
'type' => 'logos',
'container' => 'publicAssetsContainer',
'contentType' => 'image/jpeg'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://staging.api.us.aptlydone.com/document/v1/files/presigned-url"
payload := strings.NewReader("{\n \"filename\": \"company-logo.jpg\",\n \"type\": \"logos\",\n \"container\": \"publicAssetsContainer\",\n \"contentType\": \"image/jpeg\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://staging.api.us.aptlydone.com/document/v1/files/presigned-url")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"filename\": \"company-logo.jpg\",\n \"type\": \"logos\",\n \"container\": \"publicAssetsContainer\",\n \"contentType\": \"image/jpeg\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.api.us.aptlydone.com/document/v1/files/presigned-url")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"filename\": \"company-logo.jpg\",\n \"type\": \"logos\",\n \"container\": \"publicAssetsContainer\",\n \"contentType\": \"image/jpeg\"\n}"
response = http.request(request)
puts response.read_body{
"statusCode": 200,
"timestamp": "2026-01-12T09:12:23.874Z",
"message": "Success",
"data": {
"uploadUrl": "https://storage.azure.com/container/file.jpg?sig=xxx",
"fileUrl": "https://storage.azure.com/container/file.jpg",
"expiresIn": 300
}
}Documents
Get file upload URL
POST
/
v1
/
files
/
presigned-url
Get file upload URL
curl --request POST \
--url https://staging.api.us.aptlydone.com/document/v1/files/presigned-url \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"filename": "company-logo.jpg",
"type": "logos",
"container": "publicAssetsContainer",
"contentType": "image/jpeg"
}
'import requests
url = "https://staging.api.us.aptlydone.com/document/v1/files/presigned-url"
payload = {
"filename": "company-logo.jpg",
"type": "logos",
"container": "publicAssetsContainer",
"contentType": "image/jpeg"
}
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({
filename: 'company-logo.jpg',
type: 'logos',
container: 'publicAssetsContainer',
contentType: 'image/jpeg'
})
};
fetch('https://staging.api.us.aptlydone.com/document/v1/files/presigned-url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://staging.api.us.aptlydone.com/document/v1/files/presigned-url",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'filename' => 'company-logo.jpg',
'type' => 'logos',
'container' => 'publicAssetsContainer',
'contentType' => 'image/jpeg'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://staging.api.us.aptlydone.com/document/v1/files/presigned-url"
payload := strings.NewReader("{\n \"filename\": \"company-logo.jpg\",\n \"type\": \"logos\",\n \"container\": \"publicAssetsContainer\",\n \"contentType\": \"image/jpeg\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://staging.api.us.aptlydone.com/document/v1/files/presigned-url")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"filename\": \"company-logo.jpg\",\n \"type\": \"logos\",\n \"container\": \"publicAssetsContainer\",\n \"contentType\": \"image/jpeg\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.api.us.aptlydone.com/document/v1/files/presigned-url")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"filename\": \"company-logo.jpg\",\n \"type\": \"logos\",\n \"container\": \"publicAssetsContainer\",\n \"contentType\": \"image/jpeg\"\n}"
response = http.request(request)
puts response.read_body{
"statusCode": 200,
"timestamp": "2026-01-12T09:12:23.874Z",
"message": "Success",
"data": {
"uploadUrl": "https://storage.azure.com/container/file.jpg?sig=xxx",
"fileUrl": "https://storage.azure.com/container/file.jpg",
"expiresIn": 300
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Original filename
Example:
"company-logo.jpg"
Type of file being uploaded
Available options:
logos, documents, images Example:
"logos"
Container of file being uploaded
Available options:
logos, documents, images Example:
"publicAssetsContainer"
File MIME type
Example:
"image/jpeg"
Response
201 - application/json
Presigned URL generated successfully
Was this page helpful?
āI