From 4a29f2df95a7910ef4bc5fb72a59edd5cf18e8c4 Mon Sep 17 00:00:00 2001 From: Eldad Fux Date: Thu, 24 Dec 2020 11:29:52 +0200 Subject: [PATCH] Removed Flutter dev --- app/config/platforms.php | 16 - .../0.6.2/client-flutter-dev/CHANGELOG.md | 64 --- app/sdks/0.6.2/client-flutter-dev/LICENSE | 12 - app/sdks/0.6.2/client-flutter-dev/README.md | 38 -- .../examples/account/create-o-auth2session.md | 22 - .../docs/examples/account/create-recovery.md | 23 - .../docs/examples/account/create-session.md | 23 - .../examples/account/create-verification.md | 22 - .../docs/examples/account/create.md | 23 - .../docs/examples/account/delete-session.md | 22 - .../docs/examples/account/delete-sessions.md | 20 - .../docs/examples/account/delete.md | 20 - .../docs/examples/account/get-logs.md | 20 - .../docs/examples/account/get-prefs.md | 20 - .../docs/examples/account/get-sessions.md | 20 - .../docs/examples/account/get.md | 20 - .../docs/examples/account/update-email.md | 23 - .../docs/examples/account/update-name.md | 22 - .../docs/examples/account/update-password.md | 23 - .../docs/examples/account/update-prefs.md | 22 - .../docs/examples/account/update-recovery.md | 25 - .../examples/account/update-verification.md | 23 - .../docs/examples/avatars/get-browser.md | 17 - .../docs/examples/avatars/get-credit-card.md | 17 - .../docs/examples/avatars/get-favicon.md | 17 - .../docs/examples/avatars/get-flag.md | 17 - .../docs/examples/avatars/get-image.md | 17 - .../docs/examples/avatars/get-initials.md | 16 - .../docs/examples/avatars/get-q-r.md | 17 - .../docs/examples/database/create-document.md | 25 - .../docs/examples/database/delete-document.md | 23 - .../docs/examples/database/get-document.md | 23 - .../docs/examples/database/list-documents.md | 22 - .../docs/examples/database/update-document.md | 26 -- .../docs/examples/locale/get-continents.md | 20 - .../docs/examples/locale/get-countries-e-u.md | 20 - .../examples/locale/get-countries-phones.md | 20 - .../docs/examples/locale/get-countries.md | 20 - .../docs/examples/locale/get-currencies.md | 20 - .../docs/examples/locale/get-languages.md | 20 - .../docs/examples/locale/get.md | 20 - .../docs/examples/storage/create-file.md | 25 - .../docs/examples/storage/delete-file.md | 22 - .../examples/storage/get-file-download.md | 17 - .../docs/examples/storage/get-file-preview.md | 17 - .../docs/examples/storage/get-file-view.md | 17 - .../docs/examples/storage/get-file.md | 22 - .../docs/examples/storage/list-files.md | 21 - .../docs/examples/storage/update-file.md | 24 - .../docs/examples/teams/create-membership.md | 25 - .../docs/examples/teams/create.md | 22 - .../docs/examples/teams/delete-membership.md | 23 - .../docs/examples/teams/delete.md | 22 - .../docs/examples/teams/get-memberships.md | 22 - .../docs/examples/teams/get.md | 22 - .../docs/examples/teams/list.md | 21 - .../teams/update-membership-status.md | 25 - .../docs/examples/teams/update.md | 23 - .../client-flutter-dev/example/README.md | 55 --- .../client-flutter-dev/lib/appwrite_dev.dart | 10 - .../0.6.2/client-flutter-dev/lib/client.dart | 144 ------ .../0.6.2/client-flutter-dev/lib/enums.dart | 15 - .../0.6.2/client-flutter-dev/lib/service.dart | 7 - .../lib/services/account.dart | 435 ------------------ .../lib/services/avatars.dart | 238 ---------- .../lib/services/database.dart | 119 ----- .../lib/services/locale.dart | 143 ------ .../lib/services/storage.dart | 203 -------- .../lib/services/teams.dart | 207 --------- .../0.6.2/client-flutter-dev/pubspec.yaml | 24 - .../0.7.0/client-flutter-dev/CHANGELOG.md | 64 --- app/sdks/0.7.0/client-flutter-dev/LICENSE | 12 - app/sdks/0.7.0/client-flutter-dev/README.md | 38 -- .../examples/account/create-o-auth2session.md | 22 - .../docs/examples/account/create-recovery.md | 23 - .../docs/examples/account/create-session.md | 23 - .../examples/account/create-verification.md | 22 - .../docs/examples/account/create.md | 23 - .../docs/examples/account/delete-session.md | 22 - .../docs/examples/account/delete-sessions.md | 20 - .../docs/examples/account/delete.md | 20 - .../docs/examples/account/get-logs.md | 20 - .../docs/examples/account/get-prefs.md | 20 - .../docs/examples/account/get-sessions.md | 20 - .../docs/examples/account/get.md | 20 - .../docs/examples/account/update-email.md | 23 - .../docs/examples/account/update-name.md | 22 - .../docs/examples/account/update-password.md | 23 - .../docs/examples/account/update-prefs.md | 22 - .../docs/examples/account/update-recovery.md | 25 - .../examples/account/update-verification.md | 23 - .../docs/examples/avatars/get-browser.md | 17 - .../docs/examples/avatars/get-credit-card.md | 17 - .../docs/examples/avatars/get-favicon.md | 17 - .../docs/examples/avatars/get-flag.md | 17 - .../docs/examples/avatars/get-image.md | 17 - .../docs/examples/avatars/get-initials.md | 16 - .../docs/examples/avatars/get-q-r.md | 17 - .../docs/examples/database/create-document.md | 25 - .../docs/examples/database/delete-document.md | 23 - .../docs/examples/database/get-document.md | 23 - .../docs/examples/database/list-documents.md | 22 - .../docs/examples/database/update-document.md | 26 -- .../docs/examples/locale/get-continents.md | 20 - .../docs/examples/locale/get-countries-e-u.md | 20 - .../examples/locale/get-countries-phones.md | 20 - .../docs/examples/locale/get-countries.md | 20 - .../docs/examples/locale/get-currencies.md | 20 - .../docs/examples/locale/get-languages.md | 20 - .../docs/examples/locale/get.md | 20 - .../docs/examples/storage/create-file.md | 25 - .../docs/examples/storage/delete-file.md | 22 - .../examples/storage/get-file-download.md | 17 - .../docs/examples/storage/get-file-preview.md | 17 - .../docs/examples/storage/get-file-view.md | 17 - .../docs/examples/storage/get-file.md | 22 - .../docs/examples/storage/list-files.md | 21 - .../docs/examples/storage/update-file.md | 24 - .../docs/examples/teams/create-membership.md | 25 - .../docs/examples/teams/create.md | 22 - .../docs/examples/teams/delete-membership.md | 23 - .../docs/examples/teams/delete.md | 22 - .../docs/examples/teams/get-memberships.md | 22 - .../docs/examples/teams/get.md | 22 - .../docs/examples/teams/list.md | 21 - .../teams/update-membership-status.md | 25 - .../docs/examples/teams/update.md | 23 - .../client-flutter-dev/example/README.md | 55 --- .../client-flutter-dev/lib/appwrite_dev.dart | 10 - .../0.7.0/client-flutter-dev/lib/client.dart | 144 ------ .../0.7.0/client-flutter-dev/lib/enums.dart | 15 - .../0.7.0/client-flutter-dev/lib/service.dart | 7 - .../lib/services/account.dart | 435 ------------------ .../lib/services/avatars.dart | 239 ---------- .../lib/services/database.dart | 119 ----- .../lib/services/locale.dart | 143 ------ .../lib/services/storage.dart | 203 -------- .../lib/services/teams.dart | 207 --------- .../0.7.0/client-flutter-dev/pubspec.yaml | 24 - 139 files changed, 5725 deletions(-) delete mode 100644 app/sdks/0.6.2/client-flutter-dev/CHANGELOG.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/LICENSE delete mode 100644 app/sdks/0.6.2/client-flutter-dev/README.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-o-auth2session.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-recovery.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-session.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-verification.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-session.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-sessions.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-logs.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-prefs.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-sessions.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-email.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-name.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-password.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-prefs.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-recovery.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-verification.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-browser.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-credit-card.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-favicon.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-flag.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-image.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-initials.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-q-r.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/database/create-document.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/database/delete-document.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/database/get-document.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/database/list-documents.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/database/update-document.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-continents.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-e-u.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-phones.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-currencies.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-languages.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/create-file.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/delete-file.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-download.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-preview.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-view.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/list-files.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/update-file.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create-membership.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete-membership.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get-memberships.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/list.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update-membership-status.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/example/README.md delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/appwrite_dev.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/client.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/enums.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/service.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/services/account.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/services/avatars.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/services/database.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/services/locale.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/services/storage.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/lib/services/teams.dart delete mode 100644 app/sdks/0.6.2/client-flutter-dev/pubspec.yaml delete mode 100644 app/sdks/0.7.0/client-flutter-dev/CHANGELOG.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/LICENSE delete mode 100644 app/sdks/0.7.0/client-flutter-dev/README.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-o-auth2session.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-recovery.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-session.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-verification.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-session.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-sessions.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-logs.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-prefs.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-sessions.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-email.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-name.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-password.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-prefs.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-recovery.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-verification.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-browser.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-credit-card.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-favicon.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-flag.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-image.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-initials.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-q-r.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/database/create-document.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/database/delete-document.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/database/get-document.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/database/list-documents.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/database/update-document.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-continents.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-e-u.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-phones.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-currencies.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-languages.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/create-file.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/delete-file.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-download.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-preview.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-view.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/list-files.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/update-file.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create-membership.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete-membership.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get-memberships.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/list.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update-membership-status.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/example/README.md delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/appwrite_dev.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/client.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/enums.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/service.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/services/account.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/services/avatars.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/services/database.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/services/locale.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/services/storage.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/lib/services/teams.dart delete mode 100644 app/sdks/0.7.0/client-flutter-dev/pubspec.yaml diff --git a/app/config/platforms.php b/app/config/platforms.php index 98715ba652..c9a3f25b59 100644 --- a/app/config/platforms.php +++ b/app/config/platforms.php @@ -44,22 +44,6 @@ return [ 'gitRepoName' => 'sdk-for-flutter', 'gitUserName' => 'appwrite', ], - [ - 'key' => 'flutter-dev', - 'name' => 'Flutter (Dev Channel)', - 'version' => '0.3.2', - 'url' => 'https://github.com/appwrite/sdk-for-flutter-dev', - 'package' => '', - 'enabled' => true, - 'beta' => true, - 'dev' => true, - 'family' => APP_PLATFORM_CLIENT, - 'prism' => 'dart', - 'source' => realpath(__DIR__ . '/../sdks/client-flutter-dev'), - 'gitUrl' => 'git@github.com:appwrite/sdk-for-flutter-dev.git', - 'gitRepoName' => 'sdk-for-flutter-dev', - 'gitUserName' => 'appwrite', - ], [ 'key' => 'swift', 'name' => 'Swift', diff --git a/app/sdks/0.6.2/client-flutter-dev/CHANGELOG.md b/app/sdks/0.6.2/client-flutter-dev/CHANGELOG.md deleted file mode 100644 index 2e9b0e0a91..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/CHANGELOG.md +++ /dev/null @@ -1,64 +0,0 @@ -## 0.3.2 - -- Fixed package namespaces - -## 0.3.1 - -- Downgraded meta package version to 1.1.8 - -## 0.3.0 - -- Updated package dependencies (@lohanidamodar) -- Added Flutter for Web compatibility (@lohanidamodar) - -## 0.2.3 - -- Fixed OAuth2 cookie bug, where a new session cookie couldn't overwrite an old cookie - -## 0.2.2 - -- Fixed an error that happend when the OAuth session creation request was sent before any other API call -- Fixed a bug in the Avatars service where location URL generation had syntax error - -## 0.2.1 - -- Fixed callback scheme - -## 0.2.0 - -- Updated flutter_web_auth plugin to version 0.2.4 -- Added per project unique callback for OAuth2 redirects to aviod conflicts between multiple Appwrite projects - -## 0.1.1 - -- Updated flutter_web_auth version - -## 0.1.0 - -- Added examples file -- Some minor style fixes - -## 0.0.14 - -- Using MultipartFile for file uploads - -## 0.0.13 - -- Fix for file upload method - -## 0.0.12 - -- Added file upload support for storage service - -## 0.0.11 - -- Added integration with web auth plugin to support Appwrite OAuth API - -## 0.0.9 - -- Updated deafult params - -## 0.0.8 - -- Fixed compilation error in Client class -- Shorter description for package \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/LICENSE b/app/sdks/0.6.2/client-flutter-dev/LICENSE deleted file mode 100644 index fc7c051a91..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/LICENSE +++ /dev/null @@ -1,12 +0,0 @@ -Copyright (c) 2019 Appwrite (https://appwrite.io) and individual contributors. -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - 3. Neither the name Appwrite nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/README.md b/app/sdks/0.6.2/client-flutter-dev/README.md deleted file mode 100644 index 2c0ba754c3..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/README.md +++ /dev/null @@ -1,38 +0,0 @@ -# Appwrite Flutter (Dev Channel) SDK - -[![pub package](https://img.shields.io/pub/v/appwrite.svg)](https://pub.dartlang.org/packages/appwrite) -![License](https://img.shields.io/github/license/appwrite/sdk-for-flutter-dev.svg?v=1) -![Version](https://img.shields.io/badge/api%20version-0.6.2-blue.svg?v=1) - -**This SDK is compatible with Appwrite server version 0.6.2. For older versions, please check previous releases.** - -Appwrite is an open-source backend as a service server that abstract and simplify complex and repetitive development tasks behind a very simple to use REST API. Appwrite aims to help you develop your apps faster and in a more secure way. - Use the Flutter (Dev Channel) SDK to integrate your app with the Appwrite server to easily start interacting with all of Appwrite backend APIs and tools. - For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs) - - - -![Appwrite](https://appwrite.io/images/github.png) - -## Installation - -Add this to your package's `pubspec.yaml` file: - -```yml -dependencies: - appwrite_dev: ^0.3.2 -``` - -You can install packages from the command line: - -```bash -pub get appwrite_dev -``` - -## Contribution - -This library is auto-generated by Appwrite custom [SDK Generator](https://github.com/appwrite/sdk-generator). To learn more about how you can help us improve this SDK, please check the [contribution guide](https://github.com/appwrite/sdk-generator/blob/master/CONTRIBUTING.md) before sending a pull-request. - -## License - -Please see the [BSD-3-Clause license](https://raw.githubusercontent.com/appwrite/appwrite/master/LICENSE) file for more information. \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-o-auth2session.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-o-auth2session.md deleted file mode 100644 index b3cb8831ee..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-o-auth2session.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createOAuth2Session( - provider: 'amazon', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-recovery.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-recovery.md deleted file mode 100644 index 32fe469cff..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-recovery.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createRecovery( - email: 'email@example.com', - url: 'https://example.com', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-session.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-session.md deleted file mode 100644 index a5930877f4..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-session.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createSession( - email: 'email@example.com', - password: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-verification.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-verification.md deleted file mode 100644 index 738f22df42..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create-verification.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createVerification( - url: 'https://example.com', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create.md deleted file mode 100644 index 1f92976c39..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/create.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.create( - email: 'email@example.com', - password: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-session.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-session.md deleted file mode 100644 index 95b3641387..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-session.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.deleteSession( - sessionId: '[SESSION_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-sessions.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-sessions.md deleted file mode 100644 index 8aaef86816..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete-sessions.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.deleteSessions(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete.md deleted file mode 100644 index e6e29f53aa..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/delete.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.delete(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-logs.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-logs.md deleted file mode 100644 index 92d9e47916..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-logs.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.getLogs(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-prefs.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-prefs.md deleted file mode 100644 index 02874f2251..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-prefs.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.getPrefs(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-sessions.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-sessions.md deleted file mode 100644 index ace4b1b6c1..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get-sessions.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.getSessions(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get.md deleted file mode 100644 index 4651559afb..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/get.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.get(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-email.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-email.md deleted file mode 100644 index 9fc86a7aae..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-email.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateEmail( - email: 'email@example.com', - password: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-name.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-name.md deleted file mode 100644 index e5e218a515..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-name.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateName( - name: '[NAME]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-password.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-password.md deleted file mode 100644 index 869b4d9a30..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-password.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updatePassword( - password: 'password', - oldPassword: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-prefs.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-prefs.md deleted file mode 100644 index 0d50469742..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-prefs.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updatePrefs( - prefs: {}, - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-recovery.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-recovery.md deleted file mode 100644 index e028e60a7d..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-recovery.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateRecovery( - userId: '[USER_ID]', - secret: '[SECRET]', - password: 'password', - passwordAgain: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-verification.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-verification.md deleted file mode 100644 index 48d669efcc..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/account/update-verification.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateVerification( - userId: '[USER_ID]', - secret: '[SECRET]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-browser.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-browser.md deleted file mode 100644 index dec7863b1f..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-browser.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getBrowser( - code: 'aa', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-credit-card.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-credit-card.md deleted file mode 100644 index e2746c4999..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-credit-card.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getCreditCard( - code: 'amex', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-favicon.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-favicon.md deleted file mode 100644 index 1c56335b9f..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-favicon.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getFavicon( - url: 'https://example.com', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-flag.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-flag.md deleted file mode 100644 index 8a91f608ce..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-flag.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getFlag( - code: 'af', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-image.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-image.md deleted file mode 100644 index a2cbea98e3..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-image.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getImage( - url: 'https://example.com', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-initials.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-initials.md deleted file mode 100644 index 5f9353feae..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-initials.md +++ /dev/null @@ -1,16 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getInitials( - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-q-r.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-q-r.md deleted file mode 100644 index 2737297082..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/avatars/get-q-r.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getQR( - text: '[TEXT]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/create-document.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/create-document.md deleted file mode 100644 index 6fc27bdfbb..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/create-document.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.createDocument( - collectionId: '[COLLECTION_ID]', - data: {}, - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/delete-document.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/delete-document.md deleted file mode 100644 index 74bcd69d9a..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/delete-document.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.deleteDocument( - collectionId: '[COLLECTION_ID]', - documentId: '[DOCUMENT_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/get-document.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/get-document.md deleted file mode 100644 index 639209ed3c..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/get-document.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.getDocument( - collectionId: '[COLLECTION_ID]', - documentId: '[DOCUMENT_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/list-documents.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/list-documents.md deleted file mode 100644 index 41eac5dd9a..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/list-documents.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.listDocuments( - collectionId: '[COLLECTION_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/update-document.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/update-document.md deleted file mode 100644 index 0b153b1595..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/database/update-document.md +++ /dev/null @@ -1,26 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.updateDocument( - collectionId: '[COLLECTION_ID]', - documentId: '[DOCUMENT_ID]', - data: {}, - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-continents.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-continents.md deleted file mode 100644 index cae4365382..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-continents.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getContinents(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-e-u.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-e-u.md deleted file mode 100644 index c326461bef..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-e-u.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCountriesEU(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-phones.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-phones.md deleted file mode 100644 index afd3f5d5be..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries-phones.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCountriesPhones(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries.md deleted file mode 100644 index e4fc236949..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-countries.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCountries(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-currencies.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-currencies.md deleted file mode 100644 index d3eb30533e..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-currencies.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCurrencies(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-languages.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-languages.md deleted file mode 100644 index 32b2a700c0..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get-languages.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getLanguages(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get.md deleted file mode 100644 index b0cca45924..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/locale/get.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.get(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/create-file.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/create-file.md deleted file mode 100644 index d824bd5831..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/create-file.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'dart:io'; -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.createFile( - file: await MultipartFile.fromFile('./path-to-files/image.jpg', 'image.jpg'), - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/delete-file.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/delete-file.md deleted file mode 100644 index 88e7b8815c..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/delete-file.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.deleteFile( - fileId: '[FILE_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-download.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-download.md deleted file mode 100644 index 483340e24a..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-download.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = storage.getFileDownload( - fileId: '[FILE_ID]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-preview.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-preview.md deleted file mode 100644 index dd8d924fe7..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-preview.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = storage.getFilePreview( - fileId: '[FILE_ID]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-view.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-view.md deleted file mode 100644 index 8ed6a946e0..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file-view.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = storage.getFileView( - fileId: '[FILE_ID]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file.md deleted file mode 100644 index 4e398f88fd..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/get-file.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.getFile( - fileId: '[FILE_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/list-files.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/list-files.md deleted file mode 100644 index d72ba29e03..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/list-files.md +++ /dev/null @@ -1,21 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.listFiles( - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/update-file.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/update-file.md deleted file mode 100644 index 95e213ddc2..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/storage/update-file.md +++ /dev/null @@ -1,24 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.updateFile( - fileId: '[FILE_ID]', - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create-membership.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create-membership.md deleted file mode 100644 index 31bf7ec1af..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create-membership.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.createMembership( - teamId: '[TEAM_ID]', - email: 'email@example.com', - roles: [], - url: 'https://example.com', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create.md deleted file mode 100644 index e50279de01..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/create.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.create( - name: '[NAME]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete-membership.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete-membership.md deleted file mode 100644 index 015507d3a2..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete-membership.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.deleteMembership( - teamId: '[TEAM_ID]', - inviteId: '[INVITE_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete.md deleted file mode 100644 index 6cc1367f9b..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/delete.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.delete( - teamId: '[TEAM_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get-memberships.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get-memberships.md deleted file mode 100644 index d427c9ac47..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get-memberships.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.getMemberships( - teamId: '[TEAM_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get.md deleted file mode 100644 index 1bca70a23f..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/get.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.get( - teamId: '[TEAM_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/list.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/list.md deleted file mode 100644 index c56e7a5dd5..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/list.md +++ /dev/null @@ -1,21 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.list( - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update-membership-status.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update-membership-status.md deleted file mode 100644 index 6098b38ed9..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update-membership-status.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.updateMembershipStatus( - teamId: '[TEAM_ID]', - inviteId: '[INVITE_ID]', - userId: '[USER_ID]', - secret: '[SECRET]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update.md b/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update.md deleted file mode 100644 index 2494f408d9..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/docs/examples/teams/update.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.update( - teamId: '[TEAM_ID]', - name: '[NAME]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/example/README.md b/app/sdks/0.6.2/client-flutter-dev/example/README.md deleted file mode 100644 index f6768a5f85..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/example/README.md +++ /dev/null @@ -1,55 +0,0 @@ -# Examples - -Init your Appwrite client: - -```dart - Client client = Client(); - - client - .setEndpoint('https://localhost/v1') // Your Appwrite Endpoint - .setProject('5e8cf4f46b5e8') // Your project ID - .setSelfSigned() // Remove in production - ; - -``` - -Create a new user and session: - -```dart -Account account = Account(client); - -Response user = await account.create(email: 'me@appwrite.io', password: 'password', name: 'My Name'); - -Response session = await account.createSession(email: 'me@appwrite.io', password: 'password'); - -``` - -Fetch user profile: - -```dart -Account account = Account(client); - -Response profile = await account.get(); -``` - -Upload File: - -```dart -Storage storage = Storage(client); - -MultipartFile file = MultipartFile.fromFile('./path-to-file/image.jpg', filename: 'image.jpg'); - -storage.createFile( - file: file, - read: ['*'], - write: [] -) -.then((response) { - print(response); // File uploaded! -}) -.catchError((error) { - print(error.response); -}); -``` - -All examples and API features are available at the [official Appwrite docs](https://appwrite.io/docs) \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/appwrite_dev.dart b/app/sdks/0.6.2/client-flutter-dev/lib/appwrite_dev.dart deleted file mode 100644 index 95d0b72cfe..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/appwrite_dev.dart +++ /dev/null @@ -1,10 +0,0 @@ -export 'package:dio/dio.dart' show Response; - -export 'client.dart'; -export 'enums.dart'; -export 'services/account.dart'; -export 'services/avatars.dart'; -export 'services/database.dart'; -export 'services/locale.dart'; -export 'services/storage.dart'; -export 'services/teams.dart'; diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/client.dart b/app/sdks/0.6.2/client-flutter-dev/lib/client.dart deleted file mode 100644 index b874b7e9e5..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/client.dart +++ /dev/null @@ -1,144 +0,0 @@ -import 'dart:io'; - -import 'package:dio/dio.dart'; -import 'package:flutter/foundation.dart'; -import 'package:dio/adapter.dart'; -import 'package:dio_cookie_manager/dio_cookie_manager.dart'; -import 'package:cookie_jar/cookie_jar.dart'; -import 'package:path_provider/path_provider.dart'; -import 'package:package_info/package_info.dart'; - -import 'enums.dart'; - -class Client { - String endPoint; - String type = 'unknown'; - Map headers; - Map config; - bool selfSigned; - bool initialized = false; - Dio http; - PersistCookieJar cookieJar; - - Client({this.endPoint = 'https://appwrite.io/v1', this.selfSigned = false, Dio http}) : this.http = http ?? Dio() { - // Platform is not supported in web so if web, set type to web automatically and skip Platform check - if(kIsWeb) { - type = 'web'; - }else{ - type = (Platform.isIOS) ? 'ios' : type; - type = (Platform.isMacOS) ? 'macos' : type; - type = (Platform.isAndroid) ? 'android' : type; - type = (Platform.isLinux) ? 'linux' : type; - type = (Platform.isWindows) ? 'windows' : type; - type = (Platform.isFuchsia) ? 'fuchsia' : type; - } - - this.headers = { - 'content-type': 'application/json', - 'x-sdk-version': 'appwrite:flutter:0.3.2', - }; - - this.config = {}; - - assert(endPoint.startsWith(RegExp("http://|https://")), "endPoint $endPoint must start with 'http'"); - } - - Future _getCookiePath() async { - final directory = await getApplicationDocumentsDirectory(); - final path = directory.path; - final Directory dir = new Directory('$path/cookies'); - await dir.create(); - return dir; - } - - /// Your project ID - Client setProject(value) { - config['project'] = value; - addHeader('X-Appwrite-Project', value); - return this; - } - - Client setLocale(value) { - config['locale'] = value; - addHeader('X-Appwrite-Locale', value); - return this; - } - - Client setSelfSigned({bool status = true}) { - selfSigned = status; - return this; - } - - Client setEndpoint(String endPoint) { - this.endPoint = endPoint; - this.http.options.baseUrl = this.endPoint; - return this; - } - - Client addHeader(String key, String value) { - headers[key] = value; - - return this; - } - - Future init() async { - if(!initialized) { - // if web skip cookie implementation and origin header as those are automatically handled by browsers - if(!kIsWeb) { - final Directory cookieDir = await _getCookiePath(); - cookieJar = new PersistCookieJar(dir:cookieDir.path); - this.http.interceptors.add(CookieManager(cookieJar)); - if(Platform.isAndroid || Platform.isIOS) { - PackageInfo packageInfo = await PackageInfo.fromPlatform(); - addHeader('Origin', 'appwrite-' + type + '://' + packageInfo.packageName); - } else if(Platform.isLinux) { - addHeader('Origin', 'appwrite-linux://'); - } else if(Platform.isMacOS) { - addHeader('Origin', 'appwrite-macos://'); - } else if(Platform.isWindows) { - addHeader('Origin', 'appwrite-windows://'); - } else if(Platform.isFuchsia) { - addHeader('Origin', 'appwrite-fuchsia://'); - } - }else{ - // if web set httpClientAdapter as BrowserHttpClientAdapter with withCredentials true to make cookies work - this.http.options.extra['withCredentials'] = true; - } - - this.http.options.baseUrl = this.endPoint; - this.http.options.validateStatus = (status) => status < 400; - } - } - - Future call(HttpMethod method, {String path = '', Map headers = const {}, Map params = const {}}) async { - if(selfSigned && !kIsWeb) { - // Allow self signed requests - (http.httpClientAdapter as DefaultHttpClientAdapter).onHttpClientCreate = (HttpClient client) { - client.badCertificateCallback = (X509Certificate cert, String host, int port) => true; - return client; - }; - } - - await this.init(); - - // Origin is hardcoded for testing - Options options = Options( - headers: {...this.headers, ...headers}, - method: method.name(), - ); - - if(headers['content-type'] == 'multipart/form-data') { - return http.request(path, data: FormData.fromMap(params), options: options); - } - - if (method == HttpMethod.get) { - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - return http.get(path, queryParameters: params, options: options); - } else { - return http.request(path, data: params, options: options); - } - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/enums.dart b/app/sdks/0.6.2/client-flutter-dev/lib/enums.dart deleted file mode 100644 index 2757f6073e..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/enums.dart +++ /dev/null @@ -1,15 +0,0 @@ -enum HttpMethod { get, post, put, delete, patch } - -extension HttpMethodString on HttpMethod { - String name() { - return this.toString().split('.').last.toUpperCase(); - } -} - -enum OrderType { asc, desc } - -extension OrderTypeString on OrderType { - String name() { - return this.toString().split('.').last.toUpperCase(); - } -} diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/service.dart b/app/sdks/0.6.2/client-flutter-dev/lib/service.dart deleted file mode 100644 index 1ae319b705..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/service.dart +++ /dev/null @@ -1,7 +0,0 @@ -import 'client.dart'; - -class Service { - final Client client; - - const Service(this.client); -} diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/services/account.dart b/app/sdks/0.6.2/client-flutter-dev/lib/services/account.dart deleted file mode 100644 index 890303a9d6..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/services/account.dart +++ /dev/null @@ -1,435 +0,0 @@ - -import 'dart:io'; -import 'package:universal_html/html.dart' as html; - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; -import 'package:flutter/foundation.dart'; -import 'package:flutter_web_auth/flutter_web_auth.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Account extends Service { - Account(Client client): super(client); - - /// Get Account - /// - /// Get currently logged in user data as JSON object. - /// - Future get() { - final String path = '/account'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Account - /// - /// Use this endpoint to allow a new user to register a new account in your - /// project. After the user registration completes successfully, you can use - /// the [/account/verfication](/docs/client/account#createVerification) route - /// to start verifying the user email address. To allow your new user to login - /// to his new account, you need to create a new [account - /// session](/docs/client/account#createSession). - /// - Future create({@required String email, @required String password, String name = ''}) { - final String path = '/account'; - - final Map params = { - 'email': email, - 'password': password, - 'name': name, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Delete Account - /// - /// Delete a currently logged in user account. Behind the scene, the user - /// record is not deleted but permanently blocked from any access. This is done - /// to avoid deleted accounts being overtaken by new users with the same email - /// address. Any user-related resources like documents or storage files should - /// be deleted separately. - /// - Future delete() { - final String path = '/account'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Update Account Email - /// - /// Update currently logged in user account email address. After changing user - /// address, user confirmation status is being reset and a new confirmation - /// mail is sent. For security measures, user password is required to complete - /// this request. - /// - Future updateEmail({@required String email, @required String password}) { - final String path = '/account/email'; - - final Map params = { - 'email': email, - 'password': password, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Get Account Logs - /// - /// Get currently logged in user list of latest security activity logs. Each - /// log returns user IP address, location and date and time of log. - /// - Future getLogs() { - final String path = '/account/logs'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Account Name - /// - /// Update currently logged in user account name. - /// - Future updateName({@required String name}) { - final String path = '/account/name'; - - final Map params = { - 'name': name, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Update Account Password - /// - /// Update currently logged in user password. For validation, user is required - /// to pass the password twice. - /// - Future updatePassword({@required String password, @required String oldPassword}) { - final String path = '/account/password'; - - final Map params = { - 'password': password, - 'oldPassword': oldPassword, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Get Account Preferences - /// - /// Get currently logged in user preferences as a key-value object. - /// - Future getPrefs() { - final String path = '/account/prefs'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Account Preferences - /// - /// Update currently logged in user account preferences. You can pass only the - /// specific settings you wish to update. - /// - Future updatePrefs({@required dynamic prefs}) { - final String path = '/account/prefs'; - - final Map params = { - 'prefs': prefs, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Create Password Recovery - /// - /// Sends the user an email with a temporary secret key for password reset. - /// When the user clicks the confirmation link he is redirected back to your - /// app password reset URL with the secret key and email address values - /// attached to the URL query string. Use the query string params to submit a - /// request to the [PUT /account/recovery](/docs/client/account#updateRecovery) - /// endpoint to complete the process. - /// - Future createRecovery({@required String email, @required String url}) { - final String path = '/account/recovery'; - - final Map params = { - 'email': email, - 'url': url, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Complete Password Recovery - /// - /// Use this endpoint to complete the user account password reset. Both the - /// **userId** and **secret** arguments will be passed as query parameters to - /// the redirect URL you have provided when sending your request to the [POST - /// /account/recovery](/docs/client/account#createRecovery) endpoint. - /// - /// Please note that in order to avoid a [Redirect - /// Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md) - /// the only valid redirect URLs are the ones from domains you have set when - /// adding your platforms in the console interface. - /// - Future updateRecovery({@required String userId, @required String secret, @required String password, @required String passwordAgain}) { - final String path = '/account/recovery'; - - final Map params = { - 'userId': userId, - 'secret': secret, - 'password': password, - 'passwordAgain': passwordAgain, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } - - /// Get Account Sessions - /// - /// Get currently logged in user list of active sessions across different - /// devices. - /// - Future getSessions() { - final String path = '/account/sessions'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Account Session - /// - /// Allow the user to login into his account by providing a valid email and - /// password combination. This route will create a new session for the user. - /// - Future createSession({@required String email, @required String password}) { - final String path = '/account/sessions'; - - final Map params = { - 'email': email, - 'password': password, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Delete All Account Sessions - /// - /// Delete all sessions from the user account and remove any sessions cookies - /// from the end client. - /// - Future deleteSessions() { - final String path = '/account/sessions'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Create Account Session with OAuth2 - /// - /// Allow the user to login to his account using the OAuth2 provider of his - /// choice. Each OAuth2 provider should be enabled from the Appwrite console - /// first. Use the success and failure arguments to provide a redirect URL's - /// back to your app when login is completed. - /// - Future createOAuth2Session({@required String provider, String success = 'https://appwrite.io/auth/oauth2/success', String failure = 'https://appwrite.io/auth/oauth2/failure', List scopes = const []}) { - final String path = '/account/sessions/oauth2/{provider}'.replaceAll(RegExp('{provider}'), provider); - - final Map params = { - 'success': success, - 'failure': failure, - 'scopes': scopes, - 'project': client.config['project'], - }; - - - final List query = []; - - params.forEach((key, value) { - if (value is List) { - for (var item in value) { - query.add(Uri.encodeComponent(key + '[]') + '=' + Uri.encodeComponent(item)); - } - } - else { - query.add(Uri.encodeComponent(key) + '=' + Uri.encodeComponent(value)); - } - }); - - Uri endpoint = Uri.parse(client.endPoint); - Uri url = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - query: query.join('&') - ); - - if(kIsWeb) { - html.window.location.href = url.toString(); - return null; - }else{ - - return FlutterWebAuth.authenticate( - url: url.toString(), - callbackUrlScheme: "appwrite-callback-" + client.config['project'] - ).then((value) async { - Uri url = Uri.parse(value); - Cookie cookie = new Cookie(url.queryParameters['key'], url.queryParameters['secret']); - cookie.domain = Uri.parse(client.endPoint).host; - cookie.httpOnly = true; - cookie.path = '/'; - List cookies = [cookie]; - await client.init(); - client.cookieJar.saveFromResponse(Uri.parse(client.endPoint), cookies); - }); - } - - } - - /// Delete Account Session - /// - /// Use this endpoint to log out the currently logged in user from all his - /// account sessions across all his different devices. When using the option id - /// argument, only the session unique ID provider will be deleted. - /// - Future deleteSession({@required String sessionId}) { - final String path = '/account/sessions/{sessionId}'.replaceAll(RegExp('{sessionId}'), sessionId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Create Email Verification - /// - /// Use this endpoint to send a verification message to your user email address - /// to confirm they are the valid owners of that address. Both the **userId** - /// and **secret** arguments will be passed as query parameters to the URL you - /// have provided to be attached to the verification email. The provided URL - /// should redirect the user back to your app and allow you to complete the - /// verification process by verifying both the **userId** and **secret** - /// parameters. Learn more about how to [complete the verification - /// process](/docs/client/account#updateAccountVerification). - /// - /// Please note that in order to avoid a [Redirect - /// Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), - /// the only valid redirect URLs are the ones from domains you have set when - /// adding your platforms in the console interface. - /// - /// - Future createVerification({@required String url}) { - final String path = '/account/verification'; - - final Map params = { - 'url': url, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Complete Email Verification - /// - /// Use this endpoint to complete the user email verification process. Use both - /// the **userId** and **secret** parameters that were attached to your app URL - /// to verify the user email ownership. If confirmed this route will return a - /// 200 status code. - /// - Future updateVerification({@required String userId, @required String secret}) { - final String path = '/account/verification'; - - final Map params = { - 'userId': userId, - 'secret': secret, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/services/avatars.dart b/app/sdks/0.6.2/client-flutter-dev/lib/services/avatars.dart deleted file mode 100644 index b7fa6393ef..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/services/avatars.dart +++ /dev/null @@ -1,238 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Avatars extends Service { - Avatars(Client client): super(client); - - /// Get Browser Icon - /// - /// You can use this endpoint to show different browser icons to your users. - /// The code argument receives the browser code as it appears in your user - /// /account/sessions endpoint. Use width, height and quality arguments to - /// change the output settings. - /// - String getBrowser({@required String code, int width = 100, int height = 100, int quality = 100}) { - final String path = '/avatars/browsers/{code}'.replaceAll(RegExp('{code}'), code); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Credit Card Icon - /// - /// Need to display your users with your billing method or their payment - /// methods? The credit card endpoint will return you the icon of the credit - /// card provider you need. Use width, height and quality arguments to change - /// the output settings. - /// - String getCreditCard({@required String code, int width = 100, int height = 100, int quality = 100}) { - final String path = '/avatars/credit-cards/{code}'.replaceAll(RegExp('{code}'), code); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Favicon - /// - /// Use this endpoint to fetch the favorite icon (AKA favicon) of a any remote - /// website URL. - /// - String getFavicon({@required String url}) { - final String path = '/avatars/favicon'; - - final Map params = { - 'url': url, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Country Flag - /// - /// You can use this endpoint to show different country flags icons to your - /// users. The code argument receives the 2 letter country code. Use width, - /// height and quality arguments to change the output settings. - /// - String getFlag({@required String code, int width = 100, int height = 100, int quality = 100}) { - final String path = '/avatars/flags/{code}'.replaceAll(RegExp('{code}'), code); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Image from URL - /// - /// Use this endpoint to fetch a remote image URL and crop it to any image size - /// you want. This endpoint is very useful if you need to crop and display - /// remote images in your app or in case you want to make sure a 3rd party - /// image is properly served using a TLS protocol. - /// - String getImage({@required String url, int width = 400, int height = 400}) { - final String path = '/avatars/image'; - - final Map params = { - 'url': url, - 'width': width, - 'height': height, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get User Initials - /// - /// Use this endpoint to show your user initials avatar icon on your website or - /// app. By default, this route will try to print your logged-in user name or - /// email initials. You can also overwrite the user name if you pass the 'name' - /// parameter. If no name is given and no user is logged, an empty avatar will - /// be returned. - /// - /// You can use the color and background params to change the avatar colors. By - /// default, a random theme will be selected. The random theme will persist for - /// the user's initials when reloading the same theme will always return for - /// the same initials. - /// - String getInitials({String name = '', int width = 500, int height = 500, String color = '', String background = ''}) { - final String path = '/avatars/initials'; - - final Map params = { - 'name': name, - 'width': width, - 'height': height, - 'color': color, - 'background': background, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get QR Code - /// - /// Converts a given plain text to a QR code image. You can use the query - /// parameters to change the size and style of the resulting image. - /// - String getQR({@required String text, int size = 400, int margin = 1, bool download = false}) { - final String path = '/avatars/qr'; - - final Map params = { - 'text': text, - 'size': size, - 'margin': margin, - 'download': download, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/services/database.dart b/app/sdks/0.6.2/client-flutter-dev/lib/services/database.dart deleted file mode 100644 index 0fec1fb4d6..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/services/database.dart +++ /dev/null @@ -1,119 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Database extends Service { - Database(Client client): super(client); - - /// List Documents - /// - /// 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 documents. [Learn more about different API - /// modes](/docs/admin). - /// - Future listDocuments({@required String collectionId, List filters = const [], int offset = 0, int limit = 50, String orderField = '\$id', OrderType orderType = OrderType.asc, String orderCast = 'string', String search = ''}) { - final String path = '/database/collections/{collectionId}/documents'.replaceAll(RegExp('{collectionId}'), collectionId); - - final Map params = { - 'filters': filters, - 'offset': offset, - 'limit': limit, - 'orderField': orderField, - 'orderType': orderType.name(), - 'orderCast': orderCast, - 'search': search, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Document - /// - /// Create a new Document. Before using this route, you should create a new - /// collection resource using either a [server - /// integration](/docs/server/database?sdk=nodejs#createCollection) API or - /// directly from your database console. - /// - Future createDocument({@required String collectionId, @required dynamic data, @required List read, @required List write, String parentDocument = '', String parentProperty = '', String parentPropertyType = 'assign'}) { - final String path = '/database/collections/{collectionId}/documents'.replaceAll(RegExp('{collectionId}'), collectionId); - - final Map params = { - 'data': data, - 'read': read, - 'write': write, - 'parentDocument': parentDocument, - 'parentProperty': parentProperty, - 'parentPropertyType': parentPropertyType, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Get Document - /// - /// Get document by its unique ID. This endpoint response returns a JSON object - /// with the document data. - /// - Future getDocument({@required String collectionId, @required String documentId}) { - final String path = '/database/collections/{collectionId}/documents/{documentId}'.replaceAll(RegExp('{collectionId}'), collectionId).replaceAll(RegExp('{documentId}'), documentId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Document - Future updateDocument({@required String collectionId, @required String documentId, @required dynamic data, @required List read, @required List write}) { - final String path = '/database/collections/{collectionId}/documents/{documentId}'.replaceAll(RegExp('{collectionId}'), collectionId).replaceAll(RegExp('{documentId}'), documentId); - - final Map params = { - 'data': data, - 'read': read, - 'write': write, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Delete Document - /// - /// Delete document by its unique ID. This endpoint deletes only the parent - /// documents, his attributes and relations to other documents. Child documents - /// **will not** be deleted. - /// - Future deleteDocument({@required String collectionId, @required String documentId}) { - final String path = '/database/collections/{collectionId}/documents/{documentId}'.replaceAll(RegExp('{collectionId}'), collectionId).replaceAll(RegExp('{documentId}'), documentId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/services/locale.dart b/app/sdks/0.6.2/client-flutter-dev/lib/services/locale.dart deleted file mode 100644 index 095af4792c..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/services/locale.dart +++ /dev/null @@ -1,143 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Locale extends Service { - Locale(Client client): super(client); - - /// Get User Locale - /// - /// Get the current user location based on IP. Returns an object with user - /// country code, country name, continent name, continent code, ip address and - /// suggested currency. You can use the locale header to get the data in a - /// supported language. - /// - /// ([IP Geolocation by DB-IP](https://db-ip.com)) - /// - Future get() { - final String path = '/locale'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Continents - /// - /// List of all continents. You can use the locale header to get the data in a - /// supported language. - /// - Future getContinents() { - final String path = '/locale/continents'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Countries - /// - /// List of all countries. You can use the locale header to get the data in a - /// supported language. - /// - Future getCountries() { - final String path = '/locale/countries'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List EU Countries - /// - /// List of all countries that are currently members of the EU. You can use the - /// locale header to get the data in a supported language. - /// - Future getCountriesEU() { - final String path = '/locale/countries/eu'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Countries Phone Codes - /// - /// List of all countries phone codes. You can use the locale header to get the - /// data in a supported language. - /// - Future getCountriesPhones() { - final String path = '/locale/countries/phones'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Currencies - /// - /// List of all currencies, including currency symbol, name, plural, and - /// decimal digits for all major and minor currencies. You can use the locale - /// header to get the data in a supported language. - /// - Future getCurrencies() { - final String path = '/locale/currencies'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Languages - /// - /// List of all languages classified by ISO 639-1 including 2-letter code, name - /// in English, and name in the respective language. - /// - Future getLanguages() { - final String path = '/locale/languages'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/services/storage.dart b/app/sdks/0.6.2/client-flutter-dev/lib/services/storage.dart deleted file mode 100644 index 51f9345050..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/services/storage.dart +++ /dev/null @@ -1,203 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Storage extends Service { - Storage(Client client): super(client); - - /// List Files - /// - /// Get a list of all the user files. You can use the query params to filter - /// your results. On admin mode, this endpoint will return a list of all of the - /// project files. [Learn more about different API modes](/docs/admin). - /// - Future listFiles({String search = '', int limit = 25, int offset = 0, OrderType orderType = OrderType.asc}) { - final String path = '/storage/files'; - - final Map params = { - 'search': search, - 'limit': limit, - 'offset': offset, - 'orderType': orderType.name(), - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create File - /// - /// Create a new file. The user who creates the file will automatically be - /// assigned to read and write access unless he has passed custom values for - /// read and write arguments. - /// - Future createFile({@required MultipartFile file, @required List read, @required List write}) { - final String path = '/storage/files'; - - final Map params = { - 'file': file, - 'read': read, - 'write': write, - }; - - final Map headers = { - 'content-type': 'multipart/form-data', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Get File - /// - /// Get file by its unique ID. This endpoint response returns a JSON object - /// with the file metadata. - /// - Future getFile({@required String fileId}) { - final String path = '/storage/files/{fileId}'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update File - /// - /// Update file by its unique ID. Only users with write permissions have access - /// to update this resource. - /// - Future updateFile({@required String fileId, @required List read, @required List write}) { - final String path = '/storage/files/{fileId}'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'read': read, - 'write': write, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } - - /// Delete File - /// - /// Delete a file by its unique ID. Only users with write permissions have - /// access to delete this resource. - /// - Future deleteFile({@required String fileId}) { - final String path = '/storage/files/{fileId}'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Get File for Download - /// - /// Get file content by its unique ID. The endpoint response return with a - /// 'Content-Disposition: attachment' header that tells the browser to start - /// downloading the file to user downloads directory. - /// - String getFileDownload({@required String fileId}) { - final String path = '/storage/files/{fileId}/download'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get File Preview - /// - /// Get a file preview image. Currently, this method supports preview for image - /// files (jpg, png, and gif), other supported formats, like pdf, docs, slides, - /// and spreadsheets, will return the file icon image. You can also pass query - /// string arguments for cutting and resizing your preview image. - /// - String getFilePreview({@required String fileId, int width = 0, int height = 0, int quality = 100, String background = '', String output = ''}) { - final String path = '/storage/files/{fileId}/preview'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'background': background, - 'output': output, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get File for View - /// - /// Get file content by its unique ID. This endpoint is similar to the download - /// method but returns with no 'Content-Disposition: attachment' header. - /// - String getFileView({@required String fileId, String as = ''}) { - final String path = '/storage/files/{fileId}/view'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'as': as, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/lib/services/teams.dart b/app/sdks/0.6.2/client-flutter-dev/lib/services/teams.dart deleted file mode 100644 index b9205da455..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/lib/services/teams.dart +++ /dev/null @@ -1,207 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Teams extends Service { - Teams(Client client): super(client); - - /// List Teams - /// - /// Get a list of all the current user teams. You can use the query params to - /// filter your results. On admin mode, this endpoint will return a list of all - /// of the project teams. [Learn more about different API modes](/docs/admin). - /// - Future list({String search = '', int limit = 25, int offset = 0, OrderType orderType = OrderType.asc}) { - final String path = '/teams'; - - final Map params = { - 'search': search, - 'limit': limit, - 'offset': offset, - 'orderType': orderType.name(), - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Team - /// - /// Create a new team. The user who creates the team will automatically be - /// assigned as the owner of the team. The team owner can invite new members, - /// who will be able add new owners and update or delete the team from your - /// project. - /// - Future create({@required String name, List roles = const ["owner"]}) { - final String path = '/teams'; - - final Map params = { - 'name': name, - 'roles': roles, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Get Team - /// - /// Get team by its unique ID. All team members have read access for this - /// resource. - /// - Future get({@required String teamId}) { - final String path = '/teams/{teamId}'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Team - /// - /// Update team by its unique ID. Only team owners have write access for this - /// resource. - /// - Future update({@required String teamId, @required String name}) { - final String path = '/teams/{teamId}'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - 'name': name, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } - - /// Delete Team - /// - /// Delete team by its unique ID. Only team owners have write access for this - /// resource. - /// - Future delete({@required String teamId}) { - final String path = '/teams/{teamId}'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Get Team Memberships - /// - /// Get team members by the team unique ID. All team members have read access - /// for this list of resources. - /// - Future getMemberships({@required String teamId, String search = '', int limit = 25, int offset = 0, OrderType orderType = OrderType.asc}) { - final String path = '/teams/{teamId}/memberships'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - 'search': search, - 'limit': limit, - 'offset': offset, - 'orderType': orderType.name(), - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Team Membership - /// - /// Use this endpoint to invite a new member to join your team. An email with a - /// link to join the team will be sent to the new member email address if the - /// member doesn't exist in the project it will be created automatically. - /// - /// Use the 'URL' parameter to redirect the user from the invitation email back - /// to your app. When the user is redirected, use the [Update Team Membership - /// Status](/docs/client/teams#updateMembershipStatus) endpoint to allow the - /// user to accept the invitation to the team. - /// - /// Please note that in order to avoid a [Redirect - /// Attacks](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md) - /// the only valid redirect URL's are the once from domains you have set when - /// added your platforms in the console interface. - /// - Future createMembership({@required String teamId, @required String email, @required List roles, @required String url, String name = ''}) { - final String path = '/teams/{teamId}/memberships'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - 'email': email, - 'name': name, - 'roles': roles, - 'url': url, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Delete Team Membership - /// - /// This endpoint allows a user to leave a team or for a team owner to delete - /// the membership of any other team member. You can also use this endpoint to - /// delete a user membership even if he didn't accept it. - /// - Future deleteMembership({@required String teamId, @required String inviteId}) { - final String path = '/teams/{teamId}/memberships/{inviteId}'.replaceAll(RegExp('{teamId}'), teamId).replaceAll(RegExp('{inviteId}'), inviteId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Update Team Membership Status - /// - /// Use this endpoint to allow a user to accept an invitation to join a team - /// after he is being redirected back to your app from the invitation email he - /// was sent. - /// - Future updateMembershipStatus({@required String teamId, @required String inviteId, @required String userId, @required String secret}) { - final String path = '/teams/{teamId}/memberships/{inviteId}/status'.replaceAll(RegExp('{teamId}'), teamId).replaceAll(RegExp('{inviteId}'), inviteId); - - final Map params = { - 'userId': userId, - 'secret': secret, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.6.2/client-flutter-dev/pubspec.yaml b/app/sdks/0.6.2/client-flutter-dev/pubspec.yaml deleted file mode 100644 index 2b2da51d3b..0000000000 --- a/app/sdks/0.6.2/client-flutter-dev/pubspec.yaml +++ /dev/null @@ -1,24 +0,0 @@ -name: appwrite_dev -version: 0.3.2 -description: Appwrite is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API -homepage: https://appwrite.io -repository: https://github.com/appwrite/sdk-for-flutter-dev -issue_tracker: https://github.com/appwrite/sdk-generator/issues -documentation: https://appwrite.io/support -environment: - sdk: '>=2.6.0 <3.0.0' -dependencies: - meta: ^1.1.8 - path_provider: ^1.6.14 - package_info: ^0.4.3 - dio: ^3.0.10 - cookie_jar: ^1.0.1 - dio_cookie_manager: ^1.0.0 - flutter_web_auth: ^0.2.4 - universal_html: ^1.2.3 - flutter: - sdk: flutter - -dev_dependencies: - flutter_test: - sdk: flutter \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/CHANGELOG.md b/app/sdks/0.7.0/client-flutter-dev/CHANGELOG.md deleted file mode 100644 index 2e9b0e0a91..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/CHANGELOG.md +++ /dev/null @@ -1,64 +0,0 @@ -## 0.3.2 - -- Fixed package namespaces - -## 0.3.1 - -- Downgraded meta package version to 1.1.8 - -## 0.3.0 - -- Updated package dependencies (@lohanidamodar) -- Added Flutter for Web compatibility (@lohanidamodar) - -## 0.2.3 - -- Fixed OAuth2 cookie bug, where a new session cookie couldn't overwrite an old cookie - -## 0.2.2 - -- Fixed an error that happend when the OAuth session creation request was sent before any other API call -- Fixed a bug in the Avatars service where location URL generation had syntax error - -## 0.2.1 - -- Fixed callback scheme - -## 0.2.0 - -- Updated flutter_web_auth plugin to version 0.2.4 -- Added per project unique callback for OAuth2 redirects to aviod conflicts between multiple Appwrite projects - -## 0.1.1 - -- Updated flutter_web_auth version - -## 0.1.0 - -- Added examples file -- Some minor style fixes - -## 0.0.14 - -- Using MultipartFile for file uploads - -## 0.0.13 - -- Fix for file upload method - -## 0.0.12 - -- Added file upload support for storage service - -## 0.0.11 - -- Added integration with web auth plugin to support Appwrite OAuth API - -## 0.0.9 - -- Updated deafult params - -## 0.0.8 - -- Fixed compilation error in Client class -- Shorter description for package \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/LICENSE b/app/sdks/0.7.0/client-flutter-dev/LICENSE deleted file mode 100644 index fc7c051a91..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/LICENSE +++ /dev/null @@ -1,12 +0,0 @@ -Copyright (c) 2019 Appwrite (https://appwrite.io) and individual contributors. -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - - 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - - 3. Neither the name Appwrite nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/README.md b/app/sdks/0.7.0/client-flutter-dev/README.md deleted file mode 100644 index 9b04096f80..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/README.md +++ /dev/null @@ -1,38 +0,0 @@ -# Appwrite Flutter (Dev Channel) SDK - -[![pub package](https://img.shields.io/pub/v/appwrite.svg)](https://pub.dartlang.org/packages/appwrite) -![License](https://img.shields.io/github/license/appwrite/sdk-for-flutter-dev.svg?v=1) -![Version](https://img.shields.io/badge/api%20version-0.7.0-blue.svg?v=1) - -**This SDK is compatible with Appwrite server version 0.7.0. For older versions, please check previous releases.** - -Appwrite is an open-source backend as a service server that abstract and simplify complex and repetitive development tasks behind a very simple to use REST API. Appwrite aims to help you develop your apps faster and in a more secure way. - Use the Flutter (Dev Channel) SDK to integrate your app with the Appwrite server to easily start interacting with all of Appwrite backend APIs and tools. - For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs) - - - -![Appwrite](https://appwrite.io/images/github.png) - -## Installation - -Add this to your package's `pubspec.yaml` file: - -```yml -dependencies: - appwrite_dev: ^0.3.2 -``` - -You can install packages from the command line: - -```bash -pub get appwrite_dev -``` - -## Contribution - -This library is auto-generated by Appwrite custom [SDK Generator](https://github.com/appwrite/sdk-generator). To learn more about how you can help us improve this SDK, please check the [contribution guide](https://github.com/appwrite/sdk-generator/blob/master/CONTRIBUTING.md) before sending a pull-request. - -## License - -Please see the [BSD-3-Clause license](https://raw.githubusercontent.com/appwrite/appwrite/master/LICENSE) file for more information. \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-o-auth2session.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-o-auth2session.md deleted file mode 100644 index b3cb8831ee..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-o-auth2session.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createOAuth2Session( - provider: 'amazon', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-recovery.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-recovery.md deleted file mode 100644 index 32fe469cff..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-recovery.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createRecovery( - email: 'email@example.com', - url: 'https://example.com', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-session.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-session.md deleted file mode 100644 index a5930877f4..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-session.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createSession( - email: 'email@example.com', - password: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-verification.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-verification.md deleted file mode 100644 index 738f22df42..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create-verification.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.createVerification( - url: 'https://example.com', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create.md deleted file mode 100644 index 1f92976c39..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/create.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.create( - email: 'email@example.com', - password: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-session.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-session.md deleted file mode 100644 index 95b3641387..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-session.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.deleteSession( - sessionId: '[SESSION_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-sessions.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-sessions.md deleted file mode 100644 index 8aaef86816..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete-sessions.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.deleteSessions(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete.md deleted file mode 100644 index e6e29f53aa..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/delete.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.delete(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-logs.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-logs.md deleted file mode 100644 index 92d9e47916..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-logs.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.getLogs(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-prefs.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-prefs.md deleted file mode 100644 index 02874f2251..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-prefs.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.getPrefs(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-sessions.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-sessions.md deleted file mode 100644 index ace4b1b6c1..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get-sessions.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.getSessions(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get.md deleted file mode 100644 index 4651559afb..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/get.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.get(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-email.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-email.md deleted file mode 100644 index 9fc86a7aae..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-email.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateEmail( - email: 'email@example.com', - password: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-name.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-name.md deleted file mode 100644 index e5e218a515..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-name.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateName( - name: '[NAME]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-password.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-password.md deleted file mode 100644 index 869b4d9a30..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-password.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updatePassword( - password: 'password', - oldPassword: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-prefs.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-prefs.md deleted file mode 100644 index 0d50469742..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-prefs.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updatePrefs( - prefs: {}, - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-recovery.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-recovery.md deleted file mode 100644 index e028e60a7d..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-recovery.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateRecovery( - userId: '[USER_ID]', - secret: '[SECRET]', - password: 'password', - passwordAgain: 'password', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-verification.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-verification.md deleted file mode 100644 index 48d669efcc..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/account/update-verification.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Account account = Account(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = account.updateVerification( - userId: '[USER_ID]', - secret: '[SECRET]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-browser.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-browser.md deleted file mode 100644 index dec7863b1f..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-browser.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getBrowser( - code: 'aa', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-credit-card.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-credit-card.md deleted file mode 100644 index e2746c4999..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-credit-card.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getCreditCard( - code: 'amex', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-favicon.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-favicon.md deleted file mode 100644 index 1c56335b9f..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-favicon.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getFavicon( - url: 'https://example.com', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-flag.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-flag.md deleted file mode 100644 index 8a91f608ce..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-flag.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getFlag( - code: 'af', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-image.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-image.md deleted file mode 100644 index a2cbea98e3..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-image.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getImage( - url: 'https://example.com', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-initials.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-initials.md deleted file mode 100644 index 5f9353feae..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-initials.md +++ /dev/null @@ -1,16 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getInitials( - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-q-r.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-q-r.md deleted file mode 100644 index 2737297082..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/avatars/get-q-r.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Avatars avatars = Avatars(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = avatars.getQR( - text: '[TEXT]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/create-document.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/create-document.md deleted file mode 100644 index 6fc27bdfbb..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/create-document.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.createDocument( - collectionId: '[COLLECTION_ID]', - data: {}, - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/delete-document.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/delete-document.md deleted file mode 100644 index 74bcd69d9a..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/delete-document.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.deleteDocument( - collectionId: '[COLLECTION_ID]', - documentId: '[DOCUMENT_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/get-document.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/get-document.md deleted file mode 100644 index 639209ed3c..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/get-document.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.getDocument( - collectionId: '[COLLECTION_ID]', - documentId: '[DOCUMENT_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/list-documents.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/list-documents.md deleted file mode 100644 index 41eac5dd9a..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/list-documents.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.listDocuments( - collectionId: '[COLLECTION_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/update-document.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/update-document.md deleted file mode 100644 index 0b153b1595..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/database/update-document.md +++ /dev/null @@ -1,26 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Database database = Database(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = database.updateDocument( - collectionId: '[COLLECTION_ID]', - documentId: '[DOCUMENT_ID]', - data: {}, - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-continents.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-continents.md deleted file mode 100644 index cae4365382..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-continents.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getContinents(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-e-u.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-e-u.md deleted file mode 100644 index c326461bef..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-e-u.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCountriesEU(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-phones.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-phones.md deleted file mode 100644 index afd3f5d5be..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries-phones.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCountriesPhones(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries.md deleted file mode 100644 index e4fc236949..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-countries.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCountries(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-currencies.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-currencies.md deleted file mode 100644 index d3eb30533e..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-currencies.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getCurrencies(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-languages.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-languages.md deleted file mode 100644 index 32b2a700c0..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get-languages.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.getLanguages(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get.md deleted file mode 100644 index b0cca45924..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/locale/get.md +++ /dev/null @@ -1,20 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Locale locale = Locale(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = locale.get(); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/create-file.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/create-file.md deleted file mode 100644 index d824bd5831..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/create-file.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'dart:io'; -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.createFile( - file: await MultipartFile.fromFile('./path-to-files/image.jpg', 'image.jpg'), - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/delete-file.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/delete-file.md deleted file mode 100644 index 88e7b8815c..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/delete-file.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.deleteFile( - fileId: '[FILE_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-download.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-download.md deleted file mode 100644 index 483340e24a..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-download.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = storage.getFileDownload( - fileId: '[FILE_ID]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-preview.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-preview.md deleted file mode 100644 index dd8d924fe7..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-preview.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = storage.getFilePreview( - fileId: '[FILE_ID]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-view.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-view.md deleted file mode 100644 index 8ed6a946e0..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file-view.md +++ /dev/null @@ -1,17 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - String result = storage.getFileView( - fileId: '[FILE_ID]', - ); - - print(result); // Resource URL string -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file.md deleted file mode 100644 index 4e398f88fd..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/get-file.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.getFile( - fileId: '[FILE_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/list-files.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/list-files.md deleted file mode 100644 index d72ba29e03..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/list-files.md +++ /dev/null @@ -1,21 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.listFiles( - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/update-file.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/update-file.md deleted file mode 100644 index 95e213ddc2..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/storage/update-file.md +++ /dev/null @@ -1,24 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Storage storage = Storage(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = storage.updateFile( - fileId: '[FILE_ID]', - read: [], - write: [], - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create-membership.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create-membership.md deleted file mode 100644 index 31bf7ec1af..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create-membership.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.createMembership( - teamId: '[TEAM_ID]', - email: 'email@example.com', - roles: [], - url: 'https://example.com', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create.md deleted file mode 100644 index e50279de01..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/create.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.create( - name: '[NAME]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete-membership.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete-membership.md deleted file mode 100644 index 015507d3a2..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete-membership.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.deleteMembership( - teamId: '[TEAM_ID]', - inviteId: '[INVITE_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete.md deleted file mode 100644 index 6cc1367f9b..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/delete.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.delete( - teamId: '[TEAM_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get-memberships.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get-memberships.md deleted file mode 100644 index d427c9ac47..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get-memberships.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.getMemberships( - teamId: '[TEAM_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get.md deleted file mode 100644 index 1bca70a23f..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/get.md +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.get( - teamId: '[TEAM_ID]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/list.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/list.md deleted file mode 100644 index c56e7a5dd5..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/list.md +++ /dev/null @@ -1,21 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.list( - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update-membership-status.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update-membership-status.md deleted file mode 100644 index 6098b38ed9..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update-membership-status.md +++ /dev/null @@ -1,25 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.updateMembershipStatus( - teamId: '[TEAM_ID]', - inviteId: '[INVITE_ID]', - userId: '[USER_ID]', - secret: '[SECRET]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update.md b/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update.md deleted file mode 100644 index 2494f408d9..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/docs/examples/teams/update.md +++ /dev/null @@ -1,23 +0,0 @@ -import 'package:appwrite_dev/appwrite_dev.dart'; - -void main() { // Init SDK - Client client = Client(); - Teams teams = Teams(client); - - client - .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint - .setProject('5df5acd0d48c2') // Your project ID - ; - - Future result = teams.update( - teamId: '[TEAM_ID]', - name: '[NAME]', - ); - - result - .then((response) { - print(response); - }).catchError((error) { - print(error.response); - }); -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/example/README.md b/app/sdks/0.7.0/client-flutter-dev/example/README.md deleted file mode 100644 index f6768a5f85..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/example/README.md +++ /dev/null @@ -1,55 +0,0 @@ -# Examples - -Init your Appwrite client: - -```dart - Client client = Client(); - - client - .setEndpoint('https://localhost/v1') // Your Appwrite Endpoint - .setProject('5e8cf4f46b5e8') // Your project ID - .setSelfSigned() // Remove in production - ; - -``` - -Create a new user and session: - -```dart -Account account = Account(client); - -Response user = await account.create(email: 'me@appwrite.io', password: 'password', name: 'My Name'); - -Response session = await account.createSession(email: 'me@appwrite.io', password: 'password'); - -``` - -Fetch user profile: - -```dart -Account account = Account(client); - -Response profile = await account.get(); -``` - -Upload File: - -```dart -Storage storage = Storage(client); - -MultipartFile file = MultipartFile.fromFile('./path-to-file/image.jpg', filename: 'image.jpg'); - -storage.createFile( - file: file, - read: ['*'], - write: [] -) -.then((response) { - print(response); // File uploaded! -}) -.catchError((error) { - print(error.response); -}); -``` - -All examples and API features are available at the [official Appwrite docs](https://appwrite.io/docs) \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/appwrite_dev.dart b/app/sdks/0.7.0/client-flutter-dev/lib/appwrite_dev.dart deleted file mode 100644 index 95d0b72cfe..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/appwrite_dev.dart +++ /dev/null @@ -1,10 +0,0 @@ -export 'package:dio/dio.dart' show Response; - -export 'client.dart'; -export 'enums.dart'; -export 'services/account.dart'; -export 'services/avatars.dart'; -export 'services/database.dart'; -export 'services/locale.dart'; -export 'services/storage.dart'; -export 'services/teams.dart'; diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/client.dart b/app/sdks/0.7.0/client-flutter-dev/lib/client.dart deleted file mode 100644 index b874b7e9e5..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/client.dart +++ /dev/null @@ -1,144 +0,0 @@ -import 'dart:io'; - -import 'package:dio/dio.dart'; -import 'package:flutter/foundation.dart'; -import 'package:dio/adapter.dart'; -import 'package:dio_cookie_manager/dio_cookie_manager.dart'; -import 'package:cookie_jar/cookie_jar.dart'; -import 'package:path_provider/path_provider.dart'; -import 'package:package_info/package_info.dart'; - -import 'enums.dart'; - -class Client { - String endPoint; - String type = 'unknown'; - Map headers; - Map config; - bool selfSigned; - bool initialized = false; - Dio http; - PersistCookieJar cookieJar; - - Client({this.endPoint = 'https://appwrite.io/v1', this.selfSigned = false, Dio http}) : this.http = http ?? Dio() { - // Platform is not supported in web so if web, set type to web automatically and skip Platform check - if(kIsWeb) { - type = 'web'; - }else{ - type = (Platform.isIOS) ? 'ios' : type; - type = (Platform.isMacOS) ? 'macos' : type; - type = (Platform.isAndroid) ? 'android' : type; - type = (Platform.isLinux) ? 'linux' : type; - type = (Platform.isWindows) ? 'windows' : type; - type = (Platform.isFuchsia) ? 'fuchsia' : type; - } - - this.headers = { - 'content-type': 'application/json', - 'x-sdk-version': 'appwrite:flutter:0.3.2', - }; - - this.config = {}; - - assert(endPoint.startsWith(RegExp("http://|https://")), "endPoint $endPoint must start with 'http'"); - } - - Future _getCookiePath() async { - final directory = await getApplicationDocumentsDirectory(); - final path = directory.path; - final Directory dir = new Directory('$path/cookies'); - await dir.create(); - return dir; - } - - /// Your project ID - Client setProject(value) { - config['project'] = value; - addHeader('X-Appwrite-Project', value); - return this; - } - - Client setLocale(value) { - config['locale'] = value; - addHeader('X-Appwrite-Locale', value); - return this; - } - - Client setSelfSigned({bool status = true}) { - selfSigned = status; - return this; - } - - Client setEndpoint(String endPoint) { - this.endPoint = endPoint; - this.http.options.baseUrl = this.endPoint; - return this; - } - - Client addHeader(String key, String value) { - headers[key] = value; - - return this; - } - - Future init() async { - if(!initialized) { - // if web skip cookie implementation and origin header as those are automatically handled by browsers - if(!kIsWeb) { - final Directory cookieDir = await _getCookiePath(); - cookieJar = new PersistCookieJar(dir:cookieDir.path); - this.http.interceptors.add(CookieManager(cookieJar)); - if(Platform.isAndroid || Platform.isIOS) { - PackageInfo packageInfo = await PackageInfo.fromPlatform(); - addHeader('Origin', 'appwrite-' + type + '://' + packageInfo.packageName); - } else if(Platform.isLinux) { - addHeader('Origin', 'appwrite-linux://'); - } else if(Platform.isMacOS) { - addHeader('Origin', 'appwrite-macos://'); - } else if(Platform.isWindows) { - addHeader('Origin', 'appwrite-windows://'); - } else if(Platform.isFuchsia) { - addHeader('Origin', 'appwrite-fuchsia://'); - } - }else{ - // if web set httpClientAdapter as BrowserHttpClientAdapter with withCredentials true to make cookies work - this.http.options.extra['withCredentials'] = true; - } - - this.http.options.baseUrl = this.endPoint; - this.http.options.validateStatus = (status) => status < 400; - } - } - - Future call(HttpMethod method, {String path = '', Map headers = const {}, Map params = const {}}) async { - if(selfSigned && !kIsWeb) { - // Allow self signed requests - (http.httpClientAdapter as DefaultHttpClientAdapter).onHttpClientCreate = (HttpClient client) { - client.badCertificateCallback = (X509Certificate cert, String host, int port) => true; - return client; - }; - } - - await this.init(); - - // Origin is hardcoded for testing - Options options = Options( - headers: {...this.headers, ...headers}, - method: method.name(), - ); - - if(headers['content-type'] == 'multipart/form-data') { - return http.request(path, data: FormData.fromMap(params), options: options); - } - - if (method == HttpMethod.get) { - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - return http.get(path, queryParameters: params, options: options); - } else { - return http.request(path, data: params, options: options); - } - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/enums.dart b/app/sdks/0.7.0/client-flutter-dev/lib/enums.dart deleted file mode 100644 index 2757f6073e..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/enums.dart +++ /dev/null @@ -1,15 +0,0 @@ -enum HttpMethod { get, post, put, delete, patch } - -extension HttpMethodString on HttpMethod { - String name() { - return this.toString().split('.').last.toUpperCase(); - } -} - -enum OrderType { asc, desc } - -extension OrderTypeString on OrderType { - String name() { - return this.toString().split('.').last.toUpperCase(); - } -} diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/service.dart b/app/sdks/0.7.0/client-flutter-dev/lib/service.dart deleted file mode 100644 index 1ae319b705..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/service.dart +++ /dev/null @@ -1,7 +0,0 @@ -import 'client.dart'; - -class Service { - final Client client; - - const Service(this.client); -} diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/services/account.dart b/app/sdks/0.7.0/client-flutter-dev/lib/services/account.dart deleted file mode 100644 index 48a3dc0309..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/services/account.dart +++ /dev/null @@ -1,435 +0,0 @@ - -import 'dart:io'; -import 'package:universal_html/html.dart' as html; - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; -import 'package:flutter/foundation.dart'; -import 'package:flutter_web_auth/flutter_web_auth.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Account extends Service { - Account(Client client): super(client); - - /// Get Account - /// - /// Get currently logged in user data as JSON object. - /// - Future get() { - final String path = '/account'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Account - /// - /// Use this endpoint to allow a new user to register a new account in your - /// project. After the user registration completes successfully, you can use - /// the [/account/verfication](/docs/client/account#createVerification) route - /// to start verifying the user email address. To allow the new user to login - /// to their new account, you need to create a new [account - /// session](/docs/client/account#createSession). - /// - Future create({@required String email, @required String password, String name = ''}) { - final String path = '/account'; - - final Map params = { - 'email': email, - 'password': password, - 'name': name, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Delete Account - /// - /// Delete a currently logged in user account. Behind the scene, the user - /// record is not deleted but permanently blocked from any access. This is done - /// to avoid deleted accounts being overtaken by new users with the same email - /// address. Any user-related resources like documents or storage files should - /// be deleted separately. - /// - Future delete() { - final String path = '/account'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Update Account Email - /// - /// Update currently logged in user account email address. After changing user - /// address, user confirmation status is being reset and a new confirmation - /// mail is sent. For security measures, user password is required to complete - /// this request. - /// - Future updateEmail({@required String email, @required String password}) { - final String path = '/account/email'; - - final Map params = { - 'email': email, - 'password': password, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Get Account Logs - /// - /// Get currently logged in user list of latest security activity logs. Each - /// log returns user IP address, location and date and time of log. - /// - Future getLogs() { - final String path = '/account/logs'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Account Name - /// - /// Update currently logged in user account name. - /// - Future updateName({@required String name}) { - final String path = '/account/name'; - - final Map params = { - 'name': name, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Update Account Password - /// - /// Update currently logged in user password. For validation, user is required - /// to pass the password twice. - /// - Future updatePassword({@required String password, @required String oldPassword}) { - final String path = '/account/password'; - - final Map params = { - 'password': password, - 'oldPassword': oldPassword, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Get Account Preferences - /// - /// Get currently logged in user preferences as a key-value object. - /// - Future getPrefs() { - final String path = '/account/prefs'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Account Preferences - /// - /// Update currently logged in user account preferences. You can pass only the - /// specific settings you wish to update. - /// - Future updatePrefs({@required dynamic prefs}) { - final String path = '/account/prefs'; - - final Map params = { - 'prefs': prefs, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Create Password Recovery - /// - /// Sends the user an email with a temporary secret key for password reset. - /// When the user clicks the confirmation link he is redirected back to your - /// app password reset URL with the secret key and email address values - /// attached to the URL query string. Use the query string params to submit a - /// request to the [PUT /account/recovery](/docs/client/account#updateRecovery) - /// endpoint to complete the process. - /// - Future createRecovery({@required String email, @required String url}) { - final String path = '/account/recovery'; - - final Map params = { - 'email': email, - 'url': url, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Complete Password Recovery - /// - /// Use this endpoint to complete the user account password reset. Both the - /// **userId** and **secret** arguments will be passed as query parameters to - /// the redirect URL you have provided when sending your request to the [POST - /// /account/recovery](/docs/client/account#createRecovery) endpoint. - /// - /// Please note that in order to avoid a [Redirect - /// Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md) - /// the only valid redirect URLs are the ones from domains you have set when - /// adding your platforms in the console interface. - /// - Future updateRecovery({@required String userId, @required String secret, @required String password, @required String passwordAgain}) { - final String path = '/account/recovery'; - - final Map params = { - 'userId': userId, - 'secret': secret, - 'password': password, - 'passwordAgain': passwordAgain, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } - - /// Get Account Sessions - /// - /// Get currently logged in user list of active sessions across different - /// devices. - /// - Future getSessions() { - final String path = '/account/sessions'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Account Session - /// - /// Allow the user to login into their account by providing a valid email and - /// password combination. This route will create a new session for the user. - /// - Future createSession({@required String email, @required String password}) { - final String path = '/account/sessions'; - - final Map params = { - 'email': email, - 'password': password, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Delete All Account Sessions - /// - /// Delete all sessions from the user account and remove any sessions cookies - /// from the end client. - /// - Future deleteSessions() { - final String path = '/account/sessions'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Create Account Session with OAuth2 - /// - /// Allow the user to login to their account using the OAuth2 provider of their - /// choice. Each OAuth2 provider should be enabled from the Appwrite console - /// first. Use the success and failure arguments to provide a redirect URL's - /// back to your app when login is completed. - /// - Future createOAuth2Session({@required String provider, String success = 'https://appwrite.io/auth/oauth2/success', String failure = 'https://appwrite.io/auth/oauth2/failure', List scopes = const []}) { - final String path = '/account/sessions/oauth2/{provider}'.replaceAll(RegExp('{provider}'), provider); - - final Map params = { - 'success': success, - 'failure': failure, - 'scopes': scopes, - 'project': client.config['project'], - }; - - - final List query = []; - - params.forEach((key, value) { - if (value is List) { - for (var item in value) { - query.add(Uri.encodeComponent(key + '[]') + '=' + Uri.encodeComponent(item)); - } - } - else { - query.add(Uri.encodeComponent(key) + '=' + Uri.encodeComponent(value)); - } - }); - - Uri endpoint = Uri.parse(client.endPoint); - Uri url = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - query: query.join('&') - ); - - if(kIsWeb) { - html.window.location.href = url.toString(); - return null; - }else{ - - return FlutterWebAuth.authenticate( - url: url.toString(), - callbackUrlScheme: "appwrite-callback-" + client.config['project'] - ).then((value) async { - Uri url = Uri.parse(value); - Cookie cookie = new Cookie(url.queryParameters['key'], url.queryParameters['secret']); - cookie.domain = Uri.parse(client.endPoint).host; - cookie.httpOnly = true; - cookie.path = '/'; - List cookies = [cookie]; - await client.init(); - client.cookieJar.saveFromResponse(Uri.parse(client.endPoint), cookies); - }); - } - - } - - /// Delete Account Session - /// - /// Use this endpoint to log out the currently logged in user from all their - /// account sessions across all of their different devices. When using the - /// option id argument, only the session unique ID provider will be deleted. - /// - Future deleteSession({@required String sessionId}) { - final String path = '/account/sessions/{sessionId}'.replaceAll(RegExp('{sessionId}'), sessionId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Create Email Verification - /// - /// Use this endpoint to send a verification message to your user email address - /// to confirm they are the valid owners of that address. Both the **userId** - /// and **secret** arguments will be passed as query parameters to the URL you - /// have provided to be attached to the verification email. The provided URL - /// should redirect the user back to your app and allow you to complete the - /// verification process by verifying both the **userId** and **secret** - /// parameters. Learn more about how to [complete the verification - /// process](/docs/client/account#updateVerification). - /// - /// Please note that in order to avoid a [Redirect - /// Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), - /// the only valid redirect URLs are the ones from domains you have set when - /// adding your platforms in the console interface. - /// - /// - Future createVerification({@required String url}) { - final String path = '/account/verification'; - - final Map params = { - 'url': url, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Complete Email Verification - /// - /// Use this endpoint to complete the user email verification process. Use both - /// the **userId** and **secret** parameters that were attached to your app URL - /// to verify the user email ownership. If confirmed this route will return a - /// 200 status code. - /// - Future updateVerification({@required String userId, @required String secret}) { - final String path = '/account/verification'; - - final Map params = { - 'userId': userId, - 'secret': secret, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/services/avatars.dart b/app/sdks/0.7.0/client-flutter-dev/lib/services/avatars.dart deleted file mode 100644 index 89caef576c..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/services/avatars.dart +++ /dev/null @@ -1,239 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Avatars extends Service { - Avatars(Client client): super(client); - - /// Get Browser Icon - /// - /// You can use this endpoint to show different browser icons to your users. - /// The code argument receives the browser code as it appears in your user - /// /account/sessions endpoint. Use width, height and quality arguments to - /// change the output settings. - /// - String getBrowser({@required String code, int width = 100, int height = 100, int quality = 100}) { - final String path = '/avatars/browsers/{code}'.replaceAll(RegExp('{code}'), code); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Credit Card Icon - /// - /// Need to display your users with your billing method or their payment - /// methods? The credit card endpoint will return you the icon of the credit - /// card provider you need. Use width, height and quality arguments to change - /// the output settings. - /// - String getCreditCard({@required String code, int width = 100, int height = 100, int quality = 100}) { - final String path = '/avatars/credit-cards/{code}'.replaceAll(RegExp('{code}'), code); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Favicon - /// - /// Use this endpoint to fetch the favorite icon (AKA favicon) of any remote - /// website URL. - /// - /// - String getFavicon({@required String url}) { - final String path = '/avatars/favicon'; - - final Map params = { - 'url': url, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Country Flag - /// - /// You can use this endpoint to show different country flags icons to your - /// users. The code argument receives the 2 letter country code. Use width, - /// height and quality arguments to change the output settings. - /// - String getFlag({@required String code, int width = 100, int height = 100, int quality = 100}) { - final String path = '/avatars/flags/{code}'.replaceAll(RegExp('{code}'), code); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get Image from URL - /// - /// Use this endpoint to fetch a remote image URL and crop it to any image size - /// you want. This endpoint is very useful if you need to crop and display - /// remote images in your app or in case you want to make sure a 3rd party - /// image is properly served using a TLS protocol. - /// - String getImage({@required String url, int width = 400, int height = 400}) { - final String path = '/avatars/image'; - - final Map params = { - 'url': url, - 'width': width, - 'height': height, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get User Initials - /// - /// Use this endpoint to show your user initials avatar icon on your website or - /// app. By default, this route will try to print your logged-in user name or - /// email initials. You can also overwrite the user name if you pass the 'name' - /// parameter. If no name is given and no user is logged, an empty avatar will - /// be returned. - /// - /// You can use the color and background params to change the avatar colors. By - /// default, a random theme will be selected. The random theme will persist for - /// the user's initials when reloading the same theme will always return for - /// the same initials. - /// - String getInitials({String name = '', int width = 500, int height = 500, String color = '', String background = ''}) { - final String path = '/avatars/initials'; - - final Map params = { - 'name': name, - 'width': width, - 'height': height, - 'color': color, - 'background': background, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get QR Code - /// - /// Converts a given plain text to a QR code image. You can use the query - /// parameters to change the size and style of the resulting image. - /// - String getQR({@required String text, int size = 400, int margin = 1, bool download = false}) { - final String path = '/avatars/qr'; - - final Map params = { - 'text': text, - 'size': size, - 'margin': margin, - 'download': download, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/services/database.dart b/app/sdks/0.7.0/client-flutter-dev/lib/services/database.dart deleted file mode 100644 index c45afe661f..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/services/database.dart +++ /dev/null @@ -1,119 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Database extends Service { - Database(Client client): super(client); - - /// List Documents - /// - /// 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 documents. [Learn more about different API - /// modes](/docs/admin). - /// - Future listDocuments({@required String collectionId, List filters = const [], int limit = 25, int offset = 0, String orderField = '', OrderType orderType = OrderType.asc, String orderCast = 'string', String search = ''}) { - final String path = '/database/collections/{collectionId}/documents'.replaceAll(RegExp('{collectionId}'), collectionId); - - final Map params = { - 'filters': filters, - 'limit': limit, - 'offset': offset, - 'orderField': orderField, - 'orderType': orderType.name(), - 'orderCast': orderCast, - 'search': search, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Document - /// - /// Create a new Document. Before using this route, you should create a new - /// collection resource using either a [server - /// integration](/docs/server/database?sdk=nodejs#createCollection) API or - /// directly from your database console. - /// - Future createDocument({@required String collectionId, @required dynamic data, @required List read, @required List write, String parentDocument = '', String parentProperty = '', String parentPropertyType = 'assign'}) { - final String path = '/database/collections/{collectionId}/documents'.replaceAll(RegExp('{collectionId}'), collectionId); - - final Map params = { - 'data': data, - 'read': read, - 'write': write, - 'parentDocument': parentDocument, - 'parentProperty': parentProperty, - 'parentPropertyType': parentPropertyType, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Get Document - /// - /// Get document by its unique ID. This endpoint response returns a JSON object - /// with the document data. - /// - Future getDocument({@required String collectionId, @required String documentId}) { - final String path = '/database/collections/{collectionId}/documents/{documentId}'.replaceAll(RegExp('{collectionId}'), collectionId).replaceAll(RegExp('{documentId}'), documentId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Document - Future updateDocument({@required String collectionId, @required String documentId, @required dynamic data, @required List read, @required List write}) { - final String path = '/database/collections/{collectionId}/documents/{documentId}'.replaceAll(RegExp('{collectionId}'), collectionId).replaceAll(RegExp('{documentId}'), documentId); - - final Map params = { - 'data': data, - 'read': read, - 'write': write, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } - - /// Delete Document - /// - /// Delete document by its unique ID. This endpoint deletes only the parent - /// documents, its attributes and relations to other documents. Child documents - /// **will not** be deleted. - /// - Future deleteDocument({@required String collectionId, @required String documentId}) { - final String path = '/database/collections/{collectionId}/documents/{documentId}'.replaceAll(RegExp('{collectionId}'), collectionId).replaceAll(RegExp('{documentId}'), documentId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/services/locale.dart b/app/sdks/0.7.0/client-flutter-dev/lib/services/locale.dart deleted file mode 100644 index 095af4792c..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/services/locale.dart +++ /dev/null @@ -1,143 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Locale extends Service { - Locale(Client client): super(client); - - /// Get User Locale - /// - /// Get the current user location based on IP. Returns an object with user - /// country code, country name, continent name, continent code, ip address and - /// suggested currency. You can use the locale header to get the data in a - /// supported language. - /// - /// ([IP Geolocation by DB-IP](https://db-ip.com)) - /// - Future get() { - final String path = '/locale'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Continents - /// - /// List of all continents. You can use the locale header to get the data in a - /// supported language. - /// - Future getContinents() { - final String path = '/locale/continents'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Countries - /// - /// List of all countries. You can use the locale header to get the data in a - /// supported language. - /// - Future getCountries() { - final String path = '/locale/countries'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List EU Countries - /// - /// List of all countries that are currently members of the EU. You can use the - /// locale header to get the data in a supported language. - /// - Future getCountriesEU() { - final String path = '/locale/countries/eu'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Countries Phone Codes - /// - /// List of all countries phone codes. You can use the locale header to get the - /// data in a supported language. - /// - Future getCountriesPhones() { - final String path = '/locale/countries/phones'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Currencies - /// - /// List of all currencies, including currency symbol, name, plural, and - /// decimal digits for all major and minor currencies. You can use the locale - /// header to get the data in a supported language. - /// - Future getCurrencies() { - final String path = '/locale/currencies'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// List Languages - /// - /// List of all languages classified by ISO 639-1 including 2-letter code, name - /// in English, and name in the respective language. - /// - Future getLanguages() { - final String path = '/locale/languages'; - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/services/storage.dart b/app/sdks/0.7.0/client-flutter-dev/lib/services/storage.dart deleted file mode 100644 index 51f9345050..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/services/storage.dart +++ /dev/null @@ -1,203 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Storage extends Service { - Storage(Client client): super(client); - - /// List Files - /// - /// Get a list of all the user files. You can use the query params to filter - /// your results. On admin mode, this endpoint will return a list of all of the - /// project files. [Learn more about different API modes](/docs/admin). - /// - Future listFiles({String search = '', int limit = 25, int offset = 0, OrderType orderType = OrderType.asc}) { - final String path = '/storage/files'; - - final Map params = { - 'search': search, - 'limit': limit, - 'offset': offset, - 'orderType': orderType.name(), - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create File - /// - /// Create a new file. The user who creates the file will automatically be - /// assigned to read and write access unless he has passed custom values for - /// read and write arguments. - /// - Future createFile({@required MultipartFile file, @required List read, @required List write}) { - final String path = '/storage/files'; - - final Map params = { - 'file': file, - 'read': read, - 'write': write, - }; - - final Map headers = { - 'content-type': 'multipart/form-data', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Get File - /// - /// Get file by its unique ID. This endpoint response returns a JSON object - /// with the file metadata. - /// - Future getFile({@required String fileId}) { - final String path = '/storage/files/{fileId}'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update File - /// - /// Update file by its unique ID. Only users with write permissions have access - /// to update this resource. - /// - Future updateFile({@required String fileId, @required List read, @required List write}) { - final String path = '/storage/files/{fileId}'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'read': read, - 'write': write, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } - - /// Delete File - /// - /// Delete a file by its unique ID. Only users with write permissions have - /// access to delete this resource. - /// - Future deleteFile({@required String fileId}) { - final String path = '/storage/files/{fileId}'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Get File for Download - /// - /// Get file content by its unique ID. The endpoint response return with a - /// 'Content-Disposition: attachment' header that tells the browser to start - /// downloading the file to user downloads directory. - /// - String getFileDownload({@required String fileId}) { - final String path = '/storage/files/{fileId}/download'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get File Preview - /// - /// Get a file preview image. Currently, this method supports preview for image - /// files (jpg, png, and gif), other supported formats, like pdf, docs, slides, - /// and spreadsheets, will return the file icon image. You can also pass query - /// string arguments for cutting and resizing your preview image. - /// - String getFilePreview({@required String fileId, int width = 0, int height = 0, int quality = 100, String background = '', String output = ''}) { - final String path = '/storage/files/{fileId}/preview'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'width': width, - 'height': height, - 'quality': quality, - 'background': background, - 'output': output, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } - - /// Get File for View - /// - /// Get file content by its unique ID. This endpoint is similar to the download - /// method but returns with no 'Content-Disposition: attachment' header. - /// - String getFileView({@required String fileId, String as = ''}) { - final String path = '/storage/files/{fileId}/view'.replaceAll(RegExp('{fileId}'), fileId); - - final Map params = { - 'as': as, - 'project': client.config['project'], - }; - - params.keys.forEach((key) {if (params[key] is int || params[key] is double) { - params[key] = params[key].toString(); - }}); - - Uri endpoint = Uri.parse(client.endPoint); - Uri location = new Uri(scheme: endpoint.scheme, - host: endpoint.host, - port: endpoint.port, - path: endpoint.path + path, - queryParameters:params, - ); - - return location.toString(); - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/lib/services/teams.dart b/app/sdks/0.7.0/client-flutter-dev/lib/services/teams.dart deleted file mode 100644 index 050aeaf06d..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/lib/services/teams.dart +++ /dev/null @@ -1,207 +0,0 @@ - - -import 'package:dio/dio.dart'; -import 'package:meta/meta.dart'; - -import "../client.dart"; -import '../enums.dart'; -import "../service.dart"; - -class Teams extends Service { - Teams(Client client): super(client); - - /// List Teams - /// - /// Get a list of all the current user teams. You can use the query params to - /// filter your results. On admin mode, this endpoint will return a list of all - /// of the project teams. [Learn more about different API modes](/docs/admin). - /// - Future list({String search = '', int limit = 25, int offset = 0, OrderType orderType = OrderType.asc}) { - final String path = '/teams'; - - final Map params = { - 'search': search, - 'limit': limit, - 'offset': offset, - 'orderType': orderType.name(), - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Team - /// - /// Create a new team. The user who creates the team will automatically be - /// assigned as the owner of the team. The team owner can invite new members, - /// who will be able add new owners and update or delete the team from your - /// project. - /// - Future create({@required String name, List roles = const ["owner"]}) { - final String path = '/teams'; - - final Map params = { - 'name': name, - 'roles': roles, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Get Team - /// - /// Get team by its unique ID. All team members have read access for this - /// resource. - /// - Future get({@required String teamId}) { - final String path = '/teams/{teamId}'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Update Team - /// - /// Update team by its unique ID. Only team owners have write access for this - /// resource. - /// - Future update({@required String teamId, @required String name}) { - final String path = '/teams/{teamId}'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - 'name': name, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.put, path: path, params: params, headers: headers); - } - - /// Delete Team - /// - /// Delete team by its unique ID. Only team owners have write access for this - /// resource. - /// - Future delete({@required String teamId}) { - final String path = '/teams/{teamId}'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Get Team Memberships - /// - /// Get team members by the team unique ID. All team members have read access - /// for this list of resources. - /// - Future getMemberships({@required String teamId, String search = '', int limit = 25, int offset = 0, OrderType orderType = OrderType.asc}) { - final String path = '/teams/{teamId}/memberships'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - 'search': search, - 'limit': limit, - 'offset': offset, - 'orderType': orderType.name(), - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.get, path: path, params: params, headers: headers); - } - - /// Create Team Membership - /// - /// Use this endpoint to invite a new member to join your team. An email with a - /// link to join the team will be sent to the new member email address if the - /// member doesn't exist in the project it will be created automatically. - /// - /// Use the 'URL' parameter to redirect the user from the invitation email back - /// to your app. When the user is redirected, use the [Update Team Membership - /// Status](/docs/client/teams#updateMembershipStatus) endpoint to allow the - /// user to accept the invitation to the team. - /// - /// Please note that in order to avoid a [Redirect - /// Attacks](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md) - /// the only valid redirect URL's are the once from domains you have set when - /// added your platforms in the console interface. - /// - Future createMembership({@required String teamId, @required String email, @required List roles, @required String url, String name = ''}) { - final String path = '/teams/{teamId}/memberships'.replaceAll(RegExp('{teamId}'), teamId); - - final Map params = { - 'email': email, - 'name': name, - 'roles': roles, - 'url': url, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.post, path: path, params: params, headers: headers); - } - - /// Delete Team Membership - /// - /// This endpoint allows a user to leave a team or for a team owner to delete - /// the membership of any other team member. You can also use this endpoint to - /// delete a user membership even if it is not accepted. - /// - Future deleteMembership({@required String teamId, @required String inviteId}) { - final String path = '/teams/{teamId}/memberships/{inviteId}'.replaceAll(RegExp('{teamId}'), teamId).replaceAll(RegExp('{inviteId}'), inviteId); - - final Map params = { - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.delete, path: path, params: params, headers: headers); - } - - /// Update Team Membership Status - /// - /// Use this endpoint to allow a user to accept an invitation to join a team - /// after being redirected back to your app from the invitation email recieved - /// by the user. - /// - Future updateMembershipStatus({@required String teamId, @required String inviteId, @required String userId, @required String secret}) { - final String path = '/teams/{teamId}/memberships/{inviteId}/status'.replaceAll(RegExp('{teamId}'), teamId).replaceAll(RegExp('{inviteId}'), inviteId); - - final Map params = { - 'userId': userId, - 'secret': secret, - }; - - final Map headers = { - 'content-type': 'application/json', - }; - - return client.call(HttpMethod.patch, path: path, params: params, headers: headers); - } -} \ No newline at end of file diff --git a/app/sdks/0.7.0/client-flutter-dev/pubspec.yaml b/app/sdks/0.7.0/client-flutter-dev/pubspec.yaml deleted file mode 100644 index 2b2da51d3b..0000000000 --- a/app/sdks/0.7.0/client-flutter-dev/pubspec.yaml +++ /dev/null @@ -1,24 +0,0 @@ -name: appwrite_dev -version: 0.3.2 -description: Appwrite is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API -homepage: https://appwrite.io -repository: https://github.com/appwrite/sdk-for-flutter-dev -issue_tracker: https://github.com/appwrite/sdk-generator/issues -documentation: https://appwrite.io/support -environment: - sdk: '>=2.6.0 <3.0.0' -dependencies: - meta: ^1.1.8 - path_provider: ^1.6.14 - package_info: ^0.4.3 - dio: ^3.0.10 - cookie_jar: ^1.0.1 - dio_cookie_manager: ^1.0.0 - flutter_web_auth: ^0.2.4 - universal_html: ^1.2.3 - flutter: - sdk: flutter - -dev_dependencies: - flutter_test: - sdk: flutter \ No newline at end of file