doMerge branch '1.8.x' into update-examples

This commit is contained in:
Chirag Aggarwal 2025-09-05 22:36:54 +05:30
commit aaae6caa2c
38 changed files with 4317 additions and 2927 deletions

View file

@ -4830,7 +4830,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 340,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@ -4919,7 +4919,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 332,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@ -5069,7 +5069,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 333,
"weight": 332,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@ -5168,7 +5168,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 336,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@ -5316,7 +5316,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 334,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@ -5419,7 +5419,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 338,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@ -5507,7 +5507,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 343,
"weight": 342,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@ -5626,7 +5626,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 342,
"weight": 341,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@ -6010,7 +6010,7 @@
"x-appwrite": {
"method": "query",
"group": "graphql",
"weight": 255,
"weight": 254,
"cookies": false,
"type": "graphql",
"demo": "graphql\/query.md",
@ -6062,7 +6062,7 @@
"x-appwrite": {
"method": "mutation",
"group": "graphql",
"weight": 254,
"weight": 253,
"cookies": false,
"type": "graphql",
"demo": "graphql\/mutation.md",
@ -6530,7 +6530,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 301,
"weight": 300,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@ -6613,7 +6613,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 305,
"weight": 304,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@ -6688,7 +6688,7 @@
"x-appwrite": {
"method": "listFiles",
"group": "files",
"weight": 161,
"weight": 160,
"cookies": false,
"type": "",
"demo": "storage\/list-files.md",
@ -6774,7 +6774,7 @@
"x-appwrite": {
"method": "createFile",
"group": "files",
"weight": 160,
"weight": 159,
"cookies": false,
"type": "upload",
"demo": "storage\/create-file.md",
@ -6872,7 +6872,7 @@
"x-appwrite": {
"method": "getFile",
"group": "files",
"weight": 162,
"weight": 161,
"cookies": false,
"type": "",
"demo": "storage\/get-file.md",
@ -6944,7 +6944,7 @@
"x-appwrite": {
"method": "updateFile",
"group": "files",
"weight": 167,
"weight": 166,
"cookies": false,
"type": "",
"demo": "storage\/update-file.md",
@ -7033,7 +7033,7 @@
"x-appwrite": {
"method": "deleteFile",
"group": "files",
"weight": 168,
"weight": 167,
"cookies": false,
"type": "",
"demo": "storage\/delete-file.md",
@ -7100,7 +7100,7 @@
"x-appwrite": {
"method": "getFileDownload",
"group": "files",
"weight": 164,
"weight": 163,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-download.md",
@ -7178,7 +7178,7 @@
"x-appwrite": {
"method": "getFilePreview",
"group": "files",
"weight": 163,
"weight": 162,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-preview.md",
@ -7406,7 +7406,7 @@
"x-appwrite": {
"method": "getFileView",
"group": "files",
"weight": 165,
"weight": 164,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-view.md",
@ -7491,7 +7491,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 432,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@ -7579,7 +7579,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 424,
"weight": 423,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@ -7724,7 +7724,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 425,
"weight": 424,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@ -7822,7 +7822,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 428,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@ -7961,7 +7961,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 426,
"weight": 425,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@ -8063,7 +8063,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 430,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@ -8150,7 +8150,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 434,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@ -8268,7 +8268,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 434,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
@ -8386,7 +8386,7 @@
"x-appwrite": {
"method": "list",
"group": "teams",
"weight": 172,
"weight": 171,
"cookies": false,
"type": "",
"demo": "teams\/list.md",
@ -8462,7 +8462,7 @@
"x-appwrite": {
"method": "create",
"group": "teams",
"weight": 171,
"weight": 170,
"cookies": false,
"type": "",
"demo": "teams\/create.md",
@ -8547,7 +8547,7 @@
"x-appwrite": {
"method": "get",
"group": "teams",
"weight": 173,
"weight": 172,
"cookies": false,
"type": "",
"demo": "teams\/get.md",
@ -8609,7 +8609,7 @@
"x-appwrite": {
"method": "updateName",
"group": "teams",
"weight": 175,
"weight": 174,
"cookies": false,
"type": "",
"demo": "teams\/update-name.md",
@ -8683,7 +8683,7 @@
"x-appwrite": {
"method": "delete",
"group": "teams",
"weight": 177,
"weight": 176,
"cookies": false,
"type": "",
"demo": "teams\/delete.md",
@ -8747,7 +8747,7 @@
"x-appwrite": {
"method": "listMemberships",
"group": "memberships",
"weight": 179,
"weight": 178,
"cookies": false,
"type": "",
"demo": "teams\/list-memberships.md",
@ -8833,7 +8833,7 @@
"x-appwrite": {
"method": "createMembership",
"group": "memberships",
"weight": 178,
"weight": 177,
"cookies": false,
"type": "",
"demo": "teams\/create-membership.md",
@ -8944,7 +8944,7 @@
"x-appwrite": {
"method": "getMembership",
"group": "memberships",
"weight": 180,
"weight": 179,
"cookies": false,
"type": "",
"demo": "teams\/get-membership.md",
@ -9016,7 +9016,7 @@
"x-appwrite": {
"method": "updateMembership",
"group": "memberships",
"weight": 181,
"weight": 180,
"cookies": false,
"type": "",
"demo": "teams\/update-membership.md",
@ -9103,7 +9103,7 @@
"x-appwrite": {
"method": "deleteMembership",
"group": "memberships",
"weight": 183,
"weight": 182,
"cookies": false,
"type": "",
"demo": "teams\/delete-membership.md",
@ -9177,7 +9177,7 @@
"x-appwrite": {
"method": "updateMembershipStatus",
"group": "memberships",
"weight": 182,
"weight": 181,
"cookies": false,
"type": "",
"demo": "teams\/update-membership-status.md",
@ -9275,7 +9275,7 @@
"x-appwrite": {
"method": "getPrefs",
"group": "teams",
"weight": 174,
"weight": 173,
"cookies": false,
"type": "",
"demo": "teams\/get-prefs.md",
@ -9336,7 +9336,7 @@
"x-appwrite": {
"method": "updatePrefs",
"group": "teams",
"weight": 176,
"weight": 175,
"cookies": false,
"type": "",
"demo": "teams\/update-prefs.md",

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -4830,7 +4830,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 340,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@ -4919,7 +4919,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 332,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@ -5069,7 +5069,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 333,
"weight": 332,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@ -5168,7 +5168,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 336,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@ -5316,7 +5316,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 334,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@ -5419,7 +5419,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 338,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@ -5507,7 +5507,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 343,
"weight": 342,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@ -5626,7 +5626,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 342,
"weight": 341,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@ -6010,7 +6010,7 @@
"x-appwrite": {
"method": "query",
"group": "graphql",
"weight": 255,
"weight": 254,
"cookies": false,
"type": "graphql",
"demo": "graphql\/query.md",
@ -6062,7 +6062,7 @@
"x-appwrite": {
"method": "mutation",
"group": "graphql",
"weight": 254,
"weight": 253,
"cookies": false,
"type": "graphql",
"demo": "graphql\/mutation.md",
@ -6530,7 +6530,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 301,
"weight": 300,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@ -6613,7 +6613,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 305,
"weight": 304,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@ -6688,7 +6688,7 @@
"x-appwrite": {
"method": "listFiles",
"group": "files",
"weight": 161,
"weight": 160,
"cookies": false,
"type": "",
"demo": "storage\/list-files.md",
@ -6774,7 +6774,7 @@
"x-appwrite": {
"method": "createFile",
"group": "files",
"weight": 160,
"weight": 159,
"cookies": false,
"type": "upload",
"demo": "storage\/create-file.md",
@ -6872,7 +6872,7 @@
"x-appwrite": {
"method": "getFile",
"group": "files",
"weight": 162,
"weight": 161,
"cookies": false,
"type": "",
"demo": "storage\/get-file.md",
@ -6944,7 +6944,7 @@
"x-appwrite": {
"method": "updateFile",
"group": "files",
"weight": 167,
"weight": 166,
"cookies": false,
"type": "",
"demo": "storage\/update-file.md",
@ -7033,7 +7033,7 @@
"x-appwrite": {
"method": "deleteFile",
"group": "files",
"weight": 168,
"weight": 167,
"cookies": false,
"type": "",
"demo": "storage\/delete-file.md",
@ -7100,7 +7100,7 @@
"x-appwrite": {
"method": "getFileDownload",
"group": "files",
"weight": 164,
"weight": 163,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-download.md",
@ -7178,7 +7178,7 @@
"x-appwrite": {
"method": "getFilePreview",
"group": "files",
"weight": 163,
"weight": 162,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-preview.md",
@ -7406,7 +7406,7 @@
"x-appwrite": {
"method": "getFileView",
"group": "files",
"weight": 165,
"weight": 164,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-view.md",
@ -7491,7 +7491,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 432,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@ -7579,7 +7579,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 424,
"weight": 423,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@ -7724,7 +7724,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 425,
"weight": 424,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@ -7822,7 +7822,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 428,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@ -7961,7 +7961,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 426,
"weight": 425,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@ -8063,7 +8063,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 430,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@ -8150,7 +8150,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 434,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@ -8268,7 +8268,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 434,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
@ -8386,7 +8386,7 @@
"x-appwrite": {
"method": "list",
"group": "teams",
"weight": 172,
"weight": 171,
"cookies": false,
"type": "",
"demo": "teams\/list.md",
@ -8462,7 +8462,7 @@
"x-appwrite": {
"method": "create",
"group": "teams",
"weight": 171,
"weight": 170,
"cookies": false,
"type": "",
"demo": "teams\/create.md",
@ -8547,7 +8547,7 @@
"x-appwrite": {
"method": "get",
"group": "teams",
"weight": 173,
"weight": 172,
"cookies": false,
"type": "",
"demo": "teams\/get.md",
@ -8609,7 +8609,7 @@
"x-appwrite": {
"method": "updateName",
"group": "teams",
"weight": 175,
"weight": 174,
"cookies": false,
"type": "",
"demo": "teams\/update-name.md",
@ -8683,7 +8683,7 @@
"x-appwrite": {
"method": "delete",
"group": "teams",
"weight": 177,
"weight": 176,
"cookies": false,
"type": "",
"demo": "teams\/delete.md",
@ -8747,7 +8747,7 @@
"x-appwrite": {
"method": "listMemberships",
"group": "memberships",
"weight": 179,
"weight": 178,
"cookies": false,
"type": "",
"demo": "teams\/list-memberships.md",
@ -8833,7 +8833,7 @@
"x-appwrite": {
"method": "createMembership",
"group": "memberships",
"weight": 178,
"weight": 177,
"cookies": false,
"type": "",
"demo": "teams\/create-membership.md",
@ -8944,7 +8944,7 @@
"x-appwrite": {
"method": "getMembership",
"group": "memberships",
"weight": 180,
"weight": 179,
"cookies": false,
"type": "",
"demo": "teams\/get-membership.md",
@ -9016,7 +9016,7 @@
"x-appwrite": {
"method": "updateMembership",
"group": "memberships",
"weight": 181,
"weight": 180,
"cookies": false,
"type": "",
"demo": "teams\/update-membership.md",
@ -9103,7 +9103,7 @@
"x-appwrite": {
"method": "deleteMembership",
"group": "memberships",
"weight": 183,
"weight": 182,
"cookies": false,
"type": "",
"demo": "teams\/delete-membership.md",
@ -9177,7 +9177,7 @@
"x-appwrite": {
"method": "updateMembershipStatus",
"group": "memberships",
"weight": 182,
"weight": 181,
"cookies": false,
"type": "",
"demo": "teams\/update-membership-status.md",
@ -9275,7 +9275,7 @@
"x-appwrite": {
"method": "getPrefs",
"group": "teams",
"weight": 174,
"weight": 173,
"cookies": false,
"type": "",
"demo": "teams\/get-prefs.md",
@ -9336,7 +9336,7 @@
"x-appwrite": {
"method": "updatePrefs",
"group": "teams",
"weight": 176,
"weight": 175,
"cookies": false,
"type": "",
"demo": "teams\/update-prefs.md",

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -4972,7 +4972,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 340,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@ -5057,7 +5057,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 332,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@ -5204,7 +5204,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 333,
"weight": 332,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@ -5297,7 +5297,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 336,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@ -5440,7 +5440,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 334,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@ -5540,7 +5540,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 338,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@ -5623,7 +5623,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 343,
"weight": 342,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@ -5735,7 +5735,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 342,
"weight": 341,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@ -6106,7 +6106,7 @@
"x-appwrite": {
"method": "query",
"group": "graphql",
"weight": 255,
"weight": 254,
"cookies": false,
"type": "graphql",
"demo": "graphql\/query.md",
@ -6179,7 +6179,7 @@
"x-appwrite": {
"method": "mutation",
"group": "graphql",
"weight": 254,
"weight": 253,
"cookies": false,
"type": "graphql",
"demo": "graphql\/mutation.md",
@ -6660,7 +6660,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 301,
"weight": 300,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@ -6744,7 +6744,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 305,
"weight": 304,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@ -6814,7 +6814,7 @@
"x-appwrite": {
"method": "listFiles",
"group": "files",
"weight": 161,
"weight": 160,
"cookies": false,
"type": "",
"demo": "storage\/list-files.md",
@ -6896,7 +6896,7 @@
"x-appwrite": {
"method": "createFile",
"group": "files",
"weight": 160,
"weight": 159,
"cookies": false,
"type": "upload",
"demo": "storage\/create-file.md",
@ -6985,7 +6985,7 @@
"x-appwrite": {
"method": "getFile",
"group": "files",
"weight": 162,
"weight": 161,
"cookies": false,
"type": "",
"demo": "storage\/get-file.md",
@ -7054,7 +7054,7 @@
"x-appwrite": {
"method": "updateFile",
"group": "files",
"weight": 167,
"weight": 166,
"cookies": false,
"type": "",
"demo": "storage\/update-file.md",
@ -7142,7 +7142,7 @@
"x-appwrite": {
"method": "deleteFile",
"group": "files",
"weight": 168,
"weight": 167,
"cookies": false,
"type": "",
"demo": "storage\/delete-file.md",
@ -7211,7 +7211,7 @@
"x-appwrite": {
"method": "getFileDownload",
"group": "files",
"weight": 164,
"weight": 163,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-download.md",
@ -7289,7 +7289,7 @@
"x-appwrite": {
"method": "getFilePreview",
"group": "files",
"weight": 163,
"weight": 162,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-preview.md",
@ -7495,7 +7495,7 @@
"x-appwrite": {
"method": "getFileView",
"group": "files",
"weight": 165,
"weight": 164,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-view.md",
@ -7573,7 +7573,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 432,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@ -7657,7 +7657,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 424,
"weight": 423,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@ -7799,7 +7799,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 425,
"weight": 424,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@ -7891,7 +7891,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 428,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@ -8025,7 +8025,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 426,
"weight": 425,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@ -8124,7 +8124,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 430,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@ -8206,7 +8206,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 434,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@ -8317,7 +8317,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 434,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
@ -8426,7 +8426,7 @@
"x-appwrite": {
"method": "list",
"group": "teams",
"weight": 172,
"weight": 171,
"cookies": false,
"type": "",
"demo": "teams\/list.md",
@ -8500,7 +8500,7 @@
"x-appwrite": {
"method": "create",
"group": "teams",
"weight": 171,
"weight": 170,
"cookies": false,
"type": "",
"demo": "teams\/create.md",
@ -8589,7 +8589,7 @@
"x-appwrite": {
"method": "get",
"group": "teams",
"weight": 173,
"weight": 172,
"cookies": false,
"type": "",
"demo": "teams\/get.md",
@ -8650,7 +8650,7 @@
"x-appwrite": {
"method": "updateName",
"group": "teams",
"weight": 175,
"weight": 174,
"cookies": false,
"type": "",
"demo": "teams\/update-name.md",
@ -8724,7 +8724,7 @@
"x-appwrite": {
"method": "delete",
"group": "teams",
"weight": 177,
"weight": 176,
"cookies": false,
"type": "",
"demo": "teams\/delete.md",
@ -8785,7 +8785,7 @@
"x-appwrite": {
"method": "listMemberships",
"group": "memberships",
"weight": 179,
"weight": 178,
"cookies": false,
"type": "",
"demo": "teams\/list-memberships.md",
@ -8867,7 +8867,7 @@
"x-appwrite": {
"method": "createMembership",
"group": "memberships",
"weight": 178,
"weight": 177,
"cookies": false,
"type": "",
"demo": "teams\/create-membership.md",
@ -8979,7 +8979,7 @@
"x-appwrite": {
"method": "getMembership",
"group": "memberships",
"weight": 180,
"weight": 179,
"cookies": false,
"type": "",
"demo": "teams\/get-membership.md",
@ -9048,7 +9048,7 @@
"x-appwrite": {
"method": "updateMembership",
"group": "memberships",
"weight": 181,
"weight": 180,
"cookies": false,
"type": "",
"demo": "teams\/update-membership.md",
@ -9133,7 +9133,7 @@
"x-appwrite": {
"method": "deleteMembership",
"group": "memberships",
"weight": 183,
"weight": 182,
"cookies": false,
"type": "",
"demo": "teams\/delete-membership.md",
@ -9204,7 +9204,7 @@
"x-appwrite": {
"method": "updateMembershipStatus",
"group": "memberships",
"weight": 182,
"weight": 181,
"cookies": false,
"type": "",
"demo": "teams\/update-membership-status.md",
@ -9298,7 +9298,7 @@
"x-appwrite": {
"method": "getPrefs",
"group": "teams",
"weight": 174,
"weight": 173,
"cookies": false,
"type": "",
"demo": "teams\/get-prefs.md",
@ -9359,7 +9359,7 @@
"x-appwrite": {
"method": "updatePrefs",
"group": "teams",
"weight": 176,
"weight": 175,
"cookies": false,
"type": "",
"demo": "teams\/update-prefs.md",

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -4972,7 +4972,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 340,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@ -5057,7 +5057,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 332,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@ -5204,7 +5204,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 333,
"weight": 332,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@ -5297,7 +5297,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 336,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@ -5440,7 +5440,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 334,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@ -5540,7 +5540,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 338,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@ -5623,7 +5623,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 343,
"weight": 342,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@ -5735,7 +5735,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 342,
"weight": 341,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@ -6106,7 +6106,7 @@
"x-appwrite": {
"method": "query",
"group": "graphql",
"weight": 255,
"weight": 254,
"cookies": false,
"type": "graphql",
"demo": "graphql\/query.md",
@ -6179,7 +6179,7 @@
"x-appwrite": {
"method": "mutation",
"group": "graphql",
"weight": 254,
"weight": 253,
"cookies": false,
"type": "graphql",
"demo": "graphql\/mutation.md",
@ -6660,7 +6660,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 301,
"weight": 300,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@ -6744,7 +6744,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 305,
"weight": 304,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@ -6814,7 +6814,7 @@
"x-appwrite": {
"method": "listFiles",
"group": "files",
"weight": 161,
"weight": 160,
"cookies": false,
"type": "",
"demo": "storage\/list-files.md",
@ -6896,7 +6896,7 @@
"x-appwrite": {
"method": "createFile",
"group": "files",
"weight": 160,
"weight": 159,
"cookies": false,
"type": "upload",
"demo": "storage\/create-file.md",
@ -6985,7 +6985,7 @@
"x-appwrite": {
"method": "getFile",
"group": "files",
"weight": 162,
"weight": 161,
"cookies": false,
"type": "",
"demo": "storage\/get-file.md",
@ -7054,7 +7054,7 @@
"x-appwrite": {
"method": "updateFile",
"group": "files",
"weight": 167,
"weight": 166,
"cookies": false,
"type": "",
"demo": "storage\/update-file.md",
@ -7142,7 +7142,7 @@
"x-appwrite": {
"method": "deleteFile",
"group": "files",
"weight": 168,
"weight": 167,
"cookies": false,
"type": "",
"demo": "storage\/delete-file.md",
@ -7211,7 +7211,7 @@
"x-appwrite": {
"method": "getFileDownload",
"group": "files",
"weight": 164,
"weight": 163,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-download.md",
@ -7289,7 +7289,7 @@
"x-appwrite": {
"method": "getFilePreview",
"group": "files",
"weight": 163,
"weight": 162,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-preview.md",
@ -7495,7 +7495,7 @@
"x-appwrite": {
"method": "getFileView",
"group": "files",
"weight": 165,
"weight": 164,
"cookies": false,
"type": "location",
"demo": "storage\/get-file-view.md",
@ -7573,7 +7573,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 432,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@ -7657,7 +7657,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 424,
"weight": 423,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@ -7799,7 +7799,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 425,
"weight": 424,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@ -7891,7 +7891,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 428,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@ -8025,7 +8025,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 426,
"weight": 425,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@ -8124,7 +8124,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 430,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@ -8206,7 +8206,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 434,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@ -8317,7 +8317,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 434,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
@ -8426,7 +8426,7 @@
"x-appwrite": {
"method": "list",
"group": "teams",
"weight": 172,
"weight": 171,
"cookies": false,
"type": "",
"demo": "teams\/list.md",
@ -8500,7 +8500,7 @@
"x-appwrite": {
"method": "create",
"group": "teams",
"weight": 171,
"weight": 170,
"cookies": false,
"type": "",
"demo": "teams\/create.md",
@ -8589,7 +8589,7 @@
"x-appwrite": {
"method": "get",
"group": "teams",
"weight": 173,
"weight": 172,
"cookies": false,
"type": "",
"demo": "teams\/get.md",
@ -8650,7 +8650,7 @@
"x-appwrite": {
"method": "updateName",
"group": "teams",
"weight": 175,
"weight": 174,
"cookies": false,
"type": "",
"demo": "teams\/update-name.md",
@ -8724,7 +8724,7 @@
"x-appwrite": {
"method": "delete",
"group": "teams",
"weight": 177,
"weight": 176,
"cookies": false,
"type": "",
"demo": "teams\/delete.md",
@ -8785,7 +8785,7 @@
"x-appwrite": {
"method": "listMemberships",
"group": "memberships",
"weight": 179,
"weight": 178,
"cookies": false,
"type": "",
"demo": "teams\/list-memberships.md",
@ -8867,7 +8867,7 @@
"x-appwrite": {
"method": "createMembership",
"group": "memberships",
"weight": 178,
"weight": 177,
"cookies": false,
"type": "",
"demo": "teams\/create-membership.md",
@ -8979,7 +8979,7 @@
"x-appwrite": {
"method": "getMembership",
"group": "memberships",
"weight": 180,
"weight": 179,
"cookies": false,
"type": "",
"demo": "teams\/get-membership.md",
@ -9048,7 +9048,7 @@
"x-appwrite": {
"method": "updateMembership",
"group": "memberships",
"weight": 181,
"weight": 180,
"cookies": false,
"type": "",
"demo": "teams\/update-membership.md",
@ -9133,7 +9133,7 @@
"x-appwrite": {
"method": "deleteMembership",
"group": "memberships",
"weight": 183,
"weight": 182,
"cookies": false,
"type": "",
"demo": "teams\/delete-membership.md",
@ -9204,7 +9204,7 @@
"x-appwrite": {
"method": "updateMembershipStatus",
"group": "memberships",
"weight": 182,
"weight": 181,
"cookies": false,
"type": "",
"demo": "teams\/update-membership-status.md",
@ -9298,7 +9298,7 @@
"x-appwrite": {
"method": "getPrefs",
"group": "teams",
"weight": 174,
"weight": 173,
"cookies": false,
"type": "",
"demo": "teams\/get-prefs.md",
@ -9359,7 +9359,7 @@
"x-appwrite": {
"method": "updatePrefs",
"group": "teams",
"weight": 176,
"weight": 175,
"cookies": false,
"type": "",
"demo": "teams\/update-prefs.md",

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

12
composer.lock generated
View file

@ -5019,16 +5019,16 @@
"packages-dev": [
{
"name": "appwrite/sdk-generator",
"version": "1.3.1",
"version": "1.3.2",
"source": {
"type": "git",
"url": "https://github.com/appwrite/sdk-generator.git",
"reference": "b0e67a0545a1dbe91c81389ed3acf0f844e068d4"
"reference": "375a6c9b168db6fdf58fbe0d49d2261d80700b4a"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/b0e67a0545a1dbe91c81389ed3acf0f844e068d4",
"reference": "b0e67a0545a1dbe91c81389ed3acf0f844e068d4",
"url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/375a6c9b168db6fdf58fbe0d49d2261d80700b4a",
"reference": "375a6c9b168db6fdf58fbe0d49d2261d80700b4a",
"shasum": ""
},
"require": {
@ -5064,9 +5064,9 @@
"description": "Appwrite PHP library for generating API SDKs for multiple programming languages and platforms",
"support": {
"issues": "https://github.com/appwrite/sdk-generator/issues",
"source": "https://github.com/appwrite/sdk-generator/tree/1.3.1"
"source": "https://github.com/appwrite/sdk-generator/tree/1.3.2"
},
"time": "2025-09-05T15:33:58+00:00"
"time": "2025-09-05T15:50:35+00:00"
},
{
"name": "doctrine/annotations",

View file

@ -57,7 +57,8 @@ class Mapper
'datetime' => Type::string(),
'json' => Types::json(),
'none' => Types::json(),
'any' => Types::json()
'any' => Types::json(),
'array' => Types::json()
];
foreach ($defaults as $type => $default) {

View file

@ -9,11 +9,11 @@ use Appwrite\SDK\AuthType;
use Appwrite\SDK\Deprecated;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Document;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -64,7 +64,7 @@ class Create extends Action
->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).')
->param('key', '', new Key(), 'Attribute Key.')
->param('required', null, new Boolean(), 'Is attribute required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for attribute when not provided, as JSON string. Cannot be set when attribute is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for attribute when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when attribute is required.', true)
->inject('response')
->inject('dbForProject')
->inject('queueForDatabase')
@ -72,10 +72,8 @@ class Create extends Action
->callback($this->action(...));
}
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?string $default, UtopiaResponse $response, Database $dbForProject, EventDatabase $queueForDatabase, Event $queueForEvents): void
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?array $default, UtopiaResponse $response, Database $dbForProject, EventDatabase $queueForDatabase, Event $queueForEvents): void
{
$default = \is_string($default) ? \json_decode($default, true) : $default;
$attribute = $this->createAttribute($databaseId, $collectionId, new Document([
'key' => $key,
'type' => Database::VAR_LINESTRING,

View file

@ -9,10 +9,10 @@ use Appwrite\SDK\ContentType;
use Appwrite\SDK\Deprecated;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -64,7 +64,7 @@ class Update extends Action
->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).')
->param('key', '', new Key(), 'Attribute Key.')
->param('required', null, new Boolean(), 'Is attribute required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for attribute when not provided, as JSON string. Cannot be set when attribute is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for attribute when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when attribute is required.', true)
->param('newKey', null, new Key(), 'New attribute key.', true)
->inject('response')
->inject('dbForProject')
@ -72,10 +72,8 @@ class Update extends Action
->callback($this->action(...));
}
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?string $default, ?string $newKey, UtopiaResponse $response, Database $dbForProject, Event $queueForEvents): void
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?array $default, ?string $newKey, UtopiaResponse $response, Database $dbForProject, Event $queueForEvents): void
{
$default = \is_string($default) ? \json_decode($default, true) : $default;
$attribute = $this->updateAttribute(
databaseId: $databaseId,
collectionId: $collectionId,

View file

@ -9,11 +9,11 @@ use Appwrite\SDK\AuthType;
use Appwrite\SDK\Deprecated;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Document;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -64,7 +64,7 @@ class Create extends Action
->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).')
->param('key', '', new Key(), 'Attribute Key.')
->param('required', null, new Boolean(), 'Is attribute required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for attribute when not provided, as JSON string. Cannot be set when attribute is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for attribute when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when attribute is required.', true)
->inject('response')
->inject('dbForProject')
->inject('queueForDatabase')
@ -72,10 +72,8 @@ class Create extends Action
->callback($this->action(...));
}
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?string $default, UtopiaResponse $response, Database $dbForProject, EventDatabase $queueForDatabase, Event $queueForEvents): void
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?array $default, UtopiaResponse $response, Database $dbForProject, EventDatabase $queueForDatabase, Event $queueForEvents): void
{
$default = \is_string($default) ? \json_decode($default, true) : $default;
$attribute = $this->createAttribute($databaseId, $collectionId, new Document([
'key' => $key,
'type' => Database::VAR_POINT,

View file

@ -9,10 +9,10 @@ use Appwrite\SDK\ContentType;
use Appwrite\SDK\Deprecated;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -64,7 +64,7 @@ class Update extends Action
->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).')
->param('key', '', new Key(), 'Attribute Key.')
->param('required', null, new Boolean(), 'Is attribute required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for attribute when not provided, as JSON string. Cannot be set when attribute is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for attribute when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when attribute is required.', true)
->param('newKey', null, new Key(), 'New attribute key.', true)
->inject('response')
->inject('dbForProject')
@ -72,10 +72,8 @@ class Update extends Action
->callback($this->action(...));
}
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?string $default, ?string $newKey, UtopiaResponse $response, Database $dbForProject, Event $queueForEvents): void
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?array $default, ?string $newKey, UtopiaResponse $response, Database $dbForProject, Event $queueForEvents): void
{
$default = \is_string($default) ? \json_decode($default, true) : $default;
$attribute = $this->updateAttribute(
databaseId: $databaseId,
collectionId: $collectionId,

View file

@ -9,11 +9,11 @@ use Appwrite\SDK\AuthType;
use Appwrite\SDK\Deprecated;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Document;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -64,7 +64,7 @@ class Create extends Action
->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).')
->param('key', '', new Key(), 'Attribute Key.')
->param('required', null, new Boolean(), 'Is attribute required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for attribute when not provided, as JSON string. Cannot be set when attribute is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for attribute when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when attribute is required.', true)
->inject('response')
->inject('dbForProject')
->inject('queueForDatabase')
@ -72,10 +72,8 @@ class Create extends Action
->callback($this->action(...));
}
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?string $default, UtopiaResponse $response, Database $dbForProject, EventDatabase $queueForDatabase, Event $queueForEvents): void
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?array $default, UtopiaResponse $response, Database $dbForProject, EventDatabase $queueForDatabase, Event $queueForEvents): void
{
$default = \is_string($default) ? \json_decode($default, true) : $default;
$attribute = $this->createAttribute($databaseId, $collectionId, new Document([
'key' => $key,
'type' => Database::VAR_POLYGON,

View file

@ -9,10 +9,10 @@ use Appwrite\SDK\ContentType;
use Appwrite\SDK\Deprecated;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -64,7 +64,7 @@ class Update extends Action
->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#createCollection).')
->param('key', '', new Key(), 'Attribute Key.')
->param('required', null, new Boolean(), 'Is attribute required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for attribute when not provided, as JSON string. Cannot be set when attribute is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for attribute when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when attribute is required.', true)
->param('newKey', null, new Key(), 'New attribute key.', true)
->inject('response')
->inject('dbForProject')
@ -72,10 +72,8 @@ class Update extends Action
->callback($this->action(...));
}
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?string $default, ?string $newKey, UtopiaResponse $response, Database $dbForProject, Event $queueForEvents): void
public function action(string $databaseId, string $collectionId, string $key, ?bool $required, ?array $default, ?string $newKey, UtopiaResponse $response, Database $dbForProject, Event $queueForEvents): void
{
$default = \is_string($default) ? \json_decode($default, true) : $default;
$attribute = $this->updateAttribute(
databaseId: $databaseId,
collectionId: $collectionId,

View file

@ -6,10 +6,10 @@ use Appwrite\Platform\Modules\Databases\Http\Databases\Collections\Attributes\Li
use Appwrite\SDK\AuthType;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -56,7 +56,7 @@ class Create extends LineCreate
->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate).')
->param('key', '', new Key(), 'Column Key.')
->param('required', null, new Boolean(), 'Is column required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for column when not provided, as JSON string. Cannot be set when column is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for column when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when column is required.', true)
->inject('response')
->inject('dbForProject')
->inject('queueForDatabase')

View file

@ -7,10 +7,10 @@ use Appwrite\SDK\AuthType;
use Appwrite\SDK\ContentType;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -58,7 +58,7 @@ class Update extends LineUpdate
->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate).')
->param('key', '', new Key(), 'Column Key.')
->param('required', null, new Boolean(), 'Is column required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for column when not provided, as JSON string. Cannot be set when column is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for column when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when column is required.', true)
->param('newKey', null, new Key(), 'New Column Key.', true)
->inject('response')
->inject('dbForProject')

View file

@ -6,10 +6,10 @@ use Appwrite\Platform\Modules\Databases\Http\Databases\Collections\Attributes\Po
use Appwrite\SDK\AuthType;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -56,7 +56,7 @@ class Create extends PointCreate
->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate).')
->param('key', '', new Key(), 'Column Key.')
->param('required', null, new Boolean(), 'Is column required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for column when not provided, as JSON string. Cannot be set when column is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for column when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when column is required.', true)
->inject('response')
->inject('dbForProject')
->inject('queueForDatabase')

View file

@ -7,10 +7,10 @@ use Appwrite\SDK\AuthType;
use Appwrite\SDK\ContentType;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -58,7 +58,7 @@ class Update extends PointUpdate
->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate).')
->param('key', '', new Key(), 'Column Key.')
->param('required', null, new Boolean(), 'Is column required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for column when not provided, as JSON string. Cannot be set when column is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for column when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when column is required.', true)
->param('newKey', null, new Key(), 'New Column Key.', true)
->inject('response')
->inject('dbForProject')

View file

@ -6,10 +6,10 @@ use Appwrite\Platform\Modules\Databases\Http\Databases\Collections\Attributes\Po
use Appwrite\SDK\AuthType;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -56,7 +56,7 @@ class Create extends PolygonCreate
->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate).')
->param('key', '', new Key(), 'Column Key.')
->param('required', null, new Boolean(), 'Is column required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for column when not provided, as JSON string. Cannot be set when column is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for column when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when column is required.', true)
->inject('response')
->inject('dbForProject')
->inject('queueForDatabase')

View file

@ -7,10 +7,10 @@ use Appwrite\SDK\AuthType;
use Appwrite\SDK\ContentType;
use Appwrite\SDK\Method;
use Appwrite\SDK\Response as SDKResponse;
use Appwrite\Utopia\Database\Validator\Spatial;
use Appwrite\Utopia\Response as UtopiaResponse;
use Utopia\Database\Database;
use Utopia\Database\Validator\Key;
use Utopia\Database\Validator\Spatial;
use Utopia\Database\Validator\UID;
use Utopia\Swoole\Response as SwooleResponse;
use Utopia\Validator\Boolean;
@ -58,7 +58,7 @@ class Update extends PolygonUpdate
->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/server/tablesdb#tablesDBCreate).')
->param('key', '', new Key(), 'Column Key.')
->param('required', null, new Boolean(), 'Is column required?')
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for column when not provided, as JSON string. Cannot be set when column is required.', true)
->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for column when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when column is required.', true)
->param('newKey', null, new Key(), 'New Column Key.', true)
->inject('response')
->inject('dbForProject')

View file

@ -447,6 +447,15 @@ class OpenAPI3 extends Format
'type' => $validator->getValidator()->getType(),
];
break;
case 'Utopia\Database\Validator\Spatial':
$node['schema']['type'] = 'array';
$node['schema']['items'] = [
'oneOf' => [
['type' => 'array']
]
];
$node['schema']['x-example'] = '[[1,2], [3, 4]]';
break;
case 'Appwrite\Utopia\Database\Validator\Queries\Columns':
case 'Appwrite\Utopia\Database\Validator\Queries\Attributes':
case 'Appwrite\Utopia\Database\Validator\Queries\Buckets':
@ -671,6 +680,10 @@ class OpenAPI3 extends Format
$output['components']['schemas'][$model->getType()]['properties'][$name]['additionalProperties'] = true;
break;
case 'array':
$type = 'array';
break;
case 'integer':
$type = 'integer';
$format = 'int32';

View file

@ -462,6 +462,15 @@ class Swagger2 extends Format
'type' => $validator->getValidator()->getType(),
];
break;
case 'Utopia\Database\Validator\Spatial':
$node['type'] = 'array';
$node['schema']['items'] = [
'oneOf' => [
['type' => 'array']
]
];
$node['x-example'] = '[[1,2], [3, 4]]';
break;
case 'Utopia\Validator\JSON':
case 'Utopia\Validator\Mock':
case 'Utopia\Validator\Assoc':
@ -678,6 +687,10 @@ class Swagger2 extends Format
$type = 'object';
break;
case 'array':
$type = 'array';
break;
case 'integer':
$type = 'integer';
$format = 'int32';

View file

@ -1,42 +0,0 @@
<?php
namespace Appwrite\Utopia\Database\Validator;
use Utopia\Database\Validator\Spatial as SpatialValidator;
use Utopia\Validator\JSON;
class Spatial extends JSON
{
private string $spatialAttributeType;
public function getDescription(): string
{
return 'Value must be a valid spatial type JSON string';
}
/**
* @param string $spatialAttributeType
*/
public function __construct(string $spatialAttributeType)
{
$this->spatialAttributeType = $spatialAttributeType;
}
/**
* Is valid.
*
* Returns true if valid or false if not.
*
* @param $value
*
* @return bool
*/
public function isValid($value): bool
{
if (!parent::isValid($value)) {
return false;
}
$value = \json_decode($value, true);
$validator = new SpatialValidator($this->spatialAttributeType);
return $validator->isValid($value);
}
}

View file

@ -15,6 +15,7 @@ abstract class Model
public const TYPE_DATETIME_EXAMPLE = '2020-10-15T06:38:00.000+00:00';
public const TYPE_RELATIONSHIP = 'relationship';
public const TYPE_PAYLOAD = 'payload';
public const TYPE_ARRAY = 'array';
/**
* @var bool

View file

@ -12,15 +12,19 @@ class AttributeLine extends Attribute
$this
->addRule('default', [
'type' => self::TYPE_JSON,
'type' => self::TYPE_ARRAY,
'description' => 'Default value for attribute when not provided. Cannot be set when attribute is required.',
'default' => null,
'required' => false,
'example' => '[[0, 0], [1, 1]]'
'example' => [[0, 0], [1, 1]]
])
;
}
public array $conditions = [
'type' => 'linestring',
];
/**
* Get Name
*

View file

@ -12,15 +12,19 @@ class AttributePoint extends Attribute
$this
->addRule('default', [
'type' => self::TYPE_JSON,
'type' => self::TYPE_ARRAY,
'description' => 'Default value for attribute when not provided. Cannot be set when attribute is required.',
'default' => null,
'required' => false,
'example' => '[0, 0]'
'example' => [0, 0]
])
;
}
public array $conditions = [
'type' => 'point',
];
/**
* Get Name
*

View file

@ -12,15 +12,19 @@ class AttributePolygon extends Attribute
$this
->addRule('default', [
'type' => self::TYPE_JSON,
'type' => self::TYPE_ARRAY,
'description' => 'Default value for attribute when not provided. Cannot be set when attribute is required.',
'default' => null,
'required' => false,
'example' => '[[[0, 0], [0, 10]], [[10, 10], [0, 0]]]'
'example' => [[[0, 0], [0, 10]], [[10, 10], [0, 0]]]
])
;
}
public array $conditions = [
'type' => 'polygon',
];
/**
* Get Name
*

View file

@ -12,15 +12,19 @@ class ColumnLine extends Column
$this
->addRule('default', [
'type' => self::TYPE_JSON,
'type' => self::TYPE_ARRAY,
'description' => 'Default value for column when not provided. Cannot be set when column is required.',
'default' => null,
'required' => false,
'example' => '[[0, 0], [1, 1]]'
'example' => [[0, 0], [1, 1]]
])
;
}
public array $conditions = [
'type' => 'linestring',
];
/**
* Get Name
*

View file

@ -12,15 +12,19 @@ class ColumnPoint extends Column
$this
->addRule('default', [
'type' => self::TYPE_JSON,
'type' => self::TYPE_ARRAY,
'description' => 'Default value for column when not provided. Cannot be set when column is required.',
'default' => null,
'required' => false,
'example' => '[0, 0]'
'example' => [0, 0]
])
;
}
public array $conditions = [
'type' => 'point',
];
/**
* Get Name
*

View file

@ -12,15 +12,19 @@ class ColumnPolygon extends Column
$this
->addRule('default', [
'type' => self::TYPE_JSON,
'type' => self::TYPE_ARRAY,
'description' => 'Default value for column when not provided. Cannot be set when column is required.',
'default' => null,
'required' => false,
'example' => '[[[0, 0], [0, 10]], [[10, 10], [0, 0]]]'
'example' => [[[0, 0], [0, 10]], [[10, 10], [0, 0]]]
])
;
}
public array $conditions = [
'type' => 'polygon',
];
/**
* Get Name
*

View file

@ -6537,7 +6537,7 @@ trait DatabasesBase
'x-appwrite-key' => $this->getProject()['apiKey']
]), [
'required' => false,
'default' => json_encode([[0, 0], [1, 1]]),
'default' => [[0, 0], [1, 1]],
]);
$this->assertEquals(200, $response['headers']['status-code']);
@ -6564,7 +6564,7 @@ trait DatabasesBase
'x-appwrite-project' => $this->getProject()['$id'],
'x-appwrite-key' => $this->getProject()['apiKey']
]), [
'default' => json_encode([0, 0]),
'default' => [0, 0],
'required' => false
]);

View file

@ -8670,7 +8670,7 @@ trait DatabasesBase
'x-appwrite-key' => $this->getProject()['apiKey']
]), [
'required' => false,
'default' => json_encode([[0, 0], [1, 1]]),
'default' => [[0, 0], [1, 1]],
]);
$this->assertEquals(200, $response['headers']['status-code']);
@ -8697,7 +8697,7 @@ trait DatabasesBase
'x-appwrite-project' => $this->getProject()['$id'],
'x-appwrite-key' => $this->getProject()['apiKey']
]), [
'default' => json_encode([0, 0]),
'default' => [0, 0],
'required' => false
]);
$this->assertEquals(200, $response['headers']['status-code']);