diff --git a/README.md b/README.md
index 0aa839d..84aa27a 100644
--- a/README.md
+++ b/README.md
@@ -39,7 +39,7 @@ repositories {
Next, add the dependency to your project's `build.gradle(.kts)` file:
```groovy
-implementation("io.appwrite:sdk-for-kotlin:11.0.0")
+implementation("io.appwrite:sdk-for-kotlin:11.1.0")
```
### Maven
@@ -50,7 +50,7 @@ Add this to your project's `pom.xml` file:
io.appwrite
sdk-for-kotlin
- 11.0.0
+ 11.1.0
```
diff --git a/docs/examples/java/databases/create-line-attribute.md b/docs/examples/java/databases/create-line-attribute.md
index b8ff15a..ad988b8 100644
--- a/docs/examples/java/databases/create-line-attribute.md
+++ b/docs/examples/java/databases/create-line-attribute.md
@@ -14,7 +14,7 @@ databases.createLineAttribute(
"", // collectionId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([1, 2], [3, 4], [5, 6]), // default (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
error.printStackTrace();
diff --git a/docs/examples/java/databases/create-point-attribute.md b/docs/examples/java/databases/create-point-attribute.md
index f406461..89d7cc7 100644
--- a/docs/examples/java/databases/create-point-attribute.md
+++ b/docs/examples/java/databases/create-point-attribute.md
@@ -14,7 +14,7 @@ databases.createPointAttribute(
"", // collectionId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf(1, 2), // default (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
error.printStackTrace();
diff --git a/docs/examples/java/databases/create-polygon-attribute.md b/docs/examples/java/databases/create-polygon-attribute.md
index 2fc5e8b..556fb38 100644
--- a/docs/examples/java/databases/create-polygon-attribute.md
+++ b/docs/examples/java/databases/create-polygon-attribute.md
@@ -14,7 +14,7 @@ databases.createPolygonAttribute(
"", // collectionId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([[1, 2], [3, 4], [5, 6], [1, 2]]), // default (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
error.printStackTrace();
diff --git a/docs/examples/java/databases/update-line-attribute.md b/docs/examples/java/databases/update-line-attribute.md
index 3f41048..6a4265b 100644
--- a/docs/examples/java/databases/update-line-attribute.md
+++ b/docs/examples/java/databases/update-line-attribute.md
@@ -14,7 +14,7 @@ databases.updateLineAttribute(
"", // collectionId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([1, 2], [3, 4], [5, 6]), // default (optional)
"", // newKey (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
diff --git a/docs/examples/java/databases/update-point-attribute.md b/docs/examples/java/databases/update-point-attribute.md
index 7a8cb2a..38d48c2 100644
--- a/docs/examples/java/databases/update-point-attribute.md
+++ b/docs/examples/java/databases/update-point-attribute.md
@@ -14,7 +14,7 @@ databases.updatePointAttribute(
"", // collectionId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf(1, 2), // default (optional)
"", // newKey (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
diff --git a/docs/examples/java/databases/update-polygon-attribute.md b/docs/examples/java/databases/update-polygon-attribute.md
index 682e21d..6e6fd08 100644
--- a/docs/examples/java/databases/update-polygon-attribute.md
+++ b/docs/examples/java/databases/update-polygon-attribute.md
@@ -14,7 +14,7 @@ databases.updatePolygonAttribute(
"", // collectionId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([[1, 2], [3, 4], [5, 6], [1, 2]]), // default (optional)
"", // newKey (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
diff --git a/docs/examples/java/tablesdb/create-line-column.md b/docs/examples/java/tablesdb/create-line-column.md
index 96a0381..afe029e 100644
--- a/docs/examples/java/tablesdb/create-line-column.md
+++ b/docs/examples/java/tablesdb/create-line-column.md
@@ -14,7 +14,7 @@ tablesDB.createLineColumn(
"", // tableId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([1, 2], [3, 4], [5, 6]), // default (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
error.printStackTrace();
diff --git a/docs/examples/java/tablesdb/create-point-column.md b/docs/examples/java/tablesdb/create-point-column.md
index 51c0e64..2c9941b 100644
--- a/docs/examples/java/tablesdb/create-point-column.md
+++ b/docs/examples/java/tablesdb/create-point-column.md
@@ -14,7 +14,7 @@ tablesDB.createPointColumn(
"", // tableId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf(1, 2), // default (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
error.printStackTrace();
diff --git a/docs/examples/java/tablesdb/create-polygon-column.md b/docs/examples/java/tablesdb/create-polygon-column.md
index e5a6502..58ca798 100644
--- a/docs/examples/java/tablesdb/create-polygon-column.md
+++ b/docs/examples/java/tablesdb/create-polygon-column.md
@@ -14,7 +14,7 @@ tablesDB.createPolygonColumn(
"", // tableId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([[1, 2], [3, 4], [5, 6], [1, 2]]), // default (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
error.printStackTrace();
diff --git a/docs/examples/java/tablesdb/update-line-column.md b/docs/examples/java/tablesdb/update-line-column.md
index fbf151d..4c65a90 100644
--- a/docs/examples/java/tablesdb/update-line-column.md
+++ b/docs/examples/java/tablesdb/update-line-column.md
@@ -14,7 +14,7 @@ tablesDB.updateLineColumn(
"", // tableId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([1, 2], [3, 4], [5, 6]), // default (optional)
"", // newKey (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
diff --git a/docs/examples/java/tablesdb/update-point-column.md b/docs/examples/java/tablesdb/update-point-column.md
index f506e71..56ac86a 100644
--- a/docs/examples/java/tablesdb/update-point-column.md
+++ b/docs/examples/java/tablesdb/update-point-column.md
@@ -14,7 +14,7 @@ tablesDB.updatePointColumn(
"", // tableId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf(1, 2), // default (optional)
"", // newKey (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
diff --git a/docs/examples/java/tablesdb/update-polygon-column.md b/docs/examples/java/tablesdb/update-polygon-column.md
index e391aed..189d473 100644
--- a/docs/examples/java/tablesdb/update-polygon-column.md
+++ b/docs/examples/java/tablesdb/update-polygon-column.md
@@ -14,7 +14,7 @@ tablesDB.updatePolygonColumn(
"", // tableId
"", // key
false, // required
- listOf([1,2], [3, 4]), // default (optional)
+ listOf([[1, 2], [3, 4], [5, 6], [1, 2]]), // default (optional)
"", // newKey (optional)
new CoroutineCallback<>((result, error) -> {
if (error != null) {
diff --git a/docs/examples/kotlin/databases/create-line-attribute.md b/docs/examples/kotlin/databases/create-line-attribute.md
index 1b19637..af9a4d2 100644
--- a/docs/examples/kotlin/databases/create-line-attribute.md
+++ b/docs/examples/kotlin/databases/create-line-attribute.md
@@ -14,5 +14,5 @@ val response = databases.createLineAttribute(
collectionId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]) // optional
+ default = listOf([1, 2], [3, 4], [5, 6]) // optional
)
diff --git a/docs/examples/kotlin/databases/create-point-attribute.md b/docs/examples/kotlin/databases/create-point-attribute.md
index ed27944..04f095e 100644
--- a/docs/examples/kotlin/databases/create-point-attribute.md
+++ b/docs/examples/kotlin/databases/create-point-attribute.md
@@ -14,5 +14,5 @@ val response = databases.createPointAttribute(
collectionId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]) // optional
+ default = listOf(1, 2) // optional
)
diff --git a/docs/examples/kotlin/databases/create-polygon-attribute.md b/docs/examples/kotlin/databases/create-polygon-attribute.md
index 006c8e3..ffeb3c4 100644
--- a/docs/examples/kotlin/databases/create-polygon-attribute.md
+++ b/docs/examples/kotlin/databases/create-polygon-attribute.md
@@ -14,5 +14,5 @@ val response = databases.createPolygonAttribute(
collectionId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]) // optional
+ default = listOf([[1, 2], [3, 4], [5, 6], [1, 2]]) // optional
)
diff --git a/docs/examples/kotlin/databases/update-line-attribute.md b/docs/examples/kotlin/databases/update-line-attribute.md
index 3b5b78b..0d6b40a 100644
--- a/docs/examples/kotlin/databases/update-line-attribute.md
+++ b/docs/examples/kotlin/databases/update-line-attribute.md
@@ -14,6 +14,6 @@ val response = databases.updateLineAttribute(
collectionId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]), // optional
+ default = listOf([1, 2], [3, 4], [5, 6]), // optional
newKey = "" // optional
)
diff --git a/docs/examples/kotlin/databases/update-point-attribute.md b/docs/examples/kotlin/databases/update-point-attribute.md
index 2738fdb..68d5311 100644
--- a/docs/examples/kotlin/databases/update-point-attribute.md
+++ b/docs/examples/kotlin/databases/update-point-attribute.md
@@ -14,6 +14,6 @@ val response = databases.updatePointAttribute(
collectionId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]), // optional
+ default = listOf(1, 2), // optional
newKey = "" // optional
)
diff --git a/docs/examples/kotlin/databases/update-polygon-attribute.md b/docs/examples/kotlin/databases/update-polygon-attribute.md
index e2d97d8..66bbdea 100644
--- a/docs/examples/kotlin/databases/update-polygon-attribute.md
+++ b/docs/examples/kotlin/databases/update-polygon-attribute.md
@@ -14,6 +14,6 @@ val response = databases.updatePolygonAttribute(
collectionId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]), // optional
+ default = listOf([[1, 2], [3, 4], [5, 6], [1, 2]]), // optional
newKey = "" // optional
)
diff --git a/docs/examples/kotlin/tablesdb/create-line-column.md b/docs/examples/kotlin/tablesdb/create-line-column.md
index e867887..3dd9ebd 100644
--- a/docs/examples/kotlin/tablesdb/create-line-column.md
+++ b/docs/examples/kotlin/tablesdb/create-line-column.md
@@ -14,5 +14,5 @@ val response = tablesDB.createLineColumn(
tableId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]) // optional
+ default = listOf([1, 2], [3, 4], [5, 6]) // optional
)
diff --git a/docs/examples/kotlin/tablesdb/create-point-column.md b/docs/examples/kotlin/tablesdb/create-point-column.md
index 6340b37..7fd6ad7 100644
--- a/docs/examples/kotlin/tablesdb/create-point-column.md
+++ b/docs/examples/kotlin/tablesdb/create-point-column.md
@@ -14,5 +14,5 @@ val response = tablesDB.createPointColumn(
tableId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]) // optional
+ default = listOf(1, 2) // optional
)
diff --git a/docs/examples/kotlin/tablesdb/create-polygon-column.md b/docs/examples/kotlin/tablesdb/create-polygon-column.md
index d11c954..218b4cb 100644
--- a/docs/examples/kotlin/tablesdb/create-polygon-column.md
+++ b/docs/examples/kotlin/tablesdb/create-polygon-column.md
@@ -14,5 +14,5 @@ val response = tablesDB.createPolygonColumn(
tableId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]) // optional
+ default = listOf([[1, 2], [3, 4], [5, 6], [1, 2]]) // optional
)
diff --git a/docs/examples/kotlin/tablesdb/update-line-column.md b/docs/examples/kotlin/tablesdb/update-line-column.md
index 9f6d976..571d252 100644
--- a/docs/examples/kotlin/tablesdb/update-line-column.md
+++ b/docs/examples/kotlin/tablesdb/update-line-column.md
@@ -14,6 +14,6 @@ val response = tablesDB.updateLineColumn(
tableId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]), // optional
+ default = listOf([1, 2], [3, 4], [5, 6]), // optional
newKey = "" // optional
)
diff --git a/docs/examples/kotlin/tablesdb/update-point-column.md b/docs/examples/kotlin/tablesdb/update-point-column.md
index 4d28299..2230e59 100644
--- a/docs/examples/kotlin/tablesdb/update-point-column.md
+++ b/docs/examples/kotlin/tablesdb/update-point-column.md
@@ -14,6 +14,6 @@ val response = tablesDB.updatePointColumn(
tableId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]), // optional
+ default = listOf(1, 2), // optional
newKey = "" // optional
)
diff --git a/docs/examples/kotlin/tablesdb/update-polygon-column.md b/docs/examples/kotlin/tablesdb/update-polygon-column.md
index 0599559..db3a46b 100644
--- a/docs/examples/kotlin/tablesdb/update-polygon-column.md
+++ b/docs/examples/kotlin/tablesdb/update-polygon-column.md
@@ -14,6 +14,6 @@ val response = tablesDB.updatePolygonColumn(
tableId = "",
key = "",
required = false,
- default = listOf([1,2], [3, 4]), // optional
+ default = listOf([[1, 2], [3, 4], [5, 6], [1, 2]]), // optional
newKey = "" // optional
)
diff --git a/src/main/kotlin/io/appwrite/Client.kt b/src/main/kotlin/io/appwrite/Client.kt
index f5d1c6f..2caf253 100644
--- a/src/main/kotlin/io/appwrite/Client.kt
+++ b/src/main/kotlin/io/appwrite/Client.kt
@@ -58,11 +58,11 @@ class Client @JvmOverloads constructor(
init {
headers = mutableMapOf(
"content-type" to "application/json",
- "user-agent" to "AppwriteKotlinSDK/11.0.0 ${System.getProperty("http.agent")}",
+ "user-agent" to "AppwriteKotlinSDK/11.1.0 ${System.getProperty("http.agent")}",
"x-sdk-name" to "Kotlin",
"x-sdk-platform" to "server",
"x-sdk-language" to "kotlin",
- "x-sdk-version" to "11.0.0",
+ "x-sdk-version" to "11.1.0",
"x-appwrite-response-format" to "1.8.0",
)
diff --git a/src/main/kotlin/io/appwrite/Query.kt b/src/main/kotlin/io/appwrite/Query.kt
index 2a54439..717425c 100644
--- a/src/main/kotlin/io/appwrite/Query.kt
+++ b/src/main/kotlin/io/appwrite/Query.kt
@@ -41,6 +41,8 @@ class Query(
fun orderDesc(attribute: String) = Query("orderDesc", attribute).toJson()
+ fun orderRandom() = Query("orderRandom").toJson()
+
fun cursorBefore(documentId: String) = Query("cursorBefore", null, listOf(documentId)).toJson()
fun cursorAfter(documentId: String) = Query("cursorAfter", null, listOf(documentId)).toJson()
diff --git a/src/main/kotlin/io/appwrite/models/Deployment.kt b/src/main/kotlin/io/appwrite/models/Deployment.kt
index 9edb654..4c32b31 100644
--- a/src/main/kotlin/io/appwrite/models/Deployment.kt
+++ b/src/main/kotlin/io/appwrite/models/Deployment.kt
@@ -127,12 +127,6 @@ data class Deployment(
@SerializedName("providerRepositoryUrl")
val providerRepositoryUrl: String,
- /**
- * The branch of the vcs repository
- */
- @SerializedName("providerBranch")
- val providerBranch: String,
-
/**
* The commit hash of the vcs commit
*/
@@ -163,6 +157,12 @@ data class Deployment(
@SerializedName("providerCommitUrl")
val providerCommitUrl: String,
+ /**
+ * The branch of the vcs repository
+ */
+ @SerializedName("providerBranch")
+ val providerBranch: String,
+
/**
* The branch of the vcs repository
*/
@@ -191,12 +191,12 @@ data class Deployment(
"providerRepositoryName" to providerRepositoryName as Any,
"providerRepositoryOwner" to providerRepositoryOwner as Any,
"providerRepositoryUrl" to providerRepositoryUrl as Any,
- "providerBranch" to providerBranch as Any,
"providerCommitHash" to providerCommitHash as Any,
"providerCommitAuthorUrl" to providerCommitAuthorUrl as Any,
"providerCommitAuthor" to providerCommitAuthor as Any,
"providerCommitMessage" to providerCommitMessage as Any,
"providerCommitUrl" to providerCommitUrl as Any,
+ "providerBranch" to providerBranch as Any,
"providerBranchUrl" to providerBranchUrl as Any,
)
@@ -226,12 +226,12 @@ data class Deployment(
providerRepositoryName = map["providerRepositoryName"] as String,
providerRepositoryOwner = map["providerRepositoryOwner"] as String,
providerRepositoryUrl = map["providerRepositoryUrl"] as String,
- providerBranch = map["providerBranch"] as String,
providerCommitHash = map["providerCommitHash"] as String,
providerCommitAuthorUrl = map["providerCommitAuthorUrl"] as String,
providerCommitAuthor = map["providerCommitAuthor"] as String,
providerCommitMessage = map["providerCommitMessage"] as String,
providerCommitUrl = map["providerCommitUrl"] as String,
+ providerBranch = map["providerBranch"] as String,
providerBranchUrl = map["providerBranchUrl"] as String,
)
}
diff --git a/src/main/kotlin/io/appwrite/models/Execution.kt b/src/main/kotlin/io/appwrite/models/Execution.kt
index 8b395c6..3d71082 100644
--- a/src/main/kotlin/io/appwrite/models/Execution.kt
+++ b/src/main/kotlin/io/appwrite/models/Execution.kt
@@ -68,7 +68,7 @@ data class Execution(
val requestPath: String,
/**
- * HTTP response headers as a key-value object. This will return only whitelisted headers. All headers are returned if execution is created as synchronous.
+ * HTTP request headers as a key-value object. This will return only whitelisted headers. All headers are returned if execution is created as synchronous.
*/
@SerializedName("requestHeaders")
val requestHeaders: List,
diff --git a/src/main/kotlin/io/appwrite/models/HealthAntivirus.kt b/src/main/kotlin/io/appwrite/models/HealthAntivirus.kt
index 3fe3390..070a5ca 100644
--- a/src/main/kotlin/io/appwrite/models/HealthAntivirus.kt
+++ b/src/main/kotlin/io/appwrite/models/HealthAntivirus.kt
@@ -14,7 +14,7 @@ data class HealthAntivirus(
val version: String,
/**
- * Antivirus status. Possible values can are: `disabled`, `offline`, `online`
+ * Antivirus status. Possible values are: `disabled`, `offline`, `online`
*/
@SerializedName("status")
val status: String,
diff --git a/src/main/kotlin/io/appwrite/models/HealthStatus.kt b/src/main/kotlin/io/appwrite/models/HealthStatus.kt
index 6d0815d..ad309e5 100644
--- a/src/main/kotlin/io/appwrite/models/HealthStatus.kt
+++ b/src/main/kotlin/io/appwrite/models/HealthStatus.kt
@@ -20,7 +20,7 @@ data class HealthStatus(
val ping: Long,
/**
- * Service status. Possible values can are: `pass`, `fail`
+ * Service status. Possible values are: `pass`, `fail`
*/
@SerializedName("status")
val status: String,
diff --git a/src/main/kotlin/io/appwrite/services/TablesDb.kt b/src/main/kotlin/io/appwrite/services/TablesDb.kt
index f425598..855901f 100644
--- a/src/main/kotlin/io/appwrite/services/TablesDb.kt
+++ b/src/main/kotlin/io/appwrite/services/TablesDb.kt
@@ -2041,7 +2041,7 @@ class TablesDB(client: Client) : Service(client) {
*
* @param databaseId Database ID.
* @param tableId Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate). Make sure to define columns before creating rows.
- * @param rows Array of documents data as JSON objects.
+ * @param rows Array of rows data as JSON objects.
* @return [io.appwrite.models.RowList]
*/
@Throws(AppwriteException::class)
@@ -2079,7 +2079,7 @@ class TablesDB(client: Client) : Service(client) {
*
* @param databaseId Database ID.
* @param tableId Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate). Make sure to define columns before creating rows.
- * @param rows Array of documents data as JSON objects.
+ * @param rows Array of rows data as JSON objects.
* @return [io.appwrite.models.RowList]
*/
@Throws(AppwriteException::class)