From 4dec4f2ff25302747aae094616bbf4ea64bc32cc Mon Sep 17 00:00:00 2001 From: harsh mahajan Date: Fri, 22 May 2026 15:32:44 +0530 Subject: [PATCH 1/3] Fix organization project API headers and queries --- app/config/cors.php | 1 + src/Appwrite/Utopia/Database/Validator/Queries/Projects.php | 1 + 2 files changed, 2 insertions(+) diff --git a/app/config/cors.php b/app/config/cors.php index 0454a24495..8147ec8fe5 100644 --- a/app/config/cors.php +++ b/app/config/cors.php @@ -22,6 +22,7 @@ return [ 'X-Appwrite-Locale', 'X-Appwrite-Mode', 'X-Appwrite-JWT', + 'X-Appwrite-Organization', 'X-Appwrite-Response-Format', 'X-Appwrite-Timeout', 'X-Appwrite-ID', diff --git a/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php b/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php index 50c9d850f3..f56dc35953 100644 --- a/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php +++ b/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php @@ -7,6 +7,7 @@ class Projects extends Base public const ALLOWED_ATTRIBUTES = [ 'name', 'teamId', + 'status', 'labels', 'search' ]; From e831b3e952b0d87889aea42b4715d4e1e2e93db5 Mon Sep 17 00:00:00 2001 From: harsh mahajan Date: Fri, 22 May 2026 15:39:16 +0530 Subject: [PATCH 2/3] Add project status index --- app/config/collections/platform.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/app/config/collections/platform.php b/app/config/collections/platform.php index 7496b7a9a7..e7d10e73e9 100644 --- a/app/config/collections/platform.php +++ b/app/config/collections/platform.php @@ -376,6 +376,13 @@ $platformCollections = [ 'lengths' => [Database::LENGTH_KEY], 'orders' => [Database::ORDER_ASC], ], + [ + '$id' => ID::custom('_key_status'), + 'type' => Database::INDEX_KEY, + 'attributes' => ['status'], + 'lengths' => [], + 'orders' => [], + ], [ '$id' => ID::custom('_key_pingCount'), 'type' => Database::INDEX_KEY, From 6a4dcd76a79aed79fef6cdc32c17bb13fb7c0a95 Mon Sep 17 00:00:00 2001 From: harsh mahajan Date: Fri, 22 May 2026 15:45:32 +0530 Subject: [PATCH 3/3] Keep organization projects schema unchanged --- app/config/collections/platform.php | 7 ------- .../Utopia/Database/Validator/Queries/Projects.php | 1 - 2 files changed, 8 deletions(-) diff --git a/app/config/collections/platform.php b/app/config/collections/platform.php index e7d10e73e9..7496b7a9a7 100644 --- a/app/config/collections/platform.php +++ b/app/config/collections/platform.php @@ -376,13 +376,6 @@ $platformCollections = [ 'lengths' => [Database::LENGTH_KEY], 'orders' => [Database::ORDER_ASC], ], - [ - '$id' => ID::custom('_key_status'), - 'type' => Database::INDEX_KEY, - 'attributes' => ['status'], - 'lengths' => [], - 'orders' => [], - ], [ '$id' => ID::custom('_key_pingCount'), 'type' => Database::INDEX_KEY, diff --git a/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php b/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php index f56dc35953..50c9d850f3 100644 --- a/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php +++ b/src/Appwrite/Utopia/Database/Validator/Queries/Projects.php @@ -7,7 +7,6 @@ class Projects extends Base public const ALLOWED_ATTRIBUTES = [ 'name', 'teamId', - 'status', 'labels', 'search' ];