Merge branch 'master' of github.com:appwrite/appwrite into feature--flutter-support
This commit is contained in:
commit
c4c6dbbda0
32 changed files with 116 additions and 15 deletions
12
README.md
12
README.md
|
@ -73,13 +73,13 @@ Getting started with Appwrite is as easy as creating a new project, choosing you
|
||||||
|
|
||||||
### Services
|
### Services
|
||||||
|
|
||||||
* [**Account**](https://appwrite.io/docs/account) - Manage current user authentication and account. Track and manage the user sessions, devices, sigin methods, and security logs.
|
* [**Account**](https://appwrite.io/docs/account) - Manage current user authentication and account. Track and manage the user sessions, devices, sign-in methods, and security logs.
|
||||||
* [**Users**](https://appwrite.io/docs/users) - Manage and list all project users when in admin mode.
|
* [**Users**](https://appwrite.io/docs/users) - Manage and list all project users when in admin mode.
|
||||||
* [**Teams**](https://appwrite.io/docs/teams) - Manage and group users in teams. Manage memberships, invites and user roles within a team.
|
* [**Teams**](https://appwrite.io/docs/teams) - Manage and group users in teams. Manage memberships, invites, and user roles within a team.
|
||||||
* [**Database**](https://appwrite.io/docs/database) - Manage database collections and documents. Read, create, update and delete documents and filter lists of documents collections using an advanced filter with graph-like capabilities.
|
* [**Database**](https://appwrite.io/docs/database) - Manage database collections and documents. Read, create, update, and delete documents and filter lists of documents collections using an advanced filter with graph-like capabilities.
|
||||||
* [**Storage**](https://appwrite.io/docs/storage) - Manage storage files. Read, create, delete and preview files. Manipulate the preview of your files to fit your app perfectly. All files are scanned by ClamAV and stored in a secure and encrypted way.
|
* [**Storage**](https://appwrite.io/docs/storage) - Manage storage files. Read, create, delete, and preview files. Manipulate the preview of your files to fit your app perfectly. All files are scanned by ClamAV and stored in a secure and encrypted way.
|
||||||
* [**Locale**](https://appwrite.io/docs/locale) - Track user's location, and manage your app locale-based data.
|
* [**Locale**](https://appwrite.io/docs/locale) - Track your user's location, and manage your app locale-based data.
|
||||||
* [**Avatars**](https://appwrite.io/docs/avatars) - Manage your users' avatars, countries' flags, browser icons, credit card symbols and generate QR codes.
|
* [**Avatars**](https://appwrite.io/docs/avatars) - Manage your users' avatars, countries' flags, browser icons, credit card symbols, and generate QR codes.
|
||||||
|
|
||||||
For the complete API documentation, visit [https://appwrite.io/docs](https://appwrite.io/docs). For more tutorials, news and announcements check out our [blog](https://medium.com/appwrite-io).
|
For the complete API documentation, visit [https://appwrite.io/docs](https://appwrite.io/docs). For more tutorials, news and announcements check out our [blog](https://medium.com/appwrite-io).
|
||||||
|
|
||||||
|
|
|
@ -130,7 +130,7 @@ return [
|
||||||
[
|
[
|
||||||
'key' => 'dart',
|
'key' => 'dart',
|
||||||
'name' => 'Dart',
|
'name' => 'Dart',
|
||||||
'version' => '0.0.7',
|
'version' => '0.0.8',
|
||||||
'url' => 'https://github.com/appwrite/sdk-for-dart',
|
'url' => 'https://github.com/appwrite/sdk-for-dart',
|
||||||
'enabled' => true,
|
'enabled' => true,
|
||||||
'beta' => true,
|
'beta' => true,
|
||||||
|
|
|
@ -222,6 +222,32 @@ $utopia->get('/v1/mock/tests/general/redirected')
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
$utopia->get('/v1/mock/tests/general/set-cookie')
|
||||||
|
->desc('Mock a cookie request for SDK tests')
|
||||||
|
->label('scope', 'public')
|
||||||
|
->label('sdk.namespace', 'general')
|
||||||
|
->label('sdk.method', 'setCookie')
|
||||||
|
->label('sdk.description', 'Mock a set cookie request for SDK tests')
|
||||||
|
->action(
|
||||||
|
function () use ($response) {
|
||||||
|
$response->addCookie('cookieName', 'cookieValue', time() + 31536000, '/', 'localhost', true, true);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
$utopia->get('/v1/mock/tests/general/get-cookie')
|
||||||
|
->desc('Mock a cookie request for SDK tests')
|
||||||
|
->label('scope', 'public')
|
||||||
|
->label('sdk.namespace', 'general')
|
||||||
|
->label('sdk.method', 'getCookie')
|
||||||
|
->label('sdk.description', 'Mock a get cookie request for SDK tests')
|
||||||
|
->action(
|
||||||
|
function () use ($request) {
|
||||||
|
if($request->getCookie('cookieName', '') !== 'cookieValue') {
|
||||||
|
throw new Exception('Missing cookie value', 400);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
$utopia->get('/v1/mock/tests/general/empty')
|
$utopia->get('/v1/mock/tests/general/empty')
|
||||||
->desc('Mock a post request for SDK tests')
|
->desc('Mock a post request for SDK tests')
|
||||||
->label('scope', 'public')
|
->label('scope', 'public')
|
||||||
|
|
1
app/sdks/console-javascript/CHANGELOG.md
Normal file
1
app/sdks/console-javascript/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
|
@ -31,6 +31,21 @@ To install with a CDN (content delivery network) add the following scripts to th
|
||||||
<script src="https://cdn.jsdelivr.net/npm/appwrite@1.0.0"></script>
|
<script src="https://cdn.jsdelivr.net/npm/appwrite@1.0.0"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Getting Started
|
||||||
|
|
||||||
|
Initialise the Appwrite SDK in your code, and setup your API credentials:
|
||||||
|
|
||||||
|
```js
|
||||||
|
|
||||||
|
// Init your JS SDK
|
||||||
|
var appwrite = new Appwrite();
|
||||||
|
|
||||||
|
appwrite
|
||||||
|
.setEndpoint('http://localhost/v1') // Set only when using self-hosted solution
|
||||||
|
.setProject('455x34dfkj') // Your Appwrite Project UID
|
||||||
|
;
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
## Contribution
|
## Contribution
|
||||||
|
|
4
app/sdks/flutter-dart/CHANGELOG.md
Normal file
4
app/sdks/flutter-dart/CHANGELOG.md
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
## 0.0.8
|
||||||
|
|
||||||
|
- Fixed compilation error in Client class
|
||||||
|
- Shorter description for package
|
|
@ -17,7 +17,7 @@ Add this to your package's `pubspec.yaml` file:
|
||||||
|
|
||||||
```yml
|
```yml
|
||||||
dependencies:
|
dependencies:
|
||||||
appwrite: ^0.0.7
|
appwrite: ^0.0.8
|
||||||
```
|
```
|
||||||
|
|
||||||
You can install packages from the command line:
|
You can install packages from the command line:
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
import 'dart:io';
|
||||||
|
|
||||||
|
import 'package:dio/adapter.dart';
|
||||||
import 'package:dio/dio.dart';
|
import 'package:dio/dio.dart';
|
||||||
import 'package:dio_cookie_manager/dio_cookie_manager.dart';
|
import 'package:dio_cookie_manager/dio_cookie_manager.dart';
|
||||||
import 'package:cookie_jar/cookie_jar.dart';
|
import 'package:cookie_jar/cookie_jar.dart';
|
||||||
|
@ -13,7 +16,7 @@ class Client {
|
||||||
Client({this.endPoint: 'https://appwrite.io/v1', this.selfSigned: false, Dio http}) : this.http = http ?? Dio() {
|
Client({this.endPoint: 'https://appwrite.io/v1', this.selfSigned: false, Dio http}) : this.http = http ?? Dio() {
|
||||||
this.headers = {
|
this.headers = {
|
||||||
'content-type': 'application/json',
|
'content-type': 'application/json',
|
||||||
'x-sdk-version': 'appwrite:dart:0.0.7',
|
'x-sdk-version': 'appwrite:dart:0.0.8',
|
||||||
};
|
};
|
||||||
|
|
||||||
assert(endPoint.startsWith(RegExp("http://|https://")), "endPoint $endPoint must start with 'http'");
|
assert(endPoint.startsWith(RegExp("http://|https://")), "endPoint $endPoint must start with 'http'");
|
||||||
|
@ -58,6 +61,13 @@ class Client {
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<Response> call(HttpMethod method, {String path = '', Map<String, String> headers = const {}, Map<String, dynamic> params = const {}}) {
|
Future<Response> call(HttpMethod method, {String path = '', Map<String, String> headers = const {}, Map<String, dynamic> params = const {}}) {
|
||||||
|
if(this.selfSigned) {
|
||||||
|
// Allow self signed requests
|
||||||
|
(http.httpClientAdapter as DefaultHttpClientAdapter).onHttpClientCreate = (HttpClient client) {
|
||||||
|
client.badCertificateCallback = (X509Certificate cert, String host, int port) => true;
|
||||||
|
return client;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
// Origin is hardcoded for testing
|
// Origin is hardcoded for testing
|
||||||
Options options = Options(
|
Options options = Options(
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: appwrite
|
name: appwrite
|
||||||
version: 0.0.7
|
version: 0.0.8
|
||||||
description: Appwrite backend as a service cuts up to 70% of the time and costs required for building a modern application. We abstract and simplify common development tasks behind a REST APIs, to help you develop your app in a fast and secure way. For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs)
|
description: Appwrite backend as a service cuts up to 70% of the time and costs required for building a modern application. We abstract and simplify common development tasks behind a REST APIs, to help you develop your app in a fast and secure way. For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs)
|
||||||
homepage: https://github.com/appwrite/sdk-for-dart
|
homepage: https://github.com/appwrite/sdk-for-dart
|
||||||
environment:
|
environment:
|
||||||
|
|
1
app/sdks/server-go/CHANGELOG.md
Normal file
1
app/sdks/server-go/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
app/sdks/server-nodejs/CHANGELOG.md
Normal file
1
app/sdks/server-nodejs/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
app/sdks/server-php/CHANGELOG.md
Normal file
1
app/sdks/server-php/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
app/sdks/server-python/CHANGELOG.md
Normal file
1
app/sdks/server-python/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
app/sdks/server-ruby/CHANGELOG.md
Normal file
1
app/sdks/server-ruby/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
app/sdks/web-javascript/CHANGELOG.md
Normal file
1
app/sdks/web-javascript/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
|
@ -31,6 +31,21 @@ To install with a CDN (content delivery network) add the following scripts to th
|
||||||
<script src="https://cdn.jsdelivr.net/npm/appwrite@1.0.29"></script>
|
<script src="https://cdn.jsdelivr.net/npm/appwrite@1.0.29"></script>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Getting Started
|
||||||
|
|
||||||
|
Initialise the Appwrite SDK in your code, and setup your API credentials:
|
||||||
|
|
||||||
|
```js
|
||||||
|
|
||||||
|
// Init your JS SDK
|
||||||
|
var appwrite = new Appwrite();
|
||||||
|
|
||||||
|
appwrite
|
||||||
|
.setEndpoint('http://localhost/v1') // Set only when using self-hosted solution
|
||||||
|
.setProject('455x34dfkj') // Your Appwrite Project UID
|
||||||
|
;
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
## Contribution
|
## Contribution
|
||||||
|
|
|
@ -58,8 +58,10 @@ $cli
|
||||||
|
|
||||||
$result = realpath(__DIR__.'/..').'/sdks/'.$key.'-'.$language['key'];
|
$result = realpath(__DIR__.'/..').'/sdks/'.$key.'-'.$language['key'];
|
||||||
$target = realpath(__DIR__.'/..').'/sdks/git/'.$language['key'].'/';
|
$target = realpath(__DIR__.'/..').'/sdks/git/'.$language['key'].'/';
|
||||||
$readme = realpath(__DIR__ . '/../../docs/sdks/'.$language['key'].'.md');
|
$readme = realpath(__DIR__ . '/../../docs/sdks/'.$language['key'].'/README.md');
|
||||||
$readme = ($readme) ? file_get_contents($readme) : '';
|
$readme = ($readme) ? file_get_contents($readme) : '';
|
||||||
|
$changelog = realpath(__DIR__ . '/../../docs/sdks/'.$language['key'].'/CHANGELOG.md');
|
||||||
|
$changelog = ($changelog) ? file_get_contents($changelog) : '# Change Log';
|
||||||
$warning = ($language['beta']) ? '**This SDK is compatible with Appwrite server version ' . $version . '. For older versions, please check previous releases.**' : '';
|
$warning = ($language['beta']) ? '**This SDK is compatible with Appwrite server version ' . $version . '. For older versions, please check previous releases.**' : '';
|
||||||
$license = 'BSD-3-Clause';
|
$license = 'BSD-3-Clause';
|
||||||
$licenseContent = 'Copyright (c) 2019 Appwrite (https://appwrite.io) and individual contributors.
|
$licenseContent = 'Copyright (c) 2019 Appwrite (https://appwrite.io) and individual contributors.
|
||||||
|
@ -148,6 +150,7 @@ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
||||||
->setShareVia('appwrite_io')
|
->setShareVia('appwrite_io')
|
||||||
->setWarning($warning)
|
->setWarning($warning)
|
||||||
->setReadme($readme)
|
->setReadme($readme)
|
||||||
|
->setChangelog($changelog)
|
||||||
;
|
;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
4
composer.lock
generated
4
composer.lock
generated
|
@ -1622,7 +1622,11 @@
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/appwrite/sdk-generator",
|
"url": "https://github.com/appwrite/sdk-generator",
|
||||||
|
<<<<<<< HEAD
|
||||||
"reference": "ea7291f4419ad52f4565f57f1b61eace0bf3bba4"
|
"reference": "ea7291f4419ad52f4565f57f1b61eace0bf3bba4"
|
||||||
|
=======
|
||||||
|
"reference": "3b7389388f29c6e0cf53cf2233ee516fb20ad9f7"
|
||||||
|
>>>>>>> 02c7f4a6119d1e53543293d97bff66ebc9da7ebd
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"ext-curl": "*",
|
"ext-curl": "*",
|
||||||
|
|
4
docs/sdks/dart/CHANGELOG.md
Normal file
4
docs/sdks/dart/CHANGELOG.md
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
## 0.0.8
|
||||||
|
|
||||||
|
- Fixed compilation error in Client class
|
||||||
|
- Shorter description for package
|
1
docs/sdks/go/CHANGELOG.md
Normal file
1
docs/sdks/go/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/java/CHANGELOG.md
Normal file
1
docs/sdks/java/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/javascript/CHANGELOG.md
Normal file
1
docs/sdks/javascript/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/kotlin/CHANGELOG.md
Normal file
1
docs/sdks/kotlin/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/nodejs/CHANGELOG.md
Normal file
1
docs/sdks/nodejs/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/objective-c/CHANGELOG.md
Normal file
1
docs/sdks/objective-c/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/php/CHANGELOG.md
Normal file
1
docs/sdks/php/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/python/CHANGELOG.md
Normal file
1
docs/sdks/python/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/ruby/CHANGELOG.md
Normal file
1
docs/sdks/ruby/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/swift/CHANGELOG.md
Normal file
1
docs/sdks/swift/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
1
docs/sdks/typescript/CHANGELOG.md
Normal file
1
docs/sdks/typescript/CHANGELOG.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
# Change Log
|
|
@ -1,5 +1,7 @@
|
||||||
The database service allows you to create structured document collections, query and filter lists of documents, and manage an advanced set of read and write access.
|
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.
|
||||||
|
|
||||||
All the data in the database service is stored in JSON format. The service also allows you to nest child documents and use advanced filters to search and query the database just like you would with a classic graph database.
|
All the data in the database service is stored in structured JSON documents. The Appwrite database service also allows you to nest child documents in documents and use advanced filters to both search and query the database just like you would with a classic graph database.
|
||||||
|
|
||||||
By leveraging the database permission management, you can assign read or write access to the database documents for a specific user, team, user role, or even grant public access to all visitors to your project. You can learn more about [how Appwrite handles permissions and role access control](/docs/permissions).
|
Each database document structure in your project is defined using the Appwrite [collection rules](/docs/rules). The collections rules 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 document in your project for either a specific user, team, user role, or even grant it with public access. You can learn more about [how Appwrite handles permissions and access control](/docs/permissions).
|
Loading…
Reference in a new issue