Merge pull request #3419 from appwrite/database-layer-docs

Create database layer description documents
This commit is contained in:
Torsten Dittmann 2022-06-27 10:08:35 +02:00 committed by GitHub
commit fa0af50d02
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 13 additions and 8 deletions

View file

@ -159,7 +159,7 @@ App::post('/v1/databases')
->label('sdk.auth', [APP_AUTH_TYPE_KEY])
->label('sdk.namespace', 'databases')
->label('sdk.method', 'create')
->label('sdk.description', '/docs/references/databases/create-database.md') // create this file later
->label('sdk.description', '/docs/references/databases/create.md') // create this file later
->label('sdk.response.code', Response::STATUS_CODE_CREATED)
->label('sdk.response.type', Response::CONTENT_TYPE_JSON)
->label('sdk.response.model', Response::MODEL_DATABASE) // Model for database needs to be created

View file

@ -1 +1 @@
Create a new Collection.
Create a new Collection. Before using this route, you should create a new database resource using either a [server integration](/docs/server/database#databaseCreateCollection) API or directly from your database console.

View file

@ -0,0 +1 @@
Create a new Database.

View file

@ -0,0 +1 @@
Delete a database by its unique ID. Only API keys with with databases.write scope can delete a database.

View file

@ -0,0 +1 @@
Get a database by its unique ID. This endpoint response returns a JSON object with the database metadata.

View file

@ -1 +1 @@
Get a list of all the user collections. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of the project's collections. [Learn more about different API modes](/docs/admin).
Get a list of all collections that belong to the provided databaseId. You can use the search parameter to filter your results.

View file

@ -1 +1 @@
Get a list of all the user documents. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of the project's documents. [Learn more about different API modes](/docs/admin).
Get a list of all the user's documents in a given collection. You can use the query params to filter your results. On admin mode, this endpoint will return a list of all of documents belonging to the provided collectionId. [Learn more about different API modes](/docs/admin).

View file

@ -0,0 +1 @@
Get a list of all databases from the current Appwrite project. You can use the search parameter to filter your results.

View file

@ -0,0 +1 @@
Update a database by its unique ID.

View file

@ -1,7 +1,7 @@
The Database service allows you to create structured collections of documents, query and filter lists of documents, and manage an advanced set of read and write access permissions.
The Databases service allows you to create structured collections of documents, query and filter lists of documents, and manage an advanced set of read and write access permissions.
All the data in the database service is stored in structured JSON documents.
All data returned by the Databases service are represented as structured JSON documents.
Each database document structure in your project is defined using the Appwrite [collection attributes](/docs/database#attributes). The collection attributes help you ensure all your user-submitted data is validated and stored according to the collection structure.
The Databases service can contain multiple databases, each database can contain multiple collections. A collection is a group of similarly structured documents. The accepted structure of documents is defined by [collection attributes](/docs/database#attributes). The collection attributes help you ensure all your user-submitted data is validated and stored according to the collection structure.
Using Appwrite permissions architecture, you can assign read or write access to each collection or document in your project for either a specific user, team, user role, or even grant it with public access (`role:all`). You can learn more about [how Appwrite handles permissions and access control](/docs/permissions).
Using Appwrite permissions architecture, you can assign read or write access to each collection or document in your project for either a specific user, team, user role, or even grant it with public access (`role:all`). You can learn more about [how Appwrite handles permissions and access control](/docs/permissions).