Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

API spec for storage

Copple269ab8f7fe22
diff --git a/apps/reference/_api/usage.mdx b/apps/reference/_api/usage.mdx
index c8c8e4d8fa6..e5d52148f65 100644
--- a/apps/reference/_api/usage.mdx
+++ b/apps/reference/_api/usage.mdx
@@ -5,17 +5,25 @@ title: Usage
toc_max_heading_level: 3
---
-import Tabs from '@theme/Tabs'
-import TabItem from '@theme/TabItem'
+import Tabs from '@theme/Tabs';
+import TabItem from '@theme/TabItem';
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
+
## Organizations {#organizations}
Organization endpoints
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### List all organizations {#list-all-organizations}
@@ -26,8 +34,12 @@ GET https://api.supabase.com/v1/organizations
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -36,8 +48,11 @@ GET https://api.supabase.com/v1/organizations
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -52,12 +67,16 @@ GET https://api.supabase.com/v1/organizations
"type": "string"
}
},
- "required": ["id", "name"]
+ "required": [
+ "id",
+ "name"
+ ]
}
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -68,6 +87,8 @@ Unexpected error listing organizations
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -76,6 +97,7 @@ Unexpected error listing organizations
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Create an organization {#create-an-organization}
@@ -86,8 +108,11 @@ POST https://api.supabase.com/v1/organizations
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Body
```json
@@ -99,11 +124,14 @@ POST https://api.supabase.com/v1/organizations
"type": "string"
}
},
- "required": ["name"]
+ "required": [
+ "name"
+ ]
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -112,8 +140,11 @@ POST https://api.supabase.com/v1/organizations
<TabItem value="201">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -126,11 +157,15 @@ POST https://api.supabase.com/v1/organizations
"type": "string"
}
},
- "required": ["id", "name"]
+ "required": [
+ "id",
+ "name"
+ ]
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -141,6 +176,8 @@ Unexpected error creating an organization
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -149,10 +186,14 @@ Unexpected error creating an organization
<br />
+
+
## Projects {#projects}
Project endpoints
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### List all projects {#list-all-projects}
@@ -163,8 +204,12 @@ GET https://api.supabase.com/v1/projects
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -173,8 +218,11 @@ GET https://api.supabase.com/v1/projects
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -198,12 +246,19 @@ GET https://api.supabase.com/v1/projects
"type": "string"
}
},
- "required": ["id", "organization_id", "name", "region", "created_at"]
+ "required": [
+ "id",
+ "organization_id",
+ "name",
+ "region",
+ "created_at"
+ ]
}
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -212,6 +267,7 @@ GET https://api.supabase.com/v1/projects
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Create a project {#create-a-project}
@@ -222,8 +278,11 @@ POST https://api.supabase.com/v1/projects
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Body
```json
@@ -242,7 +301,10 @@ POST https://api.supabase.com/v1/projects
},
"plan": {
"type": "string",
- "enum": ["free", "pro"]
+ "enum": [
+ "free",
+ "pro"
+ ]
},
"region": {
"type": "string",
@@ -262,11 +324,18 @@ POST https://api.supabase.com/v1/projects
]
}
},
- "required": ["db_pass", "name", "organization_id", "plan", "region"]
+ "required": [
+ "db_pass",
+ "name",
+ "organization_id",
+ "plan",
+ "region"
+ ]
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -275,8 +344,11 @@ POST https://api.supabase.com/v1/projects
<TabItem value="201">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -298,11 +370,18 @@ POST https://api.supabase.com/v1/projects
"type": "string"
}
},
- "required": ["id", "organization_id", "name", "region", "created_at"]
+ "required": [
+ "id",
+ "organization_id",
+ "name",
+ "region",
+ "created_at"
+ ]
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -311,6 +390,7 @@ POST https://api.supabase.com/v1/projects
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### List all functions {#list-all-functions}
@@ -321,23 +401,35 @@ GET https://api.supabase.com/v1/projects/{ref}/functions
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -346,8 +438,11 @@ GET https://api.supabase.com/v1/projects/{ref}/functions
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -365,7 +460,11 @@ GET https://api.supabase.com/v1/projects/{ref}/functions
"type": "string"
},
"status": {
- "enum": ["ACTIVE", "REMOVED", "THROTTLED"],
+ "enum": [
+ "ACTIVE",
+ "REMOVED",
+ "THROTTLED"
+ ],
"type": "string"
},
"version": {
@@ -395,6 +494,7 @@ GET https://api.supabase.com/v1/projects/{ref}/functions
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -405,6 +505,8 @@ Failed to retrieve project's functions
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -413,6 +515,7 @@ Failed to retrieve project's functions
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Create a function {#create-a-function}
@@ -423,23 +526,34 @@ POST https://api.supabase.com/v1/projects/{ref}/functions
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Body
```json
@@ -461,11 +575,16 @@ POST https://api.supabase.com/v1/projects/{ref}/functions
"type": "boolean"
}
},
- "required": ["slug", "name", "body"]
+ "required": [
+ "slug",
+ "name",
+ "body"
+ ]
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -474,8 +593,11 @@ POST https://api.supabase.com/v1/projects/{ref}/functions
<TabItem value="201">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -491,7 +613,11 @@ POST https://api.supabase.com/v1/projects/{ref}/functions
"type": "string"
},
"status": {
- "enum": ["ACTIVE", "REMOVED", "THROTTLED"],
+ "enum": [
+ "ACTIVE",
+ "REMOVED",
+ "THROTTLED"
+ ],
"type": "string"
},
"version": {
@@ -520,6 +646,7 @@ POST https://api.supabase.com/v1/projects/{ref}/functions
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -530,6 +657,8 @@ Failed to create project's function
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -538,6 +667,7 @@ Failed to create project's function
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Retrieve a function {#retrieve-a-function}
@@ -548,41 +678,69 @@ GET https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">include_body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ include_body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">function_slug</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Function slug</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ function_slug
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Function slug
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -591,8 +749,11 @@ GET https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -608,7 +769,11 @@ GET https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
"type": "string"
},
"status": {
- "enum": ["ACTIVE", "REMOVED", "THROTTLED"],
+ "enum": [
+ "ACTIVE",
+ "REMOVED",
+ "THROTTLED"
+ ],
"type": "string"
},
"version": {
@@ -640,6 +805,7 @@ GET https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -650,6 +816,8 @@ Failed to retrieve function with given slug
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -658,6 +826,7 @@ Failed to retrieve function with given slug
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Update a function {#update-a-function}
@@ -668,32 +837,51 @@ PATCH https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">function_slug</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Function slug</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ function_slug
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Function slug
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Body
```json
@@ -715,6 +903,7 @@ PATCH https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -723,8 +912,11 @@ PATCH https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -740,7 +932,11 @@ PATCH https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
"type": "string"
},
"status": {
- "enum": ["ACTIVE", "REMOVED", "THROTTLED"],
+ "enum": [
+ "ACTIVE",
+ "REMOVED",
+ "THROTTLED"
+ ],
"type": "string"
},
"version": {
@@ -769,6 +965,7 @@ PATCH https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -779,6 +976,8 @@ Failed to update function with given slug
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -787,6 +986,7 @@ Failed to update function with given slug
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Delete a function {#delete-a-function}
@@ -797,32 +997,52 @@ DELETE https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">function_slug</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Function slug</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ function_slug
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Function slug
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -831,8 +1051,12 @@ DELETE https://api.supabase.com/v1/projects/{ref}/functions/{function_slug}
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -843,6 +1067,8 @@ Failed to delete function with given slug
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -851,6 +1077,7 @@ Failed to delete function with given slug
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### List all secrets {#list-all-secrets}
@@ -861,23 +1088,35 @@ GET https://api.supabase.com/v1/projects/{ref}/secrets
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -886,8 +1125,11 @@ GET https://api.supabase.com/v1/projects/{ref}/secrets
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -902,12 +1144,16 @@ GET https://api.supabase.com/v1/projects/{ref}/secrets
"type": "string"
}
},
- "required": ["name", "value"]
+ "required": [
+ "name",
+ "value"
+ ]
}
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -918,6 +1164,8 @@ Failed to retrieve project's secrets
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -926,6 +1174,7 @@ Failed to retrieve project's secrets
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Bulk create secrets {#bulk-create-secrets}
@@ -936,23 +1185,34 @@ POST https://api.supabase.com/v1/projects/{ref}/secrets
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Body
```json
@@ -970,12 +1230,16 @@ POST https://api.supabase.com/v1/projects/{ref}/secrets
"pattern": {}
}
},
- "required": ["name", "value"]
+ "required": [
+ "name",
+ "value"
+ ]
}
}
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -984,8 +1248,12 @@ POST https://api.supabase.com/v1/projects/{ref}/secrets
<TabItem value="201">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -996,6 +1264,8 @@ Failed to create project's secrets
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1004,6 +1274,7 @@ Failed to create project's secrets
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
### Bulk delete secrets {#bulk-delete-secrets}
@@ -1014,23 +1285,34 @@ DELETE https://api.supabase.com/v1/projects/{ref}/secrets
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">ref</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description">Project ref</div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ ref
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+ Project ref
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
#### Body
```json
@@ -1044,6 +1326,7 @@ DELETE https://api.supabase.com/v1/projects/{ref}/secrets
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
#### Responses
@@ -1052,8 +1335,11 @@ DELETE https://api.supabase.com/v1/projects/{ref}/secrets
<TabItem value="200">
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
```json
{
"schema": {
@@ -1062,6 +1348,7 @@ DELETE https://api.supabase.com/v1/projects/{ref}/secrets
}
```
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1072,6 +1359,8 @@ Failed to delete secrets with given names
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1079,3 +1368,4 @@ Failed to delete secrets with given names
</Tabs>
<br />
+
diff --git a/apps/reference/_storage/generated/config.mdx b/apps/reference/_storage/generated/config.mdx
index fb033c70ea3..2cfc75f1a27 100644
--- a/apps/reference/_storage/generated/config.mdx
+++ b/apps/reference/_storage/generated/config.mdx
@@ -2,7 +2,7 @@
id: config
slug: /config
title: Configuration
-toc_max_heading_level: 2
+toc_max_heading_level: 3
---
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY -->
@@ -11,280 +11,254 @@ A sample `.env` file is located in the [storage repository](https://github.com/s
Use this file to configure your environment variables for your Storage server.
+
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY -->
-## General
+## General {#general}
-### `ANON_KEY`
+
+
+### `ANON_KEY` {#ANON_KEY}
A long-lived JWT with anonymous Postgres privileges.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `SERVICE_KEY`
+
+### `SERVICE_KEY` {#SERVICE_KEY}
A long-lived JWT with Postgres privileges to bypass Row Level Security.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `TENANT_ID`
+
+### `TENANT_ID` {#TENANT_ID}
The ID of a Storage tenant.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `REGION`
+
+### `REGION` {#REGION}
Region of your S3 bucket.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `GLOBAL_S3_BUCKET`
+
+### `GLOBAL_S3_BUCKET` {#GLOBAL_S3_BUCKET}
Name of your S3 bucket.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `POSTGREST_URL`
+
+### `POSTGREST_URL` {#POSTGREST_URL}
The URL of your PostgREST server.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `PGRST_JWT_SECRET`
+
+### `PGRST_JWT_SECRET` {#PGRST_JWT_SECRET}
A JWT Secret for the PostgREST database.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `DATABASE_URL`
+
+### `DATABASE_URL` {#DATABASE_URL}
The URL of your Postgres database.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `PGOPTIONS`
+
+### `PGOPTIONS` {#PGOPTIONS}
Additional configuration parameters for Postgres startup.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `FILE_SIZE_LIMIT`
+
+### `FILE_SIZE_LIMIT` {#FILE_SIZE_LIMIT}
The maximum file size allowed.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `STORAGE_BACKEND`
+
+### `STORAGE_BACKEND` {#STORAGE_BACKEND}
The storage provider.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `FILE_STORAGE_BACKEND_PATH`
+
+### `FILE_STORAGE_BACKEND_PATH` {#FILE_STORAGE_BACKEND_PATH}
The location storage when the "STORAGE_BACKEND" is set to "file".
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
+
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY -->
-## Multi-tenant
+## Multi-tenant {#multitenant}
+
-### `IS_MULTITENANT`
+
+### `IS_MULTITENANT` {#IS_MULTITENANT}
Operate across multiple tenants.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `MULTITENANT_DATABASE_URL`
+
+### `MULTITENANT_DATABASE_URL` {#MULTITENANT_DATABASE_URL}
The URL of the multitenant Postgres database.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `X_FORWARDED_HOST_REGEXP`
+
+### `X_FORWARDED_HOST_REGEXP` {#X_FORWARDED_HOST_REGEXP}
TBD.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `POSTGREST_URL_SUFFIX`
+
+### `POSTGREST_URL_SUFFIX` {#POSTGREST_URL_SUFFIX}
The suffix for the PostgREST instance.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `ADMIN_API_KEYS`
+
+### `ADMIN_API_KEYS` {#ADMIN_API_KEYS}
Secure API key for administrative endpoints.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
-### `ENCRYPTION_KEY`
+
+### `ENCRYPTION_KEY` {#ENCRYPTION_KEY}
An key for encryting/decrypting secrets.
+
<ul>
- <li>
- Required: <code>true</code>
- </li>
- <li>
- Default: <code>None</code>
- </li>
+<li>Required: <code>true</code></li>
+<li>Default: <code>None</code></li>
</ul>
<br />
+
+
diff --git a/apps/reference/_storage/generated/usage.mdx b/apps/reference/_storage/generated/usage.mdx
index 9617dac28a8..723e35571e9 100644
--- a/apps/reference/_storage/generated/usage.mdx
+++ b/apps/reference/_storage/generated/usage.mdx
@@ -5,8 +5,9 @@ title: Usage
toc_max_heading_level: 3
---
-import Tabs from '@theme/Tabs'
-import TabItem from '@theme/TabItem'
+import Tabs from '@theme/Tabs';
+import TabItem from '@theme/TabItem';
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
@@ -14,45 +15,91 @@ API documentation for Supabase Storage
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
+
+## Object {#object}
+
+Object end-points
+
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Create a bucket {#create-a-bucket}
+### Delete an object {#delete-an-object}
```
-POST
+DELETE /object/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
+
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -62,6 +109,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -72,6 +121,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -80,48 +131,85 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Gets all buckets {#gets-all-buckets}
+### Deprecated (use GET /object/authenticated/{bucketName} instead): Retrieve an object {#deprecated-use-get-objectauthenticatedbucketname-instead-retrieve-an-object}
```
-GET
+GET /object/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
-</ul>
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+</ul>
-### Responses
-<Tabs>
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-<TabItem value="200">
-Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+#### Responses
-</TabItem>
+<Tabs>
<TabItem value="400">
@@ -129,6 +217,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -137,45 +227,83 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Empty a bucket {#empty-a-bucket}
+### Update the object at an existing key {#update-the-object-at-an-existing-key}
```
-POST
+PUT /object/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketId</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
+
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -185,6 +313,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -195,6 +325,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -203,45 +335,83 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Get details of a bucket {#get-details-of-a-bucket}
+### Upload a new object {#upload-a-new-object}
```
-GET
+POST /object/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketId</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
+
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -251,6 +421,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -261,6 +433,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -269,45 +443,83 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Update properties of a bucket {#update-properties-of-a-bucket}
+### Delete multiple objects {#delete-multiple-objects}
```
-PUT
+DELETE /object/{bucketName}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
+
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -317,6 +529,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -327,6 +541,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -335,57 +551,85 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Delete a bucket {#delete-a-bucket}
+### Retrieve an object {#retrieve-an-object}
```
-DELETE
+GET /object/authenticated/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketId</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
+
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
-
-<Tabs>
-
-<TabItem value="200">
-Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+#### Responses
-</TabItem>
+<Tabs>
<TabItem value="400">
@@ -393,6 +637,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -401,54 +647,100 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Delete an object {#delete-an-object}
+### Generate a presigned url to retrieve an object {#generate-a-presigned-url-to-retrieve-an-object}
```
-DELETE
+POST /object/sign/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
+</li>
+
+<li className="method-list-item">
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -458,6 +750,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -468,6 +762,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -476,54 +772,83 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Deprecated (use GET /object/authenticated/{bucketName} instead): Retrieve an object {#deprecated-use-get-objectauthenticatedbucketname-instead-retrieve-an-object}
+### Retrieve an object via a presigned URL {#retrieve-an-object-via-a-presigned-url}
```
-GET
+GET /object/sign/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ token
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -533,6 +858,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -541,54 +868,83 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Update the object at an existing key {#update-the-object-at-an-existing-key}
+### Generate presigned urls to retrieve objects {#generate-presigned-urls-to-retrieve-objects}
```
-PUT
+POST /object/sign/{bucketName}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -598,6 +954,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -608,6 +966,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -616,54 +976,66 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Upload a new object {#upload-a-new-object}
+### Moves an object {#moves-an-object}
```
-POST
+POST /object/move
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
-<ul className="method-list-group">
+#### Parameters
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -673,6 +1045,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -683,6 +1057,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -691,54 +1067,83 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Delete multiple objects {#delete-multiple-objects}
+### Search for objects under a prefix {#search-for-objects-under-a-prefix}
```
-DELETE
+POST /object/list/{bucketName}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -748,6 +1153,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -758,6 +1165,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -766,63 +1175,89 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Retrieve an object {#retrieve-an-object}
+### Copies an object {#copies-an-object}
```
-GET
+POST /object/copy
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
-<ul className="method-list-group">
+#### Parameters
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
+<TabItem value="200">
+
+Default Response
+
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
+
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+</TabItem>
+
<TabItem value="400">
Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -831,75 +1266,68 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Generate a presigned url to retrieve an object {#generate-a-presigned-url-to-retrieve-an-object}
+### Retrieve an object from a public bucket {#retrieve-an-object-from-a-public-bucket}
```
-POST
+GET /object/public/{bucketName}/{wildcard}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
-<ul className="method-list-group">
-
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+#### Parameters
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketName
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ *
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
-<Tabs>
-
-<TabItem value="200">
-
-Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+#### Responses
-</TabItem>
+<Tabs>
<TabItem value="400">
@@ -907,6 +1335,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -915,63 +1345,96 @@ Default Response
<br />
+
+
+## Bucket {#bucket}
+
+Bucket end-points
+
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Retrieve an object via a presigned URL {#retrieve-an-object-via-a-presigned-url}
+### Create a bucket {#create-a-bucket}
```
-GET
+POST /bucket/
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
-<ul className="method-list-group">
+#### Parameters
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">token</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
+<TabItem value="200">
+
+Default Response
+
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
+
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+</TabItem>
+
<TabItem value="400">
Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -980,54 +1443,49 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Generate presigned urls to retrieve objects {#generate-presigned-urls-to-retrieve-objects}
+### Gets all buckets {#gets-all-buckets}
```
-POST
+GET /bucket/
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
-<ul className="method-list-group">
+#### Parameters
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
-
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -1037,6 +1495,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1047,6 +1507,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1055,45 +1517,66 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Moves an object {#moves-an-object}
+### Empty a bucket {#empty-a-bucket}
```
-POST
+POST /bucket/{bucketId}/empty
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketId
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -1103,6 +1586,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1113,6 +1598,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1121,54 +1608,66 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Search for objects under a prefix {#search-for-objects-under-a-prefix}
+### Get details of a bucket {#get-details-of-a-bucket}
```
-POST
+GET /bucket/{bucketId}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
-<ul className="method-list-group">
+#### Parameters
-<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
-</li>
+<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketId
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -1178,6 +1677,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1188,6 +1689,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1196,45 +1699,66 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Copies an object {#copies-an-object}
+### Update properties of a bucket {#update-properties-of-a-bucket}
```
-POST
+PUT /bucket/{bucketId}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">body</span>
- <span className="method-list-item-label-badge">optional</span>
- <span className="method-list-item-validation"></span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ body
+ </span>
+ <span className="method-list-item-label-badge">
+ optional
+ </span>
+ <span className="method-list-item-validation">
+
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">authorization</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
@@ -1244,6 +1768,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1254,6 +1780,8 @@ Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1262,54 +1790,89 @@ Default Response
<br />
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-## Retrieve an object from a public bucket {#retrieve-an-object-from-a-public-bucket}
+### Delete a bucket {#delete-a-bucket}
```
-GET
+DELETE /bucket/{bucketId}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Parameters
+
+#### Parameters
<ul className="method-list-group">
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">bucketName</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ bucketId
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
<li className="method-list-item">
- <h4 className="method-list-item-label">
- <span className="method-list-item-label-name">*</span>
- <span className="method-list-item-label-badge">required</span>
- <span className="method-list-item-validation">string</span>
- </h4>
- <div class="method-list-item-description"></div>
+ <h4 className="method-list-item-label">
+ <span className="method-list-item-label-name">
+ authorization
+ </span>
+ <span className="method-list-item-label-badge">
+ required
+ </span>
+ <span className="method-list-item-validation">
+ string
+ </span>
+ </h4>
+ <div class="method-list-item-description">
+
+ </div>
</li>
</ul>
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
-### Responses
+#### Responses
<Tabs>
+<TabItem value="200">
+
+Default Response
+
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
+
+<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+</TabItem>
+
<TabItem value="400">
Default Response
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
+
+
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
@@ -1317,3 +1880,4 @@ Default Response
</Tabs>
<br />
+
diff --git a/packages/spec/package.json b/packages/spec/package.json
index a42a19a7ef1..042c4fbfe23 100644
--- a/packages/spec/package.json
+++ b/packages/spec/package.json
@@ -6,15 +6,16 @@
"license": "MIT",
"scripts": {
"api:gen": "npm run api:deparse && npm run api:gen:api",
- "api:deparse": "swagger-cli bundle --dereference --outfile ../../spec/api_v0_openapi/deparsed.json ../../spec/api_v0_openapi.json",
- "api:gen:api": "ts-node ./index.ts gen --type api --url https://api.supabase.com --input ../../spec/api_v0_openapi/deparsed.json --output ../../apps/reference/_api/usage.mdx",
+ "api:deparse": "swagger-cli bundle --dereference --outfile ../../spec/transforms/api_v0_openapi_deparsed.json ../../spec/api_v0_openapi.json",
+ "api:gen:api": "ts-node ./index.ts gen --type api --url https://api.supabase.com --input ../../spec/transforms/api_v0_openapi_deparsed.json --output ../../apps/reference/_api/usage.mdx",
"cli:gen": "npm run cli:gen:commands && npm run cli:gen:config",
"cli:gen:commands": "ts-node ./index.ts gen --type cli --input ../../spec/cli_v1_commands.yaml --output ../../apps/reference/_cli/generated/usage.mdx ",
"cli:gen:config": "ts-node ./index.ts gen --type config --input ../../spec/cli_v1_config.yaml --output ../../apps/reference/_cli/generated/config.mdx",
"gotrue:gen": "npm run gotrue:gen:config",
"gotrue:gen:config": "ts-node ./index.ts gen --type config --input ../../spec/gotrue_v1_config.yaml --output ../../apps/reference/_gotrue/config.mdx",
- "storage:gen": "npm run storage:gen:api && npm run storage:gen:config",
- "storage:gen:api": "ts-node ./index.ts gen --type api --input ../../spec/storage_v0_openapi.json --output ../../apps/reference/_storage/generated/usage.mdx",
+ "storage:gen": "npm run storage:deparse:api && npm run storage:gen:api && npm run storage:gen:config",
+ "storage:deparse:api": "swagger-cli bundle --dereference --outfile ../../spec/transforms/storage_v0_openapi_deparsed.json ../../spec/storage_v0_openapi.json",
+ "storage:gen:api": "ts-node ./index.ts gen --type api --input ../../spec/transforms/storage_v0_openapi_deparsed.json --output ../../apps/reference/_storage/generated/usage.mdx",
"storage:gen:config": "ts-node ./index.ts gen --type config --input ../../spec/storage_v1_config.yaml --output ../../apps/reference/_storage/generated/config.mdx",
"supabase-js:gen": "npm run supabase-js:gen:sdk",
"supabase-js:gen:sdk": "ts-node ./index.ts gen --type sdk --input ../../spec/supabase_js_v1_sdk.yaml --output ../../apps/reference/_supabase_js/usage.mdx",
diff --git a/packages/spec/src/docs/api.ts b/packages/spec/src/docs/api.ts
index c09e4cdc845..c7672196fc3 100644
--- a/packages/spec/src/docs/api.ts
+++ b/packages/spec/src/docs/api.ts
@@ -21,7 +21,7 @@ export default async function gen(
break
case '2.0':
- await gen_v2(spec, outputDir)
+ await gen_v2(spec, outputDir, { apiUrl })
break
default:
@@ -91,36 +91,49 @@ async function gen_v3(
}
// OPENAPI-SPEC-VERSION: 2.0
-async function gen_v2(spec: OpenAPIV2.Document, dest: string) {
- const paths = Object.entries(spec.paths).map(([key, path]) => {
+async function gen_v2(
+ spec: OpenAPIV2.Document,
+ dest: string,
+ { apiUrl }: { apiUrl: string }
+) {
+ const specLayout = spec.tags || []
+ const operations: enrichedOperation[] = []
+ Object.entries(spec.paths).forEach(([key, val]) => {
+ const fullPath = `${apiUrl}${key}`
+
+ toArrayWithKey(val!, 'operation').forEach((o) => {
+ const operation = o as v3OperationWithPath
+ const enriched = {
+ ...operation,
+ path: key,
+ fullPath,
+ operationId: slugify(operation.summary!),
+
+ responseList:
+ toArrayWithKey(operation.responses!, 'responseCode') || [],
+ }
+ operations.push(enriched)
+ })
+ })
+
+ const sections = specLayout.map((section) => {
return {
- path: key,
- operationList: toArrayWithKey(path!, 'operation').map((o) => {
- const operation = o as OpenAPIV2.OperationObject & {
- path: string
- }
- return {
- ...operation,
- operationId: slugify(operation.summary!),
- responseList: toArrayWithKey(operation.responses!, 'responseCode'),
- }
- }),
+ ...section,
+ title: toTitle(section.name),
+ id: slugify(section.name),
+ operations: operations.filter((operation) =>
+ operation.tags?.includes(section.name)
+ ),
}
})
const content = ejs.render(template, {
info: spec.info,
- paths,
+ sections,
+ operations,
})
// console.log(content)
// Write to disk
await writeToDisk(dest, content)
console.log('Saved: ', dest)
}
-
-// function addResponseCode(response: v3ResponseWithCode, spec: OpenAPIV3.Document) {
-// const jsonResponse = response.
-// return {
-// ...response
-// }
-// }
diff --git a/spec/api_v0_openapi/deparsed.json b/spec/transforms/api_v0_openapi_deparsed.json
similarity index 100%
rename from spec/api_v0_openapi/deparsed.json
rename to spec/transforms/api_v0_openapi_deparsed.json
diff --git a/spec/transforms/storage_v0_openapi_deparsed.json b/spec/transforms/storage_v0_openapi_deparsed.json
new file mode 100644
index 00000000000..7e9dacbdabe
--- /dev/null
+++ b/spec/transforms/storage_v0_openapi_deparsed.json
@@ -0,0 +1,1811 @@
+{
+ "swagger": "2.0",
+ "info": {
+ "title": "Supabase Storage API",
+ "description": "API documentation for Supabase Storage",
+ "version": "0.0.1"
+ },
+ "definitions": {
+ "def-0": {
+ "type": "object",
+ "properties": {
+ "authorization": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "authorization"
+ ],
+ "title": "authSchema"
+ },
+ "def-1": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ },
+ "paths": {
+ "/bucket/": {
+ "post": {
+ "summary": "Create a bucket",
+ "tags": [
+ "bucket"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ]
+ },
+ "id": {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ]
+ },
+ "public": {
+ "type": "boolean",
+ "examples": [
+ false
+ ]
+ }
+ },
+ "required": [
+ "name"
+ ]
+ }
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ]
+ }
+ },
+ "required": [
+ "name"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "get": {
+ "summary": "Gets all buckets",
+ "tags": [
+ "bucket"
+ ],
+ "parameters": [
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "array",
+ "items": {
+ "$id": "bucketSchema",
+ "type": "object",
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "owner": {
+ "type": "string"
+ },
+ "public": {
+ "type": "boolean"
+ },
+ "created_at": {
+ "type": "string"
+ },
+ "updated_at": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "additionalProperties": false,
+ "examples": [
+ {
+ "id": "bucket2",
+ "name": "bucket2",
+ "owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
+ "created_at": "2021-02-17T04:43:32.770206+00:00",
+ "updated_at": "2021-02-17T04:43:32.770206+00:00"
+ }
+ ],
+ "title": "bucketSchema"
+ },
+ "examples": [
+ [
+ {
+ "id": "bucket2",
+ "name": "bucket2",
+ "owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
+ "created_at": "2021-02-17T04:43:32.770206+00:00",
+ "updated_at": "2021-02-17T04:43:32.770206+00:00"
+ }
+ ]
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/bucket/{bucketId}/empty": {
+ "post": {
+ "summary": "Empty a bucket",
+ "tags": [
+ "bucket"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketId"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string",
+ "examples": [
+ "Successfully emptied"
+ ]
+ }
+ }
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/bucket/{bucketId}": {
+ "get": {
+ "summary": "Get details of a bucket",
+ "tags": [
+ "bucket"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketId"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "$id": "todo.com",
+ "type": "object",
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "owner": {
+ "type": "string"
+ },
+ "public": {
+ "type": "boolean"
+ },
+ "created_at": {
+ "type": "string"
+ },
+ "updated_at": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "additionalProperties": false,
+ "examples": [
+ {
+ "id": "bucket2",
+ "name": "bucket2",
+ "owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
+ "created_at": "2021-02-17T04:43:32.770206+00:00",
+ "updated_at": "2021-02-17T04:43:32.770206+00:00"
+ }
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "put": {
+ "summary": "Update properties of a bucket",
+ "tags": [
+ "bucket"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "public": {
+ "type": "boolean",
+ "examples": [
+ false
+ ]
+ }
+ }
+ }
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string",
+ "examples": [
+ "Successfully updated"
+ ]
+ }
+ },
+ "required": [
+ "message"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "delete": {
+ "summary": "Delete a bucket",
+ "tags": [
+ "bucket"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketId"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string",
+ "examples": [
+ "Successfully deleted"
+ ]
+ }
+ }
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/{bucketName}/{wildcard}": {
+ "delete": {
+ "summary": "Delete an object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string",
+ "examples": [
+ "Successfully deleted"
+ ]
+ }
+ }
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "get": {
+ "summary": "Deprecated (use GET /object/authenticated/{bucketName} instead): Retrieve an object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "put": {
+ "summary": "Update the object at an existing key",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "Key": {
+ "type": "string",
+ "examples": [
+ "projectref/avatars/folder/cat.png"
+ ]
+ }
+ },
+ "required": [
+ "Key"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "post": {
+ "summary": "Upload a new object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "Key": {
+ "type": "string",
+ "examples": [
+ "avatars/folder/cat.png"
+ ]
+ }
+ },
+ "required": [
+ "Key"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/{bucketName}": {
+ "delete": {
+ "summary": "Delete multiple objects",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "prefixes": {
+ "type": "array",
+ "items": {
+ "type": "string"
+ },
+ "minItems": 1,
+ "examples": [
+ [
+ "folder/cat.png",
+ "folder/morecats.png"
+ ]
+ ]
+ }
+ },
+ "required": [
+ "prefixes"
+ ]
+ }
+ },
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "array",
+ "items": {
+ "$id": "objectSchema",
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string"
+ },
+ "bucket_id": {
+ "type": "string"
+ },
+ "owner": {
+ "type": "string"
+ },
+ "id": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "updated_at": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "created_at": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "last_accessed_at": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "metadata": {
+ "anyOf": [
+ {
+ "type": "object",
+ "additionalProperties": true
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "buckets": {
+ "$id": "bucketSchema",
+ "type": "object",
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "owner": {
+ "type": "string"
+ },
+ "public": {
+ "type": "boolean"
+ },
+ "created_at": {
+ "type": "string"
+ },
+ "updated_at": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "additionalProperties": false,
+ "examples": [
+ {
+ "id": "bucket2",
+ "name": "bucket2",
+ "owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
+ "created_at": "2021-02-17T04:43:32.770206+00:00",
+ "updated_at": "2021-02-17T04:43:32.770206+00:00"
+ }
+ ]
+ }
+ },
+ "required": [
+ "name"
+ ],
+ "additionalProperties": false,
+ "examples": [
+ {
+ "name": "folder/cat.png",
+ "bucket_id": "avatars",
+ "owner": "317eadce-631a-4429-a0bb-f19a7a517b4a",
+ "id": "eaa8bdb5-2e00-4767-b5a9-d2502efe2196",
+ "updated_at": "2021-04-06T16:30:35.394674+00:00",
+ "created_at": "2021-04-06T16:30:35.394674+00:00",
+ "last_accessed_at": "2021-04-06T16:30:35.394674+00:00",
+ "metadata": {
+ "size": 1234
+ }
+ }
+ ],
+ "title": "objectSchema"
+ }
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/authenticated/{bucketName}/{wildcard}": {
+ "get": {
+ "summary": "Retrieve an object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/sign/{bucketName}/{wildcard}": {
+ "post": {
+ "summary": "Generate a presigned url to retrieve an object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "expiresIn": {
+ "type": "integer",
+ "minimum": 1,
+ "examples": [
+ 60000
+ ]
+ }
+ },
+ "required": [
+ "expiresIn"
+ ]
+ }
+ },
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "signedURL": {
+ "type": "string",
+ "examples": [
+ "/object/sign/avatars/folder/cat.png?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1cmwiOiJhdmF0YXJzL2ZvbGRlci9jYXQucG5nIiwiaWF0IjoxNjE3NzI2MjczLCJleHAiOjE2MTc3MjcyNzN9.s7Gt8ME80iREVxPhH01ZNv8oUn4XtaWsmiQ5csiUHn4"
+ ]
+ }
+ },
+ "required": [
+ "signedURL"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ },
+ "get": {
+ "summary": "Retrieve an object via a presigned URL",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1cmwiOiJidWNrZXQyL3B1YmxpYy9zYWRjYXQtdXBsb2FkMjMucG5nIiwiaWF0IjoxNjE3NzI2MjczLCJleHAiOjE2MTc3MjcyNzN9.uBQcXzuvXxfw-9WgzWMBfE_nR3VOgpvfZe032sfLSSk"
+ ],
+ "required": true,
+ "in": "query",
+ "name": "token"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ }
+ ],
+ "responses": {
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/sign/{bucketName}": {
+ "post": {
+ "summary": "Generate presigned urls to retrieve objects",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "expiresIn": {
+ "type": "integer",
+ "minimum": 1,
+ "examples": [
+ 60000
+ ]
+ },
+ "paths": {
+ "type": "array",
+ "items": {
+ "type": "string"
+ },
+ "minItems": 1,
+ "examples": [
+ [
+ "folder/cat.png",
+ "folder/morecats.png"
+ ]
+ ]
+ }
+ },
+ "required": [
+ "expiresIn",
+ "paths"
+ ]
+ }
+ },
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "array",
+ "items": {
+ "type": "object",
+ "properties": {
+ "error": {
+ "error": [
+ "string",
+ "null"
+ ],
+ "examples": [
+ "Either the object does not exist or you do not have access to it"
+ ]
+ },
+ "path": {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ]
+ },
+ "signedURL": {
+ "type": [
+ "string",
+ "null"
+ ],
+ "examples": [
+ "/object/sign/avatars/folder/cat.png?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1cmwiOiJhdmF0YXJzL2ZvbGRlci9jYXQucG5nIiwiaWF0IjoxNjE3NzI2MjczLCJleHAiOjE2MTc3MjcyNzN9.s7Gt8ME80iREVxPhH01ZNv8oUn4XtaWsmiQ5csiUHn4"
+ ]
+ }
+ },
+ "required": [
+ "error",
+ "path",
+ "signedURL"
+ ]
+ }
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/move": {
+ "post": {
+ "summary": "Moves an object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "bucketId": {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ]
+ },
+ "sourceKey": {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ]
+ },
+ "destinationKey": {
+ "type": "string",
+ "examples": [
+ "folder/newcat.png"
+ ]
+ }
+ },
+ "required": [
+ "bucketId",
+ "sourceKey",
+ "destinationKey"
+ ]
+ }
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string",
+ "examples": [
+ "Successfully moved"
+ ]
+ }
+ },
+ "required": [
+ "message"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/list/{bucketName}": {
+ "post": {
+ "summary": "Search for objects under a prefix",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "prefix": {
+ "type": "string",
+ "examples": [
+ "folder/subfolder"
+ ]
+ },
+ "limit": {
+ "type": "integer",
+ "minimum": 1,
+ "examples": [
+ 10
+ ]
+ },
+ "offset": {
+ "type": "integer",
+ "minimum": 0,
+ "examples": [
+ 0
+ ]
+ },
+ "sortBy": {
+ "type": "object",
+ "properties": {
+ "column": {
+ "type": "string",
+ "enum": [
+ "name",
+ "updated_at",
+ "created_at",
+ "last_accessed_at"
+ ]
+ },
+ "order": {
+ "type": "string",
+ "enum": [
+ "asc",
+ "desc"
+ ]
+ }
+ },
+ "required": [
+ "column"
+ ]
+ },
+ "search": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "prefix"
+ ]
+ }
+ },
+ {
+ "type": "string",
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "array",
+ "items": {
+ "$id": "objectSchema",
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string"
+ },
+ "bucket_id": {
+ "type": "string"
+ },
+ "owner": {
+ "type": "string"
+ },
+ "id": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "updated_at": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "created_at": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "last_accessed_at": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "metadata": {
+ "anyOf": [
+ {
+ "type": "object",
+ "additionalProperties": true
+ },
+ {
+ "type": "null"
+ }
+ ]
+ },
+ "buckets": {
+ "$id": "bucketSchema",
+ "type": "object",
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "owner": {
+ "type": "string"
+ },
+ "public": {
+ "type": "boolean"
+ },
+ "created_at": {
+ "type": "string"
+ },
+ "updated_at": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "additionalProperties": false,
+ "examples": [
+ {
+ "id": "bucket2",
+ "name": "bucket2",
+ "owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
+ "created_at": "2021-02-17T04:43:32.770206+00:00",
+ "updated_at": "2021-02-17T04:43:32.770206+00:00"
+ }
+ ]
+ }
+ },
+ "required": [
+ "name"
+ ],
+ "additionalProperties": false,
+ "examples": [
+ {
+ "name": "folder/cat.png",
+ "bucket_id": "avatars",
+ "owner": "317eadce-631a-4429-a0bb-f19a7a517b4a",
+ "id": "eaa8bdb5-2e00-4767-b5a9-d2502efe2196",
+ "updated_at": "2021-04-06T16:30:35.394674+00:00",
+ "created_at": "2021-04-06T16:30:35.394674+00:00",
+ "last_accessed_at": "2021-04-06T16:30:35.394674+00:00",
+ "metadata": {
+ "size": 1234
+ }
+ }
+ ]
+ }
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/copy": {
+ "post": {
+ "summary": "Copies an object",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "sourceKey": {
+ "type": "string",
+ "examples": [
+ "folder/source.png"
+ ]
+ },
+ "bucketId": {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ]
+ },
+ "destinationKey": {
+ "type": "string",
+ "examples": [
+ "folder/destination.png"
+ ]
+ }
+ },
+ "required": [
+ "sourceKey",
+ "bucketId",
+ "destinationKey"
+ ]
+ }
+ },
+ {
+ "in": "header",
+ "name": "authorization",
+ "required": true,
+ "type": "string"
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "Key": {
+ "type": "string",
+ "examples": [
+ "folder/destination.png"
+ ]
+ }
+ },
+ "required": [
+ "Key"
+ ]
+ }
+ },
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ },
+ "/object/public/{bucketName}/{wildcard}": {
+ "get": {
+ "summary": "Retrieve an object from a public bucket",
+ "tags": [
+ "object"
+ ],
+ "parameters": [
+ {
+ "type": "string",
+ "examples": [
+ "avatars"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "bucketName"
+ },
+ {
+ "type": "string",
+ "examples": [
+ "folder/cat.png"
+ ],
+ "required": true,
+ "in": "path",
+ "name": "*"
+ }
+ ],
+ "responses": {
+ "400": {
+ "description": "Default Response",
+ "schema": {
+ "type": "object",
+ "properties": {
+ "statusCode": {
+ "type": "string"
+ },
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "statusCode",
+ "error",
+ "message"
+ ],
+ "title": "errorSchema"
+ }
+ }
+ }
+ }
+ }
+ },
+ "tags": [
+ {
+ "name": "object",
+ "description": "Object end-points"
+ },
+ {
+ "name": "bucket",
+ "description": "Bucket end-points"
+ }
+ ]
+}