List Objects in Bucket
curl --request GET \
--url https://api.example.com/api/storage/buckets/{bucketName}/objects \
--header 'x-api-key: <api-key>'import requests
url = "https://api.example.com/api/storage/buckets/{bucketName}/objects"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.example.com/api/storage/buckets/{bucketName}/objects', 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://api.example.com/api/storage/buckets/{bucketName}/objects",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/storage/buckets/{bucketName}/objects"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/api/storage/buckets/{bucketName}/objects")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/storage/buckets/{bucketName}/objects")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"bucket": "avatars",
"key": "users/user123.jpg",
"size": 102400,
"mimeType": "image/jpeg",
"uploadedAt": "2024-01-15T10:30:00Z",
"url": "/api/storage/buckets/avatars/objects/users/user123.jpg"
},
{
"bucket": "avatars",
"key": "users/user456.png",
"size": 204800,
"mimeType": "image/png",
"uploadedAt": "2024-01-16T11:00:00Z",
"url": "/api/storage/buckets/avatars/objects/users/user456.png"
}
],
"pagination": {
"offset": 0,
"limit": 100,
"total": 2
},
"nextActions": "You can use PUT /api/storage/buckets/:bucketName/objects/:objectKey to upload with a specific key, or POST /api/storage/buckets/:bucketName/objects to upload with auto-generated key, and GET /api/storage/buckets/:bucketName/objects/:objectKey to download an object."
}Admin
List Objects in Bucket
GET
/
api
/
storage
/
buckets
/
{bucketName}
/
objects
List Objects in Bucket
curl --request GET \
--url https://api.example.com/api/storage/buckets/{bucketName}/objects \
--header 'x-api-key: <api-key>'import requests
url = "https://api.example.com/api/storage/buckets/{bucketName}/objects"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.example.com/api/storage/buckets/{bucketName}/objects', 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://api.example.com/api/storage/buckets/{bucketName}/objects",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/storage/buckets/{bucketName}/objects"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/api/storage/buckets/{bucketName}/objects")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/storage/buckets/{bucketName}/objects")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"bucket": "avatars",
"key": "users/user123.jpg",
"size": 102400,
"mimeType": "image/jpeg",
"uploadedAt": "2024-01-15T10:30:00Z",
"url": "/api/storage/buckets/avatars/objects/users/user123.jpg"
},
{
"bucket": "avatars",
"key": "users/user456.png",
"size": 204800,
"mimeType": "image/png",
"uploadedAt": "2024-01-16T11:00:00Z",
"url": "/api/storage/buckets/avatars/objects/users/user456.png"
}
],
"pagination": {
"offset": 0,
"limit": 100,
"total": 2
},
"nextActions": "You can use PUT /api/storage/buckets/:bucketName/objects/:objectKey to upload with a specific key, or POST /api/storage/buckets/:bucketName/objects to upload with auto-generated key, and GET /api/storage/buckets/:bucketName/objects/:objectKey to download an object."
}Authorizations
Path Parameters
Pattern:
^[a-zA-Z0-9_-]+$Query Parameters
Filter objects by key prefix
Required range:
1 <= x <= 1000Required range:
x >= 0Search objects by key (partial match)
Response
200 - application/json
List of objects in bucket
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Example:
"You can use PUT /api/storage/buckets/:bucketName/objects/:objectKey to upload with a specific key, or POST /api/storage/buckets/:bucketName/objects to upload with auto-generated key, and GET /api/storage/buckets/:bucketName/objects/:objectKey to download an object."
⌘I