GET /storage/buckets
List buckets of the project bound to the key
Exact scope storage:read. Hidden surface: 404 not_found until the Galon Object opt-in is enabled.
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
limit | query | integer | |
cursor | query | string |
Responses
| Status | Description | Body |
|---|---|---|
200 | Page of buckets, signed cursor | StorageBucketPage |
401 | Key missing or invalid | Error |
403 | scope_missing (storage:read) | Error |
400 | query_invalid, storage_page_limit_invalid, storage_cursor_invalid | Error |
404 | not_found (surface closed) | Error |
503 | storage_temporarily_unavailable | Error |
Examples
curl
curl -X GET "$GALON_API_BASE/storage/buckets" \
-H "Authorization: Bearer $GALON_API_KEY"Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.buckets.list({ limit: 20 });Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.buckets.list({"limit": 20})POST /storage/buckets
Create a bucket
Exact scope storage:write. 201 on creation, 200 on replay of the same Idempotency-Key. Hidden surface: 404 not_found until the Galon Object opt-in is enabled.
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
Idempotency-Key | header | string · required |
Request body
application/json · schema StorageBucketCreate
| Field | Type | Description |
|---|---|---|
name | string · required | |
placement | "global" | "eu" | "africa-west" · required |
Responses
| Status | Description | Body |
|---|---|---|
201 | Bucket created | StorageBucketReceipt |
200 | Idempotent replay | StorageBucketReceipt |
400 | body_fields_invalid, body_invalid, storage_idempotency_key_invalid | Error |
401 | Key missing or invalid | Error |
403 | scope_missing (storage:write) | Error |
404 | not_found (surface closed) | Error |
409 | storage_idempotency_conflict, storage_bucket_exists | Error |
413 | body_too_large | Error |
415 | content_type_invalid | Error |
422 | storage_bucket_name_invalid, storage_placement_invalid | Error |
429 | storage_bucket_quota_exceeded | Error |
503 | storage_temporarily_unavailable, storage_operation_indeterminate | Error |
Examples
curl
curl -X POST "$GALON_API_BASE/storage/buckets" \
-H "Authorization: Bearer $GALON_API_KEY" \
-H "Idempotency-Key: <unique-key>" \
-H "Content-Type: application/json" \
-d '{"name": "string", "placement": "global"}'Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.buckets.create({"name": "string", "placement": "global"}, { idempotencyKey: "<unique-key>" });Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.buckets.create({"name": "string", "placement": "global"}, idempotency_key="<unique-key>")