diff --git a/app/config/platforms.php b/app/config/platforms.php index caff21b28b..e2867c166a 100644 --- a/app/config/platforms.php +++ b/app/config/platforms.php @@ -357,12 +357,12 @@ return [ [ 'key' => 'dotnet', 'name' => '.NET', - 'version' => '2.0.0', + 'version' => '0.4.0', 'url' => 'https://github.com/appwrite/sdk-for-dotnet', 'package' => 'https://www.nuget.org/packages/Appwrite', - 'enabled' => false, + 'enabled' => true, 'beta' => true, - 'dev' => true, + 'dev' => false, 'hidden' => false, 'family' => APP_PLATFORM_SERVER, 'prism' => 'csharp', diff --git a/composer.json b/composer.json index 78f960d3d1..0ba26540bd 100644 --- a/composer.json +++ b/composer.json @@ -79,7 +79,7 @@ } ], "require-dev": { - "appwrite/sdk-generator": "0.32.*", + "appwrite/sdk-generator": "0.33.*", "ext-fileinfo": "*", "phpunit/phpunit": "9.5.20", "squizlabs/php_codesniffer": "^3.6", diff --git a/composer.lock b/composer.lock index 978d14f490..2bb32246f0 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "169ab6e7dd540e45309d3c5093506fad", + "content-hash": "3eadbfe5543aafdf8682ea0465159e3c", "packages": [ { "name": "adhocore/jwt", @@ -3034,16 +3034,16 @@ "packages-dev": [ { "name": "appwrite/sdk-generator", - "version": "0.32.3", + "version": "0.33.1", "source": { "type": "git", "url": "https://github.com/appwrite/sdk-generator.git", - "reference": "4057e14a61335070034b1cbdce9e39bef94d997d" + "reference": "551cdae31a68b19874f10ca321b1d08cfa06a13f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/4057e14a61335070034b1cbdce9e39bef94d997d", - "reference": "4057e14a61335070034b1cbdce9e39bef94d997d", + "url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/551cdae31a68b19874f10ca321b1d08cfa06a13f", + "reference": "551cdae31a68b19874f10ca321b1d08cfa06a13f", "shasum": "" }, "require": { @@ -3079,9 +3079,9 @@ "description": "Appwrite PHP library for generating API SDKs for multiple programming languages and platforms", "support": { "issues": "https://github.com/appwrite/sdk-generator/issues", - "source": "https://github.com/appwrite/sdk-generator/tree/0.32.3" + "source": "https://github.com/appwrite/sdk-generator/tree/0.33.1" }, - "time": "2023-04-27T19:22:05+00:00" + "time": "2023-05-16T04:37:34+00:00" }, { "name": "doctrine/deprecations", diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/create-phone-verification.md b/docs/examples/1.3.x/server-dotnet/examples/account/create-phone-verification.md new file mode 100644 index 0000000000..32e8ea1728 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/create-phone-verification.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Token result = await account.CreatePhoneVerification(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/create-recovery.md b/docs/examples/1.3.x/server-dotnet/examples/account/create-recovery.md new file mode 100644 index 0000000000..20cdd7e827 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/create-recovery.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Token result = await account.CreateRecovery( + email: "email@example.com", + url: "https://example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/create-verification.md b/docs/examples/1.3.x/server-dotnet/examples/account/create-verification.md new file mode 100644 index 0000000000..4a103ef85b --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/create-verification.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Token result = await account.CreateVerification( + url: "https://example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/delete-session.md b/docs/examples/1.3.x/server-dotnet/examples/account/delete-session.md new file mode 100644 index 0000000000..fe61cefa7f --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/delete-session.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +await account.DeleteSession( + sessionId: "[SESSION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/delete-sessions.md b/docs/examples/1.3.x/server-dotnet/examples/account/delete-sessions.md new file mode 100644 index 0000000000..8c37060ef8 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/delete-sessions.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +await account.DeleteSessions(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/get-prefs.md b/docs/examples/1.3.x/server-dotnet/examples/account/get-prefs.md new file mode 100644 index 0000000000..6d7d9ea2b5 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/get-prefs.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Preferences result = await account.GetPrefs(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/get-session.md b/docs/examples/1.3.x/server-dotnet/examples/account/get-session.md new file mode 100644 index 0000000000..4d2e716eeb --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/get-session.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Session result = await account.GetSession( + sessionId: "[SESSION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/get.md b/docs/examples/1.3.x/server-dotnet/examples/account/get.md new file mode 100644 index 0000000000..9853c6af1a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/get.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.Get(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/list-logs.md b/docs/examples/1.3.x/server-dotnet/examples/account/list-logs.md new file mode 100644 index 0000000000..9f4712ea06 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/list-logs.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +LogList result = await account.ListLogs(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/list-sessions.md b/docs/examples/1.3.x/server-dotnet/examples/account/list-sessions.md new file mode 100644 index 0000000000..232319e5f9 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/list-sessions.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +SessionList result = await account.ListSessions(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-email.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-email.md new file mode 100644 index 0000000000..1208095f87 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-email.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.UpdateEmail( + email: "email@example.com", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-name.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-name.md new file mode 100644 index 0000000000..f8dfbf5b11 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-name.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.UpdateName( + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-password.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-password.md new file mode 100644 index 0000000000..1a0e586b1f --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-password.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.UpdatePassword( + password: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-phone-verification.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-phone-verification.md new file mode 100644 index 0000000000..fafcea78ea --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-phone-verification.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Token result = await account.UpdatePhoneVerification( + userId: "[USER_ID]", + secret: "[SECRET]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-phone.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-phone.md new file mode 100644 index 0000000000..ccea754594 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-phone.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.UpdatePhone( + phone: "+12065550100", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-prefs.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-prefs.md new file mode 100644 index 0000000000..040815b675 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-prefs.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.UpdatePrefs( + prefs: [object]); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-recovery.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-recovery.md new file mode 100644 index 0000000000..07f09f758c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-recovery.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Token result = await account.UpdateRecovery( + userId: "[USER_ID]", + secret: "[SECRET]", + password: "password", + passwordAgain: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-session.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-session.md new file mode 100644 index 0000000000..7c2443a250 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-session.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Session result = await account.UpdateSession( + sessionId: "[SESSION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-status.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-status.md new file mode 100644 index 0000000000..0233b5d84d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-status.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +User result = await account.UpdateStatus(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/account/update-verification.md b/docs/examples/1.3.x/server-dotnet/examples/account/update-verification.md new file mode 100644 index 0000000000..23c3a99829 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/account/update-verification.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var account = new Account(client); + +Token result = await account.UpdateVerification( + userId: "[USER_ID]", + secret: "[SECRET]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-browser.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-browser.md new file mode 100644 index 0000000000..4150d3a5c0 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-browser.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetBrowser( + code: "aa"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-credit-card.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-credit-card.md new file mode 100644 index 0000000000..47cd89c89c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-credit-card.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetCreditCard( + code: "amex"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-favicon.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-favicon.md new file mode 100644 index 0000000000..0711dd3815 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-favicon.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetFavicon( + url: "https://example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-flag.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-flag.md new file mode 100644 index 0000000000..9c19d1a39d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-flag.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetFlag( + code: "af"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-image.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-image.md new file mode 100644 index 0000000000..a5888ad934 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-image.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetImage( + url: "https://example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-initials.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-initials.md new file mode 100644 index 0000000000..c037de2c63 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-initials.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetInitials(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/avatars/get-q-r.md b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-q-r.md new file mode 100644 index 0000000000..ff2634d43e --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/avatars/get-q-r.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var avatars = new Avatars(client); + +byte[] result = await avatars.GetQR( + text: "[TEXT]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-boolean-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-boolean-attribute.md new file mode 100644 index 0000000000..b29a7fa2be --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-boolean-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeBoolean result = await databases.CreateBooleanAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-collection.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-collection.md new file mode 100644 index 0000000000..fa0bf3bf95 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-collection.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Collection result = await databases.CreateCollection( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-datetime-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-datetime-attribute.md new file mode 100644 index 0000000000..c44cc40b05 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-datetime-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeDatetime result = await databases.CreateDatetimeAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-document.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-document.md new file mode 100644 index 0000000000..01532a3f77 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-document.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Document result = await databases.CreateDocument( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + documentId: "[DOCUMENT_ID]", + data: [object]); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-email-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-email-attribute.md new file mode 100644 index 0000000000..7724160754 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-email-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeEmail result = await databases.CreateEmailAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-enum-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-enum-attribute.md new file mode 100644 index 0000000000..239d09d311 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-enum-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeEnum result = await databases.CreateEnumAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + elements: new List {}, + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-float-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-float-attribute.md new file mode 100644 index 0000000000..382d4ade07 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-float-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeFloat result = await databases.CreateFloatAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-index.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-index.md new file mode 100644 index 0000000000..7cf5f507cb --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-index.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Index result = await databases.CreateIndex( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + type: "key", + attributes: new List {}); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-integer-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-integer-attribute.md new file mode 100644 index 0000000000..d3b95a77bf --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-integer-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeInteger result = await databases.CreateIntegerAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-ip-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-ip-attribute.md new file mode 100644 index 0000000000..4fd8de1816 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-ip-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeIp result = await databases.CreateIpAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-relationship-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-relationship-attribute.md new file mode 100644 index 0000000000..036211af22 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-relationship-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeRelationship result = await databases.CreateRelationshipAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + relatedCollectionId: "[RELATED_COLLECTION_ID]", + type: "oneToOne"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-string-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-string-attribute.md new file mode 100644 index 0000000000..af1f9e47f6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-string-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeString result = await databases.CreateStringAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + size: 1, + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create-url-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create-url-attribute.md new file mode 100644 index 0000000000..d0d43e93f1 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create-url-attribute.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeUrl result = await databases.CreateUrlAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/create.md b/docs/examples/1.3.x/server-dotnet/examples/databases/create.md new file mode 100644 index 0000000000..c1e62ca1d3 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/create.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Database result = await databases.Create( + databaseId: "[DATABASE_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/delete-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-attribute.md new file mode 100644 index 0000000000..b79abd9427 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-attribute.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +await databases.DeleteAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/delete-collection.md b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-collection.md new file mode 100644 index 0000000000..1530e3354f --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-collection.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +await databases.DeleteCollection( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/delete-document.md b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-document.md new file mode 100644 index 0000000000..d20281ed96 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-document.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +await databases.DeleteDocument( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + documentId: "[DOCUMENT_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/delete-index.md b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-index.md new file mode 100644 index 0000000000..3045ba945a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/delete-index.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +await databases.DeleteIndex( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/delete.md b/docs/examples/1.3.x/server-dotnet/examples/databases/delete.md new file mode 100644 index 0000000000..c367cc4248 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/delete.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +await databases.Delete( + databaseId: "[DATABASE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/get-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/get-attribute.md new file mode 100644 index 0000000000..16671ec673 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/get-attribute.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + + result = await databases.GetAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/get-collection.md b/docs/examples/1.3.x/server-dotnet/examples/databases/get-collection.md new file mode 100644 index 0000000000..2b9702c273 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/get-collection.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Collection result = await databases.GetCollection( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/get-document.md b/docs/examples/1.3.x/server-dotnet/examples/databases/get-document.md new file mode 100644 index 0000000000..7ceccde211 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/get-document.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Document result = await databases.GetDocument( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + documentId: "[DOCUMENT_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/get-index.md b/docs/examples/1.3.x/server-dotnet/examples/databases/get-index.md new file mode 100644 index 0000000000..ed04b741e8 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/get-index.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Index result = await databases.GetIndex( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/get.md b/docs/examples/1.3.x/server-dotnet/examples/databases/get.md new file mode 100644 index 0000000000..975b00c3a3 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/get.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Database result = await databases.Get( + databaseId: "[DATABASE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/list-attributes.md b/docs/examples/1.3.x/server-dotnet/examples/databases/list-attributes.md new file mode 100644 index 0000000000..15c1c7548b --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/list-attributes.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeList result = await databases.ListAttributes( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/list-collections.md b/docs/examples/1.3.x/server-dotnet/examples/databases/list-collections.md new file mode 100644 index 0000000000..1e2e545402 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/list-collections.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +CollectionList result = await databases.ListCollections( + databaseId: "[DATABASE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/list-documents.md b/docs/examples/1.3.x/server-dotnet/examples/databases/list-documents.md new file mode 100644 index 0000000000..0445238af2 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/list-documents.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +DocumentList result = await databases.ListDocuments( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/list-indexes.md b/docs/examples/1.3.x/server-dotnet/examples/databases/list-indexes.md new file mode 100644 index 0000000000..0505d19a1e --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/list-indexes.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +IndexList result = await databases.ListIndexes( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/list.md b/docs/examples/1.3.x/server-dotnet/examples/databases/list.md new file mode 100644 index 0000000000..baee085021 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/list.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +DatabaseList result = await databases.List(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-boolean-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-boolean-attribute.md new file mode 100644 index 0000000000..8e185d7357 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-boolean-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeBoolean result = await databases.UpdateBooleanAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + default: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-collection.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-collection.md new file mode 100644 index 0000000000..5744767340 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-collection.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Collection result = await databases.UpdateCollection( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-datetime-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-datetime-attribute.md new file mode 100644 index 0000000000..6d02e2baa7 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-datetime-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeDatetime result = await databases.UpdateDatetimeAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + default: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-document.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-document.md new file mode 100644 index 0000000000..48fee0d98d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-document.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Document result = await databases.UpdateDocument( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + documentId: "[DOCUMENT_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-email-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-email-attribute.md new file mode 100644 index 0000000000..066476029c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-email-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeEmail result = await databases.UpdateEmailAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + default: "email@example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-enum-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-enum-attribute.md new file mode 100644 index 0000000000..65362c0ca3 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-enum-attribute.md @@ -0,0 +1,17 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeEnum result = await databases.UpdateEnumAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + elements: new List {}, + required: false, + default: "[DEFAULT]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-float-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-float-attribute.md new file mode 100644 index 0000000000..2950bd0de1 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-float-attribute.md @@ -0,0 +1,18 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeFloat result = await databases.UpdateFloatAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + min: 0, + max: 0, + default: 0); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-integer-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-integer-attribute.md new file mode 100644 index 0000000000..880d1cc19a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-integer-attribute.md @@ -0,0 +1,18 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeInteger result = await databases.UpdateIntegerAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + min: 0, + max: 0, + default: 0); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-ip-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-ip-attribute.md new file mode 100644 index 0000000000..70fd77392f --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-ip-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeIp result = await databases.UpdateIpAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + default: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-relationship-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-relationship-attribute.md new file mode 100644 index 0000000000..e4917ef28c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-relationship-attribute.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeRelationship result = await databases.UpdateRelationshipAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-string-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-string-attribute.md new file mode 100644 index 0000000000..4744bf59df --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-string-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeString result = await databases.UpdateStringAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + default: "[DEFAULT]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update-url-attribute.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update-url-attribute.md new file mode 100644 index 0000000000..cb04a5dafe --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update-url-attribute.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +AttributeUrl result = await databases.UpdateUrlAttribute( + databaseId: "[DATABASE_ID]", + collectionId: "[COLLECTION_ID]", + key: "", + required: false, + default: "https://example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/databases/update.md b/docs/examples/1.3.x/server-dotnet/examples/databases/update.md new file mode 100644 index 0000000000..db07b7a146 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/databases/update.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var databases = new Databases(client); + +Database result = await databases.Update( + databaseId: "[DATABASE_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/create-build.md b/docs/examples/1.3.x/server-dotnet/examples/functions/create-build.md new file mode 100644 index 0000000000..6d62298b04 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/create-build.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + + result = await functions.CreateBuild( + functionId: "[FUNCTION_ID]", + deploymentId: "[DEPLOYMENT_ID]", + buildId: "[BUILD_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/create-deployment.md b/docs/examples/1.3.x/server-dotnet/examples/functions/create-deployment.md new file mode 100644 index 0000000000..98248508b6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/create-deployment.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Deployment result = await functions.CreateDeployment( + functionId: "[FUNCTION_ID]", + entrypoint: "[ENTRYPOINT]", + code: new File("./path-to-files/image.jpg"), + activate: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/create-execution.md b/docs/examples/1.3.x/server-dotnet/examples/functions/create-execution.md new file mode 100644 index 0000000000..9c015f8eb1 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/create-execution.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Execution result = await functions.CreateExecution( + functionId: "[FUNCTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/create-variable.md b/docs/examples/1.3.x/server-dotnet/examples/functions/create-variable.md new file mode 100644 index 0000000000..e5df30deb5 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/create-variable.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Variable result = await functions.CreateVariable( + functionId: "[FUNCTION_ID]", + key: "[KEY]", + value: "[VALUE]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/create.md b/docs/examples/1.3.x/server-dotnet/examples/functions/create.md new file mode 100644 index 0000000000..3f189b08e2 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/create.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Function result = await functions.Create( + functionId: "[FUNCTION_ID]", + name: "[NAME]", + runtime: "node-14.5"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/delete-deployment.md b/docs/examples/1.3.x/server-dotnet/examples/functions/delete-deployment.md new file mode 100644 index 0000000000..f52515b5e1 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/delete-deployment.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +await functions.DeleteDeployment( + functionId: "[FUNCTION_ID]", + deploymentId: "[DEPLOYMENT_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/delete-variable.md b/docs/examples/1.3.x/server-dotnet/examples/functions/delete-variable.md new file mode 100644 index 0000000000..d9fb356fc6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/delete-variable.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +await functions.DeleteVariable( + functionId: "[FUNCTION_ID]", + variableId: "[VARIABLE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/delete.md b/docs/examples/1.3.x/server-dotnet/examples/functions/delete.md new file mode 100644 index 0000000000..265ebc361f --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/delete.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +await functions.Delete( + functionId: "[FUNCTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/get-deployment.md b/docs/examples/1.3.x/server-dotnet/examples/functions/get-deployment.md new file mode 100644 index 0000000000..65d8431634 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/get-deployment.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Deployment result = await functions.GetDeployment( + functionId: "[FUNCTION_ID]", + deploymentId: "[DEPLOYMENT_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/get-execution.md b/docs/examples/1.3.x/server-dotnet/examples/functions/get-execution.md new file mode 100644 index 0000000000..f46f9d5dcd --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/get-execution.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Execution result = await functions.GetExecution( + functionId: "[FUNCTION_ID]", + executionId: "[EXECUTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/get-variable.md b/docs/examples/1.3.x/server-dotnet/examples/functions/get-variable.md new file mode 100644 index 0000000000..a90ff4f32e --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/get-variable.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Variable result = await functions.GetVariable( + functionId: "[FUNCTION_ID]", + variableId: "[VARIABLE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/get.md b/docs/examples/1.3.x/server-dotnet/examples/functions/get.md new file mode 100644 index 0000000000..0cbec8a8e5 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/get.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Function result = await functions.Get( + functionId: "[FUNCTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/list-deployments.md b/docs/examples/1.3.x/server-dotnet/examples/functions/list-deployments.md new file mode 100644 index 0000000000..d277204991 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/list-deployments.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +DeploymentList result = await functions.ListDeployments( + functionId: "[FUNCTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/list-executions.md b/docs/examples/1.3.x/server-dotnet/examples/functions/list-executions.md new file mode 100644 index 0000000000..0797af5b09 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/list-executions.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +ExecutionList result = await functions.ListExecutions( + functionId: "[FUNCTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/list-runtimes.md b/docs/examples/1.3.x/server-dotnet/examples/functions/list-runtimes.md new file mode 100644 index 0000000000..9f2edf4370 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/list-runtimes.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +RuntimeList result = await functions.ListRuntimes(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/list-variables.md b/docs/examples/1.3.x/server-dotnet/examples/functions/list-variables.md new file mode 100644 index 0000000000..f1336f651c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/list-variables.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +VariableList result = await functions.ListVariables( + functionId: "[FUNCTION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/list.md b/docs/examples/1.3.x/server-dotnet/examples/functions/list.md new file mode 100644 index 0000000000..ba78467628 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/list.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +FunctionList result = await functions.List(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/update-deployment.md b/docs/examples/1.3.x/server-dotnet/examples/functions/update-deployment.md new file mode 100644 index 0000000000..1c8498fec0 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/update-deployment.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Function result = await functions.UpdateDeployment( + functionId: "[FUNCTION_ID]", + deploymentId: "[DEPLOYMENT_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/update-variable.md b/docs/examples/1.3.x/server-dotnet/examples/functions/update-variable.md new file mode 100644 index 0000000000..ad60d979b1 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/update-variable.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Variable result = await functions.UpdateVariable( + functionId: "[FUNCTION_ID]", + variableId: "[VARIABLE_ID]", + key: "[KEY]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/functions/update.md b/docs/examples/1.3.x/server-dotnet/examples/functions/update.md new file mode 100644 index 0000000000..02bfc73c0d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/functions/update.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var functions = new Functions(client); + +Function result = await functions.Update( + functionId: "[FUNCTION_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/graphql/mutation.md b/docs/examples/1.3.x/server-dotnet/examples/graphql/mutation.md new file mode 100644 index 0000000000..ba79658dd6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/graphql/mutation.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var graphql = new Graphql(client); + +Any result = await graphql.Mutation( + query: [object]); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/graphql/query.md b/docs/examples/1.3.x/server-dotnet/examples/graphql/query.md new file mode 100644 index 0000000000..e271058e92 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/graphql/query.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var graphql = new Graphql(client); + +Any result = await graphql.Query( + query: [object]); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-antivirus.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-antivirus.md new file mode 100644 index 0000000000..f133c3d707 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-antivirus.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthAntivirus result = await health.GetAntivirus(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-cache.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-cache.md new file mode 100644 index 0000000000..4c3b8273ce --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-cache.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthStatus result = await health.GetCache(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-d-b.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-d-b.md new file mode 100644 index 0000000000..d49218f60d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-d-b.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthStatus result = await health.GetDB(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-certificates.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-certificates.md new file mode 100644 index 0000000000..4e4c042a12 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-certificates.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthQueue result = await health.GetQueueCertificates(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-functions.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-functions.md new file mode 100644 index 0000000000..1f120616d3 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-functions.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthQueue result = await health.GetQueueFunctions(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-logs.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-logs.md new file mode 100644 index 0000000000..68d6dac6a0 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-logs.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthQueue result = await health.GetQueueLogs(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-webhooks.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-webhooks.md new file mode 100644 index 0000000000..12fb20da1c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-queue-webhooks.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthQueue result = await health.GetQueueWebhooks(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-storage-local.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-storage-local.md new file mode 100644 index 0000000000..3412c03e9d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-storage-local.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthStatus result = await health.GetStorageLocal(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get-time.md b/docs/examples/1.3.x/server-dotnet/examples/health/get-time.md new file mode 100644 index 0000000000..d50d15b7ff --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get-time.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthTime result = await health.GetTime(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/health/get.md b/docs/examples/1.3.x/server-dotnet/examples/health/get.md new file mode 100644 index 0000000000..dac4a1260a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/health/get.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var health = new Health(client); + +HealthStatus result = await health.Get(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/get.md b/docs/examples/1.3.x/server-dotnet/examples/locale/get.md new file mode 100644 index 0000000000..da5866a83c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/get.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +Locale result = await locale.Get(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/list-continents.md b/docs/examples/1.3.x/server-dotnet/examples/locale/list-continents.md new file mode 100644 index 0000000000..94f5dceeee --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/list-continents.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +ContinentList result = await locale.ListContinents(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries-e-u.md b/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries-e-u.md new file mode 100644 index 0000000000..49bee6cf61 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries-e-u.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +CountryList result = await locale.ListCountriesEU(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries-phones.md b/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries-phones.md new file mode 100644 index 0000000000..1a2b57879e --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries-phones.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +PhoneList result = await locale.ListCountriesPhones(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries.md b/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries.md new file mode 100644 index 0000000000..4036ba3dd7 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/list-countries.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +CountryList result = await locale.ListCountries(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/list-currencies.md b/docs/examples/1.3.x/server-dotnet/examples/locale/list-currencies.md new file mode 100644 index 0000000000..338a7b48ba --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/list-currencies.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +CurrencyList result = await locale.ListCurrencies(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/locale/list-languages.md b/docs/examples/1.3.x/server-dotnet/examples/locale/list-languages.md new file mode 100644 index 0000000000..ce75f8c681 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/locale/list-languages.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var locale = new Locale(client); + +LanguageList result = await locale.ListLanguages(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/create-bucket.md b/docs/examples/1.3.x/server-dotnet/examples/storage/create-bucket.md new file mode 100644 index 0000000000..ce3857f3f0 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/create-bucket.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +Bucket result = await storage.CreateBucket( + bucketId: "[BUCKET_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/create-file.md b/docs/examples/1.3.x/server-dotnet/examples/storage/create-file.md new file mode 100644 index 0000000000..e177656fb5 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/create-file.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +File result = await storage.CreateFile( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]", + file: new File("./path-to-files/image.jpg")); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/delete-bucket.md b/docs/examples/1.3.x/server-dotnet/examples/storage/delete-bucket.md new file mode 100644 index 0000000000..bf2c393405 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/delete-bucket.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +await storage.DeleteBucket( + bucketId: "[BUCKET_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/delete-file.md b/docs/examples/1.3.x/server-dotnet/examples/storage/delete-file.md new file mode 100644 index 0000000000..c66b58179d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/delete-file.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +await storage.DeleteFile( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/get-bucket.md b/docs/examples/1.3.x/server-dotnet/examples/storage/get-bucket.md new file mode 100644 index 0000000000..37d6c21beb --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/get-bucket.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +Bucket result = await storage.GetBucket( + bucketId: "[BUCKET_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-download.md b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-download.md new file mode 100644 index 0000000000..690734731d --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-download.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +byte[] result = await storage.GetFileDownload( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-preview.md b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-preview.md new file mode 100644 index 0000000000..8d63fc88a8 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-preview.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +byte[] result = await storage.GetFilePreview( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-view.md b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-view.md new file mode 100644 index 0000000000..bdeb1b943c --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file-view.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +byte[] result = await storage.GetFileView( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/get-file.md b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file.md new file mode 100644 index 0000000000..9b0c29ef3e --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/get-file.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +File result = await storage.GetFile( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/list-buckets.md b/docs/examples/1.3.x/server-dotnet/examples/storage/list-buckets.md new file mode 100644 index 0000000000..869571ac7a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/list-buckets.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +BucketList result = await storage.ListBuckets(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/list-files.md b/docs/examples/1.3.x/server-dotnet/examples/storage/list-files.md new file mode 100644 index 0000000000..70108256a1 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/list-files.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +FileList result = await storage.ListFiles( + bucketId: "[BUCKET_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/update-bucket.md b/docs/examples/1.3.x/server-dotnet/examples/storage/update-bucket.md new file mode 100644 index 0000000000..f05ca9c360 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/update-bucket.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +Bucket result = await storage.UpdateBucket( + bucketId: "[BUCKET_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/storage/update-file.md b/docs/examples/1.3.x/server-dotnet/examples/storage/update-file.md new file mode 100644 index 0000000000..d2246ade1e --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/storage/update-file.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var storage = new Storage(client); + +File result = await storage.UpdateFile( + bucketId: "[BUCKET_ID]", + fileId: "[FILE_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/create-membership.md b/docs/examples/1.3.x/server-dotnet/examples/teams/create-membership.md new file mode 100644 index 0000000000..75abdfa7ef --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/create-membership.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +Membership result = await teams.CreateMembership( + teamId: "[TEAM_ID]", + roles: new List {}, + url: "https://example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/create.md b/docs/examples/1.3.x/server-dotnet/examples/teams/create.md new file mode 100644 index 0000000000..bac3d727eb --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/create.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +Team result = await teams.Create( + teamId: "[TEAM_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/delete-membership.md b/docs/examples/1.3.x/server-dotnet/examples/teams/delete-membership.md new file mode 100644 index 0000000000..60cb7ea216 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/delete-membership.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +await teams.DeleteMembership( + teamId: "[TEAM_ID]", + membershipId: "[MEMBERSHIP_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/delete.md b/docs/examples/1.3.x/server-dotnet/examples/teams/delete.md new file mode 100644 index 0000000000..2b72528cb0 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/delete.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +await teams.Delete( + teamId: "[TEAM_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/get-membership.md b/docs/examples/1.3.x/server-dotnet/examples/teams/get-membership.md new file mode 100644 index 0000000000..7873a24564 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/get-membership.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +Membership result = await teams.GetMembership( + teamId: "[TEAM_ID]", + membershipId: "[MEMBERSHIP_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/get-prefs.md b/docs/examples/1.3.x/server-dotnet/examples/teams/get-prefs.md new file mode 100644 index 0000000000..487461cb52 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/get-prefs.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var teams = new Teams(client); + +Preferences result = await teams.GetPrefs( + teamId: "[TEAM_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/get.md b/docs/examples/1.3.x/server-dotnet/examples/teams/get.md new file mode 100644 index 0000000000..32bebafbfc --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/get.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +Team result = await teams.Get( + teamId: "[TEAM_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/list-memberships.md b/docs/examples/1.3.x/server-dotnet/examples/teams/list-memberships.md new file mode 100644 index 0000000000..3ea7cb5acf --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/list-memberships.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +MembershipList result = await teams.ListMemberships( + teamId: "[TEAM_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/list.md b/docs/examples/1.3.x/server-dotnet/examples/teams/list.md new file mode 100644 index 0000000000..db4cd34fbe --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/list.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +TeamList result = await teams.List(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/update-membership-roles.md b/docs/examples/1.3.x/server-dotnet/examples/teams/update-membership-roles.md new file mode 100644 index 0000000000..1c2fada650 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/update-membership-roles.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +Membership result = await teams.UpdateMembershipRoles( + teamId: "[TEAM_ID]", + membershipId: "[MEMBERSHIP_ID]", + roles: new List {}); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/update-membership-status.md b/docs/examples/1.3.x/server-dotnet/examples/teams/update-membership-status.md new file mode 100644 index 0000000000..eaff766ac2 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/update-membership-status.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var teams = new Teams(client); + +Membership result = await teams.UpdateMembershipStatus( + teamId: "[TEAM_ID]", + membershipId: "[MEMBERSHIP_ID]", + userId: "[USER_ID]", + secret: "[SECRET]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/update-name.md b/docs/examples/1.3.x/server-dotnet/examples/teams/update-name.md new file mode 100644 index 0000000000..ca72222fc4 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/update-name.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var teams = new Teams(client); + +Team result = await teams.UpdateName( + teamId: "[TEAM_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/teams/update-prefs.md b/docs/examples/1.3.x/server-dotnet/examples/teams/update-prefs.md new file mode 100644 index 0000000000..7a51248a98 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/teams/update-prefs.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetJWT("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ..."); // Your secret JSON Web Token + +var teams = new Teams(client); + +Preferences result = await teams.UpdatePrefs( + teamId: "[TEAM_ID]", + prefs: [object]); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-argon2user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-argon2user.md new file mode 100644 index 0000000000..5bd89a2686 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-argon2user.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreateArgon2User( + userId: "[USER_ID]", + email: "email@example.com", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-bcrypt-user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-bcrypt-user.md new file mode 100644 index 0000000000..aef0d9eab9 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-bcrypt-user.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreateBcryptUser( + userId: "[USER_ID]", + email: "email@example.com", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-m-d5user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-m-d5user.md new file mode 100644 index 0000000000..e537124143 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-m-d5user.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreateMD5User( + userId: "[USER_ID]", + email: "email@example.com", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-p-h-pass-user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-p-h-pass-user.md new file mode 100644 index 0000000000..f7a0d244e8 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-p-h-pass-user.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreatePHPassUser( + userId: "[USER_ID]", + email: "email@example.com", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-s-h-a-user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-s-h-a-user.md new file mode 100644 index 0000000000..c504ec7916 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-s-h-a-user.md @@ -0,0 +1,14 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreateSHAUser( + userId: "[USER_ID]", + email: "email@example.com", + password: "password"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-scrypt-modified-user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-scrypt-modified-user.md new file mode 100644 index 0000000000..af04bbccfc --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-scrypt-modified-user.md @@ -0,0 +1,17 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreateScryptModifiedUser( + userId: "[USER_ID]", + email: "email@example.com", + password: "password", + passwordSalt: "[PASSWORD_SALT]", + passwordSaltSeparator: "[PASSWORD_SALT_SEPARATOR]", + passwordSignerKey: "[PASSWORD_SIGNER_KEY]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create-scrypt-user.md b/docs/examples/1.3.x/server-dotnet/examples/users/create-scrypt-user.md new file mode 100644 index 0000000000..3a95de571a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create-scrypt-user.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.CreateScryptUser( + userId: "[USER_ID]", + email: "email@example.com", + password: "password", + passwordSalt: "[PASSWORD_SALT]", + passwordCpu: 0, + passwordMemory: 0, + passwordParallel: 0, + passwordLength: 0); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/create.md b/docs/examples/1.3.x/server-dotnet/examples/users/create.md new file mode 100644 index 0000000000..2ed0671b34 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/create.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.Create( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/delete-session.md b/docs/examples/1.3.x/server-dotnet/examples/users/delete-session.md new file mode 100644 index 0000000000..d656c670f2 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/delete-session.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +await users.DeleteSession( + userId: "[USER_ID]", + sessionId: "[SESSION_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/delete-sessions.md b/docs/examples/1.3.x/server-dotnet/examples/users/delete-sessions.md new file mode 100644 index 0000000000..ca15eb9d79 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/delete-sessions.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +await users.DeleteSessions( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/delete.md b/docs/examples/1.3.x/server-dotnet/examples/users/delete.md new file mode 100644 index 0000000000..e3552fd2b6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/delete.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +await users.Delete( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/get-prefs.md b/docs/examples/1.3.x/server-dotnet/examples/users/get-prefs.md new file mode 100644 index 0000000000..695601b9b6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/get-prefs.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +Preferences result = await users.GetPrefs( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/get.md b/docs/examples/1.3.x/server-dotnet/examples/users/get.md new file mode 100644 index 0000000000..90411a6dde --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/get.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.Get( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/list-logs.md b/docs/examples/1.3.x/server-dotnet/examples/users/list-logs.md new file mode 100644 index 0000000000..c42a767d75 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/list-logs.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +LogList result = await users.ListLogs( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/list-memberships.md b/docs/examples/1.3.x/server-dotnet/examples/users/list-memberships.md new file mode 100644 index 0000000000..0a76062ace --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/list-memberships.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +MembershipList result = await users.ListMemberships( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/list-sessions.md b/docs/examples/1.3.x/server-dotnet/examples/users/list-sessions.md new file mode 100644 index 0000000000..43fcb7a189 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/list-sessions.md @@ -0,0 +1,12 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +SessionList result = await users.ListSessions( + userId: "[USER_ID]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/list.md b/docs/examples/1.3.x/server-dotnet/examples/users/list.md new file mode 100644 index 0000000000..7bba5b7ecb --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/list.md @@ -0,0 +1,11 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +UserList result = await users.List(); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-email-verification.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-email-verification.md new file mode 100644 index 0000000000..14d7a410b6 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-email-verification.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdateEmailVerification( + userId: "[USER_ID]", + emailVerification: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-email.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-email.md new file mode 100644 index 0000000000..dd2e1e3d39 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-email.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdateEmail( + userId: "[USER_ID]", + email: "email@example.com"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-name.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-name.md new file mode 100644 index 0000000000..01e3654c59 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-name.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdateName( + userId: "[USER_ID]", + name: "[NAME]"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-password.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-password.md new file mode 100644 index 0000000000..b8ad2c5906 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-password.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdatePassword( + userId: "[USER_ID]", + password: ""); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-phone-verification.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-phone-verification.md new file mode 100644 index 0000000000..afddc551ae --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-phone-verification.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdatePhoneVerification( + userId: "[USER_ID]", + phoneVerification: false); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-phone.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-phone.md new file mode 100644 index 0000000000..f556b734b4 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-phone.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdatePhone( + userId: "[USER_ID]", + number: "+12065550100"); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-prefs.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-prefs.md new file mode 100644 index 0000000000..8d3f10e17a --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-prefs.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +Preferences result = await users.UpdatePrefs( + userId: "[USER_ID]", + prefs: [object]); \ No newline at end of file diff --git a/docs/examples/1.3.x/server-dotnet/examples/users/update-status.md b/docs/examples/1.3.x/server-dotnet/examples/users/update-status.md new file mode 100644 index 0000000000..c2d1336223 --- /dev/null +++ b/docs/examples/1.3.x/server-dotnet/examples/users/update-status.md @@ -0,0 +1,13 @@ +using Appwrite; +using Appwrite.Models; + +var client = new Client() + .SetEndPoint("https://cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("5df5acd0d48c2") // Your project ID + .SetKey("919c2d18fb5d4...a2ae413da83346ad2"); // Your secret API key + +var users = new Users(client); + +User result = await users.UpdateStatus( + userId: "[USER_ID]", + status: false); \ No newline at end of file diff --git a/docs/sdks/dotnet/GETTING_STARTED.md b/docs/sdks/dotnet/GETTING_STARTED.md index 23bab6f70a..bb6c67eebe 100644 --- a/docs/sdks/dotnet/GETTING_STARTED.md +++ b/docs/sdks/dotnet/GETTING_STARTED.md @@ -1,44 +1,42 @@ ## Getting Started ### Initialize & Make API Request -Once you add the dependencies, its extremely easy to get started with the SDK; All you need to do is import the package in your code, set your Appwrite credentials, and start making API calls. Below is a simple example: +Once you have installed the package, it is extremely easy to get started with the SDK; all you need to do is import the package in your code, set your Appwrite credentials, and start making API calls. Below is a simple example: ```csharp using Appwrite; -static async Task Main(string[] args) -{ - var client = Client(); +var client = new Client() + .SetEndpoint("http://cloud.appwrite.io/v1") // Make sure your endpoint is accessible + .SetProject("5ff3379a01d25") // Your project ID + .SetKey("cd868db89") // Your secret API key + .SetSelfSigned(); // Use only on dev mode with a self-signed SSL cert - client - .setEndpoint('http://[HOSTNAME_OR_IP]/v1') // Make sure your endpoint is accessible - .setProject('5ff3379a01d25') // Your project ID - .setKey('cd868c7af8bdc893b4...93b7535db89') - .setSelfSigned() // Use only on dev mode with a self-signed SSL cert - ; +var users = new Users(client); - var users = Users(client); +var user = await users.Create( + userId: ID.Unique(), + email: "email@example.com", + password: "password", + name: "name"); - try { - var user = await users.Create(ID.Unique(), 'email@example.com', 'password', 'name'); - Console.WriteLine(user.ToMap()); - } catch (AppwriteException e) { - Console.WriteLine(e.Message); - } -} +Console.WriteLine(user.ToMap()); ``` ### Error Handling -The Appwrite .NET SDK raises `AppwriteException` object with `message`, `code` and `response` properties. You can handle any errors by catching `AppwriteException` and present the `message` to the user or handle it yourself based on the provided error information. Below is an example. +The Appwrite .NET SDK raises an `AppwriteException` object with `message`, `code` and `response` properties. You can handle any errors by catching `AppwriteException` and present the `message` to the user or handle it yourself based on the provided error information. Below is an example. ```csharp -var users = Users(client); +var users = new Users(client); try { - var user = await users.Create(ID.Unique(), 'email@example.com', 'password', 'name'); - Console.WriteLine(user.ToMap()); + var user = await users.Create( + userId: ID.Unique(), + email: "email@example.com", + password: "password", + name: "name"); } catch (AppwriteException e) { - Console.WriteLine(e.Message); + Console.WriteLine(e.Message); } ```