Files
supabase/apps/reference/_api/usage.mdx
T
2022-08-13 16:22:40 +02:00

273 lines
3.6 KiB
Plaintext

---
id: usage
title: Usage
toc_max_heading_level: 3
---
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" -->
## Lists all organizations {#lists-all-organizations}
```
GET https://api.supabase.com/v1/organizations
```
### Responses
<Tabs>
<TabItem value="200">
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
```json
{
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
]
}
}
}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
<TabItem value="500">
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>
</Tabs>
<br />
## Creates an organization {#creates-an-organization}
```
POST https://api.supabase.com/v1/organizations
```
### Responses
<Tabs>
<TabItem value="201">
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
```json
{
"schema": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
]
}
}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
<TabItem value="500">
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>
</Tabs>
<br />
## Gets all projects that belong to the authenticated user {#gets-all-projects-that-belong-to-the-authenticated-user}
```
GET https://api.supabase.com/v1/projects
```
### Responses
<Tabs>
<TabItem value="200">
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
```json
{
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"organization_id": {
"type": "string"
},
"name": {
"type": "string"
},
"region": {
"type": "string"
},
"created_at": {
"type": "string"
}
},
"required": [
"id",
"organization_id",
"name",
"region",
"created_at"
]
}
}
}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
</Tabs>
<br />
## Creates a project {#creates-a-project}
```
POST https://api.supabase.com/v1/projects
```
### Responses
<Tabs>
<TabItem value="200">
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
```json
{
"schema": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"organization_id": {
"type": "string"
},
"name": {
"type": "string"
},
"region": {
"type": "string"
},
"created_at": {
"type": "string"
}
},
"required": [
"id",
"organization_id",
"name",
"region",
"created_at"
]
}
}
```
<!-- AUTOGENERATED: DO NOT EDIT DIRECTLY IF THIS IS VERSION "next" -->
</TabItem>
</Tabs>
<br />