diff --git a/docs/examples/1.8.x/client-android/java/tables/create-row.md b/docs/examples/1.8.x/client-android/java/tables/create-row.md new file mode 100644 index 0000000000..8102b82c75 --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/create-row.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // + .setJWT(""); // Your secret JSON Web Token + +Tables tables = new Tables(client); + +tables.createRow( + "", // databaseId + "", // tableId + "", // rowId + mapOf( "a" to "b" ), // data + listOf("read("any")"), // permissions (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/java/tables/create-rows.md b/docs/examples/1.8.x/client-android/java/tables/create-rows.md new file mode 100644 index 0000000000..26f5d67789 --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/create-rows.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey(""); // + +Tables tables = new Tables(client); + +tables.createRows( + "", // databaseId + "", // tableId + listOf(), // rows + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/java/tables/delete-row.md b/docs/examples/1.8.x/client-android/java/tables/delete-row.md new file mode 100644 index 0000000000..596a8b7aca --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/delete-row.md @@ -0,0 +1,24 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject(""); // Your project ID + +Tables tables = new Tables(client); + +tables.deleteRow( + "", // databaseId + "", // tableId + "", // rowId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/java/tables/get-row.md b/docs/examples/1.8.x/client-android/java/tables/get-row.md new file mode 100644 index 0000000000..882a195376 --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/get-row.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject(""); // Your project ID + +Tables tables = new Tables(client); + +tables.getRow( + "", // databaseId + "", // tableId + "", // rowId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/java/tables/list-rows.md b/docs/examples/1.8.x/client-android/java/tables/list-rows.md new file mode 100644 index 0000000000..4d37570246 --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/list-rows.md @@ -0,0 +1,24 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject(""); // Your project ID + +Tables tables = new Tables(client); + +tables.listRows( + "", // databaseId + "", // tableId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/java/tables/update-row.md b/docs/examples/1.8.x/client-android/java/tables/update-row.md new file mode 100644 index 0000000000..0421c9cffb --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/update-row.md @@ -0,0 +1,26 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject(""); // Your project ID + +Tables tables = new Tables(client); + +tables.updateRow( + "", // databaseId + "", // tableId + "", // rowId + mapOf( "a" to "b" ), // data (optional) + listOf("read("any")"), // permissions (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/java/tables/upsert-row.md b/docs/examples/1.8.x/client-android/java/tables/upsert-row.md new file mode 100644 index 0000000000..a8be0cfc6c --- /dev/null +++ b/docs/examples/1.8.x/client-android/java/tables/upsert-row.md @@ -0,0 +1,26 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // + .setJWT(""); // Your secret JSON Web Token + +Tables tables = new Tables(client); + +tables.upsertRow( + "", // databaseId + "", // tableId + "", // rowId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + Log.d("Appwrite", result.toString()); + }) +); + diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/create-row.md b/docs/examples/1.8.x/client-android/kotlin/tables/create-row.md new file mode 100644 index 0000000000..8c581bf1d5 --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/create-row.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // + .setJWT("") // Your secret JSON Web Token + +val tables = Tables(client) + +val result = tables.createRow( + databaseId = "", + tableId = "", + rowId = "", + data = mapOf( "a" to "b" ), + permissions = listOf("read("any")"), // (optional) +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/create-rows.md b/docs/examples/1.8.x/client-android/kotlin/tables/create-rows.md new file mode 100644 index 0000000000..1fde9c50cf --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/create-rows.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey("") // + +val tables = Tables(client) + +val result = tables.createRows( + databaseId = "", + tableId = "", + rows = listOf(), +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/delete-row.md b/docs/examples/1.8.x/client-android/kotlin/tables/delete-row.md new file mode 100644 index 0000000000..ffa3229f30 --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/delete-row.md @@ -0,0 +1,15 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +val tables = Tables(client) + +val result = tables.deleteRow( + databaseId = "", + tableId = "", + rowId = "", +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/get-row.md b/docs/examples/1.8.x/client-android/kotlin/tables/get-row.md new file mode 100644 index 0000000000..15dabff397 --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/get-row.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +val tables = Tables(client) + +val result = tables.getRow( + databaseId = "", + tableId = "", + rowId = "", + queries = listOf(), // (optional) +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/list-rows.md b/docs/examples/1.8.x/client-android/kotlin/tables/list-rows.md new file mode 100644 index 0000000000..ff36543938 --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/list-rows.md @@ -0,0 +1,15 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +val tables = Tables(client) + +val result = tables.listRows( + databaseId = "", + tableId = "", + queries = listOf(), // (optional) +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/update-row.md b/docs/examples/1.8.x/client-android/kotlin/tables/update-row.md new file mode 100644 index 0000000000..e9b515cef4 --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/update-row.md @@ -0,0 +1,17 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +val tables = Tables(client) + +val result = tables.updateRow( + databaseId = "", + tableId = "", + rowId = "", + data = mapOf( "a" to "b" ), // (optional) + permissions = listOf("read("any")"), // (optional) +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-android/kotlin/tables/upsert-row.md b/docs/examples/1.8.x/client-android/kotlin/tables/upsert-row.md new file mode 100644 index 0000000000..6b7cb6666b --- /dev/null +++ b/docs/examples/1.8.x/client-android/kotlin/tables/upsert-row.md @@ -0,0 +1,17 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client(context) + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // + .setJWT("") // Your secret JSON Web Token + +val tables = Tables(client) + +val result = tables.upsertRow( + databaseId = "", + tableId = "", + rowId = "", +) \ No newline at end of file diff --git a/docs/examples/1.8.x/client-apple/examples/tables/create-row.md b/docs/examples/1.8.x/client-apple/examples/tables/create-row.md new file mode 100644 index 0000000000..533cf2d555 --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/create-row.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // + .setJWT("") // Your secret JSON Web Token + +let tables = Tables(client) + +let row = try await tables.createRow( + databaseId: "", + tableId: "", + rowId: "", + data: [:], + permissions: ["read("any")"] // optional +) + diff --git a/docs/examples/1.8.x/client-apple/examples/tables/create-rows.md b/docs/examples/1.8.x/client-apple/examples/tables/create-rows.md new file mode 100644 index 0000000000..effd748aa0 --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/create-rows.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey("") // + +let tables = Tables(client) + +let rowList = try await tables.createRows( + databaseId: "", + tableId: "", + rows: [] +) + diff --git a/docs/examples/1.8.x/client-apple/examples/tables/delete-row.md b/docs/examples/1.8.x/client-apple/examples/tables/delete-row.md new file mode 100644 index 0000000000..7d12ec4f4c --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/delete-row.md @@ -0,0 +1,14 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +let tables = Tables(client) + +let result = try await tables.deleteRow( + databaseId: "", + tableId: "", + rowId: "" +) + diff --git a/docs/examples/1.8.x/client-apple/examples/tables/get-row.md b/docs/examples/1.8.x/client-apple/examples/tables/get-row.md new file mode 100644 index 0000000000..93fbef9e7c --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/get-row.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +let tables = Tables(client) + +let row = try await tables.getRow( + databaseId: "", + tableId: "", + rowId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/client-apple/examples/tables/list-rows.md b/docs/examples/1.8.x/client-apple/examples/tables/list-rows.md new file mode 100644 index 0000000000..31545cce4d --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/list-rows.md @@ -0,0 +1,14 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +let tables = Tables(client) + +let rowList = try await tables.listRows( + databaseId: "", + tableId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/client-apple/examples/tables/update-row.md b/docs/examples/1.8.x/client-apple/examples/tables/update-row.md new file mode 100644 index 0000000000..601c4f0a77 --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/update-row.md @@ -0,0 +1,16 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + +let tables = Tables(client) + +let row = try await tables.updateRow( + databaseId: "", + tableId: "", + rowId: "", + data: [:], // optional + permissions: ["read("any")"] // optional +) + diff --git a/docs/examples/1.8.x/client-apple/examples/tables/upsert-row.md b/docs/examples/1.8.x/client-apple/examples/tables/upsert-row.md new file mode 100644 index 0000000000..eabcb181c3 --- /dev/null +++ b/docs/examples/1.8.x/client-apple/examples/tables/upsert-row.md @@ -0,0 +1,16 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // + .setJWT("") // Your secret JSON Web Token + +let tables = Tables(client) + +let row = try await tables.upsertRow( + databaseId: "", + tableId: "", + rowId: "" +) + diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/create-row.md b/docs/examples/1.8.x/client-flutter/examples/tables/create-row.md new file mode 100644 index 0000000000..ac9923d813 --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/create-row.md @@ -0,0 +1,17 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // + .setJWT(''); // Your secret JSON Web Token + +Tables tables = Tables(client); + +Row result = await tables.createRow( + databaseId: '', + tableId: '', + rowId: '', + data: {}, + permissions: ["read("any")"], // optional +); diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/create-rows.md b/docs/examples/1.8.x/client-flutter/examples/tables/create-rows.md new file mode 100644 index 0000000000..38c4c7503d --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/create-rows.md @@ -0,0 +1,14 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // + +Tables tables = Tables(client); + +RowList result = await tables.createRows( + databaseId: '', + tableId: '', + rows: [], +); diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/delete-row.md b/docs/examples/1.8.x/client-flutter/examples/tables/delete-row.md new file mode 100644 index 0000000000..4187c4766d --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/delete-row.md @@ -0,0 +1,13 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +Tables tables = Tables(client); + +await tables.deleteRow( + databaseId: '', + tableId: '', + rowId: '', +); diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/get-row.md b/docs/examples/1.8.x/client-flutter/examples/tables/get-row.md new file mode 100644 index 0000000000..8d8c52caa6 --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/get-row.md @@ -0,0 +1,14 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +Tables tables = Tables(client); + +Row result = await tables.getRow( + databaseId: '', + tableId: '', + rowId: '', + queries: [], // optional +); diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/list-rows.md b/docs/examples/1.8.x/client-flutter/examples/tables/list-rows.md new file mode 100644 index 0000000000..f770bbbd92 --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/list-rows.md @@ -0,0 +1,13 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +Tables tables = Tables(client); + +RowList result = await tables.listRows( + databaseId: '', + tableId: '', + queries: [], // optional +); diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/update-row.md b/docs/examples/1.8.x/client-flutter/examples/tables/update-row.md new file mode 100644 index 0000000000..f43ba5e689 --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/update-row.md @@ -0,0 +1,15 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +Tables tables = Tables(client); + +Row result = await tables.updateRow( + databaseId: '', + tableId: '', + rowId: '', + data: {}, // optional + permissions: ["read("any")"], // optional +); diff --git a/docs/examples/1.8.x/client-flutter/examples/tables/upsert-row.md b/docs/examples/1.8.x/client-flutter/examples/tables/upsert-row.md new file mode 100644 index 0000000000..26a872b692 --- /dev/null +++ b/docs/examples/1.8.x/client-flutter/examples/tables/upsert-row.md @@ -0,0 +1,15 @@ +import 'package:appwrite/appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // + .setJWT(''); // Your secret JSON Web Token + +Tables tables = Tables(client); + +Row result = await tables.upsertRow( + databaseId: '', + tableId: '', + rowId: '', +); diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/create-row.md b/docs/examples/1.8.x/client-graphql/examples/tables/create-row.md new file mode 100644 index 0000000000..c88a7f36cf --- /dev/null +++ b/docs/examples/1.8.x/client-graphql/examples/tables/create-row.md @@ -0,0 +1,18 @@ +mutation { + tablesCreateRow( + databaseId: "", + tableId: "", + rowId: "", + data: "{}", + permissions: ["read("any")"] + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/create-rows.md b/docs/examples/1.8.x/client-graphql/examples/tables/create-rows.md new file mode 100644 index 0000000000..a4ae62cfae --- /dev/null +++ b/docs/examples/1.8.x/client-graphql/examples/tables/create-rows.md @@ -0,0 +1,19 @@ +mutation { + tablesCreateRows( + databaseId: "", + tableId: "", + rows: [] + ) { + total + rows { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } + } +} diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/delete-row.md b/docs/examples/1.8.x/client-graphql/examples/tables/delete-row.md new file mode 100644 index 0000000000..f3a35c1df1 --- /dev/null +++ b/docs/examples/1.8.x/client-graphql/examples/tables/delete-row.md @@ -0,0 +1,9 @@ +mutation { + tablesDeleteRow( + databaseId: "", + tableId: "", + rowId: "" + ) { + status + } +} diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/get-row.md b/docs/examples/1.8.x/client-graphql/examples/tables/get-row.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/list-rows.md b/docs/examples/1.8.x/client-graphql/examples/tables/list-rows.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/update-row.md b/docs/examples/1.8.x/client-graphql/examples/tables/update-row.md new file mode 100644 index 0000000000..8449d8499b --- /dev/null +++ b/docs/examples/1.8.x/client-graphql/examples/tables/update-row.md @@ -0,0 +1,18 @@ +mutation { + tablesUpdateRow( + databaseId: "", + tableId: "", + rowId: "", + data: "{}", + permissions: ["read("any")"] + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/client-graphql/examples/tables/upsert-row.md b/docs/examples/1.8.x/client-graphql/examples/tables/upsert-row.md new file mode 100644 index 0000000000..480d7651bd --- /dev/null +++ b/docs/examples/1.8.x/client-graphql/examples/tables/upsert-row.md @@ -0,0 +1,16 @@ +mutation { + tablesUpsertRow( + databaseId: "", + tableId: "", + rowId: "" + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/create-row.md b/docs/examples/1.8.x/client-react-native/examples/tables/create-row.md new file mode 100644 index 0000000000..75de1c2a39 --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/create-row.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const result = await tables.createRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data + ["read("any")"] // permissions (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/create-rows.md b/docs/examples/1.8.x/client-react-native/examples/tables/create-rows.md new file mode 100644 index 0000000000..165aa4cb71 --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/create-rows.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // + +const tables = new Tables(client); + +const result = await tables.createRows( + '', // databaseId + '', // tableId + [] // rows +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/delete-row.md b/docs/examples/1.8.x/client-react-native/examples/tables/delete-row.md new file mode 100644 index 0000000000..9746f85ea0 --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/delete-row.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.deleteRow( + '', // databaseId + '', // tableId + '' // rowId +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/get-row.md b/docs/examples/1.8.x/client-react-native/examples/tables/get-row.md new file mode 100644 index 0000000000..b9434e3957 --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/get-row.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getRow( + '', // databaseId + '', // tableId + '', // rowId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/list-rows.md b/docs/examples/1.8.x/client-react-native/examples/tables/list-rows.md new file mode 100644 index 0000000000..75f81a1435 --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/list-rows.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/update-row.md b/docs/examples/1.8.x/client-react-native/examples/tables/update-row.md new file mode 100644 index 0000000000..7bb36dd254 --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/update-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data (optional) + ["read("any")"] // permissions (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-react-native/examples/tables/upsert-row.md b/docs/examples/1.8.x/client-react-native/examples/tables/upsert-row.md new file mode 100644 index 0000000000..f176425abb --- /dev/null +++ b/docs/examples/1.8.x/client-react-native/examples/tables/upsert-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "react-native-appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const result = await tables.upsertRow( + '', // databaseId + '', // tableId + '' // rowId +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-rest/examples/tables/create-row.md b/docs/examples/1.8.x/client-rest/examples/tables/create-row.md new file mode 100644 index 0000000000..c4166b8b80 --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/create-row.md @@ -0,0 +1,13 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: + +{ + "rowId": "", + "data": {}, + "permissions": ["read(\"any\")"] +} diff --git a/docs/examples/1.8.x/client-rest/examples/tables/create-rows.md b/docs/examples/1.8.x/client-rest/examples/tables/create-rows.md new file mode 100644 index 0000000000..0935afd11e --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/create-rows.md @@ -0,0 +1,11 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: + +{ + "rows": [] +} diff --git a/docs/examples/1.8.x/client-rest/examples/tables/delete-row.md b/docs/examples/1.8.x/client-rest/examples/tables/delete-row.md new file mode 100644 index 0000000000..954303d17a --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/delete-row.md @@ -0,0 +1,8 @@ +DELETE /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: + diff --git a/docs/examples/1.8.x/client-rest/examples/tables/get-row.md b/docs/examples/1.8.x/client-rest/examples/tables/get-row.md new file mode 100644 index 0000000000..fc09601df7 --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/get-row.md @@ -0,0 +1,6 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: diff --git a/docs/examples/1.8.x/client-rest/examples/tables/list-rows.md b/docs/examples/1.8.x/client-rest/examples/tables/list-rows.md new file mode 100644 index 0000000000..de214e7cea --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/list-rows.md @@ -0,0 +1,6 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: diff --git a/docs/examples/1.8.x/client-rest/examples/tables/update-row.md b/docs/examples/1.8.x/client-rest/examples/tables/update-row.md new file mode 100644 index 0000000000..f09f639e60 --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/update-row.md @@ -0,0 +1,12 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: + +{ + "data": {}, + "permissions": ["read(\"any\")"] +} diff --git a/docs/examples/1.8.x/client-rest/examples/tables/upsert-row.md b/docs/examples/1.8.x/client-rest/examples/tables/upsert-row.md new file mode 100644 index 0000000000..60528077ef --- /dev/null +++ b/docs/examples/1.8.x/client-rest/examples/tables/upsert-row.md @@ -0,0 +1,8 @@ +PUT /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-JWT: + diff --git a/docs/examples/1.8.x/client-web/examples/tables/create-row.md b/docs/examples/1.8.x/client-web/examples/tables/create-row.md new file mode 100644 index 0000000000..f7b54d1894 --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/create-row.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const result = await tables.createRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data + ["read("any")"] // permissions (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-web/examples/tables/create-rows.md b/docs/examples/1.8.x/client-web/examples/tables/create-rows.md new file mode 100644 index 0000000000..79d7d3f311 --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/create-rows.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // + +const tables = new Tables(client); + +const result = await tables.createRows( + '', // databaseId + '', // tableId + [] // rows +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-web/examples/tables/delete-row.md b/docs/examples/1.8.x/client-web/examples/tables/delete-row.md new file mode 100644 index 0000000000..5c6c4b96d9 --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/delete-row.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.deleteRow( + '', // databaseId + '', // tableId + '' // rowId +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-web/examples/tables/get-row.md b/docs/examples/1.8.x/client-web/examples/tables/get-row.md new file mode 100644 index 0000000000..708b3d96cc --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/get-row.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getRow( + '', // databaseId + '', // tableId + '', // rowId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-web/examples/tables/list-rows.md b/docs/examples/1.8.x/client-web/examples/tables/list-rows.md new file mode 100644 index 0000000000..f82d358f0d --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/list-rows.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-web/examples/tables/update-row.md b/docs/examples/1.8.x/client-web/examples/tables/update-row.md new file mode 100644 index 0000000000..0e0c5a012e --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/update-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data (optional) + ["read("any")"] // permissions (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/client-web/examples/tables/upsert-row.md b/docs/examples/1.8.x/client-web/examples/tables/upsert-row.md new file mode 100644 index 0000000000..f111fefd71 --- /dev/null +++ b/docs/examples/1.8.x/client-web/examples/tables/upsert-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "appwrite"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const result = await tables.upsertRow( + '', // databaseId + '', // tableId + '' // rowId +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..88e6bf8853 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-boolean-column.md @@ -0,0 +1,7 @@ +appwrite tables createBooleanColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..de28b7537c --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-datetime-column.md @@ -0,0 +1,7 @@ +appwrite tables createDatetimeColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-email-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-email-column.md new file mode 100644 index 0000000000..23b672e62d --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-email-column.md @@ -0,0 +1,7 @@ +appwrite tables createEmailColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-enum-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..4cd3e1d241 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-enum-column.md @@ -0,0 +1,8 @@ +appwrite tables createEnumColumn \ + --databaseId \ + --tableId \ + --key '' \ + --elements one two three \ + --required false \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-float-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-float-column.md new file mode 100644 index 0000000000..9c69e29e91 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-float-column.md @@ -0,0 +1,9 @@ +appwrite tables createFloatColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-index.md b/docs/examples/1.8.x/console-cli/examples/tables/create-index.md new file mode 100644 index 0000000000..4c6d641727 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-index.md @@ -0,0 +1,8 @@ +appwrite tables createIndex \ + --databaseId \ + --tableId \ + --key '' \ + --type key \ + --columns one two three \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-integer-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..afab48e803 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-integer-column.md @@ -0,0 +1,9 @@ +appwrite tables createIntegerColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-ip-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..000b54b918 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-ip-column.md @@ -0,0 +1,7 @@ +appwrite tables createIpColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..4ce3342768 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-relationship-column.md @@ -0,0 +1,9 @@ +appwrite tables createRelationshipColumn \ + --databaseId \ + --tableId \ + --relatedTableId \ + --type oneToOne \ + + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-row.md b/docs/examples/1.8.x/console-cli/examples/tables/create-row.md new file mode 100644 index 0000000000..e446de157b --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-row.md @@ -0,0 +1,6 @@ +appwrite tables createRow \ + --databaseId \ + --tableId \ + --rowId \ + --data '{ "key": "value" }' \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-rows.md b/docs/examples/1.8.x/console-cli/examples/tables/create-rows.md new file mode 100644 index 0000000000..cb7c68dd7b --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-rows.md @@ -0,0 +1,4 @@ +appwrite tables createRows \ + --databaseId \ + --tableId \ + --rows one two three diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-string-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-string-column.md new file mode 100644 index 0000000000..4df1792a34 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-string-column.md @@ -0,0 +1,9 @@ +appwrite tables createStringColumn \ + --databaseId \ + --tableId \ + --key '' \ + --size 1 \ + --required false \ + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create-url-column.md b/docs/examples/1.8.x/console-cli/examples/tables/create-url-column.md new file mode 100644 index 0000000000..fcb81491bd --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create-url-column.md @@ -0,0 +1,7 @@ +appwrite tables createUrlColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/create.md b/docs/examples/1.8.x/console-cli/examples/tables/create.md new file mode 100644 index 0000000000..09f52f16a1 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/create.md @@ -0,0 +1,7 @@ +appwrite tables create \ + --databaseId \ + --tableId \ + --name \ + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/console-cli/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..73743c21ce --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/decrement-row-column.md @@ -0,0 +1,7 @@ +appwrite tables decrementRowColumn \ + --databaseId \ + --tableId \ + --rowId \ + --column '' \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/delete-column.md b/docs/examples/1.8.x/console-cli/examples/tables/delete-column.md new file mode 100644 index 0000000000..e659af54d0 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/delete-column.md @@ -0,0 +1,4 @@ +appwrite tables deleteColumn \ + --databaseId \ + --tableId \ + --key '' diff --git a/docs/examples/1.8.x/console-cli/examples/tables/delete-index.md b/docs/examples/1.8.x/console-cli/examples/tables/delete-index.md new file mode 100644 index 0000000000..0de1e417d3 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/delete-index.md @@ -0,0 +1,4 @@ +appwrite tables deleteIndex \ + --databaseId \ + --tableId \ + --key '' diff --git a/docs/examples/1.8.x/console-cli/examples/tables/delete-row.md b/docs/examples/1.8.x/console-cli/examples/tables/delete-row.md new file mode 100644 index 0000000000..d6918be89e --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/delete-row.md @@ -0,0 +1,4 @@ +appwrite tables deleteRow \ + --databaseId \ + --tableId \ + --rowId diff --git a/docs/examples/1.8.x/console-cli/examples/tables/delete-rows.md b/docs/examples/1.8.x/console-cli/examples/tables/delete-rows.md new file mode 100644 index 0000000000..579586b561 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/delete-rows.md @@ -0,0 +1,4 @@ +appwrite tables deleteRows \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/delete.md b/docs/examples/1.8.x/console-cli/examples/tables/delete.md new file mode 100644 index 0000000000..0f189e09f1 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/delete.md @@ -0,0 +1,3 @@ +appwrite tables delete \ + --databaseId \ + --tableId diff --git a/docs/examples/1.8.x/console-cli/examples/tables/get-column.md b/docs/examples/1.8.x/console-cli/examples/tables/get-column.md new file mode 100644 index 0000000000..33a94b5ebc --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/get-column.md @@ -0,0 +1,4 @@ +appwrite tables getColumn \ + --databaseId \ + --tableId \ + --key '' diff --git a/docs/examples/1.8.x/console-cli/examples/tables/get-index.md b/docs/examples/1.8.x/console-cli/examples/tables/get-index.md new file mode 100644 index 0000000000..e956175e09 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/get-index.md @@ -0,0 +1,4 @@ +appwrite tables getIndex \ + --databaseId \ + --tableId \ + --key '' diff --git a/docs/examples/1.8.x/console-cli/examples/tables/get-row.md b/docs/examples/1.8.x/console-cli/examples/tables/get-row.md new file mode 100644 index 0000000000..5b3b64bfbc --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/get-row.md @@ -0,0 +1,5 @@ +appwrite tables getRow \ + --databaseId \ + --tableId \ + --rowId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/get-table-usage.md b/docs/examples/1.8.x/console-cli/examples/tables/get-table-usage.md new file mode 100644 index 0000000000..f766a418a0 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/get-table-usage.md @@ -0,0 +1,4 @@ +appwrite tables getTableUsage \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/get-usage.md b/docs/examples/1.8.x/console-cli/examples/tables/get-usage.md new file mode 100644 index 0000000000..ca955ce6df --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/get-usage.md @@ -0,0 +1,4 @@ +appwrite tables getUsage \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/get.md b/docs/examples/1.8.x/console-cli/examples/tables/get.md new file mode 100644 index 0000000000..a41e6c10ed --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/get.md @@ -0,0 +1,3 @@ +appwrite tables get \ + --databaseId \ + --tableId diff --git a/docs/examples/1.8.x/console-cli/examples/tables/increment-row-column.md b/docs/examples/1.8.x/console-cli/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..da73950231 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/increment-row-column.md @@ -0,0 +1,7 @@ +appwrite tables incrementRowColumn \ + --databaseId \ + --tableId \ + --rowId \ + --column '' \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/list-columns.md b/docs/examples/1.8.x/console-cli/examples/tables/list-columns.md new file mode 100644 index 0000000000..0439d58127 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/list-columns.md @@ -0,0 +1,4 @@ +appwrite tables listColumns \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/list-indexes.md b/docs/examples/1.8.x/console-cli/examples/tables/list-indexes.md new file mode 100644 index 0000000000..b5fd85b911 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/list-indexes.md @@ -0,0 +1,4 @@ +appwrite tables listIndexes \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/list-logs.md b/docs/examples/1.8.x/console-cli/examples/tables/list-logs.md new file mode 100644 index 0000000000..08c4ff0f8d --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/list-logs.md @@ -0,0 +1,4 @@ +appwrite tables listLogs \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/list-row-logs.md b/docs/examples/1.8.x/console-cli/examples/tables/list-row-logs.md new file mode 100644 index 0000000000..e7a8c5b8ce --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/list-row-logs.md @@ -0,0 +1,5 @@ +appwrite tables listRowLogs \ + --databaseId \ + --tableId \ + --rowId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/list-rows.md b/docs/examples/1.8.x/console-cli/examples/tables/list-rows.md new file mode 100644 index 0000000000..2a6d69d574 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/list-rows.md @@ -0,0 +1,4 @@ +appwrite tables listRows \ + --databaseId \ + --tableId \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/list.md b/docs/examples/1.8.x/console-cli/examples/tables/list.md new file mode 100644 index 0000000000..1c58d9ed03 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/list.md @@ -0,0 +1,4 @@ +appwrite tables list \ + --databaseId \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..7d736f35e5 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-boolean-column.md @@ -0,0 +1,7 @@ +appwrite tables updateBooleanColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default false \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..3da3e4a919 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-datetime-column.md @@ -0,0 +1,7 @@ +appwrite tables updateDatetimeColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default '' \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-email-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-email-column.md new file mode 100644 index 0000000000..df718b8d9a --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-email-column.md @@ -0,0 +1,7 @@ +appwrite tables updateEmailColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default email@example.com \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-enum-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..55c55fc2bd --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-enum-column.md @@ -0,0 +1,8 @@ +appwrite tables updateEnumColumn \ + --databaseId \ + --tableId \ + --key '' \ + --elements one two three \ + --required false \ + --default \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-float-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-float-column.md new file mode 100644 index 0000000000..99667a8447 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-float-column.md @@ -0,0 +1,9 @@ +appwrite tables updateFloatColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default null \ + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-integer-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..098efa0e3e --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-integer-column.md @@ -0,0 +1,9 @@ +appwrite tables updateIntegerColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default null \ + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-ip-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..50eadc3fff --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-ip-column.md @@ -0,0 +1,7 @@ +appwrite tables updateIpColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default '' \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..43e0c0ae6e --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-relationship-column.md @@ -0,0 +1,6 @@ +appwrite tables updateRelationshipColumn \ + --databaseId \ + --tableId \ + --key '' \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-row.md b/docs/examples/1.8.x/console-cli/examples/tables/update-row.md new file mode 100644 index 0000000000..d5cd0fe4ee --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-row.md @@ -0,0 +1,6 @@ +appwrite tables updateRow \ + --databaseId \ + --tableId \ + --rowId \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-rows.md b/docs/examples/1.8.x/console-cli/examples/tables/update-rows.md new file mode 100644 index 0000000000..173d608d5a --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-rows.md @@ -0,0 +1,5 @@ +appwrite tables updateRows \ + --databaseId \ + --tableId \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-string-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-string-column.md new file mode 100644 index 0000000000..3feaa734ec --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-string-column.md @@ -0,0 +1,8 @@ +appwrite tables updateStringColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default \ + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update-url-column.md b/docs/examples/1.8.x/console-cli/examples/tables/update-url-column.md new file mode 100644 index 0000000000..2df1ab14d7 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update-url-column.md @@ -0,0 +1,7 @@ +appwrite tables updateUrlColumn \ + --databaseId \ + --tableId \ + --key '' \ + --required false \ + --default https://example.com \ + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/update.md b/docs/examples/1.8.x/console-cli/examples/tables/update.md new file mode 100644 index 0000000000..a1550287c8 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/update.md @@ -0,0 +1,7 @@ +appwrite tables update \ + --databaseId \ + --tableId \ + --name \ + + + diff --git a/docs/examples/1.8.x/console-cli/examples/tables/upsert-row.md b/docs/examples/1.8.x/console-cli/examples/tables/upsert-row.md new file mode 100644 index 0000000000..0281a89b20 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/upsert-row.md @@ -0,0 +1,4 @@ +appwrite tables upsertRow \ + --databaseId \ + --tableId \ + --rowId diff --git a/docs/examples/1.8.x/console-cli/examples/tables/upsert-rows.md b/docs/examples/1.8.x/console-cli/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..828caf8f10 --- /dev/null +++ b/docs/examples/1.8.x/console-cli/examples/tables/upsert-rows.md @@ -0,0 +1,3 @@ +appwrite tables upsertRows \ + --databaseId \ + --tableId diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..bf0cca08c1 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-boolean-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createBooleanColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + false, // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..c9eb3af82c --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-datetime-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createDatetimeColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-email-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-email-column.md new file mode 100644 index 0000000000..3952161779 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-email-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createEmailColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'email@example.com', // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-enum-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..7b16da6c14 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-enum-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createEnumColumn( + '', // databaseId + '', // tableId + '', // key + [], // elements + false, // required + '', // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-float-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-float-column.md new file mode 100644 index 0000000000..6608864efe --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-float-column.md @@ -0,0 +1,20 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createFloatColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // min (optional) + null, // max (optional) + null, // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-index.md b/docs/examples/1.8.x/console-web/examples/tables/create-index.md new file mode 100644 index 0000000000..c303dd289d --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-index.md @@ -0,0 +1,19 @@ +import { Client, Tables, IndexType } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createIndex( + '', // databaseId + '', // tableId + '', // key + IndexType.Key, // type + [], // columns + [], // orders (optional) + [] // lengths (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-integer-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..0490b71189 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-integer-column.md @@ -0,0 +1,20 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createIntegerColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // min (optional) + null, // max (optional) + null, // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-ip-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..644f520032 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-ip-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createIpColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..5658eec690 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-relationship-column.md @@ -0,0 +1,20 @@ +import { Client, Tables, RelationshipType, RelationMutate } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createRelationshipColumn( + '', // databaseId + '', // tableId + '', // relatedTableId + RelationshipType.OneToOne, // type + false, // twoWay (optional) + '', // key (optional) + '', // twoWayKey (optional) + RelationMutate.Cascade // onDelete (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-row.md b/docs/examples/1.8.x/console-web/examples/tables/create-row.md new file mode 100644 index 0000000000..ba18cb6fba --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-row.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const result = await tables.createRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data + ["read("any")"] // permissions (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-rows.md b/docs/examples/1.8.x/console-web/examples/tables/create-rows.md new file mode 100644 index 0000000000..bd7f984ee3 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-rows.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const result = await tables.createRows( + '', // databaseId + '', // tableId + [] // rows +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-string-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-string-column.md new file mode 100644 index 0000000000..6c1fbd7c99 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-string-column.md @@ -0,0 +1,20 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createStringColumn( + '', // databaseId + '', // tableId + '', // key + 1, // size + false, // required + '', // default (optional) + false, // array (optional) + false // encrypt (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create-url-column.md b/docs/examples/1.8.x/console-web/examples/tables/create-url-column.md new file mode 100644 index 0000000000..88e1fc584d --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create-url-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.createUrlColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'https://example.com', // default (optional) + false // array (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/create.md b/docs/examples/1.8.x/console-web/examples/tables/create.md new file mode 100644 index 0000000000..a7bda74508 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/create.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.create( + '', // databaseId + '', // tableId + '', // name + ["read("any")"], // permissions (optional) + false, // rowSecurity (optional) + false // enabled (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/console-web/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..35cb78686c --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/decrement-row-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.decrementRowColumn( + '', // databaseId + '', // tableId + '', // rowId + '', // column + null, // value (optional) + null // min (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/delete-column.md b/docs/examples/1.8.x/console-web/examples/tables/delete-column.md new file mode 100644 index 0000000000..642856448a --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/delete-column.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.deleteColumn( + '', // databaseId + '', // tableId + '' // key +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/delete-index.md b/docs/examples/1.8.x/console-web/examples/tables/delete-index.md new file mode 100644 index 0000000000..f517513909 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/delete-index.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.deleteIndex( + '', // databaseId + '', // tableId + '' // key +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/delete-row.md b/docs/examples/1.8.x/console-web/examples/tables/delete-row.md new file mode 100644 index 0000000000..accbb3092a --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/delete-row.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.deleteRow( + '', // databaseId + '', // tableId + '' // rowId +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/delete-rows.md b/docs/examples/1.8.x/console-web/examples/tables/delete-rows.md new file mode 100644 index 0000000000..adbb613a35 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/delete-rows.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.deleteRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/delete.md b/docs/examples/1.8.x/console-web/examples/tables/delete.md new file mode 100644 index 0000000000..f235d8dda0 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/delete.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.delete( + '', // databaseId + '' // tableId +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/get-column.md b/docs/examples/1.8.x/console-web/examples/tables/get-column.md new file mode 100644 index 0000000000..7bd7f2db30 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/get-column.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getColumn( + '', // databaseId + '', // tableId + '' // key +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/get-index.md b/docs/examples/1.8.x/console-web/examples/tables/get-index.md new file mode 100644 index 0000000000..dc8c3362cf --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/get-index.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getIndex( + '', // databaseId + '', // tableId + '' // key +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/get-row.md b/docs/examples/1.8.x/console-web/examples/tables/get-row.md new file mode 100644 index 0000000000..f37558d4ff --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/get-row.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getRow( + '', // databaseId + '', // tableId + '', // rowId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/get-table-usage.md b/docs/examples/1.8.x/console-web/examples/tables/get-table-usage.md new file mode 100644 index 0000000000..4e6ca3270d --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/get-table-usage.md @@ -0,0 +1,15 @@ +import { Client, Tables, } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getTableUsage( + '', // databaseId + '', // tableId + .24h // range (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/get-usage.md b/docs/examples/1.8.x/console-web/examples/tables/get-usage.md new file mode 100644 index 0000000000..0f9d31c92d --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/get-usage.md @@ -0,0 +1,15 @@ +import { Client, Tables, DatabaseUsageRange } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.getUsage( + '', // databaseId + '', // tableId + DatabaseUsageRange.TwentyFourHours // range (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/get.md b/docs/examples/1.8.x/console-web/examples/tables/get.md new file mode 100644 index 0000000000..2b8951582a --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/get.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.get( + '', // databaseId + '' // tableId +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/increment-row-column.md b/docs/examples/1.8.x/console-web/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..ed9710a0e3 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/increment-row-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.incrementRowColumn( + '', // databaseId + '', // tableId + '', // rowId + '', // column + null, // value (optional) + null // max (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/list-columns.md b/docs/examples/1.8.x/console-web/examples/tables/list-columns.md new file mode 100644 index 0000000000..91348c4e61 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/list-columns.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listColumns( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/list-indexes.md b/docs/examples/1.8.x/console-web/examples/tables/list-indexes.md new file mode 100644 index 0000000000..0ae874663d --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/list-indexes.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listIndexes( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/list-logs.md b/docs/examples/1.8.x/console-web/examples/tables/list-logs.md new file mode 100644 index 0000000000..04d6c2300c --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/list-logs.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listLogs( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/list-row-logs.md b/docs/examples/1.8.x/console-web/examples/tables/list-row-logs.md new file mode 100644 index 0000000000..691e589a77 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/list-row-logs.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listRowLogs( + '', // databaseId + '', // tableId + '', // rowId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/list-rows.md b/docs/examples/1.8.x/console-web/examples/tables/list-rows.md new file mode 100644 index 0000000000..79f5e242a5 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/list-rows.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.listRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/list.md b/docs/examples/1.8.x/console-web/examples/tables/list.md new file mode 100644 index 0000000000..e8eb3c3dd6 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/list.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.list( + '', // databaseId + [], // queries (optional) + '' // search (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..e4bb9012e6 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-boolean-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateBooleanColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + false, // default + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..d24683aafb --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-datetime-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateDatetimeColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-email-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-email-column.md new file mode 100644 index 0000000000..b9e2483191 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-email-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateEmailColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'email@example.com', // default + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-enum-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..bfe084212c --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-enum-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateEnumColumn( + '', // databaseId + '', // tableId + '', // key + [], // elements + false, // required + '', // default + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-float-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-float-column.md new file mode 100644 index 0000000000..9075e31e69 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-float-column.md @@ -0,0 +1,20 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateFloatColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // default + null, // min (optional) + null, // max (optional) + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-integer-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..c45e4735a9 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-integer-column.md @@ -0,0 +1,20 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateIntegerColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // default + null, // min (optional) + null, // max (optional) + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-ip-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..f7cdb490dc --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-ip-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateIpColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..192eac7175 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-relationship-column.md @@ -0,0 +1,17 @@ +import { Client, Tables, RelationMutate } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateRelationshipColumn( + '', // databaseId + '', // tableId + '', // key + RelationMutate.Cascade, // onDelete (optional) + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-row.md b/docs/examples/1.8.x/console-web/examples/tables/update-row.md new file mode 100644 index 0000000000..0db00657c2 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data (optional) + ["read("any")"] // permissions (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-rows.md b/docs/examples/1.8.x/console-web/examples/tables/update-rows.md new file mode 100644 index 0000000000..72b2244f75 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-rows.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateRows( + '', // databaseId + '', // tableId + {}, // data (optional) + [] // queries (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-string-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-string-column.md new file mode 100644 index 0000000000..8f6b3b5dad --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-string-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateStringColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + 1, // size (optional) + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update-url-column.md b/docs/examples/1.8.x/console-web/examples/tables/update-url-column.md new file mode 100644 index 0000000000..a2cb65d700 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update-url-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.updateUrlColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'https://example.com', // default + '' // newKey (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/update.md b/docs/examples/1.8.x/console-web/examples/tables/update.md new file mode 100644 index 0000000000..f0552604af --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/update.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject(''); // Your project ID + +const tables = new Tables(client); + +const result = await tables.update( + '', // databaseId + '', // tableId + '', // name + ["read("any")"], // permissions (optional) + false, // rowSecurity (optional) + false // enabled (optional) +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/upsert-row.md b/docs/examples/1.8.x/console-web/examples/tables/upsert-row.md new file mode 100644 index 0000000000..f1cb65e675 --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/upsert-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const result = await tables.upsertRow( + '', // databaseId + '', // tableId + '' // rowId +); + +console.log(result); diff --git a/docs/examples/1.8.x/console-web/examples/tables/upsert-rows.md b/docs/examples/1.8.x/console-web/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..2d818cdbca --- /dev/null +++ b/docs/examples/1.8.x/console-web/examples/tables/upsert-rows.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "@appwrite.io/console"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const result = await tables.upsertRows( + '', // databaseId + '' // tableId +); + +console.log(result); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..5b3e987b9b --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-boolean-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnBoolean result = await tables.createBooleanColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: false, // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..1ad3fa250d --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-datetime-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnDatetime result = await tables.createDatetimeColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: '', // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-email-column.md new file mode 100644 index 0000000000..fa7ec71410 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-email-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnEmail result = await tables.createEmailColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: 'email@example.com', // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..5ab6bcc774 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-enum-column.md @@ -0,0 +1,18 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnEnum result = await tables.createEnumColumn( + databaseId: '', + tableId: '', + key: '', + elements: [], + xrequired: false, + xdefault: '', // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-float-column.md new file mode 100644 index 0000000000..43331187ea --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-float-column.md @@ -0,0 +1,19 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnFloat result = await tables.createFloatColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + min: 0, // (optional) + max: 0, // (optional) + xdefault: 0, // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-index.md b/docs/examples/1.8.x/server-dart/examples/tables/create-index.md new file mode 100644 index 0000000000..d76c46959f --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-index.md @@ -0,0 +1,18 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnIndex result = await tables.createIndex( + databaseId: '', + tableId: '', + key: '', + type: IndexType.key, + columns: [], + orders: [], // (optional) + lengths: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..3304325af7 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-integer-column.md @@ -0,0 +1,19 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnInteger result = await tables.createIntegerColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + min: 0, // (optional) + max: 0, // (optional) + xdefault: 0, // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..68c7abf754 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-ip-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnIp result = await tables.createIpColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: '', // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..a059740bf8 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-relationship-column.md @@ -0,0 +1,19 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnRelationship result = await tables.createRelationshipColumn( + databaseId: '', + tableId: '', + relatedTableId: '', + type: RelationshipType.oneToOne, + twoWay: false, // (optional) + key: '', // (optional) + twoWayKey: '', // (optional) + onDelete: RelationMutate.cascade, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-row.md b/docs/examples/1.8.x/server-dart/examples/tables/create-row.md new file mode 100644 index 0000000000..1ce1e1db7a --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-row.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +Tables tables = Tables(client); + +Row result = await tables.createRow( + databaseId: '', + tableId: '', + rowId: '', + data: {}, + permissions: ["read("any")"], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-rows.md b/docs/examples/1.8.x/server-dart/examples/tables/create-rows.md new file mode 100644 index 0000000000..219f2d2d33 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-rows.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +RowList result = await tables.createRows( + databaseId: '', + tableId: '', + rows: [], +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-string-column.md new file mode 100644 index 0000000000..17e192b27e --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-string-column.md @@ -0,0 +1,19 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnString result = await tables.createStringColumn( + databaseId: '', + tableId: '', + key: '', + size: 1, + xrequired: false, + xdefault: '', // (optional) + array: false, // (optional) + encrypt: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-dart/examples/tables/create-url-column.md new file mode 100644 index 0000000000..d3692fc7ac --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create-url-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnUrl result = await tables.createUrlColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: 'https://example.com', // (optional) + array: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/create.md b/docs/examples/1.8.x/server-dart/examples/tables/create.md new file mode 100644 index 0000000000..c3a4b2a989 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/create.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +Table result = await tables.create( + databaseId: '', + tableId: '', + name: '', + permissions: ["read("any")"], // (optional) + rowSecurity: false, // (optional) + enabled: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-dart/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..33d296110c --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/decrement-row-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +Row result = await tables.decrementRowColumn( + databaseId: '', + tableId: '', + rowId: '', + column: '', + value: 0, // (optional) + min: 0, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/delete-column.md b/docs/examples/1.8.x/server-dart/examples/tables/delete-column.md new file mode 100644 index 0000000000..466564f618 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/delete-column.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +await tables.deleteColumn( + databaseId: '', + tableId: '', + key: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/delete-index.md b/docs/examples/1.8.x/server-dart/examples/tables/delete-index.md new file mode 100644 index 0000000000..f2dfdbe74b --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/delete-index.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +await tables.deleteIndex( + databaseId: '', + tableId: '', + key: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/delete-row.md b/docs/examples/1.8.x/server-dart/examples/tables/delete-row.md new file mode 100644 index 0000000000..b84c1b7a9f --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/delete-row.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +Tables tables = Tables(client); + +await tables.deleteRow( + databaseId: '', + tableId: '', + rowId: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-dart/examples/tables/delete-rows.md new file mode 100644 index 0000000000..41dc3a9520 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/delete-rows.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +await tables.deleteRows( + databaseId: '', + tableId: '', + queries: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/delete.md b/docs/examples/1.8.x/server-dart/examples/tables/delete.md new file mode 100644 index 0000000000..07c9815422 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/delete.md @@ -0,0 +1,13 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +await tables.delete( + databaseId: '', + tableId: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/get-column.md b/docs/examples/1.8.x/server-dart/examples/tables/get-column.md new file mode 100644 index 0000000000..087139c87d --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/get-column.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + + result = await tables.getColumn( + databaseId: '', + tableId: '', + key: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/get-index.md b/docs/examples/1.8.x/server-dart/examples/tables/get-index.md new file mode 100644 index 0000000000..3f79deef2f --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/get-index.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnIndex result = await tables.getIndex( + databaseId: '', + tableId: '', + key: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/get-row.md b/docs/examples/1.8.x/server-dart/examples/tables/get-row.md new file mode 100644 index 0000000000..7efd04a69d --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/get-row.md @@ -0,0 +1,15 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +Tables tables = Tables(client); + +Row result = await tables.getRow( + databaseId: '', + tableId: '', + rowId: '', + queries: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/get.md b/docs/examples/1.8.x/server-dart/examples/tables/get.md new file mode 100644 index 0000000000..d02f9ff9d2 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/get.md @@ -0,0 +1,13 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +Table result = await tables.get( + databaseId: '', + tableId: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-dart/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..188ab5d1ad --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/increment-row-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +Row result = await tables.incrementRowColumn( + databaseId: '', + tableId: '', + rowId: '', + column: '', + value: 0, // (optional) + max: 0, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/list-columns.md b/docs/examples/1.8.x/server-dart/examples/tables/list-columns.md new file mode 100644 index 0000000000..7b2d479ea3 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/list-columns.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnList result = await tables.listColumns( + databaseId: '', + tableId: '', + queries: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-dart/examples/tables/list-indexes.md new file mode 100644 index 0000000000..e7418de3bc --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/list-indexes.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnIndexList result = await tables.listIndexes( + databaseId: '', + tableId: '', + queries: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/list-rows.md b/docs/examples/1.8.x/server-dart/examples/tables/list-rows.md new file mode 100644 index 0000000000..05f9567ac2 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/list-rows.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +Tables tables = Tables(client); + +RowList result = await tables.listRows( + databaseId: '', + tableId: '', + queries: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/list.md b/docs/examples/1.8.x/server-dart/examples/tables/list.md new file mode 100644 index 0000000000..51a19c099d --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/list.md @@ -0,0 +1,14 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +TableList result = await tables.list( + databaseId: '', + queries: [], // (optional) + search: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..c452238d7c --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-boolean-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnBoolean result = await tables.updateBooleanColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: false, + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..5b41d7e532 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-datetime-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnDatetime result = await tables.updateDatetimeColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: '', + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-email-column.md new file mode 100644 index 0000000000..444649a4fd --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-email-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnEmail result = await tables.updateEmailColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: 'email@example.com', + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..2e0566418a --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-enum-column.md @@ -0,0 +1,18 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnEnum result = await tables.updateEnumColumn( + databaseId: '', + tableId: '', + key: '', + elements: [], + xrequired: false, + xdefault: '', + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-float-column.md new file mode 100644 index 0000000000..199d3840d6 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-float-column.md @@ -0,0 +1,19 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnFloat result = await tables.updateFloatColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: 0, + min: 0, // (optional) + max: 0, // (optional) + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..479e63d870 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-integer-column.md @@ -0,0 +1,19 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnInteger result = await tables.updateIntegerColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: 0, + min: 0, // (optional) + max: 0, // (optional) + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..837ae4e606 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-ip-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnIp result = await tables.updateIpColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: '', + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..45745627ef --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-relationship-column.md @@ -0,0 +1,16 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnRelationship result = await tables.updateRelationshipColumn( + databaseId: '', + tableId: '', + key: '', + onDelete: RelationMutate.cascade, // (optional) + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-row.md b/docs/examples/1.8.x/server-dart/examples/tables/update-row.md new file mode 100644 index 0000000000..436329235a --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-row.md @@ -0,0 +1,16 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +Tables tables = Tables(client); + +Row result = await tables.updateRow( + databaseId: '', + tableId: '', + rowId: '', + data: {}, // (optional) + permissions: ["read("any")"], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-rows.md b/docs/examples/1.8.x/server-dart/examples/tables/update-rows.md new file mode 100644 index 0000000000..3d2aaf3e28 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-rows.md @@ -0,0 +1,15 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +RowList result = await tables.updateRows( + databaseId: '', + tableId: '', + data: {}, // (optional) + queries: [], // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-string-column.md new file mode 100644 index 0000000000..dbd569feac --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-string-column.md @@ -0,0 +1,18 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnString result = await tables.updateStringColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: '', + size: 1, // (optional) + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-dart/examples/tables/update-url-column.md new file mode 100644 index 0000000000..8630c718b5 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update-url-column.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +ColumnUrl result = await tables.updateUrlColumn( + databaseId: '', + tableId: '', + key: '', + xrequired: false, + xdefault: 'https://example.com', + newKey: '', // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/update.md b/docs/examples/1.8.x/server-dart/examples/tables/update.md new file mode 100644 index 0000000000..28ce03cd6c --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/update.md @@ -0,0 +1,17 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +Table result = await tables.update( + databaseId: '', + tableId: '', + name: '', + permissions: ["read("any")"], // (optional) + rowSecurity: false, // (optional) + enabled: false, // (optional) +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-dart/examples/tables/upsert-row.md new file mode 100644 index 0000000000..47f93f2434 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/upsert-row.md @@ -0,0 +1,15 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +Tables tables = Tables(client); + +Row result = await tables.upsertRow( + databaseId: '', + tableId: '', + rowId: '', +); diff --git a/docs/examples/1.8.x/server-dart/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-dart/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..73ceffa917 --- /dev/null +++ b/docs/examples/1.8.x/server-dart/examples/tables/upsert-rows.md @@ -0,0 +1,13 @@ +import 'package:dart_appwrite/dart_appwrite.dart'; + +Client client = Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +Tables tables = Tables(client); + +RowList result = await tables.upsertRows( + databaseId: '', + tableId: '', +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..3f9abc8c05 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-boolean-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createBooleanColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + false, // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..898b67a787 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-datetime-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createDatetimeColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-email-column.md new file mode 100644 index 0000000000..82872e4087 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-email-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createEmailColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'email@example.com', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..afbb8d00aa --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-enum-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createEnumColumn( + '', // databaseId + '', // tableId + '', // key + [], // elements + false, // required + '', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-float-column.md new file mode 100644 index 0000000000..44658bbaa9 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-float-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createFloatColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // min (optional) + null, // max (optional) + null, // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-index.md b/docs/examples/1.8.x/server-deno/examples/tables/create-index.md new file mode 100644 index 0000000000..c255189881 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-index.md @@ -0,0 +1,18 @@ +import { Client, Tables, IndexType } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createIndex( + '', // databaseId + '', // tableId + '', // key + IndexType.Key, // type + [], // columns + [], // orders (optional) + [] // lengths (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..0f1721b24a --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-integer-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createIntegerColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // min (optional) + null, // max (optional) + null, // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..ca96de6293 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-ip-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createIpColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..8c7e26e62c --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-relationship-column.md @@ -0,0 +1,19 @@ +import { Client, Tables, RelationshipType, RelationMutate } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createRelationshipColumn( + '', // databaseId + '', // tableId + '', // relatedTableId + RelationshipType.OneToOne, // type + false, // twoWay (optional) + '', // key (optional) + '', // twoWayKey (optional) + RelationMutate.Cascade // onDelete (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-row.md b/docs/examples/1.8.x/server-deno/examples/tables/create-row.md new file mode 100644 index 0000000000..12cec49af0 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-row.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const response = await tables.createRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data + ["read("any")"] // permissions (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-rows.md b/docs/examples/1.8.x/server-deno/examples/tables/create-rows.md new file mode 100644 index 0000000000..6c4f7d5627 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-rows.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createRows( + '', // databaseId + '', // tableId + [] // rows +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-string-column.md new file mode 100644 index 0000000000..db7ac8a760 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-string-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createStringColumn( + '', // databaseId + '', // tableId + '', // key + 1, // size + false, // required + '', // default (optional) + false, // array (optional) + false // encrypt (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-deno/examples/tables/create-url-column.md new file mode 100644 index 0000000000..8d6f127c00 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create-url-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.createUrlColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'https://example.com', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/create.md b/docs/examples/1.8.x/server-deno/examples/tables/create.md new file mode 100644 index 0000000000..9c75c22c3d --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/create.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.create( + '', // databaseId + '', // tableId + '', // name + ["read("any")"], // permissions (optional) + false, // rowSecurity (optional) + false // enabled (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-deno/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..e561acc529 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/decrement-row-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.decrementRowColumn( + '', // databaseId + '', // tableId + '', // rowId + '', // column + null, // value (optional) + null // min (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/delete-column.md b/docs/examples/1.8.x/server-deno/examples/tables/delete-column.md new file mode 100644 index 0000000000..89900bfbf0 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/delete-column.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.deleteColumn( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/delete-index.md b/docs/examples/1.8.x/server-deno/examples/tables/delete-index.md new file mode 100644 index 0000000000..a17791cef2 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/delete-index.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.deleteIndex( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/delete-row.md b/docs/examples/1.8.x/server-deno/examples/tables/delete-row.md new file mode 100644 index 0000000000..8f30eae2d2 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/delete-row.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new Tables(client); + +const response = await tables.deleteRow( + '', // databaseId + '', // tableId + '' // rowId +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-deno/examples/tables/delete-rows.md new file mode 100644 index 0000000000..c5aa88f9a2 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/delete-rows.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.deleteRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/delete.md b/docs/examples/1.8.x/server-deno/examples/tables/delete.md new file mode 100644 index 0000000000..36df1373dc --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/delete.md @@ -0,0 +1,13 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.delete( + '', // databaseId + '' // tableId +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/get-column.md b/docs/examples/1.8.x/server-deno/examples/tables/get-column.md new file mode 100644 index 0000000000..8a56af67e7 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/get-column.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.getColumn( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/get-index.md b/docs/examples/1.8.x/server-deno/examples/tables/get-index.md new file mode 100644 index 0000000000..61105dc661 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/get-index.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.getIndex( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/get-row.md b/docs/examples/1.8.x/server-deno/examples/tables/get-row.md new file mode 100644 index 0000000000..674ea3e648 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/get-row.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new Tables(client); + +const response = await tables.getRow( + '', // databaseId + '', // tableId + '', // rowId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/get.md b/docs/examples/1.8.x/server-deno/examples/tables/get.md new file mode 100644 index 0000000000..cc1dcb8c51 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/get.md @@ -0,0 +1,13 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.get( + '', // databaseId + '' // tableId +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-deno/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..9779d8776e --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/increment-row-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.incrementRowColumn( + '', // databaseId + '', // tableId + '', // rowId + '', // column + null, // value (optional) + null // max (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/list-columns.md b/docs/examples/1.8.x/server-deno/examples/tables/list-columns.md new file mode 100644 index 0000000000..63ec0777bb --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/list-columns.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.listColumns( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-deno/examples/tables/list-indexes.md new file mode 100644 index 0000000000..587d19f362 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/list-indexes.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.listIndexes( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/list-rows.md b/docs/examples/1.8.x/server-deno/examples/tables/list-rows.md new file mode 100644 index 0000000000..6db6bea439 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/list-rows.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new Tables(client); + +const response = await tables.listRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/list.md b/docs/examples/1.8.x/server-deno/examples/tables/list.md new file mode 100644 index 0000000000..d4da8409c9 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/list.md @@ -0,0 +1,14 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.list( + '', // databaseId + [], // queries (optional) + '' // search (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..8710c27ede --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-boolean-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateBooleanColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + false, // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..e1ca760e31 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-datetime-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateDatetimeColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-email-column.md new file mode 100644 index 0000000000..b0e25348d4 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-email-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateEmailColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'email@example.com', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..8771213a79 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-enum-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateEnumColumn( + '', // databaseId + '', // tableId + '', // key + [], // elements + false, // required + '', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-float-column.md new file mode 100644 index 0000000000..a2e6f55c1f --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-float-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateFloatColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // default + null, // min (optional) + null, // max (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..51ea17f943 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-integer-column.md @@ -0,0 +1,19 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateIntegerColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // default + null, // min (optional) + null, // max (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..4a5a1d0f81 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-ip-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateIpColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..c83b82037a --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-relationship-column.md @@ -0,0 +1,16 @@ +import { Client, Tables, RelationMutate } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateRelationshipColumn( + '', // databaseId + '', // tableId + '', // key + RelationMutate.Cascade, // onDelete (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-row.md b/docs/examples/1.8.x/server-deno/examples/tables/update-row.md new file mode 100644 index 0000000000..13da5615e7 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-row.md @@ -0,0 +1,16 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new Tables(client); + +const response = await tables.updateRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data (optional) + ["read("any")"] // permissions (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-rows.md b/docs/examples/1.8.x/server-deno/examples/tables/update-rows.md new file mode 100644 index 0000000000..1bc0a18b98 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-rows.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateRows( + '', // databaseId + '', // tableId + {}, // data (optional) + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-string-column.md new file mode 100644 index 0000000000..00dd310b1e --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-string-column.md @@ -0,0 +1,18 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateStringColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + 1, // size (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-deno/examples/tables/update-url-column.md new file mode 100644 index 0000000000..2ebf80a356 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update-url-column.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.updateUrlColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'https://example.com', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/update.md b/docs/examples/1.8.x/server-deno/examples/tables/update.md new file mode 100644 index 0000000000..43b51bd284 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/update.md @@ -0,0 +1,17 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.update( + '', // databaseId + '', // tableId + '', // name + ["read("any")"], // permissions (optional) + false, // rowSecurity (optional) + false // enabled (optional) +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-deno/examples/tables/upsert-row.md new file mode 100644 index 0000000000..45e932c7f6 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/upsert-row.md @@ -0,0 +1,15 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +const tables = new Tables(client); + +const response = await tables.upsertRow( + '', // databaseId + '', // tableId + '' // rowId +); diff --git a/docs/examples/1.8.x/server-deno/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-deno/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..9e3f542051 --- /dev/null +++ b/docs/examples/1.8.x/server-deno/examples/tables/upsert-rows.md @@ -0,0 +1,13 @@ +import { Client, Tables } from "https://deno.land/x/appwrite/mod.ts"; + +const client = new Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +const tables = new Tables(client); + +const response = await tables.upsertRows( + '', // databaseId + '' // tableId +); diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..1492487721 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-boolean-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnBoolean result = await tables.CreateBooleanColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: false, // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..6a1e07b907 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-datetime-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnDatetime result = await tables.CreateDatetimeColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-email-column.md new file mode 100644 index 0000000000..a4740484f5 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-email-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnEmail result = await tables.CreateEmailColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "email@example.com", // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..9529ad1331 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-enum-column.md @@ -0,0 +1,20 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnEnum result = await tables.CreateEnumColumn( + databaseId: "", + tableId: "", + key: "", + elements: new List(), + required: false, + default: "", // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-float-column.md new file mode 100644 index 0000000000..f8146ce272 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-float-column.md @@ -0,0 +1,21 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnFloat result = await tables.CreateFloatColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + min: 0, // optional + max: 0, // optional + default: 0, // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-index.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-index.md new file mode 100644 index 0000000000..4ea3817da2 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-index.md @@ -0,0 +1,21 @@ +using Appwrite; +using Appwrite.Enums; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnIndex result = await tables.CreateIndex( + databaseId: "", + tableId: "", + key: "", + type: IndexType.Key, + columns: new List(), + orders: new List(), // optional + lengths: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..6090426792 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-integer-column.md @@ -0,0 +1,21 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnInteger result = await tables.CreateIntegerColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + min: 0, // optional + max: 0, // optional + default: 0, // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..b5e5067e6f --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-ip-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnIp result = await tables.CreateIpColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..7c4cba49dd --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-relationship-column.md @@ -0,0 +1,22 @@ +using Appwrite; +using Appwrite.Enums; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnRelationship result = await tables.CreateRelationshipColumn( + databaseId: "", + tableId: "", + relatedTableId: "", + type: RelationshipType.OneToOne, + twoWay: false, // optional + key: "", // optional + twoWayKey: "", // optional + onDelete: RelationMutate.Cascade // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-row.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-row.md new file mode 100644 index 0000000000..642bfe457c --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-row.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetSession("") // The user session to authenticate with + .SetKey("") // Your secret API key + .SetJWT(""); // Your secret JSON Web Token + +Tables tables = new Tables(client); + +Row result = await tables.CreateRow( + databaseId: "", + tableId: "", + rowId: "", + data: [object], + permissions: ["read("any")"] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-rows.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-rows.md new file mode 100644 index 0000000000..1d44dc51ed --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-rows.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetAdmin("") // + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +RowList result = await tables.CreateRows( + databaseId: "", + tableId: "", + rows: new List() +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-string-column.md new file mode 100644 index 0000000000..e623ac0789 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-string-column.md @@ -0,0 +1,21 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnString result = await tables.CreateStringColumn( + databaseId: "", + tableId: "", + key: "", + size: 1, + required: false, + default: "", // optional + array: false, // optional + encrypt: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create-url-column.md new file mode 100644 index 0000000000..7a0fbd0a83 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create-url-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnUrl result = await tables.CreateUrlColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "https://example.com", // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/create.md b/docs/examples/1.8.x/server-dotnet/examples/tables/create.md new file mode 100644 index 0000000000..694f4101a7 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/create.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +Table result = await tables.Create( + databaseId: "", + tableId: "", + name: "", + permissions: ["read("any")"], // optional + rowSecurity: false, // optional + enabled: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..220fb2b18a --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/decrement-row-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +Row result = await tables.DecrementRowColumn( + databaseId: "", + tableId: "", + rowId: "", + column: "", + value: 0, // optional + min: 0 // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/delete-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-column.md new file mode 100644 index 0000000000..ca8987eec9 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-column.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +await tables.DeleteColumn( + databaseId: "", + tableId: "", + key: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/delete-index.md b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-index.md new file mode 100644 index 0000000000..ba7a024167 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-index.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +await tables.DeleteIndex( + databaseId: "", + tableId: "", + key: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/delete-row.md b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-row.md new file mode 100644 index 0000000000..95bae6ad6b --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-row.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +await tables.DeleteRow( + databaseId: "", + tableId: "", + rowId: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-rows.md new file mode 100644 index 0000000000..46a6e0ba94 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/delete-rows.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +await tables.DeleteRows( + databaseId: "", + tableId: "", + queries: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/delete.md b/docs/examples/1.8.x/server-dotnet/examples/tables/delete.md new file mode 100644 index 0000000000..bcff3ea05a --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/delete.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +await tables.Delete( + databaseId: "", + tableId: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/get-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/get-column.md new file mode 100644 index 0000000000..71ebb81aef --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/get-column.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + + result = await tables.GetColumn( + databaseId: "", + tableId: "", + key: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/get-index.md b/docs/examples/1.8.x/server-dotnet/examples/tables/get-index.md new file mode 100644 index 0000000000..f5b886e3e9 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/get-index.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnIndex result = await tables.GetIndex( + databaseId: "", + tableId: "", + key: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/get-row.md b/docs/examples/1.8.x/server-dotnet/examples/tables/get-row.md new file mode 100644 index 0000000000..474b3342c9 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/get-row.md @@ -0,0 +1,17 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +Row result = await tables.GetRow( + databaseId: "", + tableId: "", + rowId: "", + queries: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/get.md b/docs/examples/1.8.x/server-dotnet/examples/tables/get.md new file mode 100644 index 0000000000..1e86d228a6 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/get.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +Table result = await tables.Get( + databaseId: "", + tableId: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..e8ccd8ca78 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/increment-row-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +Row result = await tables.IncrementRowColumn( + databaseId: "", + tableId: "", + rowId: "", + column: "", + value: 0, // optional + max: 0 // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/list-columns.md b/docs/examples/1.8.x/server-dotnet/examples/tables/list-columns.md new file mode 100644 index 0000000000..fe8c739cf9 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/list-columns.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnList result = await tables.ListColumns( + databaseId: "", + tableId: "", + queries: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-dotnet/examples/tables/list-indexes.md new file mode 100644 index 0000000000..907a21048f --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/list-indexes.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnIndexList result = await tables.ListIndexes( + databaseId: "", + tableId: "", + queries: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/list-rows.md b/docs/examples/1.8.x/server-dotnet/examples/tables/list-rows.md new file mode 100644 index 0000000000..474c597a1c --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/list-rows.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +RowList result = await tables.ListRows( + databaseId: "", + tableId: "", + queries: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/list.md b/docs/examples/1.8.x/server-dotnet/examples/tables/list.md new file mode 100644 index 0000000000..2871a927c4 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/list.md @@ -0,0 +1,16 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +TableList result = await tables.List( + databaseId: "", + queries: new List(), // optional + search: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..5c610fbe7a --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-boolean-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnBoolean result = await tables.UpdateBooleanColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: false, + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..754d0f1ae6 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-datetime-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnDatetime result = await tables.UpdateDatetimeColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-email-column.md new file mode 100644 index 0000000000..6000c54e8f --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-email-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnEmail result = await tables.UpdateEmailColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "email@example.com", + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..2eaa1a51a1 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-enum-column.md @@ -0,0 +1,20 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnEnum result = await tables.UpdateEnumColumn( + databaseId: "", + tableId: "", + key: "", + elements: new List(), + required: false, + default: "", + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-float-column.md new file mode 100644 index 0000000000..7d18d8e624 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-float-column.md @@ -0,0 +1,21 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnFloat result = await tables.UpdateFloatColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: 0, + min: 0, // optional + max: 0, // optional + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..0b3b85652c --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-integer-column.md @@ -0,0 +1,21 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnInteger result = await tables.UpdateIntegerColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: 0, + min: 0, // optional + max: 0, // optional + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..ccdd0d5235 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-ip-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnIp result = await tables.UpdateIpColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..be6aa31f73 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-relationship-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Enums; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnRelationship result = await tables.UpdateRelationshipColumn( + databaseId: "", + tableId: "", + key: "", + onDelete: RelationMutate.Cascade, // optional + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-row.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-row.md new file mode 100644 index 0000000000..d049ccf805 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-row.md @@ -0,0 +1,18 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +Row result = await tables.UpdateRow( + databaseId: "", + tableId: "", + rowId: "", + data: [object], // optional + permissions: ["read("any")"] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-rows.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-rows.md new file mode 100644 index 0000000000..9d2c51c4b3 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-rows.md @@ -0,0 +1,17 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +RowList result = await tables.UpdateRows( + databaseId: "", + tableId: "", + data: [object], // optional + queries: new List() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-string-column.md new file mode 100644 index 0000000000..da280e7d8c --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-string-column.md @@ -0,0 +1,20 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnString result = await tables.UpdateStringColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + size: 1, // optional + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update-url-column.md new file mode 100644 index 0000000000..1ce961da2b --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update-url-column.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +ColumnUrl result = await tables.UpdateUrlColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "https://example.com", + newKey: "" // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/update.md b/docs/examples/1.8.x/server-dotnet/examples/tables/update.md new file mode 100644 index 0000000000..584c61c6bb --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/update.md @@ -0,0 +1,19 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetProject("") // Your project ID + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +Table result = await tables.Update( + databaseId: "", + tableId: "", + name: "", + permissions: ["read("any")"], // optional + rowSecurity: false, // optional + enabled: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-dotnet/examples/tables/upsert-row.md new file mode 100644 index 0000000000..a73c4e2402 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/upsert-row.md @@ -0,0 +1,17 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetSession("") // The user session to authenticate with + .SetKey("") // Your secret API key + .SetJWT(""); // Your secret JSON Web Token + +Tables tables = new Tables(client); + +Row result = await tables.UpsertRow( + databaseId: "", + tableId: "", + rowId: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-dotnet/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-dotnet/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..07e5e927c6 --- /dev/null +++ b/docs/examples/1.8.x/server-dotnet/examples/tables/upsert-rows.md @@ -0,0 +1,15 @@ +using Appwrite; +using Appwrite.Models; +using Appwrite.Services; + +Client client = new Client() + .SetEndPoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .SetAdmin("") // + .SetKey(""); // Your secret API key + +Tables tables = new Tables(client); + +RowList result = await tables.UpsertRows( + databaseId: "", + tableId: "" +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..70a666257f --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-boolean-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateBooleanColumn( + "", + "", + "", + false, + tables.WithCreateBooleanColumnDefault(false), + tables.WithCreateBooleanColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..beb8bd09e6 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-datetime-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateDatetimeColumn( + "", + "", + "", + false, + tables.WithCreateDatetimeColumnDefault(""), + tables.WithCreateDatetimeColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-email-column.md new file mode 100644 index 0000000000..449cc0e88a --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-email-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateEmailColumn( + "", + "", + "", + false, + tables.WithCreateEmailColumnDefault("email@example.com"), + tables.WithCreateEmailColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..8f3bb84bb7 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-enum-column.md @@ -0,0 +1,32 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateEnumColumn( + "", + "", + "", + []interface{}{}, + false, + tables.WithCreateEnumColumnDefault(""), + tables.WithCreateEnumColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-float-column.md new file mode 100644 index 0000000000..eeabd851b9 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-float-column.md @@ -0,0 +1,33 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateFloatColumn( + "", + "", + "", + false, + tables.WithCreateFloatColumnMin(0), + tables.WithCreateFloatColumnMax(0), + tables.WithCreateFloatColumnDefault(0), + tables.WithCreateFloatColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-index.md b/docs/examples/1.8.x/server-go/examples/tables/create-index.md new file mode 100644 index 0000000000..1737b29f6f --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-index.md @@ -0,0 +1,32 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateIndex( + "", + "", + "", + "key", + []interface{}{}, + tables.WithCreateIndexOrders([]interface{}{}), + tables.WithCreateIndexLengths([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..45a81f6415 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-integer-column.md @@ -0,0 +1,33 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateIntegerColumn( + "", + "", + "", + false, + tables.WithCreateIntegerColumnMin(0), + tables.WithCreateIntegerColumnMax(0), + tables.WithCreateIntegerColumnDefault(0), + tables.WithCreateIntegerColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..f6d203d65e --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-ip-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateIpColumn( + "", + "", + "", + false, + tables.WithCreateIpColumnDefault(""), + tables.WithCreateIpColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..e2e6de59de --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-relationship-column.md @@ -0,0 +1,33 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateRelationshipColumn( + "", + "", + "", + "oneToOne", + tables.WithCreateRelationshipColumnTwoWay(false), + tables.WithCreateRelationshipColumnKey(""), + tables.WithCreateRelationshipColumnTwoWayKey(""), + tables.WithCreateRelationshipColumnOnDelete("cascade"), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-row.md b/docs/examples/1.8.x/server-go/examples/tables/create-row.md new file mode 100644 index 0000000000..329f2a1c9c --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-row.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithSession("") // The user session to authenticate with + client.WithKey("") // Your secret API key + client.WithJWT("") // Your secret JSON Web Token + ) + + service := tables.New(client) + response, error := service.CreateRow( + "", + "", + "", + map[string]interface{}{}, + tables.WithCreateRowPermissions(interface{}{"read("any")"}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-rows.md b/docs/examples/1.8.x/server-go/examples/tables/create-rows.md new file mode 100644 index 0000000000..7d32206bea --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-rows.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithAdmin("") // + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateRows( + "", + "", + []interface{}{}, + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-string-column.md new file mode 100644 index 0000000000..afb41e2728 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-string-column.md @@ -0,0 +1,33 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateStringColumn( + "", + "", + "", + 1, + false, + tables.WithCreateStringColumnDefault(""), + tables.WithCreateStringColumnArray(false), + tables.WithCreateStringColumnEncrypt(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-go/examples/tables/create-url-column.md new file mode 100644 index 0000000000..c4e30e30cd --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create-url-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.CreateUrlColumn( + "", + "", + "", + false, + tables.WithCreateUrlColumnDefault("https://example.com"), + tables.WithCreateUrlColumnArray(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/create.md b/docs/examples/1.8.x/server-go/examples/tables/create.md new file mode 100644 index 0000000000..672824daa6 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/create.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.Create( + "", + "", + "", + tables.WithCreatePermissions(interface{}{"read("any")"}), + tables.WithCreateRowSecurity(false), + tables.WithCreateEnabled(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-go/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..8ef1d26a59 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/decrement-row-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.DecrementRowColumn( + "", + "", + "", + "", + tables.WithDecrementRowColumnValue(0), + tables.WithDecrementRowColumnMin(0), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/delete-column.md b/docs/examples/1.8.x/server-go/examples/tables/delete-column.md new file mode 100644 index 0000000000..f66fc199c3 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/delete-column.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.DeleteColumn( + "", + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/delete-index.md b/docs/examples/1.8.x/server-go/examples/tables/delete-index.md new file mode 100644 index 0000000000..1dddeef4e8 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/delete-index.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.DeleteIndex( + "", + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/delete-row.md b/docs/examples/1.8.x/server-go/examples/tables/delete-row.md new file mode 100644 index 0000000000..9f55934e41 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/delete-row.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithSession("") // The user session to authenticate with + ) + + service := tables.New(client) + response, error := service.DeleteRow( + "", + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-go/examples/tables/delete-rows.md new file mode 100644 index 0000000000..3ad38f8067 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/delete-rows.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.DeleteRows( + "", + "", + tables.WithDeleteRowsQueries([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/delete.md b/docs/examples/1.8.x/server-go/examples/tables/delete.md new file mode 100644 index 0000000000..9637acc51d --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/delete.md @@ -0,0 +1,27 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.Delete( + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/get-column.md b/docs/examples/1.8.x/server-go/examples/tables/get-column.md new file mode 100644 index 0000000000..292d22800e --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/get-column.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.GetColumn( + "", + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/get-index.md b/docs/examples/1.8.x/server-go/examples/tables/get-index.md new file mode 100644 index 0000000000..077e823195 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/get-index.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.GetIndex( + "", + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/get-row.md b/docs/examples/1.8.x/server-go/examples/tables/get-row.md new file mode 100644 index 0000000000..a224c60d98 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/get-row.md @@ -0,0 +1,29 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithSession("") // The user session to authenticate with + ) + + service := tables.New(client) + response, error := service.GetRow( + "", + "", + "", + tables.WithGetRowQueries([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/get.md b/docs/examples/1.8.x/server-go/examples/tables/get.md new file mode 100644 index 0000000000..60304a8fd0 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/get.md @@ -0,0 +1,27 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.Get( + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-go/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..5d8b2f5578 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/increment-row-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.IncrementRowColumn( + "", + "", + "", + "", + tables.WithIncrementRowColumnValue(0), + tables.WithIncrementRowColumnMax(0), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/list-columns.md b/docs/examples/1.8.x/server-go/examples/tables/list-columns.md new file mode 100644 index 0000000000..25712ef2a7 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/list-columns.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.ListColumns( + "", + "", + tables.WithListColumnsQueries([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-go/examples/tables/list-indexes.md new file mode 100644 index 0000000000..0be8e81164 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/list-indexes.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.ListIndexes( + "", + "", + tables.WithListIndexesQueries([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/list-rows.md b/docs/examples/1.8.x/server-go/examples/tables/list-rows.md new file mode 100644 index 0000000000..aadbcf1dad --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/list-rows.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithSession("") // The user session to authenticate with + ) + + service := tables.New(client) + response, error := service.ListRows( + "", + "", + tables.WithListRowsQueries([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/list.md b/docs/examples/1.8.x/server-go/examples/tables/list.md new file mode 100644 index 0000000000..1942b7a2d2 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/list.md @@ -0,0 +1,28 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.List( + "", + tables.WithListQueries([]interface{}{}), + tables.WithListSearch(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..c76c3bb1cc --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-boolean-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateBooleanColumn( + "", + "", + "", + false, + false, + tables.WithUpdateBooleanColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..e093904ad5 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-datetime-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateDatetimeColumn( + "", + "", + "", + false, + "", + tables.WithUpdateDatetimeColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-email-column.md new file mode 100644 index 0000000000..08845b5149 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-email-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateEmailColumn( + "", + "", + "", + false, + "email@example.com", + tables.WithUpdateEmailColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..e639f850ba --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-enum-column.md @@ -0,0 +1,32 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateEnumColumn( + "", + "", + "", + []interface{}{}, + false, + "", + tables.WithUpdateEnumColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-float-column.md new file mode 100644 index 0000000000..83fa3777c2 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-float-column.md @@ -0,0 +1,33 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateFloatColumn( + "", + "", + "", + false, + 0, + tables.WithUpdateFloatColumnMin(0), + tables.WithUpdateFloatColumnMax(0), + tables.WithUpdateFloatColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..5bbea02709 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-integer-column.md @@ -0,0 +1,33 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateIntegerColumn( + "", + "", + "", + false, + 0, + tables.WithUpdateIntegerColumnMin(0), + tables.WithUpdateIntegerColumnMax(0), + tables.WithUpdateIntegerColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..f67711aaed --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-ip-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateIpColumn( + "", + "", + "", + false, + "", + tables.WithUpdateIpColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..1ec20edbb6 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-relationship-column.md @@ -0,0 +1,30 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateRelationshipColumn( + "", + "", + "", + tables.WithUpdateRelationshipColumnOnDelete("cascade"), + tables.WithUpdateRelationshipColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-row.md b/docs/examples/1.8.x/server-go/examples/tables/update-row.md new file mode 100644 index 0000000000..8ef1189769 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-row.md @@ -0,0 +1,30 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithSession("") // The user session to authenticate with + ) + + service := tables.New(client) + response, error := service.UpdateRow( + "", + "", + "", + tables.WithUpdateRowData(map[string]interface{}{}), + tables.WithUpdateRowPermissions(interface{}{"read("any")"}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-rows.md b/docs/examples/1.8.x/server-go/examples/tables/update-rows.md new file mode 100644 index 0000000000..7579e32851 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-rows.md @@ -0,0 +1,29 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateRows( + "", + "", + tables.WithUpdateRowsData(map[string]interface{}{}), + tables.WithUpdateRowsQueries([]interface{}{}), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-string-column.md new file mode 100644 index 0000000000..0a21b05e19 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-string-column.md @@ -0,0 +1,32 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateStringColumn( + "", + "", + "", + false, + "", + tables.WithUpdateStringColumnSize(1), + tables.WithUpdateStringColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-go/examples/tables/update-url-column.md new file mode 100644 index 0000000000..aeb0541648 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update-url-column.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpdateUrlColumn( + "", + "", + "", + false, + "https://example.com", + tables.WithUpdateUrlColumnNewKey(""), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/update.md b/docs/examples/1.8.x/server-go/examples/tables/update.md new file mode 100644 index 0000000000..7a75c10713 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/update.md @@ -0,0 +1,31 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithProject("") // Your project ID + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.Update( + "", + "", + "", + tables.WithUpdatePermissions(interface{}{"read("any")"}), + tables.WithUpdateRowSecurity(false), + tables.WithUpdateEnabled(false), + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-go/examples/tables/upsert-row.md new file mode 100644 index 0000000000..9bc9f00f8b --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/upsert-row.md @@ -0,0 +1,29 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithSession("") // The user session to authenticate with + client.WithKey("") // Your secret API key + client.WithJWT("") // Your secret JSON Web Token + ) + + service := tables.New(client) + response, error := service.UpsertRow( + "", + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-go/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-go/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..bc5a4db007 --- /dev/null +++ b/docs/examples/1.8.x/server-go/examples/tables/upsert-rows.md @@ -0,0 +1,27 @@ +package main + +import ( + "fmt" + "github.com/appwrite/sdk-for-go/client" + "github.com/appwrite/sdk-for-go/tables" +) + +func main() { + client := client.New( + client.WithEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + client.WithAdmin("") // + client.WithKey("") // Your secret API key + ) + + service := tables.New(client) + response, error := service.UpsertRows( + "", + "", + ) + + if error != nil { + panic(error) + } + + fmt.Println(response) +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..564b1a964c --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-boolean-column.md @@ -0,0 +1,20 @@ +mutation { + tablesCreateBooleanColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: false, + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..34055c27fa --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-datetime-column.md @@ -0,0 +1,21 @@ +mutation { + tablesCreateDatetimeColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-email-column.md new file mode 100644 index 0000000000..a45001d0be --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-email-column.md @@ -0,0 +1,21 @@ +mutation { + tablesCreateEmailColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "email@example.com", + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..5d1c516e3a --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-enum-column.md @@ -0,0 +1,23 @@ +mutation { + tablesCreateEnumColumn( + databaseId: "", + tableId: "", + key: "", + elements: [], + required: false, + default: "", + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + elements + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-float-column.md new file mode 100644 index 0000000000..09bf481a33 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-float-column.md @@ -0,0 +1,24 @@ +mutation { + tablesCreateFloatColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + min: 0, + max: 0, + default: 0, + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + min + max + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-index.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-index.md new file mode 100644 index 0000000000..bc47403c64 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-index.md @@ -0,0 +1,21 @@ +mutation { + tablesCreateIndex( + databaseId: "", + tableId: "", + key: "", + type: "key", + columns: [], + orders: [], + lengths: [] + ) { + key + type + status + error + columns + lengths + orders + _createdAt + _updatedAt + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..04273b18b5 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-integer-column.md @@ -0,0 +1,24 @@ +mutation { + tablesCreateIntegerColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + min: 0, + max: 0, + default: 0, + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + min + max + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..c2f07c760b --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-ip-column.md @@ -0,0 +1,21 @@ +mutation { + tablesCreateIpColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..8e56bd3867 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-relationship-column.md @@ -0,0 +1,27 @@ +mutation { + tablesCreateRelationshipColumn( + databaseId: "", + tableId: "", + relatedTableId: "", + type: "oneToOne", + twoWay: false, + key: "", + twoWayKey: "", + onDelete: "cascade" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + relatedTable + relationType + twoWay + twoWayKey + onDelete + side + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-row.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-row.md new file mode 100644 index 0000000000..c88a7f36cf --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-row.md @@ -0,0 +1,18 @@ +mutation { + tablesCreateRow( + databaseId: "", + tableId: "", + rowId: "", + data: "{}", + permissions: ["read("any")"] + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-rows.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-rows.md new file mode 100644 index 0000000000..a4ae62cfae --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-rows.md @@ -0,0 +1,19 @@ +mutation { + tablesCreateRows( + databaseId: "", + tableId: "", + rows: [] + ) { + total + rows { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-string-column.md new file mode 100644 index 0000000000..b0b11c2610 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-string-column.md @@ -0,0 +1,24 @@ +mutation { + tablesCreateStringColumn( + databaseId: "", + tableId: "", + key: "", + size: 1, + required: false, + default: "", + array: false, + encrypt: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + size + default + encrypt + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/create-url-column.md new file mode 100644 index 0000000000..134208b432 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create-url-column.md @@ -0,0 +1,21 @@ +mutation { + tablesCreateUrlColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "https://example.com", + array: false + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/create.md b/docs/examples/1.8.x/server-graphql/examples/tables/create.md new file mode 100644 index 0000000000..73af2c4a8c --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/create.md @@ -0,0 +1,31 @@ +mutation { + tablesCreate( + databaseId: "", + tableId: "", + name: "", + permissions: ["read("any")"], + rowSecurity: false, + enabled: false + ) { + _id + _createdAt + _updatedAt + _permissions + databaseId + name + enabled + rowSecurity + columns + indexes { + key + type + status + error + columns + lengths + orders + _createdAt + _updatedAt + } + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..4ee58849ff --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/decrement-row-column.md @@ -0,0 +1,19 @@ +mutation { + tablesDecrementRowColumn( + databaseId: "", + tableId: "", + rowId: "", + column: "", + value: 0, + min: 0 + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/delete-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/delete-column.md new file mode 100644 index 0000000000..2c2ab098d6 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/delete-column.md @@ -0,0 +1,9 @@ +mutation { + tablesDeleteColumn( + databaseId: "", + tableId: "", + key: "" + ) { + status + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/delete-index.md b/docs/examples/1.8.x/server-graphql/examples/tables/delete-index.md new file mode 100644 index 0000000000..c95db41fd6 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/delete-index.md @@ -0,0 +1,9 @@ +mutation { + tablesDeleteIndex( + databaseId: "", + tableId: "", + key: "" + ) { + status + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/delete-row.md b/docs/examples/1.8.x/server-graphql/examples/tables/delete-row.md new file mode 100644 index 0000000000..f3a35c1df1 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/delete-row.md @@ -0,0 +1,9 @@ +mutation { + tablesDeleteRow( + databaseId: "", + tableId: "", + rowId: "" + ) { + status + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-graphql/examples/tables/delete-rows.md new file mode 100644 index 0000000000..1ee227b7e5 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/delete-rows.md @@ -0,0 +1,19 @@ +mutation { + tablesDeleteRows( + databaseId: "", + tableId: "", + queries: [] + ) { + total + rows { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/delete.md b/docs/examples/1.8.x/server-graphql/examples/tables/delete.md new file mode 100644 index 0000000000..1749422f6a --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/delete.md @@ -0,0 +1,8 @@ +mutation { + tablesDelete( + databaseId: "", + tableId: "" + ) { + status + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/get-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/get-column.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/get-index.md b/docs/examples/1.8.x/server-graphql/examples/tables/get-index.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/get-row.md b/docs/examples/1.8.x/server-graphql/examples/tables/get-row.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/get.md b/docs/examples/1.8.x/server-graphql/examples/tables/get.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..f84f149672 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/increment-row-column.md @@ -0,0 +1,19 @@ +mutation { + tablesIncrementRowColumn( + databaseId: "", + tableId: "", + rowId: "", + column: "", + value: 0, + max: 0 + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/list-columns.md b/docs/examples/1.8.x/server-graphql/examples/tables/list-columns.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-graphql/examples/tables/list-indexes.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/list-rows.md b/docs/examples/1.8.x/server-graphql/examples/tables/list-rows.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/list.md b/docs/examples/1.8.x/server-graphql/examples/tables/list.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..541abd97cc --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-boolean-column.md @@ -0,0 +1,20 @@ +mutation { + tablesUpdateBooleanColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: false, + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..01714377a4 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-datetime-column.md @@ -0,0 +1,21 @@ +mutation { + tablesUpdateDatetimeColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-email-column.md new file mode 100644 index 0000000000..ffb3a21e66 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-email-column.md @@ -0,0 +1,21 @@ +mutation { + tablesUpdateEmailColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "email@example.com", + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..45ddb00d6f --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-enum-column.md @@ -0,0 +1,23 @@ +mutation { + tablesUpdateEnumColumn( + databaseId: "", + tableId: "", + key: "", + elements: [], + required: false, + default: "", + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + elements + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-float-column.md new file mode 100644 index 0000000000..f592a53858 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-float-column.md @@ -0,0 +1,24 @@ +mutation { + tablesUpdateFloatColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: 0, + min: 0, + max: 0, + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + min + max + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..a51f02d4d7 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-integer-column.md @@ -0,0 +1,24 @@ +mutation { + tablesUpdateIntegerColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: 0, + min: 0, + max: 0, + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + min + max + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..c353c79105 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-ip-column.md @@ -0,0 +1,21 @@ +mutation { + tablesUpdateIpColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..e94800345b --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-relationship-column.md @@ -0,0 +1,24 @@ +mutation { + tablesUpdateRelationshipColumn( + databaseId: "", + tableId: "", + key: "", + onDelete: "cascade", + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + relatedTable + relationType + twoWay + twoWayKey + onDelete + side + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-row.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-row.md new file mode 100644 index 0000000000..8449d8499b --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-row.md @@ -0,0 +1,18 @@ +mutation { + tablesUpdateRow( + databaseId: "", + tableId: "", + rowId: "", + data: "{}", + permissions: ["read("any")"] + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-rows.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-rows.md new file mode 100644 index 0000000000..510648f6e1 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-rows.md @@ -0,0 +1,20 @@ +mutation { + tablesUpdateRows( + databaseId: "", + tableId: "", + data: "{}", + queries: [] + ) { + total + rows { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-string-column.md new file mode 100644 index 0000000000..0771d9a6af --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-string-column.md @@ -0,0 +1,23 @@ +mutation { + tablesUpdateStringColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + size: 1, + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + size + default + encrypt + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-graphql/examples/tables/update-url-column.md new file mode 100644 index 0000000000..a5c4a4432d --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update-url-column.md @@ -0,0 +1,21 @@ +mutation { + tablesUpdateUrlColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "https://example.com", + newKey: "" + ) { + key + type + status + error + required + array + _createdAt + _updatedAt + format + default + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/update.md b/docs/examples/1.8.x/server-graphql/examples/tables/update.md new file mode 100644 index 0000000000..4aa434c3ed --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/update.md @@ -0,0 +1,31 @@ +mutation { + tablesUpdate( + databaseId: "", + tableId: "", + name: "", + permissions: ["read("any")"], + rowSecurity: false, + enabled: false + ) { + _id + _createdAt + _updatedAt + _permissions + databaseId + name + enabled + rowSecurity + columns + indexes { + key + type + status + error + columns + lengths + orders + _createdAt + _updatedAt + } + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-graphql/examples/tables/upsert-row.md new file mode 100644 index 0000000000..480d7651bd --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/upsert-row.md @@ -0,0 +1,16 @@ +mutation { + tablesUpsertRow( + databaseId: "", + tableId: "", + rowId: "" + ) { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } +} diff --git a/docs/examples/1.8.x/server-graphql/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-graphql/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..6015470c16 --- /dev/null +++ b/docs/examples/1.8.x/server-graphql/examples/tables/upsert-rows.md @@ -0,0 +1,18 @@ +mutation { + tablesUpsertRows( + databaseId: "", + tableId: "" + ) { + total + rows { + _id + _sequence + _tableId + _databaseId + _createdAt + _updatedAt + _permissions + data + } + } +} diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-boolean-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-boolean-column.md new file mode 100644 index 0000000000..2336ee90e0 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-boolean-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createBooleanColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + false, // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-datetime-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-datetime-column.md new file mode 100644 index 0000000000..dd3df83dbf --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-datetime-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createDatetimeColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "", // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-email-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-email-column.md new file mode 100644 index 0000000000..3b130d1ecd --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-email-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createEmailColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "email@example.com", // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-enum-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-enum-column.md new file mode 100644 index 0000000000..73c6e1c7de --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-enum-column.md @@ -0,0 +1,29 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createEnumColumn( + "", // databaseId + "", // tableId + "", // key + listOf(), // elements + false, // required + "", // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-float-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-float-column.md new file mode 100644 index 0000000000..dd6f207ff4 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-float-column.md @@ -0,0 +1,30 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createFloatColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + 0, // min (optional) + 0, // max (optional) + 0, // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-index.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-index.md new file mode 100644 index 0000000000..2a4df003c0 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-index.md @@ -0,0 +1,30 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; +import io.appwrite.enums.IndexType; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createIndex( + "", // databaseId + "", // tableId + "", // key + IndexType.KEY, // type + listOf(), // columns + listOf(), // orders (optional) + listOf(), // lengths (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-integer-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-integer-column.md new file mode 100644 index 0000000000..3546ac8174 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-integer-column.md @@ -0,0 +1,30 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createIntegerColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + 0, // min (optional) + 0, // max (optional) + 0, // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-ip-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-ip-column.md new file mode 100644 index 0000000000..825d8b0c5c --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-ip-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createIpColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "", // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-relationship-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-relationship-column.md new file mode 100644 index 0000000000..7a0b50a541 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-relationship-column.md @@ -0,0 +1,31 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; +import io.appwrite.enums.RelationshipType; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createRelationshipColumn( + "", // databaseId + "", // tableId + "", // relatedTableId + RelationshipType.ONETOONE, // type + false, // twoWay (optional) + "", // key (optional) + "", // twoWayKey (optional) + RelationMutate.CASCADE, // onDelete (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-row.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-row.md new file mode 100644 index 0000000000..7ba3678aad --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-row.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // Your secret API key + .setJWT(""); // Your secret JSON Web Token + +Tables tables = new Tables(client); + +tables.createRow( + "", // databaseId + "", // tableId + "", // rowId + mapOf( "a" to "b" ), // data + listOf("read("any")"), // permissions (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-rows.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-rows.md new file mode 100644 index 0000000000..c20aa2c11f --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-rows.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createRows( + "", // databaseId + "", // tableId + listOf(), // rows + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-string-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-string-column.md new file mode 100644 index 0000000000..b8cb626601 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-string-column.md @@ -0,0 +1,30 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createStringColumn( + "", // databaseId + "", // tableId + "", // key + 1, // size + false, // required + "", // default (optional) + false, // array (optional) + false, // encrypt (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create-url-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/create-url-column.md new file mode 100644 index 0000000000..91e90c8bc4 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create-url-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.createUrlColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "https://example.com", // default (optional) + false, // array (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/create.md b/docs/examples/1.8.x/server-kotlin/java/tables/create.md new file mode 100644 index 0000000000..6a9faf06dd --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/create.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.create( + "", // databaseId + "", // tableId + "", // name + listOf("read("any")"), // permissions (optional) + false, // rowSecurity (optional) + false, // enabled (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/decrement-row-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/decrement-row-column.md new file mode 100644 index 0000000000..9e79f36e14 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/decrement-row-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.decrementRowColumn( + "", // databaseId + "", // tableId + "", // rowId + "", // column + 0, // value (optional) + 0, // min (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/delete-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/delete-column.md new file mode 100644 index 0000000000..f14390c905 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/delete-column.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.deleteColumn( + "", // databaseId + "", // tableId + "", // key + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/delete-index.md b/docs/examples/1.8.x/server-kotlin/java/tables/delete-index.md new file mode 100644 index 0000000000..1b22eb00d8 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/delete-index.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.deleteIndex( + "", // databaseId + "", // tableId + "", // key + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/delete-row.md b/docs/examples/1.8.x/server-kotlin/java/tables/delete-row.md new file mode 100644 index 0000000000..a48745a225 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/delete-row.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +tables.deleteRow( + "", // databaseId + "", // tableId + "", // rowId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/delete-rows.md b/docs/examples/1.8.x/server-kotlin/java/tables/delete-rows.md new file mode 100644 index 0000000000..6a86321fad --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/delete-rows.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.deleteRows( + "", // databaseId + "", // tableId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/delete.md b/docs/examples/1.8.x/server-kotlin/java/tables/delete.md new file mode 100644 index 0000000000..e777c7292e --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/delete.md @@ -0,0 +1,24 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.delete( + "", // databaseId + "", // tableId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/get-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/get-column.md new file mode 100644 index 0000000000..b4f7e1298f --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/get-column.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.getColumn( + "", // databaseId + "", // tableId + "", // key + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/get-index.md b/docs/examples/1.8.x/server-kotlin/java/tables/get-index.md new file mode 100644 index 0000000000..5bcd59d4cd --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/get-index.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.getIndex( + "", // databaseId + "", // tableId + "", // key + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/get-row.md b/docs/examples/1.8.x/server-kotlin/java/tables/get-row.md new file mode 100644 index 0000000000..7f72c25cd8 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/get-row.md @@ -0,0 +1,26 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +tables.getRow( + "", // databaseId + "", // tableId + "", // rowId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/get.md b/docs/examples/1.8.x/server-kotlin/java/tables/get.md new file mode 100644 index 0000000000..6f3c639450 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/get.md @@ -0,0 +1,24 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.get( + "", // databaseId + "", // tableId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/increment-row-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/increment-row-column.md new file mode 100644 index 0000000000..f9c828398a --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/increment-row-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.incrementRowColumn( + "", // databaseId + "", // tableId + "", // rowId + "", // column + 0, // value (optional) + 0, // max (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/list-columns.md b/docs/examples/1.8.x/server-kotlin/java/tables/list-columns.md new file mode 100644 index 0000000000..05e1960021 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/list-columns.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.listColumns( + "", // databaseId + "", // tableId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/list-indexes.md b/docs/examples/1.8.x/server-kotlin/java/tables/list-indexes.md new file mode 100644 index 0000000000..c9bd445fe8 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/list-indexes.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.listIndexes( + "", // databaseId + "", // tableId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/list-rows.md b/docs/examples/1.8.x/server-kotlin/java/tables/list-rows.md new file mode 100644 index 0000000000..8cbc356556 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/list-rows.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +tables.listRows( + "", // databaseId + "", // tableId + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/list.md b/docs/examples/1.8.x/server-kotlin/java/tables/list.md new file mode 100644 index 0000000000..c3e0c559aa --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/list.md @@ -0,0 +1,25 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.list( + "", // databaseId + listOf(), // queries (optional) + "", // search (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-boolean-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-boolean-column.md new file mode 100644 index 0000000000..647190e7bc --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-boolean-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateBooleanColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + false, // default + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-datetime-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-datetime-column.md new file mode 100644 index 0000000000..38e0e60da5 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-datetime-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateDatetimeColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "", // default + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-email-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-email-column.md new file mode 100644 index 0000000000..918884e0b3 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-email-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateEmailColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "email@example.com", // default + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-enum-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-enum-column.md new file mode 100644 index 0000000000..b1bbc83520 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-enum-column.md @@ -0,0 +1,29 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateEnumColumn( + "", // databaseId + "", // tableId + "", // key + listOf(), // elements + false, // required + "", // default + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-float-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-float-column.md new file mode 100644 index 0000000000..977c23727c --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-float-column.md @@ -0,0 +1,30 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateFloatColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + 0, // default + 0, // min (optional) + 0, // max (optional) + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-integer-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-integer-column.md new file mode 100644 index 0000000000..d2ad81d0eb --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-integer-column.md @@ -0,0 +1,30 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateIntegerColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + 0, // default + 0, // min (optional) + 0, // max (optional) + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-ip-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-ip-column.md new file mode 100644 index 0000000000..cd6e67bc2c --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-ip-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateIpColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "", // default + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-relationship-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-relationship-column.md new file mode 100644 index 0000000000..e0dc185e0e --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-relationship-column.md @@ -0,0 +1,27 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateRelationshipColumn( + "", // databaseId + "", // tableId + "", // key + RelationMutate.CASCADE, // onDelete (optional) + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-row.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-row.md new file mode 100644 index 0000000000..8270c3fa9b --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-row.md @@ -0,0 +1,27 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession(""); // The user session to authenticate with + +Tables tables = new Tables(client); + +tables.updateRow( + "", // databaseId + "", // tableId + "", // rowId + mapOf( "a" to "b" ), // data (optional) + listOf("read("any")"), // permissions (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-rows.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-rows.md new file mode 100644 index 0000000000..a51878508f --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-rows.md @@ -0,0 +1,26 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateRows( + "", // databaseId + "", // tableId + mapOf( "a" to "b" ), // data (optional) + listOf(), // queries (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-string-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-string-column.md new file mode 100644 index 0000000000..31e279d068 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-string-column.md @@ -0,0 +1,29 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateStringColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "", // default + 1, // size (optional) + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update-url-column.md b/docs/examples/1.8.x/server-kotlin/java/tables/update-url-column.md new file mode 100644 index 0000000000..201e578ac6 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update-url-column.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.updateUrlColumn( + "", // databaseId + "", // tableId + "", // key + false, // required + "https://example.com", // default + "", // newKey (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/update.md b/docs/examples/1.8.x/server-kotlin/java/tables/update.md new file mode 100644 index 0000000000..cf560cb461 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/update.md @@ -0,0 +1,28 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.update( + "", // databaseId + "", // tableId + "", // name + listOf("read("any")"), // permissions (optional) + false, // rowSecurity (optional) + false, // enabled (optional) + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/upsert-row.md b/docs/examples/1.8.x/server-kotlin/java/tables/upsert-row.md new file mode 100644 index 0000000000..11127c5bfa --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/upsert-row.md @@ -0,0 +1,26 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // Your secret API key + .setJWT(""); // Your secret JSON Web Token + +Tables tables = new Tables(client); + +tables.upsertRow( + "", // databaseId + "", // tableId + "", // rowId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/java/tables/upsert-rows.md b/docs/examples/1.8.x/server-kotlin/java/tables/upsert-rows.md new file mode 100644 index 0000000000..14b382263b --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/java/tables/upsert-rows.md @@ -0,0 +1,24 @@ +import io.appwrite.Client; +import io.appwrite.coroutines.CoroutineCallback; +import io.appwrite.services.Tables; + +Client client = new Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey(""); // Your secret API key + +Tables tables = new Tables(client); + +tables.upsertRows( + "", // databaseId + "", // tableId + new CoroutineCallback<>((result, error) -> { + if (error != null) { + error.printStackTrace(); + return; + } + + System.out.println(result); + }) +); + diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-boolean-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-boolean-column.md new file mode 100644 index 0000000000..68b8dc51bd --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-boolean-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createBooleanColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = false, // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-datetime-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-datetime-column.md new file mode 100644 index 0000000000..8740a71d3c --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-datetime-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createDatetimeColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "", // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-email-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-email-column.md new file mode 100644 index 0000000000..34a6cb669f --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-email-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createEmailColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "email@example.com", // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-enum-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-enum-column.md new file mode 100644 index 0000000000..d3d2fc9286 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-enum-column.md @@ -0,0 +1,20 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createEnumColumn( + databaseId = "", + tableId = "", + key = "", + elements = listOf(), + required = false, + default = "", // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-float-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-float-column.md new file mode 100644 index 0000000000..8540430cea --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-float-column.md @@ -0,0 +1,21 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createFloatColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + min = 0, // optional + max = 0, // optional + default = 0, // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-index.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-index.md new file mode 100644 index 0000000000..053c88a93a --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-index.md @@ -0,0 +1,21 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables +import io.appwrite.enums.IndexType + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createIndex( + databaseId = "", + tableId = "", + key = "", + type = IndexType.KEY, + columns = listOf(), + orders = listOf(), // optional + lengths = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-integer-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-integer-column.md new file mode 100644 index 0000000000..1222746259 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-integer-column.md @@ -0,0 +1,21 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createIntegerColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + min = 0, // optional + max = 0, // optional + default = 0, // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-ip-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-ip-column.md new file mode 100644 index 0000000000..277c756d24 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-ip-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createIpColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "", // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-relationship-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-relationship-column.md new file mode 100644 index 0000000000..aa07fac6a8 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-relationship-column.md @@ -0,0 +1,22 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables +import io.appwrite.enums.RelationshipType + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createRelationshipColumn( + databaseId = "", + tableId = "", + relatedTableId = "", + type = RelationshipType.ONETOONE, + twoWay = false, // optional + key = "", // optional + twoWayKey = "", // optional + onDelete = "cascade" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-row.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-row.md new file mode 100644 index 0000000000..5df0890f99 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-row.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // Your secret API key + .setJWT("") // Your secret JSON Web Token + +val tables = Tables(client) + +val response = tables.createRow( + databaseId = "", + tableId = "", + rowId = "", + data = mapOf( "a" to "b" ), + permissions = listOf("read("any")") // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-rows.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-rows.md new file mode 100644 index 0000000000..f549d6fb8c --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-rows.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createRows( + databaseId = "", + tableId = "", + rows = listOf() +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-string-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-string-column.md new file mode 100644 index 0000000000..d82026c31d --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-string-column.md @@ -0,0 +1,21 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createStringColumn( + databaseId = "", + tableId = "", + key = "", + size = 1, + required = false, + default = "", // optional + array = false, // optional + encrypt = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-url-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-url-column.md new file mode 100644 index 0000000000..42f50e9ec9 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create-url-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.createUrlColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "https://example.com", // optional + array = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/create.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create.md new file mode 100644 index 0000000000..3dc1d1a37d --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/create.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.create( + databaseId = "", + tableId = "", + name = "", + permissions = listOf("read("any")"), // optional + rowSecurity = false, // optional + enabled = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/decrement-row-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/decrement-row-column.md new file mode 100644 index 0000000000..f78f7bbed7 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/decrement-row-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.decrementRowColumn( + databaseId = "", + tableId = "", + rowId = "", + column = "", + value = 0, // optional + min = 0 // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-column.md new file mode 100644 index 0000000000..d41f2ceabf --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-column.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.deleteColumn( + databaseId = "", + tableId = "", + key = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-index.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-index.md new file mode 100644 index 0000000000..7af6648f2f --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-index.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.deleteIndex( + databaseId = "", + tableId = "", + key = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-row.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-row.md new file mode 100644 index 0000000000..d182ccff95 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-row.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +val tables = Tables(client) + +val response = tables.deleteRow( + databaseId = "", + tableId = "", + rowId = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-rows.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-rows.md new file mode 100644 index 0000000000..54ff6b690c --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete-rows.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.deleteRows( + databaseId = "", + tableId = "", + queries = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete.md new file mode 100644 index 0000000000..5cbd03226a --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/delete.md @@ -0,0 +1,15 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.delete( + databaseId = "", + tableId = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-column.md new file mode 100644 index 0000000000..6f4d65b4dc --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-column.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.getColumn( + databaseId = "", + tableId = "", + key = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-index.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-index.md new file mode 100644 index 0000000000..660502f228 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-index.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.getIndex( + databaseId = "", + tableId = "", + key = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-row.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-row.md new file mode 100644 index 0000000000..cbaaa6c3e9 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get-row.md @@ -0,0 +1,17 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +val tables = Tables(client) + +val response = tables.getRow( + databaseId = "", + tableId = "", + rowId = "", + queries = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/get.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get.md new file mode 100644 index 0000000000..ff6d354c15 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/get.md @@ -0,0 +1,15 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.get( + databaseId = "", + tableId = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/increment-row-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/increment-row-column.md new file mode 100644 index 0000000000..7917b7f939 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/increment-row-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.incrementRowColumn( + databaseId = "", + tableId = "", + rowId = "", + column = "", + value = 0, // optional + max = 0 // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-columns.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-columns.md new file mode 100644 index 0000000000..4c1765193d --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-columns.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.listColumns( + databaseId = "", + tableId = "", + queries = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-indexes.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-indexes.md new file mode 100644 index 0000000000..bcd1fe75ab --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-indexes.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.listIndexes( + databaseId = "", + tableId = "", + queries = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-rows.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-rows.md new file mode 100644 index 0000000000..38b776acb8 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list-rows.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +val tables = Tables(client) + +val response = tables.listRows( + databaseId = "", + tableId = "", + queries = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/list.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list.md new file mode 100644 index 0000000000..37b03445da --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/list.md @@ -0,0 +1,16 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.list( + databaseId = "", + queries = listOf(), // optional + search = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-boolean-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-boolean-column.md new file mode 100644 index 0000000000..10a0422d2d --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-boolean-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateBooleanColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = false, + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-datetime-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-datetime-column.md new file mode 100644 index 0000000000..69ccf0354e --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-datetime-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateDatetimeColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "", + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-email-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-email-column.md new file mode 100644 index 0000000000..593a89b4ce --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-email-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateEmailColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "email@example.com", + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-enum-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-enum-column.md new file mode 100644 index 0000000000..b672e3e155 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-enum-column.md @@ -0,0 +1,20 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateEnumColumn( + databaseId = "", + tableId = "", + key = "", + elements = listOf(), + required = false, + default = "", + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-float-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-float-column.md new file mode 100644 index 0000000000..005c4e64a5 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-float-column.md @@ -0,0 +1,21 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateFloatColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = 0, + min = 0, // optional + max = 0, // optional + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-integer-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-integer-column.md new file mode 100644 index 0000000000..39da19d562 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-integer-column.md @@ -0,0 +1,21 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateIntegerColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = 0, + min = 0, // optional + max = 0, // optional + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-ip-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-ip-column.md new file mode 100644 index 0000000000..40e54bcdfd --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-ip-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateIpColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "", + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-relationship-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-relationship-column.md new file mode 100644 index 0000000000..d4c36e8802 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-relationship-column.md @@ -0,0 +1,18 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateRelationshipColumn( + databaseId = "", + tableId = "", + key = "", + onDelete = "cascade", // optional + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-row.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-row.md new file mode 100644 index 0000000000..6d3d9a47f7 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-row.md @@ -0,0 +1,18 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +val tables = Tables(client) + +val response = tables.updateRow( + databaseId = "", + tableId = "", + rowId = "", + data = mapOf( "a" to "b" ), // optional + permissions = listOf("read("any")") // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-rows.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-rows.md new file mode 100644 index 0000000000..aac87c19b0 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-rows.md @@ -0,0 +1,17 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateRows( + databaseId = "", + tableId = "", + data = mapOf( "a" to "b" ), // optional + queries = listOf() // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-string-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-string-column.md new file mode 100644 index 0000000000..bb5b1f4bcf --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-string-column.md @@ -0,0 +1,20 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateStringColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "", + size = 1, // optional + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-url-column.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-url-column.md new file mode 100644 index 0000000000..07f43e3907 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update-url-column.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.updateUrlColumn( + databaseId = "", + tableId = "", + key = "", + required = false, + default = "https://example.com", + newKey = "" // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/update.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update.md new file mode 100644 index 0000000000..381532316d --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/update.md @@ -0,0 +1,19 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.update( + databaseId = "", + tableId = "", + name = "", + permissions = listOf("read("any")"), // optional + rowSecurity = false, // optional + enabled = false // optional +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/upsert-row.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/upsert-row.md new file mode 100644 index 0000000000..6e02b3abe9 --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/upsert-row.md @@ -0,0 +1,17 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // Your secret API key + .setJWT("") // Your secret JSON Web Token + +val tables = Tables(client) + +val response = tables.upsertRow( + databaseId = "", + tableId = "", + rowId = "" +) diff --git a/docs/examples/1.8.x/server-kotlin/kotlin/tables/upsert-rows.md b/docs/examples/1.8.x/server-kotlin/kotlin/tables/upsert-rows.md new file mode 100644 index 0000000000..d639e3d30b --- /dev/null +++ b/docs/examples/1.8.x/server-kotlin/kotlin/tables/upsert-rows.md @@ -0,0 +1,15 @@ +import io.appwrite.Client +import io.appwrite.coroutines.CoroutineCallback +import io.appwrite.services.Tables + +val client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey("") // Your secret API key + +val tables = Tables(client) + +val response = tables.upsertRows( + databaseId = "", + tableId = "" +) diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..64893d77a8 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-boolean-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createBooleanColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + false, // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..0d63244727 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-datetime-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createDatetimeColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-email-column.md new file mode 100644 index 0000000000..2257fdd7d6 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-email-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createEmailColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'email@example.com', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..dbc75feea5 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-enum-column.md @@ -0,0 +1,18 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createEnumColumn( + '', // databaseId + '', // tableId + '', // key + [], // elements + false, // required + '', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-float-column.md new file mode 100644 index 0000000000..690b5849eb --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-float-column.md @@ -0,0 +1,19 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createFloatColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // min (optional) + null, // max (optional) + null, // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-index.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-index.md new file mode 100644 index 0000000000..aef047ba5f --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-index.md @@ -0,0 +1,18 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createIndex( + '', // databaseId + '', // tableId + '', // key + sdk.IndexType.Key, // type + [], // columns + [], // orders (optional) + [] // lengths (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..05e66b548c --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-integer-column.md @@ -0,0 +1,19 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createIntegerColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // min (optional) + null, // max (optional) + null, // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..69b5c635d2 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-ip-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createIpColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..b6e7fa517f --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-relationship-column.md @@ -0,0 +1,19 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createRelationshipColumn( + '', // databaseId + '', // tableId + '', // relatedTableId + sdk.RelationshipType.OneToOne, // type + false, // twoWay (optional) + '', // key (optional) + '', // twoWayKey (optional) + sdk.RelationMutate.Cascade // onDelete (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-row.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-row.md new file mode 100644 index 0000000000..84da608d41 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-row.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +const tables = new sdk.Tables(client); + +const result = await tables.createRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data + ["read("any")"] // permissions (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-rows.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-rows.md new file mode 100644 index 0000000000..6a6918b8df --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-rows.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createRows( + '', // databaseId + '', // tableId + [] // rows +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-string-column.md new file mode 100644 index 0000000000..8e14cb45c9 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-string-column.md @@ -0,0 +1,19 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createStringColumn( + '', // databaseId + '', // tableId + '', // key + 1, // size + false, // required + '', // default (optional) + false, // array (optional) + false // encrypt (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create-url-column.md new file mode 100644 index 0000000000..73cdfa3710 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create-url-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.createUrlColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'https://example.com', // default (optional) + false // array (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/create.md b/docs/examples/1.8.x/server-nodejs/examples/tables/create.md new file mode 100644 index 0000000000..54d6bc61bd --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/create.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.create( + '', // databaseId + '', // tableId + '', // name + ["read("any")"], // permissions (optional) + false, // rowSecurity (optional) + false // enabled (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..2e7df6aa92 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/decrement-row-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.decrementRowColumn( + '', // databaseId + '', // tableId + '', // rowId + '', // column + null, // value (optional) + null // min (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/delete-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-column.md new file mode 100644 index 0000000000..a892c61baa --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-column.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.deleteColumn( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/delete-index.md b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-index.md new file mode 100644 index 0000000000..f6bc7919db --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-index.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.deleteIndex( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/delete-row.md b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-row.md new file mode 100644 index 0000000000..5bc60cd6cb --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-row.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new sdk.Tables(client); + +const result = await tables.deleteRow( + '', // databaseId + '', // tableId + '' // rowId +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-rows.md new file mode 100644 index 0000000000..11b16b71ae --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/delete-rows.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.deleteRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/delete.md b/docs/examples/1.8.x/server-nodejs/examples/tables/delete.md new file mode 100644 index 0000000000..fed3eee5a4 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/delete.md @@ -0,0 +1,13 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.delete( + '', // databaseId + '' // tableId +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/get-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/get-column.md new file mode 100644 index 0000000000..daa20e17e2 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/get-column.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.getColumn( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/get-index.md b/docs/examples/1.8.x/server-nodejs/examples/tables/get-index.md new file mode 100644 index 0000000000..56ba871d67 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/get-index.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.getIndex( + '', // databaseId + '', // tableId + '' // key +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/get-row.md b/docs/examples/1.8.x/server-nodejs/examples/tables/get-row.md new file mode 100644 index 0000000000..df952d9595 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/get-row.md @@ -0,0 +1,15 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new sdk.Tables(client); + +const result = await tables.getRow( + '', // databaseId + '', // tableId + '', // rowId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/get.md b/docs/examples/1.8.x/server-nodejs/examples/tables/get.md new file mode 100644 index 0000000000..b078574b5c --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/get.md @@ -0,0 +1,13 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.get( + '', // databaseId + '' // tableId +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..bb5856c74a --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/increment-row-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.incrementRowColumn( + '', // databaseId + '', // tableId + '', // rowId + '', // column + null, // value (optional) + null // max (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/list-columns.md b/docs/examples/1.8.x/server-nodejs/examples/tables/list-columns.md new file mode 100644 index 0000000000..f9af43bea5 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/list-columns.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.listColumns( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-nodejs/examples/tables/list-indexes.md new file mode 100644 index 0000000000..7eaf4b8710 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/list-indexes.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.listIndexes( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/list-rows.md b/docs/examples/1.8.x/server-nodejs/examples/tables/list-rows.md new file mode 100644 index 0000000000..aa5b341649 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/list-rows.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new sdk.Tables(client); + +const result = await tables.listRows( + '', // databaseId + '', // tableId + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/list.md b/docs/examples/1.8.x/server-nodejs/examples/tables/list.md new file mode 100644 index 0000000000..872a98df08 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/list.md @@ -0,0 +1,14 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.list( + '', // databaseId + [], // queries (optional) + '' // search (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..84ff5d2bef --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-boolean-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateBooleanColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + false, // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..c02559a171 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-datetime-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateDatetimeColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-email-column.md new file mode 100644 index 0000000000..9560b60e29 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-email-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateEmailColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'email@example.com', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..861fce6add --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-enum-column.md @@ -0,0 +1,18 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateEnumColumn( + '', // databaseId + '', // tableId + '', // key + [], // elements + false, // required + '', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-float-column.md new file mode 100644 index 0000000000..01845ca3cc --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-float-column.md @@ -0,0 +1,19 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateFloatColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // default + null, // min (optional) + null, // max (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..0b7432247f --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-integer-column.md @@ -0,0 +1,19 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateIntegerColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + null, // default + null, // min (optional) + null, // max (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..6ba5eccf3e --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-ip-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateIpColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..3409b8caad --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-relationship-column.md @@ -0,0 +1,16 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateRelationshipColumn( + '', // databaseId + '', // tableId + '', // key + sdk.RelationMutate.Cascade, // onDelete (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-row.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-row.md new file mode 100644 index 0000000000..ff8e98eb38 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-row.md @@ -0,0 +1,16 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setSession(''); // The user session to authenticate with + +const tables = new sdk.Tables(client); + +const result = await tables.updateRow( + '', // databaseId + '', // tableId + '', // rowId + {}, // data (optional) + ["read("any")"] // permissions (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-rows.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-rows.md new file mode 100644 index 0000000000..72cef07202 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-rows.md @@ -0,0 +1,15 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateRows( + '', // databaseId + '', // tableId + {}, // data (optional) + [] // queries (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-string-column.md new file mode 100644 index 0000000000..f9445a50c1 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-string-column.md @@ -0,0 +1,18 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateStringColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + '', // default + 1, // size (optional) + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update-url-column.md new file mode 100644 index 0000000000..c6ffdf3044 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update-url-column.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.updateUrlColumn( + '', // databaseId + '', // tableId + '', // key + false, // required + 'https://example.com', // default + '' // newKey (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/update.md b/docs/examples/1.8.x/server-nodejs/examples/tables/update.md new file mode 100644 index 0000000000..4fd981ffbf --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/update.md @@ -0,0 +1,17 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setProject('') // Your project ID + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.update( + '', // databaseId + '', // tableId + '', // name + ["read("any")"], // permissions (optional) + false, // rowSecurity (optional) + false // enabled (optional) +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-nodejs/examples/tables/upsert-row.md new file mode 100644 index 0000000000..2b08d56785 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/upsert-row.md @@ -0,0 +1,15 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setSession('') // The user session to authenticate with + .setKey('') // Your secret API key + .setJWT(''); // Your secret JSON Web Token + +const tables = new sdk.Tables(client); + +const result = await tables.upsertRow( + '', // databaseId + '', // tableId + '' // rowId +); diff --git a/docs/examples/1.8.x/server-nodejs/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-nodejs/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..75d681dbf0 --- /dev/null +++ b/docs/examples/1.8.x/server-nodejs/examples/tables/upsert-rows.md @@ -0,0 +1,13 @@ +const sdk = require('node-appwrite'); + +const client = new sdk.Client() + .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + .setAdmin('') // + .setKey(''); // Your secret API key + +const tables = new sdk.Tables(client); + +const result = await tables.upsertRows( + '', // databaseId + '' // tableId +); diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..28339753ac --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-boolean-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createBooleanColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: false, // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..d7f18f2ede --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-datetime-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createDatetimeColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: '', // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-email-column.md new file mode 100644 index 0000000000..15ec2cf2e5 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-email-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createEmailColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: 'email@example.com', // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..aa2b6138f7 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-enum-column.md @@ -0,0 +1,21 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createEnumColumn( + databaseId: '', + tableId: '', + key: '', + elements: [], + required: false, + default: '', // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-float-column.md new file mode 100644 index 0000000000..1f620dc887 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-float-column.md @@ -0,0 +1,22 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createFloatColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + min: null, // optional + max: null, // optional + default: null, // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-index.md b/docs/examples/1.8.x/server-php/examples/tables/create-index.md new file mode 100644 index 0000000000..9844e041d4 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-index.md @@ -0,0 +1,22 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createIndex( + databaseId: '', + tableId: '', + key: '', + type: IndexType::KEY(), + columns: [], + orders: [], // optional + lengths: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..185f12c5cb --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-integer-column.md @@ -0,0 +1,22 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createIntegerColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + min: null, // optional + max: null, // optional + default: null, // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..1f74e4dd72 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-ip-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createIpColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: '', // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..c86b4c558a --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-relationship-column.md @@ -0,0 +1,23 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createRelationshipColumn( + databaseId: '', + tableId: '', + relatedTableId: '', + type: RelationshipType::ONETOONE(), + twoWay: false, // optional + key: '', // optional + twoWayKey: '', // optional + onDelete: RelationMutate::CASCADE() // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-row.md b/docs/examples/1.8.x/server-php/examples/tables/create-row.md new file mode 100644 index 0000000000..6b64a7e058 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-row.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setSession('') // The user session to authenticate with + ->setKey('') // Your secret API key + ->setJWT(''); // Your secret JSON Web Token + +$tables = new Tables($client); + +$result = $tables->createRow( + databaseId: '', + tableId: '', + rowId: '', + data: [], + permissions: ["read("any")"] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-rows.md b/docs/examples/1.8.x/server-php/examples/tables/create-rows.md new file mode 100644 index 0000000000..a1bf72ad13 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-rows.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setAdmin('') // + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createRows( + databaseId: '', + tableId: '', + rows: [] +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-string-column.md new file mode 100644 index 0000000000..085aff25c8 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-string-column.md @@ -0,0 +1,22 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createStringColumn( + databaseId: '', + tableId: '', + key: '', + size: 1, + required: false, + default: '', // optional + array: false, // optional + encrypt: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-php/examples/tables/create-url-column.md new file mode 100644 index 0000000000..d0bdb55dd4 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create-url-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->createUrlColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: 'https://example.com', // optional + array: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/create.md b/docs/examples/1.8.x/server-php/examples/tables/create.md new file mode 100644 index 0000000000..773d7a24eb --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/create.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->create( + databaseId: '', + tableId: '', + name: '', + permissions: ["read("any")"], // optional + rowSecurity: false, // optional + enabled: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-php/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..b0c44b6d0a --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/decrement-row-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->decrementRowColumn( + databaseId: '', + tableId: '', + rowId: '', + column: '', + value: null, // optional + min: null // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/delete-column.md b/docs/examples/1.8.x/server-php/examples/tables/delete-column.md new file mode 100644 index 0000000000..9bd6738cb7 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/delete-column.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->deleteColumn( + databaseId: '', + tableId: '', + key: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/delete-index.md b/docs/examples/1.8.x/server-php/examples/tables/delete-index.md new file mode 100644 index 0000000000..bbd748433a --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/delete-index.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->deleteIndex( + databaseId: '', + tableId: '', + key: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/delete-row.md b/docs/examples/1.8.x/server-php/examples/tables/delete-row.md new file mode 100644 index 0000000000..0c4ab6ef40 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/delete-row.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setSession(''); // The user session to authenticate with + +$tables = new Tables($client); + +$result = $tables->deleteRow( + databaseId: '', + tableId: '', + rowId: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-php/examples/tables/delete-rows.md new file mode 100644 index 0000000000..b0c984cc17 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/delete-rows.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->deleteRows( + databaseId: '', + tableId: '', + queries: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/delete.md b/docs/examples/1.8.x/server-php/examples/tables/delete.md new file mode 100644 index 0000000000..f145eedc91 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/delete.md @@ -0,0 +1,16 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->delete( + databaseId: '', + tableId: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/get-column.md b/docs/examples/1.8.x/server-php/examples/tables/get-column.md new file mode 100644 index 0000000000..b8b676564e --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/get-column.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->getColumn( + databaseId: '', + tableId: '', + key: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/get-index.md b/docs/examples/1.8.x/server-php/examples/tables/get-index.md new file mode 100644 index 0000000000..5d1139d596 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/get-index.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->getIndex( + databaseId: '', + tableId: '', + key: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/get-row.md b/docs/examples/1.8.x/server-php/examples/tables/get-row.md new file mode 100644 index 0000000000..ccde387b89 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/get-row.md @@ -0,0 +1,18 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setSession(''); // The user session to authenticate with + +$tables = new Tables($client); + +$result = $tables->getRow( + databaseId: '', + tableId: '', + rowId: '', + queries: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/get.md b/docs/examples/1.8.x/server-php/examples/tables/get.md new file mode 100644 index 0000000000..d07ef7338a --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/get.md @@ -0,0 +1,16 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->get( + databaseId: '', + tableId: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-php/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..aa5a3c0d53 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/increment-row-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->incrementRowColumn( + databaseId: '', + tableId: '', + rowId: '', + column: '', + value: null, // optional + max: null // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/list-columns.md b/docs/examples/1.8.x/server-php/examples/tables/list-columns.md new file mode 100644 index 0000000000..0338567240 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/list-columns.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->listColumns( + databaseId: '', + tableId: '', + queries: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-php/examples/tables/list-indexes.md new file mode 100644 index 0000000000..df1f8c6aca --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/list-indexes.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->listIndexes( + databaseId: '', + tableId: '', + queries: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/list-rows.md b/docs/examples/1.8.x/server-php/examples/tables/list-rows.md new file mode 100644 index 0000000000..2041d72b05 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/list-rows.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setSession(''); // The user session to authenticate with + +$tables = new Tables($client); + +$result = $tables->listRows( + databaseId: '', + tableId: '', + queries: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/list.md b/docs/examples/1.8.x/server-php/examples/tables/list.md new file mode 100644 index 0000000000..37df0a4baa --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/list.md @@ -0,0 +1,17 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->list( + databaseId: '', + queries: [], // optional + search: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..8ad80506d8 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-boolean-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateBooleanColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: false, + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..5185357f17 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-datetime-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateDatetimeColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: '', + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-email-column.md new file mode 100644 index 0000000000..7acbb811eb --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-email-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateEmailColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: 'email@example.com', + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..478905af67 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-enum-column.md @@ -0,0 +1,21 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateEnumColumn( + databaseId: '', + tableId: '', + key: '', + elements: [], + required: false, + default: '', + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-float-column.md new file mode 100644 index 0000000000..1d9c5fd997 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-float-column.md @@ -0,0 +1,22 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateFloatColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: null, + min: null, // optional + max: null, // optional + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..f6998db0a2 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-integer-column.md @@ -0,0 +1,22 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateIntegerColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: null, + min: null, // optional + max: null, // optional + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..e7906fbd0f --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-ip-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateIpColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: '', + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..d6505c77f1 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-relationship-column.md @@ -0,0 +1,19 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateRelationshipColumn( + databaseId: '', + tableId: '', + key: '', + onDelete: RelationMutate::CASCADE(), // optional + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-row.md b/docs/examples/1.8.x/server-php/examples/tables/update-row.md new file mode 100644 index 0000000000..921c43d935 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-row.md @@ -0,0 +1,19 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setSession(''); // The user session to authenticate with + +$tables = new Tables($client); + +$result = $tables->updateRow( + databaseId: '', + tableId: '', + rowId: '', + data: [], // optional + permissions: ["read("any")"] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-rows.md b/docs/examples/1.8.x/server-php/examples/tables/update-rows.md new file mode 100644 index 0000000000..f61fa2b17d --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-rows.md @@ -0,0 +1,18 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateRows( + databaseId: '', + tableId: '', + data: [], // optional + queries: [] // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-string-column.md new file mode 100644 index 0000000000..8856ec19c1 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-string-column.md @@ -0,0 +1,21 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateStringColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: '', + size: 1, // optional + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-php/examples/tables/update-url-column.md new file mode 100644 index 0000000000..faa46d1806 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update-url-column.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->updateUrlColumn( + databaseId: '', + tableId: '', + key: '', + required: false, + default: 'https://example.com', + newKey: '' // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/update.md b/docs/examples/1.8.x/server-php/examples/tables/update.md new file mode 100644 index 0000000000..39f076b8f8 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/update.md @@ -0,0 +1,20 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setProject('') // Your project ID + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->update( + databaseId: '', + tableId: '', + name: '', + permissions: ["read("any")"], // optional + rowSecurity: false, // optional + enabled: false // optional +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-php/examples/tables/upsert-row.md new file mode 100644 index 0000000000..2bddd9b5b3 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/upsert-row.md @@ -0,0 +1,18 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setSession('') // The user session to authenticate with + ->setKey('') // Your secret API key + ->setJWT(''); // Your secret JSON Web Token + +$tables = new Tables($client); + +$result = $tables->upsertRow( + databaseId: '', + tableId: '', + rowId: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-php/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-php/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..5ed5f028a9 --- /dev/null +++ b/docs/examples/1.8.x/server-php/examples/tables/upsert-rows.md @@ -0,0 +1,16 @@ +setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint + ->setAdmin('') // + ->setKey(''); // Your secret API key + +$tables = new Tables($client); + +$result = $tables->upsertRows( + databaseId: '', + tableId: '' +); \ No newline at end of file diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..cfbaa3b0ee --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-boolean-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_boolean_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = False, # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..a9f76b5e5f --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-datetime-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_datetime_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = '', # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-email-column.md new file mode 100644 index 0000000000..73ac0faad6 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-email-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_email_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = 'email@example.com', # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..2013c39fa0 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-enum-column.md @@ -0,0 +1,19 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_enum_column( + database_id = '', + table_id = '', + key = '', + elements = [], + required = False, + default = '', # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-float-column.md new file mode 100644 index 0000000000..a56a196093 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-float-column.md @@ -0,0 +1,20 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_float_column( + database_id = '', + table_id = '', + key = '', + required = False, + min = None, # optional + max = None, # optional + default = None, # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-index.md b/docs/examples/1.8.x/server-python/examples/tables/create-index.md new file mode 100644 index 0000000000..69086af0b0 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-index.md @@ -0,0 +1,20 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables +from appwrite.enums import IndexType + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_index( + database_id = '', + table_id = '', + key = '', + type = IndexType.KEY, + columns = [], + orders = [], # optional + lengths = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..d52b14bc5c --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-integer-column.md @@ -0,0 +1,20 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_integer_column( + database_id = '', + table_id = '', + key = '', + required = False, + min = None, # optional + max = None, # optional + default = None, # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..b5c7ef56db --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-ip-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_ip_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = '', # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..187271f887 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-relationship-column.md @@ -0,0 +1,21 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables +from appwrite.enums import RelationshipType + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_relationship_column( + database_id = '', + table_id = '', + related_table_id = '', + type = RelationshipType.ONETOONE, + two_way = False, # optional + key = '', # optional + two_way_key = '', # optional + on_delete = RelationMutate.CASCADE # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-row.md b/docs/examples/1.8.x/server-python/examples/tables/create-row.md new file mode 100644 index 0000000000..8850a974b8 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-row.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_session('') # The user session to authenticate with +client.set_key('') # Your secret API key +client.set_jwt('') # Your secret JSON Web Token + +tables = Tables(client) + +result = tables.create_row( + database_id = '', + table_id = '', + row_id = '', + data = {}, + permissions = ["read("any")"] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-rows.md b/docs/examples/1.8.x/server-python/examples/tables/create-rows.md new file mode 100644 index 0000000000..3fae165081 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-rows.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_admin('') # +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_rows( + database_id = '', + table_id = '', + rows = [] +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-string-column.md new file mode 100644 index 0000000000..1308fea2ad --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-string-column.md @@ -0,0 +1,20 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_string_column( + database_id = '', + table_id = '', + key = '', + size = 1, + required = False, + default = '', # optional + array = False, # optional + encrypt = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-python/examples/tables/create-url-column.md new file mode 100644 index 0000000000..f15c3e0574 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create-url-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create_url_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = 'https://example.com', # optional + array = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/create.md b/docs/examples/1.8.x/server-python/examples/tables/create.md new file mode 100644 index 0000000000..3a02843c4d --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/create.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.create( + database_id = '', + table_id = '', + name = '', + permissions = ["read("any")"], # optional + row_security = False, # optional + enabled = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-python/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..bf027d6e76 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/decrement-row-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.decrement_row_column( + database_id = '', + table_id = '', + row_id = '', + column = '', + value = None, # optional + min = None # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/delete-column.md b/docs/examples/1.8.x/server-python/examples/tables/delete-column.md new file mode 100644 index 0000000000..cf2dd6d5e5 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/delete-column.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.delete_column( + database_id = '', + table_id = '', + key = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/delete-index.md b/docs/examples/1.8.x/server-python/examples/tables/delete-index.md new file mode 100644 index 0000000000..5f78d1ce1d --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/delete-index.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.delete_index( + database_id = '', + table_id = '', + key = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/delete-row.md b/docs/examples/1.8.x/server-python/examples/tables/delete-row.md new file mode 100644 index 0000000000..40a8b09fcf --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/delete-row.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_session('') # The user session to authenticate with + +tables = Tables(client) + +result = tables.delete_row( + database_id = '', + table_id = '', + row_id = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-python/examples/tables/delete-rows.md new file mode 100644 index 0000000000..236aea1c9b --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/delete-rows.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.delete_rows( + database_id = '', + table_id = '', + queries = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/delete.md b/docs/examples/1.8.x/server-python/examples/tables/delete.md new file mode 100644 index 0000000000..de48bfc2b5 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/delete.md @@ -0,0 +1,14 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.delete( + database_id = '', + table_id = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/get-column.md b/docs/examples/1.8.x/server-python/examples/tables/get-column.md new file mode 100644 index 0000000000..4bd4617142 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/get-column.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.get_column( + database_id = '', + table_id = '', + key = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/get-index.md b/docs/examples/1.8.x/server-python/examples/tables/get-index.md new file mode 100644 index 0000000000..cf88017fbe --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/get-index.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.get_index( + database_id = '', + table_id = '', + key = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/get-row.md b/docs/examples/1.8.x/server-python/examples/tables/get-row.md new file mode 100644 index 0000000000..25fefb23fd --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/get-row.md @@ -0,0 +1,16 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_session('') # The user session to authenticate with + +tables = Tables(client) + +result = tables.get_row( + database_id = '', + table_id = '', + row_id = '', + queries = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/get.md b/docs/examples/1.8.x/server-python/examples/tables/get.md new file mode 100644 index 0000000000..789410cfb7 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/get.md @@ -0,0 +1,14 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.get( + database_id = '', + table_id = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-python/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..cfb923029e --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/increment-row-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.increment_row_column( + database_id = '', + table_id = '', + row_id = '', + column = '', + value = None, # optional + max = None # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/list-columns.md b/docs/examples/1.8.x/server-python/examples/tables/list-columns.md new file mode 100644 index 0000000000..d9c5b16468 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/list-columns.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.list_columns( + database_id = '', + table_id = '', + queries = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-python/examples/tables/list-indexes.md new file mode 100644 index 0000000000..0b0bb585e7 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/list-indexes.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.list_indexes( + database_id = '', + table_id = '', + queries = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/list-rows.md b/docs/examples/1.8.x/server-python/examples/tables/list-rows.md new file mode 100644 index 0000000000..2ece6f6cf7 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/list-rows.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_session('') # The user session to authenticate with + +tables = Tables(client) + +result = tables.list_rows( + database_id = '', + table_id = '', + queries = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/list.md b/docs/examples/1.8.x/server-python/examples/tables/list.md new file mode 100644 index 0000000000..55a99e996d --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/list.md @@ -0,0 +1,15 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.list( + database_id = '', + queries = [], # optional + search = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..1bc7a4afac --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-boolean-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_boolean_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = False, + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..157ff44a7b --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-datetime-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_datetime_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = '', + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-email-column.md new file mode 100644 index 0000000000..8b9e4cad36 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-email-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_email_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = 'email@example.com', + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..b46971beac --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-enum-column.md @@ -0,0 +1,19 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_enum_column( + database_id = '', + table_id = '', + key = '', + elements = [], + required = False, + default = '', + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-float-column.md new file mode 100644 index 0000000000..243a26f0aa --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-float-column.md @@ -0,0 +1,20 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_float_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = None, + min = None, # optional + max = None, # optional + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..99b55c17a7 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-integer-column.md @@ -0,0 +1,20 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_integer_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = None, + min = None, # optional + max = None, # optional + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..2fb470ae6e --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-ip-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_ip_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = '', + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..35a307c7e2 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-relationship-column.md @@ -0,0 +1,17 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_relationship_column( + database_id = '', + table_id = '', + key = '', + on_delete = RelationMutate.CASCADE, # optional + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-row.md b/docs/examples/1.8.x/server-python/examples/tables/update-row.md new file mode 100644 index 0000000000..4a71fc97f2 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-row.md @@ -0,0 +1,17 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_session('') # The user session to authenticate with + +tables = Tables(client) + +result = tables.update_row( + database_id = '', + table_id = '', + row_id = '', + data = {}, # optional + permissions = ["read("any")"] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-rows.md b/docs/examples/1.8.x/server-python/examples/tables/update-rows.md new file mode 100644 index 0000000000..a834346678 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-rows.md @@ -0,0 +1,16 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_rows( + database_id = '', + table_id = '', + data = {}, # optional + queries = [] # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-string-column.md new file mode 100644 index 0000000000..252c26433e --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-string-column.md @@ -0,0 +1,19 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_string_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = '', + size = 1, # optional + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-python/examples/tables/update-url-column.md new file mode 100644 index 0000000000..235e2f3bc4 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update-url-column.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update_url_column( + database_id = '', + table_id = '', + key = '', + required = False, + default = 'https://example.com', + new_key = '' # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/update.md b/docs/examples/1.8.x/server-python/examples/tables/update.md new file mode 100644 index 0000000000..c567bd5500 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/update.md @@ -0,0 +1,18 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_project('') # Your project ID +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.update( + database_id = '', + table_id = '', + name = '', + permissions = ["read("any")"], # optional + row_security = False, # optional + enabled = False # optional +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-python/examples/tables/upsert-row.md new file mode 100644 index 0000000000..e418708bc3 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/upsert-row.md @@ -0,0 +1,16 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_session('') # The user session to authenticate with +client.set_key('') # Your secret API key +client.set_jwt('') # Your secret JSON Web Token + +tables = Tables(client) + +result = tables.upsert_row( + database_id = '', + table_id = '', + row_id = '' +) diff --git a/docs/examples/1.8.x/server-python/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-python/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..85c2e94d69 --- /dev/null +++ b/docs/examples/1.8.x/server-python/examples/tables/upsert-rows.md @@ -0,0 +1,14 @@ +from appwrite.client import Client +from appwrite.services.tables import Tables + +client = Client() +client.set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint +client.set_admin('') # +client.set_key('') # Your secret API key + +tables = Tables(client) + +result = tables.upsert_rows( + database_id = '', + table_id = '' +) diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..4152d8538f --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-boolean-column.md @@ -0,0 +1,13 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/boolean HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "default": false, + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..d5318d96db --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-datetime-column.md @@ -0,0 +1,13 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/datetime HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "default": , + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-email-column.md new file mode 100644 index 0000000000..b213fa6ceb --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-email-column.md @@ -0,0 +1,13 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/email HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "default": "email@example.com", + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..125f617f1f --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-enum-column.md @@ -0,0 +1,14 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/enum HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "elements": [], + "required": false, + "default": "", + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-float-column.md new file mode 100644 index 0000000000..2e010318ff --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-float-column.md @@ -0,0 +1,15 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/float HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "min": 0, + "max": 0, + "default": 0, + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-index.md b/docs/examples/1.8.x/server-rest/examples/tables/create-index.md new file mode 100644 index 0000000000..eaddec973a --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-index.md @@ -0,0 +1,14 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/indexes HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "type": "key", + "columns": [], + "orders": [], + "lengths": [] +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..f284dc03ef --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-integer-column.md @@ -0,0 +1,15 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/integer HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "min": 0, + "max": 0, + "default": 0, + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..8def17fc27 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-ip-column.md @@ -0,0 +1,13 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/ip HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "default": , + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..d8feb21916 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-relationship-column.md @@ -0,0 +1,15 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/relationship HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "relatedTableId": "", + "type": "oneToOne", + "twoWay": false, + "key": , + "twoWayKey": , + "onDelete": "cascade" +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-row.md b/docs/examples/1.8.x/server-rest/examples/tables/create-row.md new file mode 100644 index 0000000000..075be16fa4 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-row.md @@ -0,0 +1,14 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: + +{ + "rowId": "", + "data": {}, + "permissions": ["read(\"any\")"] +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-rows.md b/docs/examples/1.8.x/server-rest/examples/tables/create-rows.md new file mode 100644 index 0000000000..ad3d6983cc --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-rows.md @@ -0,0 +1,12 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: + +{ + "rows": [] +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-string-column.md new file mode 100644 index 0000000000..e654a05e3a --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-string-column.md @@ -0,0 +1,15 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/string HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "size": 1, + "required": false, + "default": "", + "array": false, + "encrypt": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-rest/examples/tables/create-url-column.md new file mode 100644 index 0000000000..d98d77c68d --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create-url-column.md @@ -0,0 +1,13 @@ +POST /v1/databases/{databaseId}/tables/{tableId}/columns/url HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "key": , + "required": false, + "default": "https://example.com", + "array": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/create.md b/docs/examples/1.8.x/server-rest/examples/tables/create.md new file mode 100644 index 0000000000..14e1f6ec05 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/create.md @@ -0,0 +1,14 @@ +POST /v1/databases/{databaseId}/tables HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "tableId": "", + "name": "", + "permissions": ["read(\"any\")"], + "rowSecurity": false, + "enabled": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-rest/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..a76efb3a69 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/decrement-row-column.md @@ -0,0 +1,11 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId}/{column}/decrement HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "value": 0, + "min": 0 +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/delete-column.md b/docs/examples/1.8.x/server-rest/examples/tables/delete-column.md new file mode 100644 index 0000000000..2bda57366c --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/delete-column.md @@ -0,0 +1,7 @@ +DELETE /v1/databases/{databaseId}/tables/{tableId}/columns/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + diff --git a/docs/examples/1.8.x/server-rest/examples/tables/delete-index.md b/docs/examples/1.8.x/server-rest/examples/tables/delete-index.md new file mode 100644 index 0000000000..ffffc38c64 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/delete-index.md @@ -0,0 +1,7 @@ +DELETE /v1/databases/{databaseId}/tables/{tableId}/indexes/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + diff --git a/docs/examples/1.8.x/server-rest/examples/tables/delete-row.md b/docs/examples/1.8.x/server-rest/examples/tables/delete-row.md new file mode 100644 index 0000000000..f10adef821 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/delete-row.md @@ -0,0 +1,9 @@ +DELETE /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: + diff --git a/docs/examples/1.8.x/server-rest/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-rest/examples/tables/delete-rows.md new file mode 100644 index 0000000000..fcaf8fb472 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/delete-rows.md @@ -0,0 +1,10 @@ +DELETE /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "queries": [] +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/delete.md b/docs/examples/1.8.x/server-rest/examples/tables/delete.md new file mode 100644 index 0000000000..379bead1ad --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/delete.md @@ -0,0 +1,7 @@ +DELETE /v1/databases/{databaseId}/tables/{tableId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + diff --git a/docs/examples/1.8.x/server-rest/examples/tables/get-column.md b/docs/examples/1.8.x/server-rest/examples/tables/get-column.md new file mode 100644 index 0000000000..31d1856539 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/get-column.md @@ -0,0 +1,5 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/columns/{key} HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/get-index.md b/docs/examples/1.8.x/server-rest/examples/tables/get-index.md new file mode 100644 index 0000000000..076058d7f3 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/get-index.md @@ -0,0 +1,5 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/indexes/{key} HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/get-row.md b/docs/examples/1.8.x/server-rest/examples/tables/get-row.md new file mode 100644 index 0000000000..0b827f18a8 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/get-row.md @@ -0,0 +1,7 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/get.md b/docs/examples/1.8.x/server-rest/examples/tables/get.md new file mode 100644 index 0000000000..74877ec0c0 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/get.md @@ -0,0 +1,5 @@ +GET /v1/databases/{databaseId}/tables/{tableId} HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-rest/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..480645c39c --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/increment-row-column.md @@ -0,0 +1,11 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId}/{column}/increment HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "value": 0, + "max": 0 +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/list-columns.md b/docs/examples/1.8.x/server-rest/examples/tables/list-columns.md new file mode 100644 index 0000000000..152b36ca26 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/list-columns.md @@ -0,0 +1,5 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/columns HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-rest/examples/tables/list-indexes.md new file mode 100644 index 0000000000..ee10a85d5e --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/list-indexes.md @@ -0,0 +1,5 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/indexes HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/list-rows.md b/docs/examples/1.8.x/server-rest/examples/tables/list-rows.md new file mode 100644 index 0000000000..46e69ab609 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/list-rows.md @@ -0,0 +1,7 @@ +GET /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/list.md b/docs/examples/1.8.x/server-rest/examples/tables/list.md new file mode 100644 index 0000000000..e856ef7241 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/list.md @@ -0,0 +1,5 @@ +GET /v1/databases/{databaseId}/tables HTTP/1.1 +Host: cloud.appwrite.io +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..e4a1c4602a --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-boolean-column.md @@ -0,0 +1,12 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/boolean/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "default": false, + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..6b531dc604 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-datetime-column.md @@ -0,0 +1,12 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/datetime/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "default": , + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-email-column.md new file mode 100644 index 0000000000..531aa7a31a --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-email-column.md @@ -0,0 +1,12 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/email/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "default": "email@example.com", + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..b02936fc5a --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-enum-column.md @@ -0,0 +1,13 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/enum/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "elements": [], + "required": false, + "default": "", + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-float-column.md new file mode 100644 index 0000000000..313acb6c20 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-float-column.md @@ -0,0 +1,14 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/float/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "min": 0, + "max": 0, + "default": 0, + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..a2552e93ff --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-integer-column.md @@ -0,0 +1,14 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/integer/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "min": 0, + "max": 0, + "default": 0, + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..b3cef978e2 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-ip-column.md @@ -0,0 +1,12 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/ip/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "default": , + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..19fed27fdf --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-relationship-column.md @@ -0,0 +1,11 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/{key}/relationship HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "onDelete": "cascade", + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-row.md b/docs/examples/1.8.x/server-rest/examples/tables/update-row.md new file mode 100644 index 0000000000..20c92d746b --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-row.md @@ -0,0 +1,13 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: + +{ + "data": {}, + "permissions": ["read(\"any\")"] +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-rows.md b/docs/examples/1.8.x/server-rest/examples/tables/update-rows.md new file mode 100644 index 0000000000..249653070c --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-rows.md @@ -0,0 +1,11 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "data": {}, + "queries": [] +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-string-column.md new file mode 100644 index 0000000000..7a25ee52e8 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-string-column.md @@ -0,0 +1,13 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/string/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "default": "", + "size": 1, + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-rest/examples/tables/update-url-column.md new file mode 100644 index 0000000000..2097e91d85 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update-url-column.md @@ -0,0 +1,12 @@ +PATCH /v1/databases/{databaseId}/tables/{tableId}/columns/url/{key} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "required": false, + "default": "https://example.com", + "newKey": +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/update.md b/docs/examples/1.8.x/server-rest/examples/tables/update.md new file mode 100644 index 0000000000..786a36cf3c --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/update.md @@ -0,0 +1,13 @@ +PUT /v1/databases/{databaseId}/tables/{tableId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + +{ + "name": "", + "permissions": ["read(\"any\")"], + "rowSecurity": false, + "enabled": false +} diff --git a/docs/examples/1.8.x/server-rest/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-rest/examples/tables/upsert-row.md new file mode 100644 index 0000000000..7edca8018c --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/upsert-row.md @@ -0,0 +1,9 @@ +PUT /v1/databases/{databaseId}/tables/{tableId}/rows/{rowId} HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Session: +X-Appwrite-Key: +X-Appwrite-JWT: + diff --git a/docs/examples/1.8.x/server-rest/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-rest/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..cfcb914866 --- /dev/null +++ b/docs/examples/1.8.x/server-rest/examples/tables/upsert-rows.md @@ -0,0 +1,7 @@ +PUT /v1/databases/{databaseId}/tables/{tableId}/rows HTTP/1.1 +Host: cloud.appwrite.io +Content-Type: application/json +X-Appwrite-Response-Format: 1.7.0 +X-Appwrite-Project: +X-Appwrite-Key: + diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..7df3908513 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-boolean-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_boolean_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: false, # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..2d65509184 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-datetime-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_datetime_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: '', # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-email-column.md new file mode 100644 index 0000000000..01f7ad43b5 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-email-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_email_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: 'email@example.com', # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..97fcb589e4 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-enum-column.md @@ -0,0 +1,20 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_enum_column( + database_id: '', + table_id: '', + key: '', + elements: [], + required: false, + default: '', # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-float-column.md new file mode 100644 index 0000000000..9df32a3f5b --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-float-column.md @@ -0,0 +1,21 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_float_column( + database_id: '', + table_id: '', + key: '', + required: false, + min: null, # optional + max: null, # optional + default: null, # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-index.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-index.md new file mode 100644 index 0000000000..3c8dfdfb6b --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-index.md @@ -0,0 +1,21 @@ +require 'appwrite' + +include Appwrite +include Appwrite::Enums + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_index( + database_id: '', + table_id: '', + key: '', + type: IndexType::KEY, + columns: [], + orders: [], # optional + lengths: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..d0c5c78108 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-integer-column.md @@ -0,0 +1,21 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_integer_column( + database_id: '', + table_id: '', + key: '', + required: false, + min: null, # optional + max: null, # optional + default: null, # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..0c97840a27 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-ip-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_ip_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: '', # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..8f7fb841aa --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-relationship-column.md @@ -0,0 +1,22 @@ +require 'appwrite' + +include Appwrite +include Appwrite::Enums + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_relationship_column( + database_id: '', + table_id: '', + related_table_id: '', + type: RelationshipType::ONETOONE, + two_way: false, # optional + key: '', # optional + two_way_key: '', # optional + on_delete: RelationMutate::CASCADE # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-row.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-row.md new file mode 100644 index 0000000000..a625249700 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-row.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_session('') # The user session to authenticate with + .set_key('') # Your secret API key + .set_jwt('') # Your secret JSON Web Token + +tables = Tables.new(client) + +result = tables.create_row( + database_id: '', + table_id: '', + row_id: '', + data: {}, + permissions: ["read("any")"] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-rows.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-rows.md new file mode 100644 index 0000000000..2e78b96cbc --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-rows.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_admin('') # + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_rows( + database_id: '', + table_id: '', + rows: [] +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-string-column.md new file mode 100644 index 0000000000..d47cf49e0c --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-string-column.md @@ -0,0 +1,21 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_string_column( + database_id: '', + table_id: '', + key: '', + size: 1, + required: false, + default: '', # optional + array: false, # optional + encrypt: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/create-url-column.md new file mode 100644 index 0000000000..fcfebac7a8 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create-url-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create_url_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: 'https://example.com', # optional + array: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/create.md b/docs/examples/1.8.x/server-ruby/examples/tables/create.md new file mode 100644 index 0000000000..5a255fafac --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/create.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.create( + database_id: '', + table_id: '', + name: '', + permissions: ["read("any")"], # optional + row_security: false, # optional + enabled: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..e22afcb0ad --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/decrement-row-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.decrement_row_column( + database_id: '', + table_id: '', + row_id: '', + column: '', + value: null, # optional + min: null # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/delete-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/delete-column.md new file mode 100644 index 0000000000..245864053f --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/delete-column.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.delete_column( + database_id: '', + table_id: '', + key: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/delete-index.md b/docs/examples/1.8.x/server-ruby/examples/tables/delete-index.md new file mode 100644 index 0000000000..54bd5455aa --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/delete-index.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.delete_index( + database_id: '', + table_id: '', + key: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/delete-row.md b/docs/examples/1.8.x/server-ruby/examples/tables/delete-row.md new file mode 100644 index 0000000000..9841fc2d2f --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/delete-row.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_session('') # The user session to authenticate with + +tables = Tables.new(client) + +result = tables.delete_row( + database_id: '', + table_id: '', + row_id: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-ruby/examples/tables/delete-rows.md new file mode 100644 index 0000000000..7be1e4bc70 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/delete-rows.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.delete_rows( + database_id: '', + table_id: '', + queries: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/delete.md b/docs/examples/1.8.x/server-ruby/examples/tables/delete.md new file mode 100644 index 0000000000..ca607f2b6b --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/delete.md @@ -0,0 +1,15 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.delete( + database_id: '', + table_id: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/get-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/get-column.md new file mode 100644 index 0000000000..1a1469d005 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/get-column.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.get_column( + database_id: '', + table_id: '', + key: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/get-index.md b/docs/examples/1.8.x/server-ruby/examples/tables/get-index.md new file mode 100644 index 0000000000..7d762ce8ae --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/get-index.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.get_index( + database_id: '', + table_id: '', + key: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/get-row.md b/docs/examples/1.8.x/server-ruby/examples/tables/get-row.md new file mode 100644 index 0000000000..4526bb7316 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/get-row.md @@ -0,0 +1,17 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_session('') # The user session to authenticate with + +tables = Tables.new(client) + +result = tables.get_row( + database_id: '', + table_id: '', + row_id: '', + queries: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/get.md b/docs/examples/1.8.x/server-ruby/examples/tables/get.md new file mode 100644 index 0000000000..22ba02aebc --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/get.md @@ -0,0 +1,15 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.get( + database_id: '', + table_id: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..c0a91d4b62 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/increment-row-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.increment_row_column( + database_id: '', + table_id: '', + row_id: '', + column: '', + value: null, # optional + max: null # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/list-columns.md b/docs/examples/1.8.x/server-ruby/examples/tables/list-columns.md new file mode 100644 index 0000000000..7e851564c2 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/list-columns.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.list_columns( + database_id: '', + table_id: '', + queries: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-ruby/examples/tables/list-indexes.md new file mode 100644 index 0000000000..0789291071 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/list-indexes.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.list_indexes( + database_id: '', + table_id: '', + queries: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/list-rows.md b/docs/examples/1.8.x/server-ruby/examples/tables/list-rows.md new file mode 100644 index 0000000000..bc9a0a49f6 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/list-rows.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_session('') # The user session to authenticate with + +tables = Tables.new(client) + +result = tables.list_rows( + database_id: '', + table_id: '', + queries: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/list.md b/docs/examples/1.8.x/server-ruby/examples/tables/list.md new file mode 100644 index 0000000000..7cf987ebb9 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/list.md @@ -0,0 +1,16 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.list( + database_id: '', + queries: [], # optional + search: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..a09b365cd1 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-boolean-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_boolean_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: false, + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..55e0484b4c --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-datetime-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_datetime_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: '', + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-email-column.md new file mode 100644 index 0000000000..285cd6655a --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-email-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_email_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: 'email@example.com', + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..90773ed9e4 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-enum-column.md @@ -0,0 +1,20 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_enum_column( + database_id: '', + table_id: '', + key: '', + elements: [], + required: false, + default: '', + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-float-column.md new file mode 100644 index 0000000000..0bb992bd3c --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-float-column.md @@ -0,0 +1,21 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_float_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: null, + min: null, # optional + max: null, # optional + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..35f8c471a8 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-integer-column.md @@ -0,0 +1,21 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_integer_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: null, + min: null, # optional + max: null, # optional + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..2ad1840a9d --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-ip-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_ip_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: '', + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..de86fd53d7 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-relationship-column.md @@ -0,0 +1,18 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_relationship_column( + database_id: '', + table_id: '', + key: '', + on_delete: RelationMutate::CASCADE, # optional + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-row.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-row.md new file mode 100644 index 0000000000..500927dcf0 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-row.md @@ -0,0 +1,18 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_session('') # The user session to authenticate with + +tables = Tables.new(client) + +result = tables.update_row( + database_id: '', + table_id: '', + row_id: '', + data: {}, # optional + permissions: ["read("any")"] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-rows.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-rows.md new file mode 100644 index 0000000000..8cee1810be --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-rows.md @@ -0,0 +1,17 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_rows( + database_id: '', + table_id: '', + data: {}, # optional + queries: [] # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-string-column.md new file mode 100644 index 0000000000..2240f49555 --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-string-column.md @@ -0,0 +1,20 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_string_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: '', + size: 1, # optional + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-ruby/examples/tables/update-url-column.md new file mode 100644 index 0000000000..0947a78a9e --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update-url-column.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update_url_column( + database_id: '', + table_id: '', + key: '', + required: false, + default: 'https://example.com', + new_key: '' # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/update.md b/docs/examples/1.8.x/server-ruby/examples/tables/update.md new file mode 100644 index 0000000000..003d3d041c --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/update.md @@ -0,0 +1,19 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_project('') # Your project ID + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.update( + database_id: '', + table_id: '', + name: '', + permissions: ["read("any")"], # optional + row_security: false, # optional + enabled: false # optional +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-ruby/examples/tables/upsert-row.md new file mode 100644 index 0000000000..d96172e1ec --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/upsert-row.md @@ -0,0 +1,17 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_session('') # The user session to authenticate with + .set_key('') # Your secret API key + .set_jwt('') # Your secret JSON Web Token + +tables = Tables.new(client) + +result = tables.upsert_row( + database_id: '', + table_id: '', + row_id: '' +) diff --git a/docs/examples/1.8.x/server-ruby/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-ruby/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..8987b1ee0e --- /dev/null +++ b/docs/examples/1.8.x/server-ruby/examples/tables/upsert-rows.md @@ -0,0 +1,15 @@ +require 'appwrite' + +include Appwrite + +client = Client.new + .set_endpoint('https://.cloud.appwrite.io/v1') # Your API Endpoint + .set_admin('') # + .set_key('') # Your secret API key + +tables = Tables.new(client) + +result = tables.upsert_rows( + database_id: '', + table_id: '' +) diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-boolean-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-boolean-column.md new file mode 100644 index 0000000000..1b9627afac --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-boolean-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnBoolean = try await tables.createBooleanColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: false, // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-datetime-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-datetime-column.md new file mode 100644 index 0000000000..e002fb8042 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-datetime-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnDatetime = try await tables.createDatetimeColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-email-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-email-column.md new file mode 100644 index 0000000000..338493dbc5 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-email-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnEmail = try await tables.createEmailColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "email@example.com", // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-enum-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-enum-column.md new file mode 100644 index 0000000000..a6a9fff2c4 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-enum-column.md @@ -0,0 +1,19 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnEnum = try await tables.createEnumColumn( + databaseId: "", + tableId: "", + key: "", + elements: [], + required: false, + default: "", // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-float-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-float-column.md new file mode 100644 index 0000000000..12e4062454 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-float-column.md @@ -0,0 +1,20 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnFloat = try await tables.createFloatColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + min: 0, // optional + max: 0, // optional + default: 0, // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-index.md b/docs/examples/1.8.x/server-swift/examples/tables/create-index.md new file mode 100644 index 0000000000..03dea1ac48 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-index.md @@ -0,0 +1,20 @@ +import Appwrite +import AppwriteEnums + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnIndex = try await tables.createIndex( + databaseId: "", + tableId: "", + key: "", + type: .key, + columns: [], + orders: [], // optional + lengths: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-integer-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-integer-column.md new file mode 100644 index 0000000000..6c04294025 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-integer-column.md @@ -0,0 +1,20 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnInteger = try await tables.createIntegerColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + min: 0, // optional + max: 0, // optional + default: 0, // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-ip-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-ip-column.md new file mode 100644 index 0000000000..2cd0b2795f --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-ip-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnIp = try await tables.createIpColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-relationship-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-relationship-column.md new file mode 100644 index 0000000000..66b993cf9a --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-relationship-column.md @@ -0,0 +1,21 @@ +import Appwrite +import AppwriteEnums + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnRelationship = try await tables.createRelationshipColumn( + databaseId: "", + tableId: "", + relatedTableId: "", + type: .oneToOne, + twoWay: false, // optional + key: "", // optional + twoWayKey: "", // optional + onDelete: .cascade // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-row.md b/docs/examples/1.8.x/server-swift/examples/tables/create-row.md new file mode 100644 index 0000000000..a736355127 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-row.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // Your secret API key + .setJWT("") // Your secret JSON Web Token + +let tables = Tables(client) + +let row = try await tables.createRow( + databaseId: "", + tableId: "", + rowId: "", + data: [:], + permissions: ["read("any")"] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-rows.md b/docs/examples/1.8.x/server-swift/examples/tables/create-rows.md new file mode 100644 index 0000000000..ee2095f08f --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-rows.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey("") // Your secret API key + +let tables = Tables(client) + +let rowList = try await tables.createRows( + databaseId: "", + tableId: "", + rows: [] +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-string-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-string-column.md new file mode 100644 index 0000000000..e83ffdf367 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-string-column.md @@ -0,0 +1,20 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnString = try await tables.createStringColumn( + databaseId: "", + tableId: "", + key: "", + size: 1, + required: false, + default: "", // optional + array: false, // optional + encrypt: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create-url-column.md b/docs/examples/1.8.x/server-swift/examples/tables/create-url-column.md new file mode 100644 index 0000000000..150b51309d --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create-url-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnUrl = try await tables.createUrlColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "https://example.com", // optional + array: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/create.md b/docs/examples/1.8.x/server-swift/examples/tables/create.md new file mode 100644 index 0000000000..0843dfd242 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/create.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let table = try await tables.create( + databaseId: "", + tableId: "", + name: "", + permissions: ["read("any")"], // optional + rowSecurity: false, // optional + enabled: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/decrement-row-column.md b/docs/examples/1.8.x/server-swift/examples/tables/decrement-row-column.md new file mode 100644 index 0000000000..ef24324780 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/decrement-row-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let row = try await tables.decrementRowColumn( + databaseId: "", + tableId: "", + rowId: "", + column: "", + value: 0, // optional + min: 0 // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/delete-column.md b/docs/examples/1.8.x/server-swift/examples/tables/delete-column.md new file mode 100644 index 0000000000..07f825ddbe --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/delete-column.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let result = try await tables.deleteColumn( + databaseId: "", + tableId: "", + key: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/delete-index.md b/docs/examples/1.8.x/server-swift/examples/tables/delete-index.md new file mode 100644 index 0000000000..b6d2e5bfea --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/delete-index.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let result = try await tables.deleteIndex( + databaseId: "", + tableId: "", + key: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/delete-row.md b/docs/examples/1.8.x/server-swift/examples/tables/delete-row.md new file mode 100644 index 0000000000..92bc38777e --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/delete-row.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +let tables = Tables(client) + +let result = try await tables.deleteRow( + databaseId: "", + tableId: "", + rowId: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/delete-rows.md b/docs/examples/1.8.x/server-swift/examples/tables/delete-rows.md new file mode 100644 index 0000000000..d27fbce85f --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/delete-rows.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let rowList = try await tables.deleteRows( + databaseId: "", + tableId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/delete.md b/docs/examples/1.8.x/server-swift/examples/tables/delete.md new file mode 100644 index 0000000000..aefa1d8cda --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/delete.md @@ -0,0 +1,14 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let result = try await tables.delete( + databaseId: "", + tableId: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/get-column.md b/docs/examples/1.8.x/server-swift/examples/tables/get-column.md new file mode 100644 index 0000000000..653f79dce7 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/get-column.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let result = try await tables.getColumn( + databaseId: "", + tableId: "", + key: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/get-index.md b/docs/examples/1.8.x/server-swift/examples/tables/get-index.md new file mode 100644 index 0000000000..6835f56aa0 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/get-index.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnIndex = try await tables.getIndex( + databaseId: "", + tableId: "", + key: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/get-row.md b/docs/examples/1.8.x/server-swift/examples/tables/get-row.md new file mode 100644 index 0000000000..e2ff10f09a --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/get-row.md @@ -0,0 +1,16 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +let tables = Tables(client) + +let row = try await tables.getRow( + databaseId: "", + tableId: "", + rowId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/get.md b/docs/examples/1.8.x/server-swift/examples/tables/get.md new file mode 100644 index 0000000000..610bf42529 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/get.md @@ -0,0 +1,14 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let table = try await tables.get( + databaseId: "", + tableId: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/increment-row-column.md b/docs/examples/1.8.x/server-swift/examples/tables/increment-row-column.md new file mode 100644 index 0000000000..6ea883d612 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/increment-row-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let row = try await tables.incrementRowColumn( + databaseId: "", + tableId: "", + rowId: "", + column: "", + value: 0, // optional + max: 0 // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/list-columns.md b/docs/examples/1.8.x/server-swift/examples/tables/list-columns.md new file mode 100644 index 0000000000..88c86137a4 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/list-columns.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnList = try await tables.listColumns( + databaseId: "", + tableId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/list-indexes.md b/docs/examples/1.8.x/server-swift/examples/tables/list-indexes.md new file mode 100644 index 0000000000..2ea8e99eca --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/list-indexes.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnIndexList = try await tables.listIndexes( + databaseId: "", + tableId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/list-rows.md b/docs/examples/1.8.x/server-swift/examples/tables/list-rows.md new file mode 100644 index 0000000000..ca2e5b0d4b --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/list-rows.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +let tables = Tables(client) + +let rowList = try await tables.listRows( + databaseId: "", + tableId: "", + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/list.md b/docs/examples/1.8.x/server-swift/examples/tables/list.md new file mode 100644 index 0000000000..e135b50289 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/list.md @@ -0,0 +1,15 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let tableList = try await tables.list( + databaseId: "", + queries: [], // optional + search: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-boolean-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-boolean-column.md new file mode 100644 index 0000000000..e0d1ea2f9f --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-boolean-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnBoolean = try await tables.updateBooleanColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: false, + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-datetime-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-datetime-column.md new file mode 100644 index 0000000000..f09e27920b --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-datetime-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnDatetime = try await tables.updateDatetimeColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-email-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-email-column.md new file mode 100644 index 0000000000..f7b8cc4ede --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-email-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnEmail = try await tables.updateEmailColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "email@example.com", + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-enum-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-enum-column.md new file mode 100644 index 0000000000..776da72e59 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-enum-column.md @@ -0,0 +1,19 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnEnum = try await tables.updateEnumColumn( + databaseId: "", + tableId: "", + key: "", + elements: [], + required: false, + default: "", + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-float-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-float-column.md new file mode 100644 index 0000000000..d6cd34c4b5 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-float-column.md @@ -0,0 +1,20 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnFloat = try await tables.updateFloatColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: 0, + min: 0, // optional + max: 0, // optional + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-integer-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-integer-column.md new file mode 100644 index 0000000000..e1265cedbf --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-integer-column.md @@ -0,0 +1,20 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnInteger = try await tables.updateIntegerColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: 0, + min: 0, // optional + max: 0, // optional + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-ip-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-ip-column.md new file mode 100644 index 0000000000..4f3538bb7a --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-ip-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnIp = try await tables.updateIpColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-relationship-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-relationship-column.md new file mode 100644 index 0000000000..74bfd62750 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-relationship-column.md @@ -0,0 +1,18 @@ +import Appwrite +import AppwriteEnums + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnRelationship = try await tables.updateRelationshipColumn( + databaseId: "", + tableId: "", + key: "", + onDelete: .cascade, // optional + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-row.md b/docs/examples/1.8.x/server-swift/examples/tables/update-row.md new file mode 100644 index 0000000000..7fa81f6b58 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-row.md @@ -0,0 +1,17 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setSession("") // The user session to authenticate with + +let tables = Tables(client) + +let row = try await tables.updateRow( + databaseId: "", + tableId: "", + rowId: "", + data: [:], // optional + permissions: ["read("any")"] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-rows.md b/docs/examples/1.8.x/server-swift/examples/tables/update-rows.md new file mode 100644 index 0000000000..d7cd0697da --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-rows.md @@ -0,0 +1,16 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let rowList = try await tables.updateRows( + databaseId: "", + tableId: "", + data: [:], // optional + queries: [] // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-string-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-string-column.md new file mode 100644 index 0000000000..ba14d9a96a --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-string-column.md @@ -0,0 +1,19 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnString = try await tables.updateStringColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "", + size: 1, // optional + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update-url-column.md b/docs/examples/1.8.x/server-swift/examples/tables/update-url-column.md new file mode 100644 index 0000000000..19015e4c88 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update-url-column.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let columnUrl = try await tables.updateUrlColumn( + databaseId: "", + tableId: "", + key: "", + required: false, + default: "https://example.com", + newKey: "" // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/update.md b/docs/examples/1.8.x/server-swift/examples/tables/update.md new file mode 100644 index 0000000000..c9840a0a51 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/update.md @@ -0,0 +1,18 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setProject("") // Your project ID + .setKey("") // Your secret API key + +let tables = Tables(client) + +let table = try await tables.update( + databaseId: "", + tableId: "", + name: "", + permissions: ["read("any")"], // optional + rowSecurity: false, // optional + enabled: false // optional +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/upsert-row.md b/docs/examples/1.8.x/server-swift/examples/tables/upsert-row.md new file mode 100644 index 0000000000..c5c5b73afc --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/upsert-row.md @@ -0,0 +1,16 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setSession("") // The user session to authenticate with + .setKey("") // Your secret API key + .setJWT("") // Your secret JSON Web Token + +let tables = Tables(client) + +let row = try await tables.upsertRow( + databaseId: "", + tableId: "", + rowId: "" +) + diff --git a/docs/examples/1.8.x/server-swift/examples/tables/upsert-rows.md b/docs/examples/1.8.x/server-swift/examples/tables/upsert-rows.md new file mode 100644 index 0000000000..037d927dc9 --- /dev/null +++ b/docs/examples/1.8.x/server-swift/examples/tables/upsert-rows.md @@ -0,0 +1,14 @@ +import Appwrite + +let client = Client() + .setEndpoint("https://.cloud.appwrite.io/v1") // Your API Endpoint + .setAdmin("") // + .setKey("") // Your secret API key + +let tables = Tables(client) + +let rowList = try await tables.upsertRows( + databaseId: "", + tableId: "" +) +