Storage
Buckets for any storage client, and the team's storage key.
/v1/bucketsList buckets and the storage endpoint#
- Credential
- An API key or a dashboard session
- Roles
- Any role
Response
200BucketList
endpointstringrequiredbucketsBucket[]requirednamestringrequiredcreated_atstring (date-time)size_bytesinteger | nulllast measured
objectsinteger | nullstatusstringone of
availableprojectsConnected[]namestringrequiredkindstringrequiredone of
function,appenvironmentsstring[]requiredbindingsstring[]required
Errors
| Status | Description |
|---|---|
| 401 | unauthorized: missing, invalid, expired or revoked credential |
| 500 | internal: an unexpected failure |
Example
curl "https://api.ibel.ai/v1/buckets" \
-H "Authorization: Bearer $KEY"/v1/bucketsCreate a bucket#
The team's first bucket also creates its storage key and returns the secret once (step-up for that one only).
- Credential
- An API key or a dashboard session
- Roles
- owner, admin, developer
- Step-up
- With a dashboard session, a second factor confirmed in the last 10 minutes; API keys pass.
Request bodyapplication/json
namestringrequired3-63 lowercase letters, digits and single hyphens
pattern
^[a-z0-9][a-z0-9-]{1,61}[a-z0-9]$
Response
201BucketCreated
namestringrequiredendpointstringrequiredaccess_keystringrequiredsecret_keystringonly when the key was just made
notestring
Errors
| Status | Description |
|---|---|
| 400 | Bad request: bad_name, bad_json |
| 401 | unauthorized: missing, invalid, expired or revoked credential |
| 403 | Not allowed: forbidden, step_up_required |
| 409 | Conflict: name_taken |
| 500 | internal: an unexpected failure |
| 503 | Unavailable: storage |
Example
curl -X POST "https://api.ibel.ai/v1/buckets" \
-H "Authorization: Bearer $KEY" \
-d '{"name":"uploads"}'/v1/buckets/{name}Get a bucket#
- Credential
- An API key or a dashboard session
- Roles
- Any role
Parameters
namestringpathrequiredthe bucket's name
pattern
^[a-z0-9][a-z0-9-]{1,61}[a-z0-9]$
Response
200Bucket
namestringrequiredcreated_atstring (date-time)size_bytesinteger | nulllast measured
objectsinteger | nullstatusstringone of
availableprojectsConnected[]namestringrequiredkindstringrequiredone of
function,appenvironmentsstring[]requiredbindingsstring[]required
endpointstringrequired
Errors
| Status | Description |
|---|---|
| 401 | unauthorized: missing, invalid, expired or revoked credential |
| 404 | Not found: not_found |
| 500 | internal: an unexpected failure |
Example
curl "https://api.ibel.ai/v1/buckets/uploads" \
-H "Authorization: Bearer $KEY"/v1/buckets/{name}Delete an empty bucket#
Refused while a live version binds it (checked after the role and the name).
- Credential
- An API key or a dashboard session
- Roles
- owner, admin, developer
Parameters
namestringpathrequiredthe bucket's name
pattern
^[a-z0-9][a-z0-9-]{1,61}[a-z0-9]$
Response
200Deleted
namestringdeletedbooleanrequired
Errors
| Status | Description |
|---|---|
| 401 | unauthorized: missing, invalid, expired or revoked credential |
| 403 | Not allowed: forbidden |
| 404 | Not found: not_found |
| 409 | Conflict: bound, not_empty |
| 500 | internal: an unexpected failure |
| 503 | Unavailable: storage |
Example
curl -X DELETE "https://api.ibel.ai/v1/buckets/uploads" \
-H "Authorization: Bearer $KEY"- Credential
- An API key or a dashboard session
- Roles
- owner, admin, developer
- Step-up
- With a dashboard session, a second factor confirmed in the last 10 minutes; API keys pass.
Response
200StorageCredentials
endpointstringrequiredaccess_keystringrequiredsecret_keystringrequiredregionstringrequired
Errors
| Status | Description |
|---|---|
| 401 | unauthorized: missing, invalid, expired or revoked credential |
| 403 | Not allowed: forbidden, step_up_required |
| 500 | internal: an unexpected failure |
| 503 | Unavailable: storage |
Example
curl -X POST "https://api.ibel.ai/v1/storage/credentials" \
-H "Authorization: Bearer $KEY"/v1/buckets/{name}/observabilitySize, objects and requests per hour#
- Credential
- An API key or a dashboard session
- Roles
- Any role
Parameters
namestringpathrequiredthe bucket's name
pattern
^[a-z0-9][a-z0-9-]{1,61}[a-z0-9]$rangestringquery24h (default), 7d or 30d
one of
24h,7d,30d· default"24h"
Response
200ResourceObservability
rangestringrequiredstepstringrequiredtotalsobjectrequiredmetricsobject[]requiredkeystringrequiredlabelstringrequiredunitstringrequired
seriesobject[]requiredtstring (date-time)
tablesobject[]databases only: the latest top statements
keystringlabelstringsampled_atstring (date-time)columnsobject[]keystringlabelstring
rowsobject[]
notestring
Errors
| Status | Description |
|---|---|
| 400 | Bad request: bad_range |
| 401 | unauthorized: missing, invalid, expired or revoked credential |
| 404 | Not found: not_found |
| 500 | internal: an unexpected failure |
Example
curl "https://api.ibel.ai/v1/buckets/uploads/observability" \
-H "Authorization: Bearer $KEY"