diff --git a/app/config/specs/open-api3-1.8.x-client.json b/app/config/specs/open-api3-1.8.x-client.json index c72300e004..61543c2853 100644 --- a/app/config/specs/open-api3-1.8.x-client.json +++ b/app/config/specs/open-api3-1.8.x-client.json @@ -1891,7 +1891,7 @@ "prefs": { "type": "object", "description": "Prefs key-value JSON object.", - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -5020,7 +5020,7 @@ "data": { "type": "object", "description": "Document data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -7675,7 +7675,7 @@ "data": { "type": "object", "description": "Row data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/open-api3-1.8.x-console.json b/app/config/specs/open-api3-1.8.x-console.json index b39181e025..3f0dcc0e2d 100644 --- a/app/config/specs/open-api3-1.8.x-console.json +++ b/app/config/specs/open-api3-1.8.x-console.json @@ -1911,7 +1911,7 @@ "prefs": { "type": "object", "description": "Prefs key-value JSON object.", - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9575,7 +9575,7 @@ "data": { "type": "object", "description": "Document data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -15150,7 +15150,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "tags": [ "health" @@ -37474,7 +37474,7 @@ "data": { "type": "object", "description": "Row data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/open-api3-1.8.x-server.json b/app/config/specs/open-api3-1.8.x-server.json index 22f0affafa..fd039be84a 100644 --- a/app/config/specs/open-api3-1.8.x-server.json +++ b/app/config/specs/open-api3-1.8.x-server.json @@ -1926,7 +1926,7 @@ "prefs": { "type": "object", "description": "Prefs key-value JSON object.", - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9057,7 +9057,7 @@ "data": { "type": "object", "description": "Document data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -13887,7 +13887,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "tags": [ "health" @@ -27845,7 +27845,7 @@ "data": { "type": "object", "description": "Row data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/open-api3-latest-client.json b/app/config/specs/open-api3-latest-client.json index c72300e004..61543c2853 100644 --- a/app/config/specs/open-api3-latest-client.json +++ b/app/config/specs/open-api3-latest-client.json @@ -1891,7 +1891,7 @@ "prefs": { "type": "object", "description": "Prefs key-value JSON object.", - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -5020,7 +5020,7 @@ "data": { "type": "object", "description": "Document data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -7675,7 +7675,7 @@ "data": { "type": "object", "description": "Row data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index b39181e025..3f0dcc0e2d 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -1911,7 +1911,7 @@ "prefs": { "type": "object", "description": "Prefs key-value JSON object.", - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9575,7 +9575,7 @@ "data": { "type": "object", "description": "Document data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -15150,7 +15150,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "tags": [ "health" @@ -37474,7 +37474,7 @@ "data": { "type": "object", "description": "Row data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index 22f0affafa..fd039be84a 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -1926,7 +1926,7 @@ "prefs": { "type": "object", "description": "Prefs key-value JSON object.", - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9057,7 +9057,7 @@ "data": { "type": "object", "description": "Document data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -13887,7 +13887,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "tags": [ "health" @@ -27845,7 +27845,7 @@ "data": { "type": "object", "description": "Row data as JSON object.", - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/swagger2-1.8.x-client.json b/app/config/specs/swagger2-1.8.x-client.json index ea98bd764b..7982031e95 100644 --- a/app/config/specs/swagger2-1.8.x-client.json +++ b/app/config/specs/swagger2-1.8.x-client.json @@ -1979,7 +1979,7 @@ "type": "object", "description": "Prefs key-value JSON object.", "default": {}, - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -5154,7 +5154,7 @@ "type": "object", "description": "Document data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -7749,7 +7749,7 @@ "type": "object", "description": "Row data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/swagger2-1.8.x-console.json b/app/config/specs/swagger2-1.8.x-console.json index 03435662b0..53edc8c93e 100644 --- a/app/config/specs/swagger2-1.8.x-console.json +++ b/app/config/specs/swagger2-1.8.x-console.json @@ -2009,7 +2009,7 @@ "type": "object", "description": "Prefs key-value JSON object.", "default": {}, - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9680,7 +9680,7 @@ "type": "object", "description": "Document data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -15186,7 +15186,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "consumes": [], "produces": [ @@ -37572,7 +37572,7 @@ "type": "object", "description": "Row data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/swagger2-1.8.x-server.json b/app/config/specs/swagger2-1.8.x-server.json index 5fb2c27cb9..abb141ae66 100644 --- a/app/config/specs/swagger2-1.8.x-server.json +++ b/app/config/specs/swagger2-1.8.x-server.json @@ -2023,7 +2023,7 @@ "type": "object", "description": "Prefs key-value JSON object.", "default": {}, - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9152,7 +9152,7 @@ "type": "object", "description": "Document data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -13952,7 +13952,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "consumes": [], "produces": [ @@ -28003,7 +28003,7 @@ "type": "object", "description": "Row data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/swagger2-latest-client.json b/app/config/specs/swagger2-latest-client.json index ea98bd764b..7982031e95 100644 --- a/app/config/specs/swagger2-latest-client.json +++ b/app/config/specs/swagger2-latest-client.json @@ -1979,7 +1979,7 @@ "type": "object", "description": "Prefs key-value JSON object.", "default": {}, - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -5154,7 +5154,7 @@ "type": "object", "description": "Document data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -7749,7 +7749,7 @@ "type": "object", "description": "Row data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 03435662b0..53edc8c93e 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -2009,7 +2009,7 @@ "type": "object", "description": "Prefs key-value JSON object.", "default": {}, - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9680,7 +9680,7 @@ "type": "object", "description": "Document data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -15186,7 +15186,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "consumes": [], "produces": [ @@ -37572,7 +37572,7 @@ "type": "object", "description": "Row data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index 5fb2c27cb9..abb141ae66 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -2023,7 +2023,7 @@ "type": "object", "description": "Prefs key-value JSON object.", "default": {}, - "x-example": "{}" + "x-example": "{\"language\":\"en\",\"timezone\":\"UTC\",\"darkTheme\":true}" } }, "required": [ @@ -9152,7 +9152,7 @@ "type": "object", "description": "Document data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", @@ -13952,7 +13952,7 @@ }, "\/health\/queue\/stats-resources": { "get": { - "summary": "Get stats resources queue", + "summary": "Get stats resources queue", "operationId": "healthGetQueueStatsResources", "consumes": [], "produces": [ @@ -28003,7 +28003,7 @@ "type": "object", "description": "Row data as JSON object.", "default": [], - "x-example": "{}" + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" }, "permissions": { "type": "array", diff --git a/app/controllers/api/account.php b/app/controllers/api/account.php index 24cc116aed..7f76e39cd9 100644 --- a/app/controllers/api/account.php +++ b/app/controllers/api/account.php @@ -3168,7 +3168,7 @@ App::patch('/v1/account/prefs') ], contentType: ContentType::JSON )) - ->param('prefs', [], new Assoc(), 'Prefs key-value JSON object.') + ->param('prefs', [], new Assoc(), 'Prefs key-value JSON object.', example: '{"language":"en","timezone":"UTC","darkTheme":true}') ->inject('requestTimestamp') ->inject('response') ->inject('user') diff --git a/composer.json b/composer.json index 0c662c775f..c4e5e72305 100644 --- a/composer.json +++ b/composer.json @@ -68,7 +68,7 @@ "utopia-php/platform": "0.7.*", "utopia-php/pools": "0.8.*", "utopia-php/preloader": "0.2.*", - "utopia-php/queue": "0.11.0", + "utopia-php/queue": "0.12.0", "utopia-php/registry": "0.5.*", "utopia-php/storage": "0.18.*", "utopia-php/swoole": "0.8.*", diff --git a/composer.lock b/composer.lock index 683bb58e93..d8323ceeea 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0da713ee5642eba1d30bc51c1a04a723", + "content-hash": "afc8b2b314887779f507fd6a101ef6af", "packages": [ { "name": "adhocore/jwt", @@ -67,6 +67,99 @@ ], "time": "2025-02-18T01:00:50+00:00" }, + { + "name": "appwrite-labs/php-amqplib", + "version": "0.1.2", + "source": { + "type": "git", + "url": "https://github.com/appwrite-labs/php-amqplib.git", + "reference": "c8e043045388ddad5ddab5f48df2b9046ca6873f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/appwrite-labs/php-amqplib/zipball/c8e043045388ddad5ddab5f48df2b9046ca6873f", + "reference": "c8e043045388ddad5ddab5f48df2b9046ca6873f", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "ext-sockets": "*", + "php": "^7.2||^8.0", + "phpseclib/phpseclib": "^2.0|^3.0" + }, + "conflict": { + "php": "7.4.0 - 7.4.1" + }, + "replace": { + "php-amqplib/php-amqplib": "self.version", + "videlalvaro/php-amqplib": "self.version" + }, + "require-dev": { + "ext-curl": "*", + "nategood/httpful": "^0.2.20", + "phpunit/phpunit": "^7.5|^9.5", + "squizlabs/php_codesniffer": "^3.6", + "swoole/ide-helper": "^5.0" + }, + "suggest": { + "ext-swoole": "For Swoole coroutine support" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "psr-4": { + "PhpAmqpLib\\": "PhpAmqpLib/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "LGPL-2.1-or-later" + ], + "authors": [ + { + "name": "Appwrite Labs", + "email": "team@appwrite.io", + "role": "Fork Maintainer" + }, + { + "name": "Alvaro Videla", + "role": "Original Maintainer" + }, + { + "name": "Raúl Araya", + "email": "nubeiro@gmail.com", + "role": "Maintainer" + }, + { + "name": "Luke Bakken", + "email": "luke@bakken.io", + "role": "Maintainer" + }, + { + "name": "Ramūnas Dronga", + "email": "github@ramuno.lt", + "role": "Maintainer" + } + ], + "description": "Fork of php-amqplib with Swoole coroutine support. A pure PHP implementation of the AMQP protocol tested against RabbitMQ.", + "homepage": "https://github.com/appwrite-labs/php-amqplib/", + "keywords": [ + "async", + "coroutine", + "message", + "queue", + "rabbitmq", + "swoole" + ], + "support": { + "source": "https://github.com/appwrite-labs/php-amqplib/tree/0.1.2" + }, + "time": "2025-07-04T20:54:22+00:00" + }, { "name": "appwrite/appwrite", "version": "15.1.0", @@ -1687,87 +1780,6 @@ }, "time": "2020-10-15T08:29:30+00:00" }, - { - "name": "php-amqplib/php-amqplib", - "version": "v3.7.3", - "source": { - "type": "git", - "url": "https://github.com/php-amqplib/php-amqplib.git", - "reference": "9f50fe69a9f1a19e2cb25596a354d705de36fe59" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-amqplib/php-amqplib/zipball/9f50fe69a9f1a19e2cb25596a354d705de36fe59", - "reference": "9f50fe69a9f1a19e2cb25596a354d705de36fe59", - "shasum": "" - }, - "require": { - "ext-mbstring": "*", - "ext-sockets": "*", - "php": "^7.2||^8.0", - "phpseclib/phpseclib": "^2.0|^3.0" - }, - "conflict": { - "php": "7.4.0 - 7.4.1" - }, - "replace": { - "videlalvaro/php-amqplib": "self.version" - }, - "require-dev": { - "ext-curl": "*", - "nategood/httpful": "^0.2.20", - "phpunit/phpunit": "^7.5|^9.5", - "squizlabs/php_codesniffer": "^3.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "psr-4": { - "PhpAmqpLib\\": "PhpAmqpLib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "LGPL-2.1-or-later" - ], - "authors": [ - { - "name": "Alvaro Videla", - "role": "Original Maintainer" - }, - { - "name": "Raúl Araya", - "email": "nubeiro@gmail.com", - "role": "Maintainer" - }, - { - "name": "Luke Bakken", - "email": "luke@bakken.io", - "role": "Maintainer" - }, - { - "name": "Ramūnas Dronga", - "email": "github@ramuno.lt", - "role": "Maintainer" - } - ], - "description": "Formerly videlalvaro/php-amqplib. This library is a pure PHP implementation of the AMQP protocol. It's been tested against RabbitMQ.", - "homepage": "https://github.com/php-amqplib/php-amqplib/", - "keywords": [ - "message", - "queue", - "rabbitmq" - ], - "support": { - "issues": "https://github.com/php-amqplib/php-amqplib/issues", - "source": "https://github.com/php-amqplib/php-amqplib/tree/v3.7.3" - }, - "time": "2025-02-18T20:11:13+00:00" - }, { "name": "php-http/discovery", "version": "1.20.0", @@ -4296,16 +4308,16 @@ }, { "name": "utopia-php/platform", - "version": "0.7.8", + "version": "0.7.11", "source": { "type": "git", "url": "https://github.com/utopia-php/platform.git", - "reference": "e3a4536c46f10988b1a446ec6b8dd8a9914be854" + "reference": "f3341d1ef82e0b0f9d5f2c61829c947d86f8c850" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/platform/zipball/e3a4536c46f10988b1a446ec6b8dd8a9914be854", - "reference": "e3a4536c46f10988b1a446ec6b8dd8a9914be854", + "url": "https://api.github.com/repos/utopia-php/platform/zipball/f3341d1ef82e0b0f9d5f2c61829c947d86f8c850", + "reference": "f3341d1ef82e0b0f9d5f2c61829c947d86f8c850", "shasum": "" }, "require": { @@ -4314,7 +4326,7 @@ "php": ">=8.0", "utopia-php/cli": "0.15.*", "utopia-php/framework": "0.33.*", - "utopia-php/queue": "0.11.*" + "utopia-php/queue": "^0.12.0" }, "require-dev": { "laravel/pint": "1.*", @@ -4340,9 +4352,9 @@ ], "support": { "issues": "https://github.com/utopia-php/platform/issues", - "source": "https://github.com/utopia-php/platform/tree/0.7.8" + "source": "https://github.com/utopia-php/platform/tree/0.7.11" }, - "time": "2025-05-30T10:05:43+00:00" + "time": "2025-09-04T04:38:38+00:00" }, { "name": "utopia-php/pools", @@ -4451,21 +4463,21 @@ }, { "name": "utopia-php/queue", - "version": "0.11.0", + "version": "0.12.0", "source": { "type": "git", "url": "https://github.com/utopia-php/queue.git", - "reference": "06b5ced0eaed2ecc6aab6d8e1b4d96bff37a1ce5" + "reference": "3a7603ee712c592bfc54af4a76f0426c428b5574" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/queue/zipball/06b5ced0eaed2ecc6aab6d8e1b4d96bff37a1ce5", - "reference": "06b5ced0eaed2ecc6aab6d8e1b4d96bff37a1ce5", + "url": "https://api.github.com/repos/utopia-php/queue/zipball/3a7603ee712c592bfc54af4a76f0426c428b5574", + "reference": "3a7603ee712c592bfc54af4a76f0426c428b5574", "shasum": "" }, "require": { + "appwrite-labs/php-amqplib": "^0.1", "php": ">=8.3", - "php-amqplib/php-amqplib": "^3.7", "utopia-php/cli": "0.15.*", "utopia-php/fetch": "0.4.*", "utopia-php/framework": "0.33.*", @@ -4511,9 +4523,9 @@ ], "support": { "issues": "https://github.com/utopia-php/queue/issues", - "source": "https://github.com/utopia-php/queue/tree/0.11.0" + "source": "https://github.com/utopia-php/queue/tree/0.12.0" }, - "time": "2025-05-30T09:52:38+00:00" + "time": "2025-06-24T18:58:38+00:00" }, { "name": "utopia-php/registry", diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php index d274e1f128..c03daabd4f 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php @@ -116,7 +116,7 @@ class Create extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('documentId', '', new CustomId(), 'Document ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.', true) ->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). Make sure to define attributes before creating documents.') - ->param('data', [], new JSON(), 'Document data as JSON object.', true) + ->param('data', [], new JSON(), 'Document data as JSON object.', true, example: '{"username":"walter.obrien","email":"walter.obrien@example.com","fullName":"Walter O\'Brien","age":30,"isAdmin":false}') ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('documents', [], fn (array $plan) => new ArrayList(new JSON(), $plan['databasesBatchSize'] ?? APP_LIMIT_DATABASE_BATCH), 'Array of documents data as JSON objects.', true, ['plan']) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php index 5290131dd1..a7aa2607e5 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php @@ -95,7 +95,7 @@ class Create extends DocumentCreate ->param('databaseId', '', new UID(), 'Database ID.') ->param('rowId', '', new CustomId(), 'Row ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.', true) ->param('tableId', '', new UID(), '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('data', [], new JSON(), 'Row data as JSON object.', true) + ->param('data', [], new JSON(), 'Row data as JSON object.', true, example: '{"username":"walter.obrien","email":"walter.obrien@example.com","fullName":"Walter O\'Brien","age":30,"isAdmin":false}') ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('rows', [], fn (array $plan) => new ArrayList(new JSON(), $plan['databasesBatchSize'] ?? APP_LIMIT_DATABASE_BATCH), 'Array of documents data as JSON objects.', true, ['plan']) ->inject('response') diff --git a/src/Appwrite/SDK/Specification/Format/OpenAPI3.php b/src/Appwrite/SDK/Specification/Format/OpenAPI3.php index 4a492e4c00..db95f984c8 100644 --- a/src/Appwrite/SDK/Specification/Format/OpenAPI3.php +++ b/src/Appwrite/SDK/Specification/Format/OpenAPI3.php @@ -433,7 +433,7 @@ class OpenAPI3 extends Format case 'Utopia\Validator\Assoc': $param['default'] = (empty($param['default'])) ? new \stdClass() : $param['default']; $node['schema']['type'] = 'object'; - $node['schema']['x-example'] = '{}'; + $node['schema']['x-example'] = ($param['example'] ?? '') ?: '{}'; break; case 'Utopia\Storage\Validator\File': $consumes = ['multipart/form-data']; diff --git a/src/Appwrite/SDK/Specification/Format/Swagger2.php b/src/Appwrite/SDK/Specification/Format/Swagger2.php index 313d46be8f..c734d37f0e 100644 --- a/src/Appwrite/SDK/Specification/Format/Swagger2.php +++ b/src/Appwrite/SDK/Specification/Format/Swagger2.php @@ -467,7 +467,7 @@ class Swagger2 extends Format case 'Utopia\Validator\Assoc': $node['type'] = 'object'; $node['default'] = (empty($param['default'])) ? new \stdClass() : $param['default']; - $node['x-example'] = '{}'; + $node['x-example'] = ($param['example'] ?? '') ?: '{}'; break; case 'Utopia\Storage\Validator\File': $consumes = ['multipart/form-data'];