Compare commits

...
Author SHA1 Message Date
Chirag Aggarwal a5701b462a update composer 2025-10-27 17:54:17 +05:30
Chirag Aggarwal eac292b7e6 update composer 2025-10-27 13:53:58 +05:30
Damodar LohaniandGitHub 15b12551a0 Merge pull request #10702 from appwrite/fix-description
fix: execution status enum description
2025-10-27 12:08:20 +05:45
Chirag Aggarwal 22f44c51d6 regen specs 2025-10-27 11:23:56 +05:30
Damodar LohaniandGitHub 128dc34a52 Merge pull request #10705 from appwrite/fix-warning-builds-worker
Fix warning builds worker
2025-10-27 10:42:29 +05:45
Chirag Aggarwal ecc3f61f1e fix: warning Undefined variable $adapter 2025-10-27 08:41:13 +05:30
Chirag Aggarwal ffb2a02ea0 fix: execution status enum description 2025-10-25 10:52:22 +05:30
Matej BačoandGitHub 3733df6fc5 Merge pull request #10698 from appwrite/ser-218-functions
Fix errors on downloading function deployment output
2025-10-24 16:57:48 +02:00
Hemachandar b5d26bb426 Fix errors on downloading function deployment output 2025-10-24 19:59:48 +05:30
Matej Bačo fa4529846c Applying SDK generation fix for Console
https://github.com/appwrite/appwrite/pull/10628/files
2025-10-24 16:18:11 +02:00
Matej BačoandGitHub 1fc790802d Merge pull request #10681 from appwrite/feat-tanstack-start-sites
Feat: Tanstack support
2025-10-24 15:57:20 +02:00
Matej Bačo 52ababa800 Update docker-compose.yml 2025-10-24 14:57:12 +02:00
Matej Bačo b3c1dea8d7 Fix template test 2025-10-24 13:25:25 +02:00
Matej Bačo f51c387cd8 Update composer.lock 2025-10-24 12:44:42 +02:00
Matej Bačo 3dd1c3de13 Merge branch '1.8.x' into feat-tanstack-start-sites 2025-10-24 12:43:51 +02:00
Matej Bačo 4472437696 AI code review fix 2025-10-24 12:41:46 +02:00
Matej Bačo ca39c2cde5 Add tanstack starter 2025-10-24 12:33:50 +02:00
Jake BarnbyandGitHub 24bfad100d Merge pull request #10690 from appwrite/feat-resend
feat: resend adapter
2025-10-24 09:13:24 +00:00
Matej BačoandGitHub a8de338d5f Merge pull request #10633 from appwrite/ser-376
Dark mode styles for emails
2025-10-24 10:50:53 +02:00
Chirag Aggarwal 9c0772f125 add tests 2025-10-24 14:19:59 +05:30
HemachandarandGitHub 572870e320 Merge branch '1.8.x' into ser-376 2025-10-24 13:55:21 +05:30
Matej BačoandGitHub 046d1190cf Merge pull request #10691 from appwrite/chore-skip-auth-to-delete-vcs-lock
Skip auth check to delete vcs lock document
2025-10-23 18:00:58 +02:00
Khushboo Verma a6af0cc73a Skip auth check to delete vcs lock document 2025-10-23 20:27:45 +05:30
Chirag Aggarwal f12481ce20 add update endpoint 2025-10-23 19:42:12 +05:30
Chirag Aggarwal a280a565f6 feat: resend adapter 2025-10-23 19:06:11 +05:30
Matej BačoandGitHub c80b40cec7 Merge pull request #10648 from appwrite/ser-218
Fix errors on downloading large deployment output
2025-10-23 14:25:34 +02:00
HemachandarandGitHub 5ebb7e23a9 Merge branch '1.8.x' into ser-218 2025-10-23 17:31:16 +05:30
Matej Bačo 6f188a03d5 Manual QA bug fixing 2025-10-23 12:43:57 +02:00
Steven NguyenandGitHub aec26277c7 Merge pull request #10500 from appwrite/copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1
Fix hardcoded specification defaults to use dynamic plan-based logic
2025-10-22 15:41:11 -07:00
Luke B. SilverandGitHub 887820dbec Merge pull request #10683 from appwrite/fix-stats-usage-memory-leak
fix: stats usage memory leak
2025-10-22 17:53:47 +01:00
loks0n 18371eb511 fix: stats usage memory leak 2025-10-22 17:53:16 +01:00
Matej BačoandGitHub c38d319aeb Merge pull request #10535 from appwrite/fix-author-url-in-template-deployments
Fix Author URL in template deployments
2025-10-22 17:35:41 +02:00
Khushboo Verma 9c55da5b99 Resolve merge conflicts 2025-10-22 20:44:47 +05:30
Matej Bačo 3019551db5 remove leftover todo 2025-10-22 16:04:30 +02:00
Matej Bačo d787408e1d Implement package-based framework detection 2025-10-22 15:28:49 +02:00
Matej Bačo a5486128d4 Update composer.lock 2025-10-22 13:41:55 +02:00
Matej Bačo 14b1cc6e48 Merge branch '1.8.x' into feat-tanstack-start-sites 2025-10-22 13:41:37 +02:00
Matej Bačo f9257c1ec9 add tanstack template, use detection lib v 0.2 2025-10-22 13:40:49 +02:00
Luke B. SilverandGitHub 45e938b4ba Merge pull request #10679 from appwrite/update-apple-swift-13.3.0
chore: update apple sdk to 13.3.0
2025-10-22 12:17:33 +01:00
Chirag Aggarwal c2d4997810 update apple to 13.3.0 2025-10-22 14:17:57 +05:30
Matej BačoandGitHub de03506c0a Merge pull request #10674 from appwrite/feat-SER-457-add-max-build-duration-env
feat: add _APP_COMPUTE_BUILD_TIMEOUT to console variables
2025-10-22 09:32:46 +02:00
Harsh MahajanandGitHub b6349b17f2 Merge branch '1.8.x' into feat-SER-457-add-max-build-duration-env 2025-10-22 10:24:37 +05:30
Jake BarnbyandGitHub 2e699ef8b9 Merge pull request #10678 from appwrite/update-domains-0.9.1
update domain lib to 0.9.1
2025-10-22 04:53:35 +00:00
Harsh MahajanandGitHub f5034a6ad8 Merge branch '1.8.x' into feat-SER-457-add-max-build-duration-env 2025-10-22 09:56:56 +05:30
Chirag Aggarwal 9c30f32281 update domain lib to 0.9.1 2025-10-22 09:29:45 +05:30
Steven NguyenandGitHub 2652a21332 Merge pull request #10404 from appwrite/feat-1.8.0-release-prep
Prepare 1.8.0 release
2025-10-21 15:40:07 -07:00
Harsh MahajanandGitHub d48ef373a7 Fix environment variable assignment for build timeout 2025-10-21 17:48:48 +05:30
Harsh MahajanGitHubcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
4cb20b3fe3 Update app/controllers/api/console.php
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-10-21 17:47:30 +05:30
Harsh Mahajan 803244ccf7 feat:add _APP_COMPUTE_BUILD_TIMEOUT to console variables 2025-10-21 11:48:48 +00:00
Luke B. SilverandGitHub 16a2dd0b27 Merge pull request #10672 from appwrite/update-cli-10.2.2
chore: update cli to 10.2.2
2025-10-21 10:53:16 +01:00
Chirag Aggarwal 8154a8524a update sdk gen 2025-10-21 12:51:10 +05:30
Chirag Aggarwal 0e567e3e68 chore: update cli to 10.2.2 2025-10-21 11:40:50 +05:30
Jake BarnbyandGitHub f150cffa17 Merge pull request #10670 from appwrite/revert-auth
Revert "Merge pull request #10468 from appwrite/feat-apps-module-dl"
2025-10-21 02:58:23 +00:00
Jake Barnby f4efb81832 Update lock 2025-10-21 15:07:53 +13:00
Jake Barnby ddde13a78f Revert "Merge pull request #10468 from appwrite/feat-apps-module-dl"
This reverts commit 9dd1939d1f, reversing
changes made to 8dfdfcb522.

# Conflicts:
#	app/config/collections/common.php
#	app/controllers/api/users.php
#	app/init/resources.php
#	composer.lock
2025-10-21 14:59:30 +13:00
Jake BarnbyandGitHub e2d3624713 Merge pull request #10664 from appwrite/feat-update-db
Update db
2025-10-20 14:11:36 +00:00
Matej BačoandGitHub 411951f9d5 Merge pull request #10669 from appwrite/copilot/update-github-comment-title
Change GitHub alert from NOTE to TIP in VCS build comments
2025-10-20 16:03:59 +02:00
Jake Barnby caa699e181 Update database 2025-10-21 02:25:51 +13:00
copilot-swe-agent[bot]andMeldiron d9773f44b1 Change GitHub alert from NOTE to TIP in VCS comments
Co-authored-by: Meldiron <19310830+Meldiron@users.noreply.github.com>
2025-10-20 12:32:38 +00:00
copilot-swe-agent[bot] 46dd8fdc68 Initial plan 2025-10-20 12:28:04 +00:00
Jake Barnby 94d02aff4f Fix DB tests 2025-10-21 01:24:50 +13:00
Jake Barnby d23f993a6c Fix validator constructor 2025-10-21 00:13:43 +13:00
Jake Barnby bfe639fb70 Fix key 2025-10-21 00:13:32 +13:00
Jake Barnby 568651291e Update libs 2025-10-20 23:13:17 +13:00
Damodar LohaniandGitHub 254f026458 Merge pull request #10667 from appwrite/fix-auth-refactor
Fix: reset argon 2 options to previous default
2025-10-19 14:00:25 +05:45
Damodar Lohani 248d3aea7a Fix: reset argon 2 options to previous default 2025-10-19 05:44:44 +00:00
Jake Barnby 11042af051 Update db 2025-10-18 02:19:43 +13:00
Luke B. SilverandGitHub 07d55d17a3 Merge pull request #10658 from appwrite/update-domains-0.8.3
update domain lib to 0.8.4
2025-10-17 13:09:36 +01:00
Chirag Aggarwal abfab60eec update to 0.8.4 2025-10-17 17:05:47 +05:30
Chirag Aggarwal fc3ac122dd Merge branch '1.8.x' into update-domains-0.8.3 2025-10-17 17:05:24 +05:30
Jake BarnbyandGitHub 3963b632d8 Merge pull request #10663 from appwrite/update-apple-swift
chore: update apple and swift sdks to 13.2.2
2025-10-17 07:01:25 +00:00
Chirag Aggarwal 1936a01464 chore: update apple and swift sdks to 13.2.2 2025-10-17 12:28:31 +05:30
Luke B. SilverandGitHub 2cbfa6930f Merge pull request #10655 from appwrite/fix-test-dependencies-projects
Refactor ProjectsConsoleClientTest to remove test dependencies
2025-10-16 11:30:50 +01:00
Chirag Aggarwal 33a856af41 update domain lib to 0.8.3 2025-10-16 15:54:43 +05:30
Chirag Aggarwal 5d1d937fde remove changes 2025-10-16 15:29:59 +05:30
Chirag Aggarwal 83ec855f4b skip harder ones 2025-10-16 15:18:21 +05:30
Luke B. SilverandGitHub 5ce9b8eaeb Merge pull request #10656 from appwrite/feat-replace-sleep-in-webhooks-service
Replace sleep in webhook tests with assertEventually
2025-10-16 10:45:32 +01:00
Khushboo Verma be983eb68a Remove race condition 2025-10-16 14:40:47 +05:30
Chirag Aggarwal c6f144313d more tests 2025-10-16 14:29:57 +05:30
Chirag Aggarwal ae8ec1c736 formatting 2025-10-16 14:26:39 +05:30
Chirag Aggarwal 19d7f02371 more tests 2025-10-16 14:25:12 +05:30
Khushboo Verma f0660f3fda Replace sleep in webhook tests with assertEventually 2025-10-16 14:23:35 +05:30
Chirag Aggarwal 9ded176cf2 Refactor ProjectsConsoleClientTest to remove test dependencies
- Remove @depends annotations to make tests independent
- Each test now creates its own team and project instead of relying on shared state
- Replace sleep() calls with assertEventually() for more reliable async testing
- Change test methods to return void instead of passing data between tests
- Remove unnecessary sleep() call that was causing test flakiness
2025-10-16 14:21:30 +05:30
Damodar LohaniandGitHub 2e10cd0009 Merge pull request #10654 from appwrite/fix-undefined-var
Fix: undefined variable warning
2025-10-16 13:40:04 +05:45
Damodar Lohani 7ff664e62b Fix: undefined $user 2025-10-16 07:38:13 +00:00
Damodar LohaniandGitHub 9dd1939d1f Merge pull request #10468 from appwrite/feat-apps-module-dl
Feat apps module dl
2025-10-16 11:40:27 +05:45
Damodar LohaniandGitHub 8dfdfcb522 Merge pull request #10652 from appwrite/fix-undefined-sequence
Fix undefined sequence
2025-10-16 10:34:37 +05:45
Damodar LohaniandGitHub b63c2804f1 Fix: undefined $sequence 2025-10-16 10:26:49 +05:45
Damodar Lohani ced2270571 remove unused injection 2025-10-16 03:39:39 +00:00
Damodar Lohani d3436077a1 remove unused hash 2025-10-16 03:39:18 +00:00
Damodar Lohani e06349e803 update argon2 instances 2025-10-16 03:34:45 +00:00
Damodar Lohani 9849b9d678 Fix empty check 2025-10-16 02:41:53 +00:00
Damodar Lohani 22136867ed add additional check 2025-10-16 02:29:30 +00:00
Damodar Lohani 2df621f9c5 Fix: update comment, typings 2025-10-16 02:23:41 +00:00
Damodar Lohani 9a599e2015 update recommended param for argon2 2025-10-16 02:20:28 +00:00
Damodar Lohani 431dd96b98 chaining 2025-10-16 02:17:59 +00:00
Damodar Lohani 4d8f950955 fix roles filtering 2025-10-16 02:17:52 +00:00
Damodar Lohani 08e559180d fix missing injection 2025-10-16 02:08:07 +00:00
Damodar Lohani 4cb63068de improve install loop 2025-10-16 02:07:17 +00:00
Damodar Lohani f062b39cfa Fix encoding 2025-10-16 02:06:01 +00:00
Hemachandar 635d77350a set header 2025-10-15 16:05:34 +05:30
Hemachandar 9f07a2bca4 early return 2025-10-15 15:16:28 +05:30
Damodar Lohani 06ee421965 update composer 2025-10-15 07:11:27 +00:00
Damodar Lohani c3c69cc43b Merge remote-tracking branch 'origin/1.8.x' into feat-apps-module-dl 2025-10-15 07:05:23 +00:00
Damodar Lohani e47d53ddcc Merge remote-tracking branch 'origin/main' into feat-apps-module-dl 2025-10-15 07:04:38 +00:00
Jake BarnbyandGitHub 290a7b27db Merge branch 'main' into 1.8.x 2025-10-15 18:45:38 +13:00
Hemachandar bad74bd0b8 Add cache header for deployment download API 2025-10-14 18:18:41 +05:30
Damodar Lohani 5e5b22d649 fix jwt 2025-10-12 04:38:14 +00:00
Damodar Lohani 1b17c32405 update block 2025-10-12 03:51:37 +00:00
Damodar Lohani d56dff954f Merge remote-tracking branch 'origin/1.8.x' into feat-apps-module-dl 2025-10-12 00:34:07 +00:00
Hemachandar c525e15ea5 Dark mode styles for emails 2025-10-10 23:01:26 +05:30
Jake BarnbyandGitHub 852f06cc28 Merge pull request #10623 from Veera-mulge/change-desc
Update README.md
2025-10-10 02:09:26 +13:00
VeereshandGitHub d82171b4de Update README.md 2025-10-09 18:36:30 +05:30
Khushboo VermaandGitHub 0c64eaf441 Merge branch '1.8.x' into copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1 2025-10-07 19:56:12 +05:30
Khushboo VermaandGitHub 248e538518 Merge branch '1.8.x' into copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1 2025-10-07 16:56:48 +05:30
Khushboo VermaandGitHub 1a07123abe Merge branch '1.8.x' into copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1 2025-10-07 14:14:16 +05:30
Khushboo VermaandGitHub 35578bfada Merge branch '1.8.x' into copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1 2025-10-07 12:10:42 +05:30
Khushboo VermaandGitHub bd772c97cf Merge branch '1.8.x' into copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1 2025-10-01 12:39:14 +01:00
Khushboo VermaandGitHub b40769b086 Merge branch '1.8.x' into copilot/fix-3b5374b7-acb3-4c22-9573-00c1feec5bc1 2025-09-29 22:48:38 +01:00
Khushboo Verma 5d5c1d8f43 Fix Author URL in template deployments 2025-09-22 20:29:25 +05:30
Damodar Lohani 4540362f42 Fix: token hash magic url session 2025-09-18 01:37:19 +00:00
Damodar Lohani 3065f53d83 Fix token hash 2025-09-18 01:14:14 +00:00
Damodar Lohani 74f181d7a8 fix token length 2025-09-17 10:18:49 +00:00
Damodar LohaniandGitHub 337eda8538 Merge branch '1.8.x' into feat-apps-module-dl 2025-09-17 14:49:22 +05:45
Damodar LohaniandGitHub 20c3641ac1 Merge branch '1.8.x' into feat-apps-module-dl 2025-09-16 10:25:30 +05:45
Damodar Lohani 33f7056e7a reest callback 2025-09-16 04:38:52 +00:00
Damodar Lohani 73e7c98131 Fix token length update 2025-09-16 04:36:30 +00:00
Damodar Lohani 1157d6fd10 Fix re-hashing 2025-09-16 04:27:00 +00:00
Steven NguyenandGitHub 536cff9cc6 chore: add specification validator test 2025-09-15 21:39:23 +00:00
Steven NguyenandGitHub 62014fda26 fix: implement dynamic specification defaults for Functions and Sites
Prior to this, self-hosted instances would defualt to the lowest specification.

Now, if there is no plan (ie. on self-hosted), the highest specification is used.

If there is a plan, the lowest specification available in the plan is used.
2025-09-15 21:39:22 +00:00
copilot-swe-agent[bot]andstnguyen90 fea3544d4b Implement dynamic specification defaults for Functions and Sites
Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com>
2025-09-15 19:18:07 +00:00
copilot-swe-agent[bot] 679de3574f Initial plan 2025-09-15 19:11:33 +00:00
Damodar Lohani cfd82d9709 use newer syntax 2025-09-15 10:57:31 +00:00
Damodar Lohani 21245836c7 Merge remote-tracking branch 'origin/1.8.x' into feat-apps-module-dl 2025-09-15 10:44:43 +00:00
Damodar Lohani b5ca4c1166 update suggestion 2025-09-15 10:43:40 +00:00
Damodar Lohani 780799f87a update to initialize first 2025-09-15 10:41:29 +00:00
Damodar Lohani 4579e41ace update check 2025-09-15 10:33:21 +00:00
Damodar Lohani 19cf94bd7e Fix oauth2 changes 2025-09-15 10:22:45 +00:00
Damodar Lohani 13b98409ae reset length 2025-09-14 05:56:56 +00:00
Damodar Lohani 518389d32c fix length 2025-09-14 05:37:06 +00:00
Damodar Lohani 800db0b99d Fix magic URL token length 2025-09-14 05:23:30 +00:00
Damodar Lohani cfa4530797 composer update 2025-09-14 05:03:20 +00:00
Damodar Lohani d42841d80a fix: remove hardcode, reuse hasher 2025-09-14 05:02:50 +00:00
3b668f7806 Update composer.json
Co-authored-by: Matej Bačo <matejbacocom@gmail.com>
2025-09-14 10:45:53 +05:45
32b290a231 Update src/Appwrite/Platform/Modules/Functions/Http/Executions/Create.php
Co-authored-by: Matej Bačo <matejbacocom@gmail.com>
2025-09-14 10:44:46 +05:45
Damodar Lohani 365aaca56d fix: remove legacy token generator use 2025-09-14 04:58:34 +00:00
Damodar Lohani 1c726d0466 fix: encoded not defined 2025-09-14 04:53:49 +00:00
Damodar Lohani c903caabcc remove dump 2025-09-14 04:50:13 +00:00
Damodar Lohani 53a117bd0f Merge remote-tracking branch 'origin/1.8.x' into feat-apps-module-dl 2025-09-14 04:49:34 +00:00
Damodar Lohani 72f5793928 revert date format 2025-09-11 09:18:23 +00:00
Damodar LohaniandGitHub b8e3a19586 Merge branch '1.8.x' into feat-apps-module-dl 2025-09-11 14:47:14 +05:45
Damodar Lohani e36de6b72b revert date format 2025-09-11 08:59:27 +00:00
Damodar Lohani bcec5c0922 revert date format 2025-09-11 08:57:27 +00:00
Damodar Lohani 72186f1882 reset det change 2025-09-11 08:46:38 +00:00
Damodar Lohani e4d70a4d4f Fix: default options 2025-09-11 07:55:52 +00:00
Damodar Lohani 6d19d76bac Fix scope check 2025-09-11 06:51:01 +00:00
Damodar Lohani 55bebd92f3 Fix date format 2025-09-11 06:27:58 +00:00
Damodar LohaniandGitHub 0d4df67958 Merge branch '1.8.x' into feat-apps-module-dl 2025-09-11 11:59:31 +05:45
Damodar Lohani 356fbed325 fix password update 2025-09-10 09:09:12 +00:00
Damodar Lohani 4578819a58 revert test update 2025-09-10 07:59:00 +00:00
Damodar Lohani 6099313cb4 Fxi teams tests 2025-09-10 07:57:45 +00:00
Damodar Lohani 487663f892 fixed attribute 2025-09-10 07:30:22 +00:00
Damodar LohaniandGitHub d8e769ef1f Merge branch '1.8.x' into feat-apps-module-dl 2025-09-10 12:48:44 +05:45
Damodar Lohani 41dbe1a384 Fix internal ID refactor 2025-09-10 07:03:11 +00:00
Damodar Lohani 631c00023e update lock 2025-09-10 04:38:14 +00:00
Damodar Lohani 4478edc211 fix linter 2025-09-10 04:25:21 +00:00
Damodar Lohani 2be8895dfd Merge remote-tracking branch 'origin/1.8.x' into feat-apps-module-dl 2025-09-10 03:56:34 +00:00
Christy Jacob b5c5f76acc Merge branch '1.7.x' of github.com:appwrite/appwrite into feat-apps-module 2025-06-20 17:39:28 +04:00
Eldad Fux 6f861a91ee Updated auth lib 2025-04-29 21:33:59 +02:00
Eldad Fux 0483c7efb5 Merge fixes 2025-04-29 20:44:05 +02:00
Eldad Fux fb29fe7b3c Merge remote-tracking branch 'origin/1.7.x' into feat-apps-module 2025-04-29 20:12:31 +02:00
Eldad Fux 1bf1766822 Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-28 08:20:24 +01:00
Eldad Fux 57edb4a385 Removed leftovers 2025-03-28 08:17:47 +01:00
Eldad Fux 17c555ab6c Expanded the identities collection 2025-03-28 02:13:17 +01:00
Eldad Fux d6bd72cfd3 formatting 2025-03-19 14:10:56 +01:00
Eldad Fux 8c9123beaa Fixed tests 2025-03-19 13:54:32 +01:00
Eldad Fux 3d967e695f Updated auth lib 2025-03-19 07:57:28 +01:00
Eldad Fux a7d7e39dfd Fixed tests 2025-03-18 22:47:17 +01:00
Eldad Fux 38cb95e940 Fixed tests 2025-03-18 22:28:19 +01:00
Eldad Fux b2b20c48b3 Fixed tests 2025-03-18 22:12:03 +01:00
Eldad Fux fed6579491 Update teams tests 2025-03-18 21:52:41 +01:00
Eldad Fux 8cb85cafbd Fixes realtime tests 2025-03-18 20:24:38 +01:00
Eldad Fux 55e560bb41 Fixed unit tests 2025-03-18 19:08:58 +01:00
Eldad Fux dd9a40221e Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-18 17:38:32 +01:00
Eldad Fux 24300cd3bd tests 2025-03-18 17:22:58 +01:00
Eldad Fux 4d5961c3ab Fixed test 2025-03-18 16:20:37 +01:00
Eldad Fux afb40218d7 Fixed tests 2025-03-18 16:12:13 +01:00
Eldad Fux 3daa3821ef Fixed syntax error 2025-03-18 10:24:42 +01:00
Eldad Fux 84cec0e32c format 2025-03-18 10:18:29 +01:00
Eldad Fux 7bae15d4fe Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-18 10:15:06 +01:00
Eldad Fux 0180f72067 Removed unsed methods and tests 2025-03-18 00:30:31 +01:00
Eldad Fux f537091eb2 Fixed tests 2025-03-17 23:57:44 +01:00
Eldad Fux c99c83a006 Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-17 23:15:57 +01:00
Eldad Fux 113828cd00 Improved errors 2025-03-17 22:51:22 +01:00
Eldad Fux 477add3022 Formatting 2025-03-17 21:49:10 +01:00
Eldad Fux 8aa5714173 cleanups 2025-03-17 21:44:31 +01:00
Eldad Fux fdb83c51f7 formatting 2025-03-17 12:46:07 +01:00
Eldad Fux c15739bba7 Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-17 12:44:49 +01:00
Eldad Fux 1ce84f1650 WIP 2025-03-17 12:39:35 +01:00
Eldad Fux f618a8b563 Fixed account test 2025-03-16 22:16:02 +01:00
Eldad Fux 9346efc24a Fixed some tests 2025-03-16 19:35:42 +01:00
Eldad Fux a5e57a9a67 Work in progress, moving to instance based auth 2025-03-16 18:54:55 +01:00
Eldad Fux cc724218b0 fixed formatting 2025-03-16 18:32:46 +01:00
Eldad Fux 706ce4b3b6 WIP - cleaning up auth managment 2025-03-16 18:30:48 +01:00
Eldad Fux c08355df8d Updated composer 2025-03-16 10:34:45 +01:00
Eldad Fux 2d5904e3d0 Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-16 10:26:55 +01:00
Eldad Fux d1318cf016 Updated dependencies 2025-03-10 02:19:57 +01:00
Eldad Fux 91921859a2 Merge remote-tracking branch 'origin/1.6.x' into feat-apps-module 2025-03-10 02:14:35 +01:00
Eldad Fux a058925252 Code formatting 2025-03-10 00:23:22 +01:00
Eldad Fux fadb24f295 revert change to build 2025-03-10 00:21:49 +01:00
Eldad Fux 748119334d Merge remote-tracking branch 'origin/feat-sites' into feat-apps-module 2025-03-10 00:18:23 +01:00
Eldad Fux cb05b87dda Upgraded users to use utopia/auth 2025-03-10 00:08:04 +01:00
Eldad Fux aa36d944db Add teamId to project array in e2e test 2025-03-01 22:00:37 +01:00
60 changed files with 5595 additions and 2506 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
> We just announced Timestamp Overrides for Appwrite Databases - [Learn more](https://appwrite.io/blog/post/announcing-timestamp-overrides)
> We just announced Transactions API for Appwrite Databases - [Learn more](https://appwrite.io/blog/post/announcing-transactions-api)
> Appwrite Cloud is now Generally Available - [Learn more](https://appwrite.io/cloud-ga)
+25
View File
@@ -202,6 +202,31 @@ return [
]
]
],
'tanstack-start' => [
'key' => 'tanstack-start',
'name' => 'TanStack Start',
'screenshotSleep' => 3000,
'buildRuntime' => 'node-22',
'runtimes' => getVersions($templateRuntimes['NODE']['versions'], 'node'),
'bundleCommand' => 'bash /usr/local/server/helpers/tanstack-start/bundle.sh',
'envCommand' => 'source /usr/local/server/helpers/tanstack-start/env.sh',
'adapters' => [
'ssr' => [
'key' => 'ssr',
'buildCommand' => 'npm run build',
'installCommand' => 'npm install',
'outputDirectory' => './dist',
'startCommand' => 'bash helpers/tanstack-start/server.sh',
],
'static' => [
'key' => 'static',
'buildCommand' => 'npm run build',
'installCommand' => 'npm install',
'outputDirectory' => './dist/client',
'startCommand' => 'bash helpers/server.sh',
]
]
],
'remix' => [
'key' => 'remix',
'name' => 'Remix',
@@ -2,6 +2,38 @@
<html>
<head>
<link rel="preconnect" href="https://assets.appwrite.io/" crossorigin>
<meta name="color-scheme" content="light dark">
<meta name="supported-color-schemes" content="light dark">
<style type="text/css">
:root {
color-scheme: light dark;
supported-color-schemes: light dark;
}
@media (prefers-color-scheme: dark ) {
body {
color: #616b7c !important;
background-color: #ffffff !important;
}
a {
color: currentColor !important;
}
a.button {
color: #ffffff !important;
background-color: #2D2D31 !important;
border-color: #414146 !important;
}
h1, h2, h3 {
color: #373b4d !important;
}
h4 {
color: #4f5769 !important;
}
p.security-phrase:not(:empty), hr {
border-color: #e8e9f0 !important;
}
}
</style>
<style>
@font-face {
font-family: 'Inter';
@@ -37,7 +69,6 @@
font-family: "Inter", sans-serif;
background-color: #ffffff;
margin: 0;
padding: 0;
}
a {
color: currentColor;
@@ -2,6 +2,38 @@
<html>
<head>
<link rel="preconnect" href="https://assets.appwrite.io/" crossorigin>
<meta name="color-scheme" content="light dark">
<meta name="supported-color-schemes" content="light dark">
<style type="text/css">
:root {
color-scheme: light dark;
supported-color-schemes: light dark;
}
@media (prefers-color-scheme: dark ) {
body {
color: #616b7c !important;
background-color: #ffffff !important;
}
a {
color: currentColor !important;
}
a.button {
color: #ffffff !important;
background-color: #2D2D31 !important;
border-color: #414146 !important;
}
h1, h2, h3 {
color: #373b4d !important;
}
h4 {
color: #4f5769 !important;
}
p.security-phrase:not(:empty), hr {
border-color: #e8e9f0 !important;
}
}
</style>
<style>
@font-face {
font-family: 'Inter';
+3 -3
View File
@@ -79,7 +79,7 @@ return [
[
'key' => 'apple',
'name' => 'Apple',
'version' => '13.2.1',
'version' => '13.3.0',
'url' => 'https://github.com/appwrite/sdk-for-apple',
'package' => 'https://github.com/appwrite/sdk-for-apple',
'enabled' => true,
@@ -226,7 +226,7 @@ return [
[
'key' => 'cli',
'name' => 'Command Line',
'version' => '10.2.1',
'version' => '10.2.2',
'url' => 'https://github.com/appwrite/sdk-for-cli',
'package' => 'https://www.npmjs.com/package/appwrite-cli',
'enabled' => true,
@@ -418,7 +418,7 @@ return [
[
'key' => 'swift',
'name' => 'Swift',
'version' => '13.2.1',
'version' => '13.2.2',
'url' => 'https://github.com/appwrite/sdk-for-swift',
'package' => 'https://github.com/appwrite/sdk-for-swift',
'enabled' => true,
+57 -39
View File
@@ -4934,7 +4934,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 376,
"weight": 378,
"cookies": false,
"type": "",
"demo": "databases\/list-transactions.md",
@@ -4999,7 +4999,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 372,
"weight": 374,
"cookies": false,
"type": "",
"demo": "databases\/create-transaction.md",
@@ -5067,7 +5067,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 373,
"weight": 375,
"cookies": false,
"type": "",
"demo": "databases\/get-transaction.md",
@@ -5129,7 +5129,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 374,
"weight": 376,
"cookies": false,
"type": "",
"demo": "databases\/update-transaction.md",
@@ -5205,7 +5205,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 375,
"weight": 377,
"cookies": false,
"type": "",
"demo": "databases\/delete-transaction.md",
@@ -5269,7 +5269,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 377,
"weight": 379,
"cookies": false,
"type": "",
"demo": "databases\/create-operations.md",
@@ -5352,7 +5352,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 335,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@@ -5451,7 +5451,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 327,
"weight": 329,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@@ -5607,7 +5607,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 328,
"weight": 330,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@@ -5716,7 +5716,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 331,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@@ -5870,7 +5870,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 329,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@@ -5978,7 +5978,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 333,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@@ -6082,7 +6082,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 338,
"weight": 340,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@@ -6206,7 +6206,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 337,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@@ -6330,7 +6330,7 @@
"x-appwrite": {
"method": "listExecutions",
"group": "executions",
"weight": 468,
"weight": 470,
"cookies": false,
"type": "",
"demo": "functions\/list-executions.md",
@@ -6405,7 +6405,7 @@
"x-appwrite": {
"method": "createExecution",
"group": "executions",
"weight": 466,
"weight": 468,
"cookies": false,
"type": "",
"demo": "functions\/create-execution.md",
@@ -6521,7 +6521,7 @@
"x-appwrite": {
"method": "getExecution",
"group": "executions",
"weight": 467,
"weight": 469,
"cookies": false,
"type": "",
"demo": "functions\/get-execution.md",
@@ -7115,7 +7115,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 296,
"weight": 298,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@@ -7198,7 +7198,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 300,
"weight": 302,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@@ -8076,7 +8076,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 441,
"weight": 443,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-transactions.md",
@@ -8084,7 +8084,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client",
@@ -8141,7 +8144,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 437,
"weight": 439,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-transaction.md",
@@ -8149,7 +8152,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8209,7 +8215,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 438,
"weight": 440,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-transaction.md",
@@ -8217,7 +8223,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client",
@@ -8271,7 +8280,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 439,
"weight": 441,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-transaction.md",
@@ -8279,7 +8288,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8347,7 +8359,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 440,
"weight": 442,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-transaction.md",
@@ -8355,7 +8367,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8411,7 +8426,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 442,
"weight": 444,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-operations.md",
@@ -8419,7 +8434,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8494,7 +8512,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 433,
"weight": 435,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@@ -8592,7 +8610,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 425,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@@ -8743,7 +8761,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 426,
"weight": 428,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@@ -8851,7 +8869,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 429,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@@ -8996,7 +9014,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 427,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@@ -9103,7 +9121,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 431,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@@ -9206,7 +9224,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 436,
"weight": 438,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@@ -9329,7 +9347,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 437,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+60 -41
View File
@@ -4934,7 +4934,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 376,
"weight": 378,
"cookies": false,
"type": "",
"demo": "databases\/list-transactions.md",
@@ -4999,7 +4999,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 372,
"weight": 374,
"cookies": false,
"type": "",
"demo": "databases\/create-transaction.md",
@@ -5067,7 +5067,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 373,
"weight": 375,
"cookies": false,
"type": "",
"demo": "databases\/get-transaction.md",
@@ -5129,7 +5129,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 374,
"weight": 376,
"cookies": false,
"type": "",
"demo": "databases\/update-transaction.md",
@@ -5205,7 +5205,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 375,
"weight": 377,
"cookies": false,
"type": "",
"demo": "databases\/delete-transaction.md",
@@ -5269,7 +5269,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 377,
"weight": 379,
"cookies": false,
"type": "",
"demo": "databases\/create-operations.md",
@@ -5352,7 +5352,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 335,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@@ -5451,7 +5451,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 327,
"weight": 329,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@@ -5607,7 +5607,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 328,
"weight": 330,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@@ -5716,7 +5716,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 331,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@@ -5870,7 +5870,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 329,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@@ -5978,7 +5978,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 333,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@@ -6082,7 +6082,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 338,
"weight": 340,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@@ -6206,7 +6206,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 337,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@@ -6330,7 +6330,7 @@
"x-appwrite": {
"method": "listExecutions",
"group": "executions",
"weight": 468,
"weight": 470,
"cookies": false,
"type": "",
"demo": "functions\/list-executions.md",
@@ -6405,7 +6405,7 @@
"x-appwrite": {
"method": "createExecution",
"group": "executions",
"weight": 466,
"weight": 468,
"cookies": false,
"type": "",
"demo": "functions\/create-execution.md",
@@ -6521,7 +6521,7 @@
"x-appwrite": {
"method": "getExecution",
"group": "executions",
"weight": 467,
"weight": 469,
"cookies": false,
"type": "",
"demo": "functions\/get-execution.md",
@@ -7115,7 +7115,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 296,
"weight": 298,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@@ -7198,7 +7198,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 300,
"weight": 302,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@@ -8076,7 +8076,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 441,
"weight": 443,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-transactions.md",
@@ -8084,7 +8084,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client",
@@ -8141,7 +8144,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 437,
"weight": 439,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-transaction.md",
@@ -8149,7 +8152,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8209,7 +8215,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 438,
"weight": 440,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-transaction.md",
@@ -8217,7 +8223,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client",
@@ -8271,7 +8280,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 439,
"weight": 441,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-transaction.md",
@@ -8279,7 +8288,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8347,7 +8359,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 440,
"weight": 442,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-transaction.md",
@@ -8355,7 +8367,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8411,7 +8426,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 442,
"weight": 444,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-operations.md",
@@ -8419,7 +8434,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client",
@@ -8494,7 +8512,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 433,
"weight": 435,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@@ -8592,7 +8610,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 425,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@@ -8743,7 +8761,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 426,
"weight": 428,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@@ -8851,7 +8869,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 429,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@@ -8996,7 +9014,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 427,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@@ -9103,7 +9121,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 431,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@@ -9206,7 +9224,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 436,
"weight": 438,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@@ -9329,7 +9347,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 437,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
@@ -12496,13 +12514,14 @@
},
"status": {
"type": "string",
"description": "The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, or `failed`.",
"description": "The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, `failed`, or `scheduled`.",
"x-example": "processing",
"enum": [
"waiting",
"processing",
"completed",
"failed"
"failed",
"scheduled"
]
},
"requestMethod": {
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+57 -39
View File
@@ -5076,7 +5076,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 376,
"weight": 378,
"cookies": false,
"type": "",
"demo": "databases\/list-transactions.md",
@@ -5141,7 +5141,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 372,
"weight": 374,
"cookies": false,
"type": "",
"demo": "databases\/create-transaction.md",
@@ -5209,7 +5209,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 373,
"weight": 375,
"cookies": false,
"type": "",
"demo": "databases\/get-transaction.md",
@@ -5270,7 +5270,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 374,
"weight": 376,
"cookies": false,
"type": "",
"demo": "databases\/update-transaction.md",
@@ -5347,7 +5347,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 375,
"weight": 377,
"cookies": false,
"type": "",
"demo": "databases\/delete-transaction.md",
@@ -5410,7 +5410,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 377,
"weight": 379,
"cookies": false,
"type": "",
"demo": "databases\/create-operations.md",
@@ -5489,7 +5489,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 335,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@@ -5582,7 +5582,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 327,
"weight": 329,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@@ -5736,7 +5736,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 328,
"weight": 330,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@@ -5837,7 +5837,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 331,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@@ -5987,7 +5987,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 329,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@@ -6093,7 +6093,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 333,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@@ -6191,7 +6191,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 338,
"weight": 340,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@@ -6309,7 +6309,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 337,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@@ -6425,7 +6425,7 @@
"x-appwrite": {
"method": "listExecutions",
"group": "executions",
"weight": 468,
"weight": 470,
"cookies": false,
"type": "",
"demo": "functions\/list-executions.md",
@@ -6498,7 +6498,7 @@
"x-appwrite": {
"method": "createExecution",
"group": "executions",
"weight": 466,
"weight": 468,
"cookies": false,
"type": "",
"demo": "functions\/create-execution.md",
@@ -6615,7 +6615,7 @@
"x-appwrite": {
"method": "getExecution",
"group": "executions",
"weight": 467,
"weight": 469,
"cookies": false,
"type": "",
"demo": "functions\/get-execution.md",
@@ -7240,7 +7240,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 296,
"weight": 298,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@@ -7324,7 +7324,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 300,
"weight": 302,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@@ -8153,7 +8153,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 441,
"weight": 443,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-transactions.md",
@@ -8161,7 +8161,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client"
@@ -8218,7 +8221,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 437,
"weight": 439,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-transaction.md",
@@ -8226,7 +8229,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8286,7 +8292,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 438,
"weight": 440,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-transaction.md",
@@ -8294,7 +8300,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client"
@@ -8347,7 +8356,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 439,
"weight": 441,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-transaction.md",
@@ -8355,7 +8364,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8424,7 +8436,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 440,
"weight": 442,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-transaction.md",
@@ -8432,7 +8444,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8487,7 +8502,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 442,
"weight": 444,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-operations.md",
@@ -8495,7 +8510,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8566,7 +8584,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 433,
"weight": 435,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@@ -8658,7 +8676,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 425,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@@ -8807,7 +8825,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 426,
"weight": 428,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@@ -8907,7 +8925,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 429,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@@ -9048,7 +9066,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 427,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@@ -9153,7 +9171,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 431,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@@ -9250,7 +9268,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 436,
"weight": 438,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@@ -9367,7 +9385,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 437,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+60 -41
View File
@@ -5076,7 +5076,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 376,
"weight": 378,
"cookies": false,
"type": "",
"demo": "databases\/list-transactions.md",
@@ -5141,7 +5141,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 372,
"weight": 374,
"cookies": false,
"type": "",
"demo": "databases\/create-transaction.md",
@@ -5209,7 +5209,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 373,
"weight": 375,
"cookies": false,
"type": "",
"demo": "databases\/get-transaction.md",
@@ -5270,7 +5270,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 374,
"weight": 376,
"cookies": false,
"type": "",
"demo": "databases\/update-transaction.md",
@@ -5347,7 +5347,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 375,
"weight": 377,
"cookies": false,
"type": "",
"demo": "databases\/delete-transaction.md",
@@ -5410,7 +5410,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 377,
"weight": 379,
"cookies": false,
"type": "",
"demo": "databases\/create-operations.md",
@@ -5489,7 +5489,7 @@
"x-appwrite": {
"method": "listDocuments",
"group": "documents",
"weight": 335,
"weight": 337,
"cookies": false,
"type": "",
"demo": "databases\/list-documents.md",
@@ -5582,7 +5582,7 @@
"x-appwrite": {
"method": "createDocument",
"group": "documents",
"weight": 327,
"weight": 329,
"cookies": false,
"type": "",
"demo": "databases\/create-document.md",
@@ -5736,7 +5736,7 @@
"x-appwrite": {
"method": "getDocument",
"group": "documents",
"weight": 328,
"weight": 330,
"cookies": false,
"type": "",
"demo": "databases\/get-document.md",
@@ -5837,7 +5837,7 @@
"x-appwrite": {
"method": "upsertDocument",
"group": "documents",
"weight": 331,
"weight": 333,
"cookies": false,
"type": "",
"demo": "databases\/upsert-document.md",
@@ -5987,7 +5987,7 @@
"x-appwrite": {
"method": "updateDocument",
"group": "documents",
"weight": 329,
"weight": 331,
"cookies": false,
"type": "",
"demo": "databases\/update-document.md",
@@ -6093,7 +6093,7 @@
"x-appwrite": {
"method": "deleteDocument",
"group": "documents",
"weight": 333,
"weight": 335,
"cookies": false,
"type": "",
"demo": "databases\/delete-document.md",
@@ -6191,7 +6191,7 @@
"x-appwrite": {
"method": "decrementDocumentAttribute",
"group": "documents",
"weight": 338,
"weight": 340,
"cookies": false,
"type": "",
"demo": "databases\/decrement-document-attribute.md",
@@ -6309,7 +6309,7 @@
"x-appwrite": {
"method": "incrementDocumentAttribute",
"group": "documents",
"weight": 337,
"weight": 339,
"cookies": false,
"type": "",
"demo": "databases\/increment-document-attribute.md",
@@ -6425,7 +6425,7 @@
"x-appwrite": {
"method": "listExecutions",
"group": "executions",
"weight": 468,
"weight": 470,
"cookies": false,
"type": "",
"demo": "functions\/list-executions.md",
@@ -6498,7 +6498,7 @@
"x-appwrite": {
"method": "createExecution",
"group": "executions",
"weight": 466,
"weight": 468,
"cookies": false,
"type": "",
"demo": "functions\/create-execution.md",
@@ -6615,7 +6615,7 @@
"x-appwrite": {
"method": "getExecution",
"group": "executions",
"weight": 467,
"weight": 469,
"cookies": false,
"type": "",
"demo": "functions\/get-execution.md",
@@ -7240,7 +7240,7 @@
"x-appwrite": {
"method": "createSubscriber",
"group": "subscribers",
"weight": 296,
"weight": 298,
"cookies": false,
"type": "",
"demo": "messaging\/create-subscriber.md",
@@ -7324,7 +7324,7 @@
"x-appwrite": {
"method": "deleteSubscriber",
"group": "subscribers",
"weight": 300,
"weight": 302,
"cookies": false,
"type": "",
"demo": "messaging\/delete-subscriber.md",
@@ -8153,7 +8153,7 @@
"x-appwrite": {
"method": "listTransactions",
"group": "transactions",
"weight": 441,
"weight": 443,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-transactions.md",
@@ -8161,7 +8161,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client"
@@ -8218,7 +8221,7 @@
"x-appwrite": {
"method": "createTransaction",
"group": "transactions",
"weight": 437,
"weight": 439,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-transaction.md",
@@ -8226,7 +8229,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8286,7 +8292,7 @@
"x-appwrite": {
"method": "getTransaction",
"group": "transactions",
"weight": 438,
"weight": 440,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-transaction.md",
@@ -8294,7 +8300,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.read",
"scope": [
"documents.read",
"rows.read"
],
"platforms": [
"server",
"client"
@@ -8347,7 +8356,7 @@
"x-appwrite": {
"method": "updateTransaction",
"group": "transactions",
"weight": 439,
"weight": 441,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-transaction.md",
@@ -8355,7 +8364,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8424,7 +8436,7 @@
"x-appwrite": {
"method": "deleteTransaction",
"group": "transactions",
"weight": 440,
"weight": 442,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-transaction.md",
@@ -8432,7 +8444,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8487,7 +8502,7 @@
"x-appwrite": {
"method": "createOperations",
"group": "transactions",
"weight": 442,
"weight": 444,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-operations.md",
@@ -8495,7 +8510,10 @@
"rate-limit": 0,
"rate-time": 3600,
"rate-key": "url:{url},ip:{ip}",
"scope": "rows.write",
"scope": [
"documents.write",
"rows.write"
],
"platforms": [
"server",
"client"
@@ -8566,7 +8584,7 @@
"x-appwrite": {
"method": "listRows",
"group": "rows",
"weight": 433,
"weight": 435,
"cookies": false,
"type": "",
"demo": "tablesdb\/list-rows.md",
@@ -8658,7 +8676,7 @@
"x-appwrite": {
"method": "createRow",
"group": "rows",
"weight": 425,
"weight": 427,
"cookies": false,
"type": "",
"demo": "tablesdb\/create-row.md",
@@ -8807,7 +8825,7 @@
"x-appwrite": {
"method": "getRow",
"group": "rows",
"weight": 426,
"weight": 428,
"cookies": false,
"type": "",
"demo": "tablesdb\/get-row.md",
@@ -8907,7 +8925,7 @@
"x-appwrite": {
"method": "upsertRow",
"group": "rows",
"weight": 429,
"weight": 431,
"cookies": false,
"type": "",
"demo": "tablesdb\/upsert-row.md",
@@ -9048,7 +9066,7 @@
"x-appwrite": {
"method": "updateRow",
"group": "rows",
"weight": 427,
"weight": 429,
"cookies": false,
"type": "",
"demo": "tablesdb\/update-row.md",
@@ -9153,7 +9171,7 @@
"x-appwrite": {
"method": "deleteRow",
"group": "rows",
"weight": 431,
"weight": 433,
"cookies": false,
"type": "",
"demo": "tablesdb\/delete-row.md",
@@ -9250,7 +9268,7 @@
"x-appwrite": {
"method": "decrementRowColumn",
"group": "rows",
"weight": 436,
"weight": 438,
"cookies": false,
"type": "",
"demo": "tablesdb\/decrement-row-column.md",
@@ -9367,7 +9385,7 @@
"x-appwrite": {
"method": "incrementRowColumn",
"group": "rows",
"weight": 435,
"weight": 437,
"cookies": false,
"type": "",
"demo": "tablesdb\/increment-row-column.md",
@@ -12486,13 +12504,14 @@
},
"status": {
"type": "string",
"description": "The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, or `failed`.",
"description": "The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, `failed`, or `scheduled`.",
"x-example": "processing",
"enum": [
"waiting",
"processing",
"completed",
"failed"
"failed",
"scheduled"
]
},
"requestMethod": {
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+78
View File
@@ -9,6 +9,11 @@ use Utopia\System\System;
$protocol = System::getEnv('_APP_OPTIONS_FORCE_HTTPS') === 'disabled' ? 'http' : 'https';
$hostname = System::getEnv('_APP_DOMAIN', '');
// Temporary fix until we can set _APP_DOMAIN to "localhost" instead of "traefik"
if (System::getEnv('_APP_ENV', 'development') === 'development') {
$hostname = 'localhost';
}
$url = $protocol . '://' . $hostname;
class UseCases
@@ -111,6 +116,16 @@ const TEMPLATE_FRAMEWORKS = [
'outputDirectory' => './dist',
'fallbackFile' => '+not-found.html',
],
'TANSTACK_START' => [
'key' => 'tanstack-start',
'name' => 'TanStack Start',
'installCommand' => 'npm install',
'buildCommand' => 'npm run build',
'outputDirectory' => './dist',
'buildRuntime' => 'node-22',
'adapter' => 'ssr',
'fallbackFile' => '',
],
'ANGULAR' => [
'key' => 'angular',
'name' => 'Angular',
@@ -950,6 +965,50 @@ return [
],
]
],
[
'key' => 'starter-for-tanstack-start',
'name' => 'TanStack Start starter',
'useCases' => [UseCases::STARTER],
'tagline' => 'Simple TanStack Start application integrated with Appwrite SDK.',
'score' => 6, // 0 to 10 based on looks of screenshot (avoid 1,2,3,8,9,10 if possible)
'screenshotDark' => $url . '/images/sites/templates/starter-for-tanstack-start-dark.png',
'screenshotLight' => $url . '/images/sites/templates/starter-for-tanstack-start-light.png',
'frameworks' => [
getFramework('TANSTACK_START', [
'providerRootDirectory' => './',
]),
],
'vcsProvider' => 'github',
'providerRepositoryId' => 'starter-for-tanstack-start',
'providerOwner' => 'appwrite',
'providerVersion' => '0.1.*',
'variables' => [
[
'name' => 'VITE_APPWRITE_ENDPOINT',
'description' => 'Endpoint of Appwrite server',
'value' => '{apiEndpoint}',
'placeholder' => '{apiEndpoint}',
'required' => true,
'type' => 'text'
],
[
'name' => 'VITE_APPWRITE_PROJECT_ID',
'description' => 'Your Appwrite project ID',
'value' => '{projectId}',
'placeholder' => '{projectId}',
'required' => true,
'type' => 'text'
],
[
'name' => 'VITE_APPWRITE_PROJECT_NAME',
'description' => 'Your Appwrite project name',
'value' => '{projectName}',
'placeholder' => '{projectName}',
'required' => true,
'type' => 'text'
],
]
],
[
'key' => 'starter-for-nuxt',
'name' => 'Nuxt starter',
@@ -1327,6 +1386,25 @@ return [
'providerVersion' => '0.3.*',
'variables' => [],
],
[
'key' => 'playground-for-tanstack-start',
'name' => 'TanStack Start playground',
'tagline' => 'A basic TanStack Start website without Appwrite SDK integration.',
'score' => 1, // 0 to 10 based on looks of screenshot (avoid 1,2,3,8,9,10 if possible)
'useCases' => [UseCases::STARTER],
'screenshotDark' => $url . '/images/sites/templates/playground-for-tanstack-start-dark.png',
'screenshotLight' => $url . '/images/sites/templates/playground-for-tanstack-start-light.png',
'frameworks' => [
getFramework('TANSTACK_START', [
'providerRootDirectory' => './tanstack-start/starter',
]),
],
'vcsProvider' => 'github',
'providerRepositoryId' => 'templates-for-sites',
'providerOwner' => 'appwrite',
'providerVersion' => '0.5.*',
'variables' => [],
],
[
'key' => 'playground-for-react-native',
'name' => 'React Native playground',
+1
View File
@@ -74,6 +74,7 @@ App::get('/v1/console/variables')
// Combine CAA domain with most common flags and tag (no parameters)
'_APP_DOMAIN_TARGET_CAA' => '0 issue "' . System::getEnv('_APP_DOMAIN_TARGET_CAA') . '"',
'_APP_STORAGE_LIMIT' => +System::getEnv('_APP_STORAGE_LIMIT'),
'_APP_COMPUTE_BUILD_TIMEOUT' => +System::getEnv('_APP_COMPUTE_BUILD_TIMEOUT'),
'_APP_COMPUTE_SIZE_LIMIT' => +System::getEnv('_APP_COMPUTE_SIZE_LIMIT'),
'_APP_USAGE_STATS' => System::getEnv('_APP_USAGE_STATS'),
'_APP_VCS_ENABLED' => $isVcsEnabled,
+180
View File
@@ -231,6 +231,88 @@ App::post('/v1/messaging/providers/sendgrid')
->dynamic($provider, Response::MODEL_PROVIDER);
});
App::post('/v1/messaging/providers/resend')
->desc('Create Resend provider')
->groups(['api', 'messaging'])
->label('audits.event', 'provider.create')
->label('audits.resource', 'provider/{response.$id}')
->label('event', 'providers.[providerId].create')
->label('scope', 'providers.write')
->label('resourceType', RESOURCE_TYPE_PROVIDERS)
->label('sdk', new Method(
namespace: 'messaging',
group: 'providers',
name: 'createResendProvider',
description: '/docs/references/messaging/create-resend-provider.md',
auth: [AuthType::ADMIN, AuthType::KEY],
responses: [
new SDKResponse(
code: Response::STATUS_CODE_CREATED,
model: Response::MODEL_PROVIDER,
)
]
))
->param('providerId', '', new CustomId(), 'Provider 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.')
->param('name', '', new Text(128), 'Provider name.')
->param('apiKey', '', new Text(0), 'Resend API key.', true)
->param('fromName', '', new Text(128, 0), 'Sender Name.', true)
->param('fromEmail', '', new Email(), 'Sender email address.', true)
->param('replyToName', '', new Text(128, 0), 'Name set in the reply to field for the mail. Default value is sender name.', true)
->param('replyToEmail', '', new Email(), 'Email set in the reply to field for the mail. Default value is sender email.', true)
->param('enabled', null, new Boolean(), 'Set as enabled.', true)
->inject('queueForEvents')
->inject('dbForProject')
->inject('response')
->action(function (string $providerId, string $name, string $apiKey, string $fromName, string $fromEmail, string $replyToName, string $replyToEmail, ?bool $enabled, Event $queueForEvents, Database $dbForProject, Response $response) {
$providerId = $providerId == 'unique()' ? ID::unique() : $providerId;
$credentials = [];
if (!empty($apiKey)) {
$credentials['apiKey'] = $apiKey;
}
$options = [
'fromName' => $fromName,
'fromEmail' => $fromEmail,
'replyToName' => $replyToName,
'replyToEmail' => $replyToEmail,
];
if (
$enabled === true
&& !empty($fromEmail)
&& \array_key_exists('apiKey', $credentials)
) {
$enabled = true;
} else {
$enabled = false;
}
$provider = new Document([
'$id' => $providerId,
'name' => $name,
'provider' => 'resend',
'type' => MESSAGE_TYPE_EMAIL,
'enabled' => $enabled,
'credentials' => $credentials,
'options' => $options,
]);
try {
$provider = $dbForProject->createDocument('providers', $provider);
} catch (DuplicateException) {
throw new Exception(Exception::PROVIDER_ALREADY_EXISTS);
}
$queueForEvents
->setParam('providerId', $provider->getId());
$response
->setStatusCode(Response::STATUS_CODE_CREATED)
->dynamic($provider, Response::MODEL_PROVIDER);
});
App::post('/v1/messaging/providers/smtp')
->desc('Create SMTP provider')
->groups(['api', 'messaging'])
@@ -1372,6 +1454,104 @@ App::patch('/v1/messaging/providers/sendgrid/:providerId')
->dynamic($provider, Response::MODEL_PROVIDER);
});
App::patch('/v1/messaging/providers/resend/:providerId')
->desc('Update Resend provider')
->groups(['api', 'messaging'])
->label('audits.event', 'provider.update')
->label('audits.resource', 'provider/{response.$id}')
->label('event', 'providers.[providerId].update')
->label('scope', 'providers.write')
->label('resourceType', RESOURCE_TYPE_PROVIDERS)
->label('sdk', new Method(
namespace: 'messaging',
group: 'providers',
name: 'updateResendProvider',
description: '/docs/references/messaging/update-resend-provider.md',
auth: [AuthType::ADMIN, AuthType::KEY],
responses: [
new SDKResponse(
code: Response::STATUS_CODE_OK,
model: Response::MODEL_PROVIDER,
)
]
))
->param('providerId', '', new UID(), 'Provider ID.')
->param('name', '', new Text(128), 'Provider name.', true)
->param('enabled', null, new Boolean(), 'Set as enabled.', true)
->param('apiKey', '', new Text(0), 'Resend API key.', true)
->param('fromName', '', new Text(128), 'Sender Name.', true)
->param('fromEmail', '', new Email(), 'Sender email address.', true)
->param('replyToName', '', new Text(128), 'Name set in the Reply To field for the mail. Default value is Sender Name.', true)
->param('replyToEmail', '', new Text(128), 'Email set in the Reply To field for the mail. Default value is Sender Email.', true)
->inject('queueForEvents')
->inject('dbForProject')
->inject('response')
->action(function (string $providerId, string $name, ?bool $enabled, string $apiKey, string $fromName, string $fromEmail, string $replyToName, string $replyToEmail, Event $queueForEvents, Database $dbForProject, Response $response) {
$provider = $dbForProject->getDocument('providers', $providerId);
if ($provider->isEmpty()) {
throw new Exception(Exception::PROVIDER_NOT_FOUND);
}
$providerAttr = $provider->getAttribute('provider');
if ($providerAttr !== 'resend') {
throw new Exception(Exception::PROVIDER_INCORRECT_TYPE);
}
if (!empty($name)) {
$provider->setAttribute('name', $name);
}
$options = $provider->getAttribute('options');
if (!empty($fromName)) {
$options['fromName'] = $fromName;
}
if (!empty($fromEmail)) {
$options['fromEmail'] = $fromEmail;
}
if (!empty($replyToName)) {
$options['replyToName'] = $replyToName;
}
if (!empty($replyToEmail)) {
$options['replyToEmail'] = $replyToEmail;
}
$provider->setAttribute('options', $options);
if (!empty($apiKey)) {
$provider->setAttribute('credentials', [
'apiKey' => $apiKey,
]);
}
if (!\is_null($enabled)) {
if ($enabled) {
if (
\array_key_exists('apiKey', $provider->getAttribute('credentials')) &&
\array_key_exists('fromEmail', $provider->getAttribute('options'))
) {
$provider->setAttribute('enabled', true);
} else {
throw new Exception(Exception::PROVIDER_MISSING_CREDENTIALS);
}
} else {
$provider->setAttribute('enabled', false);
}
}
$provider = $dbForProject->updateDocument('providers', $provider->getId(), $provider);
$queueForEvents
->setParam('providerId', $provider->getId());
$response
->dynamic($provider, Response::MODEL_PROVIDER);
});
App::patch('/v1/messaging/providers/smtp/:providerId')
->desc('Update SMTP provider')
->groups(['api', 'messaging'])
+95 -18
View File
@@ -29,12 +29,20 @@ use Utopia\Database\Helpers\Role;
use Utopia\Database\Query;
use Utopia\Database\Validator\Authorization;
use Utopia\Database\Validator\Query\Cursor;
use Utopia\Detector\Detection\Framework\Analog;
use Utopia\Detector\Detection\Framework\Angular;
use Utopia\Detector\Detection\Framework\Astro;
use Utopia\Detector\Detection\Framework\Flutter;
use Utopia\Detector\Detection\Framework\Lynx;
use Utopia\Detector\Detection\Framework\NextJs;
use Utopia\Detector\Detection\Framework\Nuxt;
use Utopia\Detector\Detection\Framework\React;
use Utopia\Detector\Detection\Framework\ReactNative;
use Utopia\Detector\Detection\Framework\Remix;
use Utopia\Detector\Detection\Framework\Svelte;
use Utopia\Detector\Detection\Framework\SvelteKit;
use Utopia\Detector\Detection\Framework\TanStackStart;
use Utopia\Detector\Detection\Framework\Vue;
use Utopia\Detector\Detection\Packager\NPM;
use Utopia\Detector\Detection\Packager\PNPM;
use Utopia\Detector\Detection\Packager\Yarn;
@@ -58,6 +66,7 @@ use Utopia\Validator\Boolean;
use Utopia\Validator\Text;
use Utopia\Validator\WhiteList;
use Utopia\VCS\Adapter\Git\GitHub;
use Utopia\VCS\Exception\FileNotFound;
use Utopia\VCS\Exception\RepositoryNotFound;
use function Swoole\Coroutine\batch;
@@ -166,7 +175,7 @@ $createGitDeployments = function (GitHub $github, string $providerInstallationId
$latestCommentId = \strval($github->updateComment($owner, $repositoryName, $latestCommentId, $comment->generateComment()));
} finally {
$dbForPlatform->deleteDocument('vcsCommentLocks', $latestCommentId);
Authorization::skip(fn () => $dbForPlatform->deleteDocument('vcsCommentLocks', $latestCommentId));
}
}
} else {
@@ -237,7 +246,7 @@ $createGitDeployments = function (GitHub $github, string $providerInstallationId
$latestCommentId = \strval($github->updateComment($owner, $repositoryName, $latestCommentId, $comment->generateComment()));
} finally {
$dbForPlatform->deleteDocument('vcsCommentLocks', $latestCommentId);
Authorization::skip(fn () => $dbForPlatform->deleteDocument('vcsCommentLocks', $latestCommentId));
}
}
}
@@ -458,7 +467,7 @@ $createGitDeployments = function (GitHub $github, string $providerInstallationId
$github->updateComment($owner, $repositoryName, $latestCommentId, $comment->generateComment());
}
} finally {
$dbForPlatform->deleteDocument('vcsCommentLocks', $latestCommentId);
Authorization::skip(fn () => $dbForPlatform->deleteDocument('vcsCommentLocks', $latestCommentId));
}
}
}
@@ -818,7 +827,10 @@ App::post('/v1/vcs/github/installations/:installationId/detections')
$files = \array_column($files, 'name');
$languages = $github->listRepositoryLanguages($owner, $repositoryName);
$detector = new Packager($files);
$detector = new Packager();
foreach ($files as $file) {
$detector->addInput($file);
}
$detector
->addOption(new Yarn())
->addOption(new PNPM())
@@ -828,6 +840,14 @@ App::post('/v1/vcs/github/installations/:installationId/detections')
$packager = !\is_null($detection) ? $detection->getName() : 'npm';
if ($type === 'framework') {
$packages = '';
try {
$contentResponse = $github->getRepositoryContent($owner, $repositoryName, \rtrim($providerRootDirectory, '/') . '/package.json');
$packages = $contentResponse['content'] ?? '';
} catch (FileNotFound $e) {
// Continue detection without package.json
}
$output = new Document([
'framework' => '',
'installCommand' => '',
@@ -835,14 +855,27 @@ App::post('/v1/vcs/github/installations/:installationId/detections')
'outputDirectory' => '',
]);
$detector = new Framework($files, $packager);
$detector = new Framework($packager);
$detector->addInput($packages, Framework::INPUT_PACKAGES);
foreach ($files as $file) {
$detector->addInput($file, Framework::INPUT_FILE);
}
$detector
->addOption(new Flutter())
->addOption(new Nuxt())
->addOption(new Analog())
->addOption(new Angular())
->addOption(new Astro())
->addOption(new SvelteKit())
->addOption(new Flutter())
->addOption(new Lynx())
->addOption(new NextJs())
->addOption(new Remix());
->addOption(new Nuxt())
->addOption(new React())
->addOption(new ReactNative())
->addOption(new Remix())
->addOption(new Svelte())
->addOption(new SvelteKit())
->addOption(new TanStackStart())
->addOption(new Vue());
$framework = $detector->detect();
@@ -877,7 +910,18 @@ App::post('/v1/vcs/github/installations/:installationId/detections')
];
foreach ($strategies as $strategy) {
$detector = new Runtime($strategy === Strategy::LANGUAGES ? $languages : $files, $strategy, $packager);
$detector = new Runtime($strategy, $packager);
if ($strategy === Strategy::LANGUAGES) {
foreach ($languages as $language) {
$detector->addInput($language);
}
} else {
foreach ($files as $file) {
$detector->addInput($file);
}
}
$detector
->addOption(new Node())
->addOption(new Bun())
@@ -984,7 +1028,10 @@ App::get('/v1/vcs/github/installations/:installationId/providerRepositories')
$files = $github->listRepositoryContents($repo['organization'], $repo['name'], '');
$files = \array_column($files, 'name');
$detector = new Packager($files);
$detector = new Packager();
foreach ($files as $file) {
$detector->addInput($file);
}
$detector
->addOption(new Yarn())
->addOption(new PNPM())
@@ -994,14 +1041,35 @@ App::get('/v1/vcs/github/installations/:installationId/providerRepositories')
$packager = !\is_null($detection) ? $detection->getName() : 'npm';
if ($type === 'framework') {
$frameworkDetector = new Framework($files, $packager);
$packages = '';
try {
$contentResponse = $github->getRepositoryContent($repo['organization'], $repo['name'], 'package.json');
$packages = $contentResponse['content'] ?? '';
} catch (FileNotFound $e) {
// Continue detection without package.json
}
$frameworkDetector = new Framework($packager);
$frameworkDetector->addInput($packages, Framework::INPUT_PACKAGES);
foreach ($files as $file) {
$frameworkDetector->addInput($file, Framework::INPUT_FILE);
}
$frameworkDetector
->addOption(new Flutter())
->addOption(new Nuxt())
->addOption(new Analog())
->addOption(new Angular())
->addOption(new Astro())
->addOption(new SvelteKit())
->addOption(new Flutter())
->addOption(new Lynx())
->addOption(new NextJs())
->addOption(new Remix());
->addOption(new Nuxt())
->addOption(new React())
->addOption(new ReactNative())
->addOption(new Remix())
->addOption(new Svelte())
->addOption(new SvelteKit())
->addOption(new TanStackStart())
->addOption(new Vue());
$detectedFramework = $frameworkDetector->detect();
@@ -1026,7 +1094,16 @@ App::get('/v1/vcs/github/installations/:installationId/providerRepositories')
];
foreach ($strategies as $strategy) {
$detector = new Runtime($strategy === Strategy::LANGUAGES ? $languages : $files, $strategy, $packager);
$detector = new Runtime($strategy, $packager);
if ($strategy === Strategy::LANGUAGES) {
foreach ($languages as $language) {
$detector->addInput($language);
}
} else {
foreach ($files as $file) {
$detector->addInput($file);
}
}
$detector
->addOption(new Node())
->addOption(new Bun())
@@ -1374,7 +1451,7 @@ App::post('/v1/vcs/github/events')
Authorization::skip(fn () => $dbForPlatform->deleteDocument('repositories', $repository->getId()));
}
$dbForPlatform->deleteDocument('installations', $installation->getId());
Authorization::skip(fn () => $dbForPlatform->deleteDocument('installations', $installation->getId()));
}
}
} elseif ($event == $github::EVENT_PULL_REQUEST) {
+1
View File
@@ -90,6 +90,7 @@ const APP_PLATFORM_CLIENT = 'client';
const APP_PLATFORM_CONSOLE = 'console';
const APP_VCS_GITHUB_USERNAME = 'Appwrite';
const APP_VCS_GITHUB_EMAIL = 'team@appwrite.io';
const APP_VCS_GITHUB_URL = 'https://github.com/TeamAppwrite';
const APP_BRANDED_EMAIL_BASE_TEMPLATE = 'email-base-styled';
// Database Reconnect
+5 -5
View File
@@ -52,9 +52,9 @@
"utopia-php/cache": "0.13.*",
"utopia-php/cli": "0.15.*",
"utopia-php/config": "0.2.*",
"utopia-php/database": "2.*",
"utopia-php/detector": "0.1.*",
"utopia-php/domains": "0.8.*",
"utopia-php/database": "3.*",
"utopia-php/detector": "0.2.*",
"utopia-php/domains": "dev-update-opensrs-adapter-authcode",
"utopia-php/dns": "0.3.*",
"utopia-php/dsn": "0.2.1",
"utopia-php/framework": "0.33.*",
@@ -62,7 +62,7 @@
"utopia-php/image": "0.8.*",
"utopia-php/locale": "0.8.*",
"utopia-php/logger": "0.6.*",
"utopia-php/messaging": "0.19.*",
"utopia-php/messaging": "0.20.*",
"utopia-php/migration": "1.*",
"utopia-php/orchestration": "0.9.*",
"utopia-php/platform": "0.7.*",
@@ -74,7 +74,7 @@
"utopia-php/swoole": "0.8.*",
"utopia-php/system": "0.9.*",
"utopia-php/telemetry": "0.1.*",
"utopia-php/vcs": "0.11.*",
"utopia-php/vcs": "0.12.*",
"utopia-php/websocket": "0.3.*",
"matomo/device-detector": "6.4.*",
"dragonmantank/cron-expression": "3.4.*",
Generated
+414 -98
View File
@@ -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": "568800edca746c4e8d0d50648b25f589",
"content-hash": "da953f772e92288a416c2e2ac8ad4d0a",
"packages": [
{
"name": "adhocore/jwt",
@@ -756,16 +756,16 @@
},
{
"name": "google/protobuf",
"version": "v4.32.1",
"version": "v4.33.0",
"source": {
"type": "git",
"url": "https://github.com/protocolbuffers/protobuf-php.git",
"reference": "c4ed1c1f9bbc1e91766e2cd6c0af749324fe87cb"
"reference": "b50269e23204e5ae859a326ec3d90f09efe3047d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/protocolbuffers/protobuf-php/zipball/c4ed1c1f9bbc1e91766e2cd6c0af749324fe87cb",
"reference": "c4ed1c1f9bbc1e91766e2cd6c0af749324fe87cb",
"url": "https://api.github.com/repos/protocolbuffers/protobuf-php/zipball/b50269e23204e5ae859a326ec3d90f09efe3047d",
"reference": "b50269e23204e5ae859a326ec3d90f09efe3047d",
"shasum": ""
},
"require": {
@@ -794,9 +794,9 @@
"proto"
],
"support": {
"source": "https://github.com/protocolbuffers/protobuf-php/tree/v4.32.1"
"source": "https://github.com/protocolbuffers/protobuf-php/tree/v4.33.0"
},
"time": "2025-09-14T05:14:52+00:00"
"time": "2025-10-15T20:10:28+00:00"
},
{
"name": "league/csv",
@@ -959,6 +959,83 @@
},
"time": "2025-08-20T17:20:16+00:00"
},
{
"name": "mongodb/mongodb",
"version": "2.1.1",
"source": {
"type": "git",
"url": "https://github.com/mongodb/mongo-php-library.git",
"reference": "f399d24905dd42f97dfe0af9706129743ef247ac"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/mongodb/mongo-php-library/zipball/f399d24905dd42f97dfe0af9706129743ef247ac",
"reference": "f399d24905dd42f97dfe0af9706129743ef247ac",
"shasum": ""
},
"require": {
"composer-runtime-api": "^2.0",
"ext-mongodb": "^2.1",
"php": "^8.1",
"psr/log": "^1.1.4|^2|^3",
"symfony/polyfill-php85": "^1.32"
},
"replace": {
"mongodb/builder": "*"
},
"require-dev": {
"doctrine/coding-standard": "^12.0",
"phpunit/phpunit": "^10.5.35",
"rector/rector": "^1.2",
"squizlabs/php_codesniffer": "^3.7",
"vimeo/psalm": "6.5.*"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.x-dev"
}
},
"autoload": {
"files": [
"src/functions.php"
],
"psr-4": {
"MongoDB\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"Apache-2.0"
],
"authors": [
{
"name": "Andreas Braun",
"email": "andreas.braun@mongodb.com"
},
{
"name": "Jeremy Mikola",
"email": "jmikola@gmail.com"
},
{
"name": "Jérôme Tamarelle",
"email": "jerome.tamarelle@mongodb.com"
}
],
"description": "MongoDB driver library",
"homepage": "https://jira.mongodb.org/browse/PHPLIB",
"keywords": [
"database",
"driver",
"mongodb",
"persistence"
],
"support": {
"issues": "https://github.com/mongodb/mongo-php-library/issues",
"source": "https://github.com/mongodb/mongo-php-library/tree/2.1.1"
},
"time": "2025-08-13T20:50:05+00:00"
},
{
"name": "mustangostang/spyc",
"version": "0.6.3",
@@ -3017,6 +3094,86 @@
],
"time": "2025-07-08T02:45:35+00:00"
},
{
"name": "symfony/polyfill-php85",
"version": "v1.33.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php85.git",
"reference": "d4e5fcd4ab3d998ab16c0db48e6cbb9a01993f91"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php85/zipball/d4e5fcd4ab3d998ab16c0db48e6cbb9a01993f91",
"reference": "d4e5fcd4ab3d998ab16c0db48e6cbb9a01993f91",
"shasum": ""
},
"require": {
"php": ">=7.2"
},
"type": "library",
"extra": {
"thanks": {
"url": "https://github.com/symfony/polyfill",
"name": "symfony/polyfill"
}
},
"autoload": {
"files": [
"bootstrap.php"
],
"psr-4": {
"Symfony\\Polyfill\\Php85\\": ""
},
"classmap": [
"Resources/stubs"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Nicolas Grekas",
"email": "p@tchwork.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony polyfill backporting some PHP 8.5+ features to lower PHP versions",
"homepage": "https://symfony.com",
"keywords": [
"compatibility",
"polyfill",
"portable",
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-php85/tree/v1.33.0"
},
"funding": [
{
"url": "https://symfony.com/sponsor",
"type": "custom"
},
{
"url": "https://github.com/fabpot",
"type": "github"
},
{
"url": "https://github.com/nicolas-grekas",
"type": "github"
},
{
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
"type": "tidelift"
}
],
"time": "2025-06-23T16:12:55+00:00"
},
{
"name": "symfony/service-contracts",
"version": "v3.6.0",
@@ -3293,16 +3450,16 @@
},
{
"name": "utopia-php/abuse",
"version": "1.0.1",
"version": "1.0.2",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/abuse.git",
"reference": "cd591568791556d246d901d6aaf9935ab02c3f9a"
"reference": "611fa66a97e87c0dbbc133a717d970da7a5ca828"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/abuse/zipball/cd591568791556d246d901d6aaf9935ab02c3f9a",
"reference": "cd591568791556d246d901d6aaf9935ab02c3f9a",
"url": "https://api.github.com/repos/utopia-php/abuse/zipball/611fa66a97e87c0dbbc133a717d970da7a5ca828",
"reference": "611fa66a97e87c0dbbc133a717d970da7a5ca828",
"shasum": ""
},
"require": {
@@ -3310,7 +3467,7 @@
"ext-pdo": "*",
"ext-redis": "*",
"php": ">=8.0",
"utopia-php/database": "2.*"
"utopia-php/database": "*"
},
"require-dev": {
"laravel/pint": "1.*",
@@ -3338,9 +3495,9 @@
],
"support": {
"issues": "https://github.com/utopia-php/abuse/issues",
"source": "https://github.com/utopia-php/abuse/tree/1.0.1"
"source": "https://github.com/utopia-php/abuse/tree/1.0.2"
},
"time": "2025-09-04T12:46:54+00:00"
"time": "2025-10-20T07:18:33+00:00"
},
{
"name": "utopia-php/analytics",
@@ -3390,21 +3547,21 @@
},
{
"name": "utopia-php/audit",
"version": "1.0.1",
"version": "1.0.2",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/audit.git",
"reference": "5ef26d6a2ab2db7bb86288a1a6ef970307b46f22"
"reference": "8c17065c2473d4ca799f65585ca74eb53e1be211"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/audit/zipball/5ef26d6a2ab2db7bb86288a1a6ef970307b46f22",
"reference": "5ef26d6a2ab2db7bb86288a1a6ef970307b46f22",
"url": "https://api.github.com/repos/utopia-php/audit/zipball/8c17065c2473d4ca799f65585ca74eb53e1be211",
"reference": "8c17065c2473d4ca799f65585ca74eb53e1be211",
"shasum": ""
},
"require": {
"php": ">=8.0",
"utopia-php/database": "2.*"
"utopia-php/database": "*"
},
"require-dev": {
"laravel/pint": "1.*",
@@ -3431,9 +3588,9 @@
],
"support": {
"issues": "https://github.com/utopia-php/audit/issues",
"source": "https://github.com/utopia-php/audit/tree/1.0.1"
"source": "https://github.com/utopia-php/audit/tree/1.0.2"
},
"time": "2025-09-04T12:46:43+00:00"
"time": "2025-10-20T07:14:26+00:00"
},
{
"name": "utopia-php/cache",
@@ -3634,30 +3791,80 @@
"time": "2020-10-24T09:49:09+00:00"
},
{
"name": "utopia-php/database",
"version": "2.3.2",
"name": "utopia-php/console",
"version": "0.0.1",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/database.git",
"reference": "35c978ddd20b649d119296094686d3cc9fcf161f"
"url": "https://github.com/utopia-php/console.git",
"reference": "f77104e4a888fa9cb3e08f32955ec09479ab7a92"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/database/zipball/35c978ddd20b649d119296094686d3cc9fcf161f",
"reference": "35c978ddd20b649d119296094686d3cc9fcf161f",
"url": "https://api.github.com/repos/utopia-php/console/zipball/f77104e4a888fa9cb3e08f32955ec09479ab7a92",
"reference": "f77104e4a888fa9cb3e08f32955ec09479ab7a92",
"shasum": ""
},
"require": {
"php": ">=7.4"
},
"require-dev": {
"laravel/pint": "1.2.*",
"phpstan/phpstan": "^1.10",
"phpunit/phpunit": "^9.3",
"squizlabs/php_codesniffer": "^3.6",
"swoole/ide-helper": "4.8.8"
},
"type": "library",
"autoload": {
"psr-4": {
"Utopia\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"description": "Console helpers for logging, prompting, and executing commands",
"keywords": [
"cli",
"console",
"php",
"terminal",
"utopia"
],
"support": {
"issues": "https://github.com/utopia-php/console/issues",
"source": "https://github.com/utopia-php/console/tree/0.0.1"
},
"time": "2025-10-20T14:41:36+00:00"
},
{
"name": "utopia-php/database",
"version": "3.0.2",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/database.git",
"reference": "b92554e2e7b3b00f0f0acb2b53c6a11e1349b81e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/database/zipball/b92554e2e7b3b00f0f0acb2b53c6a11e1349b81e",
"reference": "b92554e2e7b3b00f0f0acb2b53c6a11e1349b81e",
"shasum": ""
},
"require": {
"ext-mbstring": "*",
"ext-mongodb": "*",
"ext-pdo": "*",
"php": ">=8.1",
"utopia-php/cache": "0.13.*",
"utopia-php/framework": "0.33.*",
"utopia-php/mongo": "0.11.*",
"utopia-php/pools": "0.8.*"
},
"require-dev": {
"fakerphp/faker": "1.23.*",
"laravel/pint": "1.*",
"laravel/pint": "*",
"pcov/clobber": "2.*",
"phpstan/phpstan": "1.*",
"phpunit/phpunit": "9.*",
@@ -3685,22 +3892,22 @@
],
"support": {
"issues": "https://github.com/utopia-php/database/issues",
"source": "https://github.com/utopia-php/database/tree/2.3.2"
"source": "https://github.com/utopia-php/database/tree/3.0.2"
},
"time": "2025-10-07T03:09:32+00:00"
"time": "2025-10-20T23:58:56+00:00"
},
{
"name": "utopia-php/detector",
"version": "0.1.5",
"version": "0.2.0",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/detector.git",
"reference": "b5d6ba51352485b524589bc0ee8d07a9efafe718"
"reference": "795ed56169af833fd6a4ea58a6c747e05ccc7ba6"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/detector/zipball/b5d6ba51352485b524589bc0ee8d07a9efafe718",
"reference": "b5d6ba51352485b524589bc0ee8d07a9efafe718",
"url": "https://api.github.com/repos/utopia-php/detector/zipball/795ed56169af833fd6a4ea58a6c747e05ccc7ba6",
"reference": "795ed56169af833fd6a4ea58a6c747e05ccc7ba6",
"shasum": ""
},
"require": {
@@ -3730,9 +3937,9 @@
],
"support": {
"issues": "https://github.com/utopia-php/detector/issues",
"source": "https://github.com/utopia-php/detector/tree/0.1.5"
"source": "https://github.com/utopia-php/detector/tree/0.2.0"
},
"time": "2025-05-19T11:01:28+00:00"
"time": "2025-10-21T13:57:30+00:00"
},
{
"name": "utopia-php/dns",
@@ -3792,21 +3999,22 @@
},
{
"name": "utopia-php/domains",
"version": "0.8.2",
"version": "dev-update-opensrs-adapter-authcode",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/domains.git",
"reference": "caa294dcebd05c8af876c8afef3e992faccdf645"
"reference": "e0b1452609e8f3465bb73cb3eb0a61520b35ae5d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/domains/zipball/caa294dcebd05c8af876c8afef3e992faccdf645",
"reference": "caa294dcebd05c8af876c8afef3e992faccdf645",
"url": "https://api.github.com/repos/utopia-php/domains/zipball/e0b1452609e8f3465bb73cb3eb0a61520b35ae5d",
"reference": "e0b1452609e8f3465bb73cb3eb0a61520b35ae5d",
"shasum": ""
},
"require": {
"php": ">=8.0",
"utopia-php/framework": "0.33.*"
"utopia-php/cache": "0.13.*",
"utopia-php/validators": "0.0.*"
},
"require-dev": {
"laravel/pint": "1.2.*",
@@ -3847,9 +4055,9 @@
],
"support": {
"issues": "https://github.com/utopia-php/domains/issues",
"source": "https://github.com/utopia-php/domains/tree/0.8.2"
"source": "https://github.com/utopia-php/domains/tree/update-opensrs-adapter-authcode"
},
"time": "2025-10-06T09:56:54+00:00"
"time": "2025-10-27T11:48:32+00:00"
},
{
"name": "utopia-php/dsn",
@@ -4136,16 +4344,16 @@
},
{
"name": "utopia-php/messaging",
"version": "0.19.0",
"version": "0.20.0",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/messaging.git",
"reference": "0b866d54e70c792a3c4f5ca9c12a6d358a31f4b8"
"reference": "6c5be4588d97e3732a1907ecb13cd8a098eade96"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/messaging/zipball/0b866d54e70c792a3c4f5ca9c12a6d358a31f4b8",
"reference": "0b866d54e70c792a3c4f5ca9c12a6d358a31f4b8",
"url": "https://api.github.com/repos/utopia-php/messaging/zipball/6c5be4588d97e3732a1907ecb13cd8a098eade96",
"reference": "6c5be4588d97e3732a1907ecb13cd8a098eade96",
"shasum": ""
},
"require": {
@@ -4181,22 +4389,22 @@
],
"support": {
"issues": "https://github.com/utopia-php/messaging/issues",
"source": "https://github.com/utopia-php/messaging/tree/0.19.0"
"source": "https://github.com/utopia-php/messaging/tree/0.20.0"
},
"time": "2025-10-14T11:46:49+00:00"
"time": "2025-10-22T04:27:37+00:00"
},
{
"name": "utopia-php/migration",
"version": "1.1.0",
"version": "1.3.2",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/migration.git",
"reference": "6fb6f8f032cd34c3c65728a55d494adeac2ff038"
"reference": "f5c1d2cae764290766a4c2d1546c1d51de95b67f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/migration/zipball/6fb6f8f032cd34c3c65728a55d494adeac2ff038",
"reference": "6fb6f8f032cd34c3c65728a55d494adeac2ff038",
"url": "https://api.github.com/repos/utopia-php/migration/zipball/f5c1d2cae764290766a4c2d1546c1d51de95b67f",
"reference": "f5c1d2cae764290766a4c2d1546c1d51de95b67f",
"shasum": ""
},
"require": {
@@ -4204,9 +4412,9 @@
"ext-curl": "*",
"ext-openssl": "*",
"php": ">=8.1",
"utopia-php/database": "2.*",
"utopia-php/console": "0.0.*",
"utopia-php/database": "3.*",
"utopia-php/dsn": "0.2.*",
"utopia-php/framework": "0.33.*",
"utopia-php/storage": "0.18.*"
},
"require-dev": {
@@ -4214,7 +4422,6 @@
"laravel/pint": "1.*",
"phpstan/phpstan": "1.*",
"phpunit/phpunit": "11.*",
"utopia-php/cli": "0.16.*",
"vlucas/phpdotenv": "5.*"
},
"type": "library",
@@ -4237,9 +4444,70 @@
],
"support": {
"issues": "https://github.com/utopia-php/migration/issues",
"source": "https://github.com/utopia-php/migration/tree/1.1.0"
"source": "https://github.com/utopia-php/migration/tree/1.3.2"
},
"time": "2025-09-10T05:45:30+00:00"
"time": "2025-10-22T12:30:47+00:00"
},
{
"name": "utopia-php/mongo",
"version": "0.11.0",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/mongo.git",
"reference": "34bc0cda8ea368cde68702a6fffe2c3ac625398e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/mongo/zipball/34bc0cda8ea368cde68702a6fffe2c3ac625398e",
"reference": "34bc0cda8ea368cde68702a6fffe2c3ac625398e",
"shasum": ""
},
"require": {
"ext-mongodb": "2.1.*",
"mongodb/mongodb": "2.1.*",
"php": ">=8.0",
"ramsey/uuid": "4.9.*"
},
"require-dev": {
"fakerphp/faker": "1.*",
"laravel/pint": "*",
"phpstan/phpstan": "*",
"phpunit/phpunit": "9.*",
"swoole/ide-helper": "5.1.*"
},
"type": "library",
"autoload": {
"psr-4": {
"Utopia\\Mongo\\": "src"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Eldad Fux",
"email": "eldad@appwrite.io"
},
{
"name": "Wess",
"email": "wess@appwrite.io"
}
],
"description": "A simple library to manage Mongo database",
"keywords": [
"database",
"mongo",
"php",
"upf",
"utopia"
],
"support": {
"issues": "https://github.com/utopia-php/mongo/issues",
"source": "https://github.com/utopia-php/mongo/tree/0.11.0"
},
"time": "2025-10-20T11:11:23+00:00"
},
{
"name": "utopia-php/orchestration",
@@ -4780,17 +5048,63 @@
"time": "2025-03-17T11:57:52+00:00"
},
{
"name": "utopia-php/vcs",
"version": "0.11.0",
"name": "utopia-php/validators",
"version": "0.0.2",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/vcs.git",
"reference": "0e665eaa7d906168525bf6aac50b6bcc3e4fe528"
"url": "https://github.com/utopia-php/validators.git",
"reference": "894210695c5d35fa248fb65f7fe7237b6ff4fb0b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/vcs/zipball/0e665eaa7d906168525bf6aac50b6bcc3e4fe528",
"reference": "0e665eaa7d906168525bf6aac50b6bcc3e4fe528",
"url": "https://api.github.com/repos/utopia-php/validators/zipball/894210695c5d35fa248fb65f7fe7237b6ff4fb0b",
"reference": "894210695c5d35fa248fb65f7fe7237b6ff4fb0b",
"shasum": ""
},
"require": {
"php": ">=8.1"
},
"require-dev": {
"ext-xdebug": "*",
"laravel/pint": "^1.2",
"phpstan/phpstan": "1.*",
"phpunit/phpunit": "^9.5.25"
},
"type": "library",
"autoload": {
"psr-4": {
"Utopia\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"description": "A lightweight collection of reusable validators for Utopia projects",
"keywords": [
"php",
"utopia",
"validation",
"validator"
],
"support": {
"issues": "https://github.com/utopia-php/validators/issues",
"source": "https://github.com/utopia-php/validators/tree/0.0.2"
},
"time": "2025-10-20T21:52:28+00:00"
},
{
"name": "utopia-php/vcs",
"version": "0.12.0",
"source": {
"type": "git",
"url": "https://github.com/utopia-php/vcs.git",
"reference": "28457cf347972c4ec95d3ca77776a4921364a665"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/utopia-php/vcs/zipball/28457cf347972c4ec95d3ca77776a4921364a665",
"reference": "28457cf347972c4ec95d3ca77776a4921364a665",
"shasum": ""
},
"require": {
@@ -4824,9 +5138,9 @@
],
"support": {
"issues": "https://github.com/utopia-php/vcs/issues",
"source": "https://github.com/utopia-php/vcs/tree/0.11.0"
"source": "https://github.com/utopia-php/vcs/tree/0.12.0"
},
"time": "2025-07-23T13:54:58+00:00"
"time": "2025-10-22T12:58:29+00:00"
},
{
"name": "utopia-php/websocket",
@@ -4879,28 +5193,28 @@
},
{
"name": "webmozart/assert",
"version": "1.11.0",
"version": "1.12.0",
"source": {
"type": "git",
"url": "https://github.com/webmozarts/assert.git",
"reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991"
"reference": "541057574806f942c94662b817a50f63f7345360"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991",
"reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991",
"url": "https://api.github.com/repos/webmozarts/assert/zipball/541057574806f942c94662b817a50f63f7345360",
"reference": "541057574806f942c94662b817a50f63f7345360",
"shasum": ""
},
"require": {
"ext-ctype": "*",
"ext-date": "*",
"ext-filter": "*",
"php": "^7.2 || ^8.0"
},
"conflict": {
"phpstan/phpstan": "<0.12.20",
"vimeo/psalm": "<4.6.1 || 4.6.2"
},
"require-dev": {
"phpunit/phpunit": "^8.5.13"
"suggest": {
"ext-intl": "",
"ext-simplexml": "",
"ext-spl": ""
},
"type": "library",
"extra": {
@@ -4931,9 +5245,9 @@
],
"support": {
"issues": "https://github.com/webmozarts/assert/issues",
"source": "https://github.com/webmozarts/assert/tree/1.11.0"
"source": "https://github.com/webmozarts/assert/tree/1.12.0"
},
"time": "2022-06-03T18:03:27+00:00"
"time": "2025-10-20T12:43:39+00:00"
},
{
"name": "webonyx/graphql-php",
@@ -5004,16 +5318,16 @@
"packages-dev": [
{
"name": "appwrite/sdk-generator",
"version": "1.4.4",
"version": "1.4.14",
"source": {
"type": "git",
"url": "https://github.com/appwrite/sdk-generator.git",
"reference": "a20b20cfd70a1879f0d0fb2b4f669aa5ed836c49"
"reference": "b9405ccaeac5619c76558a82b7bfeb440b665b9f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/a20b20cfd70a1879f0d0fb2b4f669aa5ed836c49",
"reference": "a20b20cfd70a1879f0d0fb2b4f669aa5ed836c49",
"url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/b9405ccaeac5619c76558a82b7bfeb440b665b9f",
"reference": "b9405ccaeac5619c76558a82b7bfeb440b665b9f",
"shasum": ""
},
"require": {
@@ -5049,9 +5363,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.4.4"
"source": "https://github.com/appwrite/sdk-generator/tree/1.4.14"
},
"time": "2025-10-13T09:20:49+00:00"
"time": "2025-10-27T11:17:01+00:00"
},
{
"name": "doctrine/annotations",
@@ -5528,16 +5842,16 @@
},
{
"name": "nikic/php-parser",
"version": "v5.6.1",
"version": "v5.6.2",
"source": {
"type": "git",
"url": "https://github.com/nikic/PHP-Parser.git",
"reference": "f103601b29efebd7ff4a1ca7b3eeea9e3336a2a2"
"reference": "3a454ca033b9e06b63282ce19562e892747449bb"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/f103601b29efebd7ff4a1ca7b3eeea9e3336a2a2",
"reference": "f103601b29efebd7ff4a1ca7b3eeea9e3336a2a2",
"url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/3a454ca033b9e06b63282ce19562e892747449bb",
"reference": "3a454ca033b9e06b63282ce19562e892747449bb",
"shasum": ""
},
"require": {
@@ -5580,9 +5894,9 @@
],
"support": {
"issues": "https://github.com/nikic/PHP-Parser/issues",
"source": "https://github.com/nikic/PHP-Parser/tree/v5.6.1"
"source": "https://github.com/nikic/PHP-Parser/tree/v5.6.2"
},
"time": "2025-08-13T20:13:15+00:00"
"time": "2025-10-21T19:32:17+00:00"
},
{
"name": "phar-io/manifest",
@@ -5755,16 +6069,16 @@
},
{
"name": "phpbench/phpbench",
"version": "1.4.1",
"version": "1.4.2",
"source": {
"type": "git",
"url": "https://github.com/phpbench/phpbench.git",
"reference": "78cd98a9aa34e0f8f80ca01972a8b88d2c30194b"
"reference": "bb61ae6c54b3d58642be154eb09f4e73c3511018"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpbench/phpbench/zipball/78cd98a9aa34e0f8f80ca01972a8b88d2c30194b",
"reference": "78cd98a9aa34e0f8f80ca01972a8b88d2c30194b",
"url": "https://api.github.com/repos/phpbench/phpbench/zipball/bb61ae6c54b3d58642be154eb09f4e73c3511018",
"reference": "bb61ae6c54b3d58642be154eb09f4e73c3511018",
"shasum": ""
},
"require": {
@@ -5791,7 +6105,7 @@
"ergebnis/composer-normalize": "^2.39",
"friendsofphp/php-cs-fixer": "^3.0",
"jangregor/phpstan-prophecy": "^1.0",
"phpspec/prophecy": "dev-master",
"phpspec/prophecy": "^1.22",
"phpstan/extension-installer": "^1.1",
"phpstan/phpstan": "^1.0",
"phpstan/phpstan-phpunit": "^1.0",
@@ -5841,7 +6155,7 @@
],
"support": {
"issues": "https://github.com/phpbench/phpbench/issues",
"source": "https://github.com/phpbench/phpbench/tree/1.4.1"
"source": "https://github.com/phpbench/phpbench/tree/1.4.2"
},
"funding": [
{
@@ -5849,7 +6163,7 @@
"type": "github"
}
],
"time": "2025-03-12T08:01:40+00:00"
"time": "2025-10-26T14:21:59+00:00"
},
{
"name": "phpstan/phpstan",
@@ -8518,7 +8832,9 @@
],
"aliases": [],
"minimum-stability": "stable",
"stability-flags": {},
"stability-flags": {
"utopia-php/domains": 20
},
"prefer-stable": false,
"prefer-lowest": false,
"platform": {
+1 -1
View File
@@ -966,7 +966,7 @@ services:
hostname: exc1
<<: *x-logging
stop_signal: SIGINT
image: openruntimes/executor:0.11.0
image: openruntimes/executor:0.11.4
restart: unless-stopped
networks:
- appwrite
@@ -0,0 +1 @@
Create a new Resend provider.
@@ -0,0 +1 @@
Update a Resend provider by its unique ID.
+8
View File
@@ -1,5 +1,13 @@
# Change Log
## 13.3.0
* Add `onOpen`, `onClose` and `onError` callbacks to `Realtime` service
## 13.2.2
* Fix issue: Missing AppwriteEnums dependency causing build failure
## 13.2.1
* Add transaction support for Databases and TablesDB
+6
View File
@@ -1,5 +1,11 @@
# Change Log
## 10.2.2
* Fix `logout` command showing duplicate sessions
* Fix `logout` command showing a blank email even when logged out
* Add syncing of `tablesDB` resource during `push tables` command
## 10.2.1
* Add transaction support for Databases and TablesDB
+4
View File
@@ -1,5 +1,9 @@
# Change Log
## 13.2.2
* Fix issue: Missing AppwriteEnums dependency causing build failure
## 13.2.1
* Add transaction support for Databases and TablesDB
Binary file not shown.

After

Width:  |  Height:  |  Size: 295 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 295 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

@@ -5,6 +5,8 @@ namespace Appwrite\Platform\Modules\Compute;
use Appwrite\Event\Build;
use Appwrite\Extend\Exception;
use Appwrite\Platform\Action;
use Appwrite\Platform\Modules\Compute\Validator\Specification as SpecificationValidator;
use Utopia\Config\Config;
use Utopia\Database\Database;
use Utopia\Database\Document;
use Utopia\Database\Exception\Duplicate;
@@ -19,6 +21,37 @@ use Utopia\VCS\Exception\RepositoryNotFound;
class Base extends Action
{
/**
* Get default specification based on plan and available specifications.
*
* @param array $plan The billing plan configuration
* @return string The appropriate default specification
*/
protected function getDefaultSpecification(array $plan): string
{
$specifications = Config::getParam('specifications', []);
if (empty($specifications)) {
return APP_COMPUTE_SPECIFICATION_DEFAULT;
}
$specificationValidator = new SpecificationValidator(
$plan,
$specifications,
System::getEnv('_APP_COMPUTE_CPUS', 0),
System::getEnv('_APP_COMPUTE_MEMORY', 0)
);
$allowedSpecifications = $specificationValidator->getAllowedSpecifications();
// If there is no plan use the highest specification
if (empty($plan)) {
return end($allowedSpecifications) ?? APP_COMPUTE_SPECIFICATION_DEFAULT;
}
// Otherwise, use the lowest specification available in the plan
return $allowedSpecifications[0] ?? APP_COMPUTE_SPECIFICATION_DEFAULT;
}
public function redeployVcsFunction(Request $request, Document $function, Document $project, Document $installation, Database $dbForProject, Build $queueForBuilds, Document $template, GitHub $github, bool $activate, string $referenceType = 'branch', string $reference = ''): Document
{
$deploymentId = ID::unique();
@@ -160,7 +160,7 @@ class Create extends Action
throw new Exception($this->getParentInvalidTypeException(), "Cannot create an index for a relationship $contextType: " . $oldAttributes[$attributeIndex]['key']);
}
// ensure attribute is available
// Ensure attribute is available
if ($attributeStatus !== 'available') {
$contextType = ucfirst($contextType);
throw new Exception($this->getParentNotAvailableException(), "$contextType not available: " . $oldAttributes[$attributeIndex]['key']);
@@ -171,7 +171,7 @@ class Create extends Action
}
if ($attributeArray === true) {
$lengths[$i] = Database::ARRAY_INDEX_LENGTH;
$lengths[$i] = Database::MAX_ARRAY_INDEX_LENGTH;
$orders[$i] = null;
}
}
@@ -190,21 +190,18 @@ class Create extends Action
'orders' => $orders,
]);
$maxIndexLength = $dbForProject->getAdapter()->getMaxIndexLength();
$internalIndexesKeys = $dbForProject->getAdapter()->getInternalIndexesKeys();
$supportForIndexArray = $dbForProject->getAdapter()->getSupportForIndexArray();
$supportForSpatialAttributes = $dbForProject->getAdapter()->getSupportForSpatialAttributes();
$supportForSpatialIndexNull = $dbForProject->getAdapter()->getSupportForSpatialIndexNull();
$supportForSpatialIndexOrder = $dbForProject->getAdapter()->getSupportForSpatialIndexOrder();
$validator = new IndexValidator(
$collection->getAttribute('attributes'),
$maxIndexLength,
$internalIndexesKeys,
$supportForIndexArray,
$supportForSpatialAttributes,
$supportForSpatialIndexNull,
$supportForSpatialIndexOrder
$collection->getAttribute('indexes'),
$dbForProject->getAdapter()->getMaxIndexLength(),
$dbForProject->getAdapter()->getInternalIndexesKeys(),
$dbForProject->getAdapter()->getSupportForIndexArray(),
$dbForProject->getAdapter()->getSupportForSpatialIndexNull(),
$dbForProject->getAdapter()->getSupportForSpatialIndexOrder(),
$dbForProject->getAdapter()->getSupportForVectors(),
$dbForProject->getAdapter()->getSupportForAttributes(),
$dbForProject->getAdapter()->getSupportForMultipleFulltextIndexes(),
$dbForProject->getAdapter()->getSupportForIdenticalIndexes()
);
if (!$validator->isValid($index)) {
@@ -105,9 +105,7 @@ class Get extends Action
$response
->setContentType('application/gzip')
->addHeader('Cache-Control', 'no-cache, no-store, must-revalidate')
->addHeader('Expires', '0')
->addHeader('Pragma', 'no-cache')
->addHeader('Cache-Control', 'private, max-age=3888000') // 45 days
->addHeader('X-Peak', \memory_get_peak_usage())
->addHeader('Content-Disposition', 'attachment; filename="' . $deploymentId . '-' . $type . '.tar.gz"');
@@ -134,6 +132,7 @@ class Get extends Action
->setStatusCode(Response::STATUS_CODE_PARTIALCONTENT);
$response->send($device->read($path, $start, ($end - $start + 1)));
return;
}
if ($size > APP_STORAGE_READ_BUFFER) {
@@ -93,7 +93,7 @@ class Create extends Base
->param('providerBranch', '', new Text(128, 0), 'Production branch for the repo linked to the function.', true)
->param('providerSilentMode', false, new Boolean(), 'Is the VCS (Version Control System) connection in silent mode for the repo linked to the function? In silent mode, comments will not be made on commits and pull requests.', true)
->param('providerRootDirectory', '', new Text(128, 0), 'Path to function code in the linked repo.', true)
->param('specification', APP_COMPUTE_SPECIFICATION_DEFAULT, fn (array $plan) => new Specification(
->param('specification', fn (array $plan) => $this->getDefaultSpecification($plan), fn (array $plan) => new Specification(
$plan,
Config::getParam('specifications', []),
System::getEnv('_APP_COMPUTE_CPUS', 0),
@@ -89,7 +89,7 @@ class Update extends Base
->param('providerBranch', '', new Text(128, 0), 'Production branch for the repo linked to the function', true)
->param('providerSilentMode', false, new Boolean(), 'Is the VCS (Version Control System) connection in silent mode for the repo linked to the function? In silent mode, comments will not be made on commits and pull requests.', true)
->param('providerRootDirectory', '', new Text(128, 0), 'Path to function code in the linked repo.', true)
->param('specification', APP_COMPUTE_SPECIFICATION_DEFAULT, fn (array $plan) => new Specification(
->param('specification', fn (array $plan) => $this->getDefaultSpecification($plan), fn (array $plan) => new Specification(
$plan,
Config::getParam('specifications', []),
System::getEnv('_APP_COMPUTE_CPUS', 0),
@@ -467,11 +467,10 @@ class Builds extends Action
}
$providerCommitHash = \trim($stdout);
$authorUrl = "https://github.com/$cloneOwner";
$deployment->setAttribute('providerCommitHash', $providerCommitHash ?? '');
$deployment->setAttribute('providerCommitAuthorUrl', $authorUrl);
$deployment->setAttribute('providerCommitAuthor', 'Appwrite');
$deployment->setAttribute('providerCommitAuthorUrl', APP_VCS_GITHUB_URL);
$deployment->setAttribute('providerCommitAuthor', APP_VCS_GITHUB_USERNAME);
$deployment->setAttribute('providerCommitMessage', "Create '" . $resource->getAttribute('name', '') . "' function");
$deployment->setAttribute('providerCommitUrl', "https://github.com/$cloneOwner/$cloneRepository/commit/$providerCommitHash");
$deployment = $dbForProject->updateDocument('deployments', $deployment->getId(), $deployment);
@@ -868,13 +867,17 @@ class Builds extends Action
$deployment->setAttribute('buildLogs', $logs);
$adapter = null;
if ($resource->getCollection() === 'sites' && !empty($detectionLogs)) {
$files = \explode("\n", $detectionLogs); // Parse output
$files = \array_filter($files); // Remove empty
$files = \array_map(fn ($file) => \trim($file), $files); // Remove whitepsaces
$files = \array_map(fn ($file) => \str_starts_with($file, './') ? \substr($file, 2) : $file, $files); // Remove beginning ./
$detector = new Rendering($files, $resource->getAttribute('framework', ''));
$detector = new Rendering($resource->getAttribute('framework', ''));
foreach ($files as $file) {
$detector->addInput($file);
}
$detector
->addOption(new SSR())
->addOption(new XStatic());
@@ -102,17 +102,15 @@ class Get extends Action
throw new Exception(Exception::DEPLOYMENT_NOT_FOUND);
}
$response
->setContentType('application/gzip')
->addHeader('Cache-Control', 'no-cache, no-store, must-revalidate')
->addHeader('Expires', '0')
->addHeader('Pragma', 'no-cache')
->addHeader('X-Peak', \memory_get_peak_usage())
->addHeader('Content-Disposition', 'attachment; filename="' . $deploymentId . '-' . $type . '.tar.gz"');
$size = $device->getFileSize($path);
$rangeHeader = $request->getHeader('range');
$response
->setContentType('application/gzip')
->addHeader('Cache-Control', 'private, max-age=3888000') // 45 days
->addHeader('X-Peak', \memory_get_peak_usage())
->addHeader('Content-Disposition', 'attachment; filename="' . $deploymentId . '-' . $type . '.tar.gz"');
if (!empty($rangeHeader)) {
$start = $request->getRangeStart();
$end = $request->getRangeEnd();
@@ -133,6 +131,7 @@ class Get extends Action
->setStatusCode(Response::STATUS_CODE_PARTIALCONTENT);
$response->send($device->read($path, $start, ($end - $start + 1)));
return;
}
if ($size > APP_STORAGE_READ_BUFFER) {
@@ -78,7 +78,7 @@ class Create extends Base
->param('providerBranch', '', new Text(128, 0), 'Production branch for the repo linked to the site.', true)
->param('providerSilentMode', false, new Boolean(), 'Is the VCS (Version Control System) connection in silent mode for the repo linked to the site? In silent mode, comments will not be made on commits and pull requests.', true)
->param('providerRootDirectory', '', new Text(128, 0), 'Path to site code in the linked repo.', true)
->param('specification', APP_COMPUTE_SPECIFICATION_DEFAULT, fn (array $plan) => new Specification(
->param('specification', fn (array $plan) => $this->getDefaultSpecification($plan), fn (array $plan) => new Specification(
$plan,
Config::getParam('specifications', []),
System::getEnv('_APP_COMPUTE_CPUS', 0),
@@ -82,7 +82,7 @@ class Update extends Base
->param('providerBranch', '', new Text(128, 0), 'Production branch for the repo linked to the site.', true)
->param('providerSilentMode', false, new Boolean(), 'Is the VCS (Version Control System) connection in silent mode for the repo linked to the site? In silent mode, comments will not be made on commits and pull requests.', true)
->param('providerRootDirectory', '', new Text(128, 0), 'Path to site code in the linked repo.', true)
->param('specification', APP_COMPUTE_SPECIFICATION_DEFAULT, fn (array $plan) => new Specification(
->param('specification', fn (array $plan) => $this->getDefaultSpecification($plan), fn (array $plan) => new Specification(
$plan,
Config::getParam('specifications', []),
System::getEnv('_APP_COMPUTE_CPUS', 0),
@@ -2,6 +2,9 @@
namespace Appwrite\Platform\Tasks;
// Example usage: docker compose exec appwrite screenshot --templateId="playground-for-tanstack-start"
// Expected output: public/images/sites/templates/playground-for-tanstack-start-light.png (and dark.png)
use Appwrite\ID;
use Tests\E2E\Client;
use Utopia\CLI\Console;
@@ -16,6 +16,7 @@ use Utopia\DSN\DSN;
use Utopia\Logger\Log;
use Utopia\Messaging\Adapter\Email as EmailAdapter;
use Utopia\Messaging\Adapter\Email\Mailgun;
use Utopia\Messaging\Adapter\Email\Resend;
use Utopia\Messaging\Adapter\Email\Sendgrid;
use Utopia\Messaging\Adapter\Email\SMTP;
use Utopia\Messaging\Adapter\Push\APNS;
@@ -506,6 +507,7 @@ class Messaging extends Action
$credentials['isEuRegion'] ?? false
),
'sendgrid' => new Sendgrid($apiKey),
'resend' => new Resend($apiKey),
default => null
};
}
+1 -2
View File
@@ -428,14 +428,13 @@ class StatsUsage extends Action
/**
* Sort by unique index key reduce locks/deadlocks
*/
usort($projectStats['stats'], function ($a, $b) {
usort($projectStats['stats'], function ($a, $b) use ($sequence) {
// Metric DESC
$cmp = strcmp($b['metric'], $a['metric']);
if ($cmp !== 0) {
return $cmp;
}
unset($this->projects[$sequence]);
// Period ASC
$cmp = strcmp($a['period'], $b['period']);
if ($cmp !== 0) {
@@ -22,6 +22,12 @@ class ConsoleVariables extends Model
'default' => '',
'example' => '127.0.0.1',
])
->addRule('_APP_COMPUTE_BUILD_TIMEOUT', [
'type' => self::TYPE_INTEGER,
'description' => 'Maximum build timeout in seconds.',
'default' => '',
'example' => 900,
])
->addRule('_APP_DOMAIN_TARGET_AAAA', [
'type' => self::TYPE_STRING,
'description' => 'AAAA target for your Appwrite custom domains.',
@@ -60,10 +60,10 @@ class Execution extends Model
])
->addRule('status', [
'type' => self::TYPE_ENUM,
'description' => 'The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, or `failed`.',
'description' => 'The status of the function execution. Possible values can be: `waiting`, `processing`, `completed`, `failed`, or `scheduled`.',
'default' => '',
'example' => 'processing',
'enum' => ['waiting', 'processing', 'completed', 'failed'],
'enum' => ['waiting', 'processing', 'completed', 'failed', 'scheduled'],
])
->addRule('requestMethod', [
'type' => self::TYPE_STRING,
+1 -1
View File
@@ -193,7 +193,7 @@ class Comment
}
$tip = $this->tips[array_rand($this->tips)];
$text .= "\n<br>\n\n> [!NOTE]\n> $tip\n\n";
$text .= "\n<br>\n\n> [!TIP]\n> $tip\n\n";
return $text;
}
@@ -24,9 +24,10 @@ class ConsoleConsoleClientTest extends Scope
], $this->getHeaders()));
$this->assertEquals(200, $response['headers']['status-code']);
$this->assertCount(14, $response['body']);
$this->assertCount(15, $response['body']);
$this->assertIsString($response['body']['_APP_DOMAIN_TARGET_CNAME']);
$this->assertIsString($response['body']['_APP_DOMAIN_TARGET_A']);
$this->assertIsInt($response['body']['_APP_COMPUTE_BUILD_TIMEOUT']);
$this->assertIsString($response['body']['_APP_DOMAIN_TARGET_AAAA']);
$this->assertIsString($response['body']['_APP_DOMAIN_TARGET_CAA']);
$this->assertIsInt($response['body']['_APP_STORAGE_LIMIT']);
@@ -1281,7 +1281,7 @@ trait DatabasesBase
]);
$this->assertEquals(400, $fulltextReleaseYear['headers']['status-code']);
$this->assertEquals($fulltextReleaseYear['body']['message'], 'Attribute "releaseYear" cannot be part of a FULLTEXT index, must be of type string');
$this->assertEquals($fulltextReleaseYear['body']['message'], 'Attribute "releaseYear" cannot be part of a fulltext index, must be of type string');
$noAttributes = $this->client->call(Client::METHOD_POST, '/databases/' . $databaseId . '/collections/' . $data['moviesId'] . '/indexes', array_merge([
'content-type' => 'application/json',
@@ -1465,7 +1465,7 @@ trait DatabasesBase
$this->assertEquals([128, 200], $index['body']['lengths']);
// Test case for lengths array overriding
// set a length for an array attribute, it should get overriden with Database::ARRAY_INDEX_LENGTH
// set a length for an array attribute, it should get overriden with Database::MAX_ARRAY_INDEX_LENGTH
$create = $this->client->call(Client::METHOD_POST, "/databases/{$databaseId}/collections/{$collectionId}/indexes", [
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
@@ -1483,7 +1483,7 @@ trait DatabasesBase
'x-appwrite-project' => $this->getProject()['$id'],
'x-appwrite-key' => $this->getProject()['apiKey']
]);
$this->assertEquals([Database::ARRAY_INDEX_LENGTH], $index['body']['lengths']);
$this->assertEquals([Database::MAX_ARRAY_INDEX_LENGTH], $index['body']['lengths']);
// Test case for count of lengths greater than attributes (should throw 400)
$create = $this->client->call(Client::METHOD_POST, "/databases/{$databaseId}/collections/{$collectionId}/indexes", [
@@ -1281,7 +1281,7 @@ trait DatabasesBase
]);
$this->assertEquals(400, $fulltextReleaseYear['headers']['status-code']);
$this->assertEquals($fulltextReleaseYear['body']['message'], 'Attribute "releaseYear" cannot be part of a FULLTEXT index, must be of type string');
$this->assertEquals($fulltextReleaseYear['body']['message'], 'Attribute "releaseYear" cannot be part of a fulltext index, must be of type string');
$noAttributes = $this->client->call(Client::METHOD_POST, '/tablesdb/' . $databaseId . '/tables/' . $data['moviesId'] . '/indexes', array_merge([
'content-type' => 'application/json',
+22
View File
@@ -292,6 +292,7 @@ trait Base
// Providers
public const string CREATE_MAILGUN_PROVIDER = 'create_mailgun_provider';
public const string CREATE_SENDGRID_PROVIDER = 'create_sendgrid_provider';
public const string CREATE_RESEND_PROVIDER = 'create_resend_provider';
public const string CREATE_SMTP_PROVIDER = 'create_smtp_provider';
public const string CREATE_TWILIO_PROVIDER = 'create_twilio_provider';
public const string CREATE_TELESIGN_PROVIDER = 'create_telesign_provider';
@@ -304,6 +305,7 @@ trait Base
public const string GET_PROVIDER = 'get_provider';
public const string UPDATE_MAILGUN_PROVIDER = 'update_mailgun_provider';
public const string UPDATE_SENDGRID_PROVIDER = 'update_sendgrid_provider';
public const string UPDATE_RESEND_PROVIDER = 'update_resend_provider';
public const string UPDATE_SMTP_PROVIDER = 'update_smtp_provider';
public const string UPDATE_TWILIO_PROVIDER = 'update_twilio_provider';
public const string UPDATE_TELESIGN_PROVIDER = 'update_telesign_provider';
@@ -2494,6 +2496,16 @@ trait Base
enabled
}
}';
case self::CREATE_RESEND_PROVIDER:
return 'mutation createResendProvider($providerId: String!, $name: String!, $apiKey: String!, $fromName: String!, $fromEmail: String!, $replyToName: String, $replyToEmail: String) {
messagingCreateResendProvider(providerId: $providerId, name: $name, apiKey: $apiKey, fromName: $fromName, fromEmail: $fromEmail, replyToName: $replyToName, replyToEmail: $replyToEmail) {
_id
name
provider
type
enabled
}
}';
case self::CREATE_SMTP_PROVIDER:
return 'mutation createSmtpProvider($providerId: String!, $name: String!, $host: String!, $port: Int!, $username: String!, $password: String!, $encryption: String!, $autoTLS: Boolean! $fromName: String!, $fromEmail: String!, $replyToName: String, $replyToEmail: String) {
messagingCreateSmtpProvider(providerId: $providerId, name: $name, host: $host, port: $port, username: $username, password: $password, encryption: $encryption, autoTLS: $autoTLS, fromName: $fromName, fromEmail: $fromEmail, replyToName: $replyToName, replyToEmail: $replyToEmail) {
@@ -2618,6 +2630,16 @@ trait Base
enabled
}
}';
case self::UPDATE_RESEND_PROVIDER:
return 'mutation messagingUpdateResendProvider($providerId: String!, $name: String!, $apiKey: String!, $enabled: Boolean, $fromName: String, $fromEmail: String, $replyToName: String, $replyToEmail: String) {
messagingUpdateResendProvider(providerId: $providerId, name: $name, apiKey: $apiKey, enabled: $enabled, fromName: $fromName, fromEmail: $fromEmail, replyToName: $replyToName, replyToEmail: $replyToEmail) {
_id
name
provider
type
enabled
}
}';
case self::UPDATE_SMTP_PROVIDER:
return 'mutation updateSmtpProvider($providerId: String!, $name: String!, $host: String!, $port: Int!, $username: String!, $password: String!, $encryption: String!, $autoTLS: Boolean!, $fromName: String, $fromEmail: String, $enabled: Boolean) {
messagingUpdateSmtpProvider(providerId: $providerId, name: $name, host: $host, port: $port, username: $username, password: $password, encryption: $encryption, autoTLS: $autoTLS, fromName: $fromName, fromEmail: $fromEmail, enabled: $enabled) {
+22 -10
View File
@@ -26,6 +26,13 @@ class MessagingTest extends Scope
'fromName' => 'Sender Name',
'fromEmail' => 'sender-email@my-domain.com',
],
'Resend' => [
'providerId' => ID::unique(),
'name' => 'Resend1',
'apiKey' => 'my-apikey',
'fromName' => 'Sender Name',
'fromEmail' => 'sender-email@my-domain.com',
],
'Mailgun' => [
'providerId' => ID::unique(),
'name' => 'Mailgun1',
@@ -123,45 +130,50 @@ class MessagingTest extends Scope
'name' => 'Sengrid2',
'apiKey' => 'my-apikey',
],
'Mailgun' => [
'Resend' => [
'providerId' => $providers[1]['_id'],
'name' => 'Resend2',
'apiKey' => 'my-apikey',
],
'Mailgun' => [
'providerId' => $providers[2]['_id'],
'name' => 'Mailgun2',
'apiKey' => 'my-apikey',
'domain' => 'my-domain',
],
'Twilio' => [
'providerId' => $providers[2]['_id'],
'providerId' => $providers[3]['_id'],
'name' => 'Twilio2',
'accountSid' => 'my-accountSid',
'authToken' => 'my-authToken',
],
'Telesign' => [
'providerId' => $providers[3]['_id'],
'providerId' => $providers[4]['_id'],
'name' => 'Telesign2',
'customerId' => 'my-username',
'apiKey' => 'my-password',
],
'Textmagic' => [
'providerId' => $providers[4]['_id'],
'providerId' => $providers[5]['_id'],
'name' => 'Textmagic2',
'username' => 'my-username',
'apiKey' => 'my-apikey',
],
'Msg91' => [
'providerId' => $providers[5]['_id'],
'providerId' => $providers[6]['_id'],
'name' => 'Ms91-2',
'senderId' => 'my-senderid',
'authKey' => 'my-authkey',
'templateId' => '123456',
],
'Vonage' => [
'providerId' => $providers[6]['_id'],
'providerId' => $providers[7]['_id'],
'name' => 'Vonage2',
'apiKey' => 'my-apikey',
'apiSecret' => 'my-apisecret',
],
'Fcm' => [
'providerId' => $providers[7]['_id'],
'providerId' => $providers[8]['_id'],
'name' => 'FCM2',
'serviceAccountJSON' => [
'type' => 'service_account',
@@ -171,7 +183,7 @@ class MessagingTest extends Scope
]
],
'Apns' => [
'providerId' => $providers[8]['_id'],
'providerId' => $providers[9]['_id'],
'name' => 'APNS2',
'authKey' => 'my-authkey',
'authKeyId' => 'my-authkeyid',
@@ -205,7 +217,7 @@ class MessagingTest extends Scope
], [
'query' => $this->getQuery('update_mailgun_provider'),
'variables' => [
'providerId' => $providers[1]['_id'],
'providerId' => $providers[2]['_id'],
'name' => 'Mailgun2',
'apiKey' => 'my-apikey',
'domain' => 'my-domain',
@@ -213,7 +225,7 @@ class MessagingTest extends Scope
'enabled' => false,
]
]);
$providers[1] = $response['body']['data']['messagingUpdateMailgunProvider'];
$providers[2] = $response['body']['data']['messagingUpdateMailgunProvider'];
$this->assertEquals(200, $response['headers']['status-code']);
$this->assertEquals('Mailgun2', $response['body']['data']['messagingUpdateMailgunProvider']['name']);
$this->assertEquals(false, $response['body']['data']['messagingUpdateMailgunProvider']['enabled']);
+14 -3
View File
@@ -25,6 +25,13 @@ trait MessagingBase
'apiKey' => 'my-apikey',
'from' => 'sender-email@my-domain.com',
],
'resend' => [
'providerId' => ID::unique(),
'name' => 'Resend1',
'apiKey' => 'my-apikey',
'fromName' => 'Sender Name',
'fromEmail' => 'sender-email@my-domain.com',
],
'mailgun' => [
'providerId' => ID::unique(),
'name' => 'Mailgun1',
@@ -132,6 +139,10 @@ trait MessagingBase
'name' => 'Sengrid2',
'apiKey' => 'my-apikey',
],
'resend' => [
'name' => 'Resend2',
'apiKey' => 'my-apikey',
],
'mailgun' => [
'name' => 'Mailgun2',
'apiKey' => 'my-apikey',
@@ -210,7 +221,7 @@ trait MessagingBase
$providers[$index] = $response['body'];
}
$response = $this->client->call(Client::METHOD_PATCH, '/messaging/providers/mailgun/' . $providers[1]['$id'], [
$response = $this->client->call(Client::METHOD_PATCH, '/messaging/providers/mailgun/' . $providers[2]['$id'], [
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
'x-appwrite-key' => $this->getProject()['apiKey'],
@@ -226,7 +237,7 @@ trait MessagingBase
$this->assertEquals('Mailgun2', $response['body']['name']);
$this->assertEquals(false, $response['body']['enabled']);
$providers[1] = $response['body'];
$providers[2] = $response['body'];
return $providers;
}
@@ -269,7 +280,7 @@ trait MessagingBase
]);
$this->assertEquals(200, $response['headers']['status-code']);
$this->assertEquals(11, \count($response['body']['providers']));
$this->assertEquals(12, \count($response['body']['providers']));
return $providers;
}
@@ -113,13 +113,33 @@ class ProjectsConsoleClientTest extends Scope
];
}
/**
* @depends testCreateProject
*/
public function testCreateDuplicateProject($data)
public function testCreateDuplicateProject(): void
{
$teamId = $data['teamId'] ?? '';
$projectId = $data['projectId'] ?? '';
// Create a team
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Duplicate Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
$teamId = $team['body']['$id'];
// Create a project
$projectId = ID::unique();
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => $projectId,
'name' => 'Original Project',
'teamId' => $teamId,
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
/**
* Test for FAILURE
@@ -417,12 +437,32 @@ class ProjectsConsoleClientTest extends Scope
return $data;
}
/**
* @depends testCreateProject
*/
public function testGetProject($data): array
public function testGetProject(): void
{
$id = $data['projectId'] ?? '';
// Create a team
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Get Project Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
// Create a project
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => ID::unique(),
'name' => 'Project Test',
'teamId' => $team['body']['$id'],
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
$id = $response['body']['$id'];
/**
* Test for SUCCESS
@@ -440,7 +480,6 @@ class ProjectsConsoleClientTest extends Scope
/**
* Test for FAILURE
*/
$response = $this->client->call(Client::METHOD_GET, '/projects/empty', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
@@ -454,8 +493,6 @@ class ProjectsConsoleClientTest extends Scope
], $this->getHeaders()));
$this->assertEquals(400, $response['headers']['status-code']);
return $data;
}
/**
@@ -513,12 +550,33 @@ class ProjectsConsoleClientTest extends Scope
return $data;
}
/**
* @depends testCreateProject
*/
public function testUpdateProject($data): array
public function testUpdateProject(): void
{
$id = $data['projectId'] ?? '';
// Create a team
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Update Project Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
$teamId = $team['body']['$id'];
// Create a project
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => ID::unique(),
'name' => 'Project Test',
'teamId' => $teamId,
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
$id = $response['body']['$id'];
/**
* Test for SUCCESS
@@ -543,7 +601,6 @@ class ProjectsConsoleClientTest extends Scope
/**
* Test for FAILURE
*/
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
@@ -553,8 +610,6 @@ class ProjectsConsoleClientTest extends Scope
]);
$this->assertEquals(401, $response['headers']['status-code']);
return ['projectId' => $projectId];
}
/**
@@ -608,11 +663,35 @@ class ProjectsConsoleClientTest extends Scope
/**
* @group smtpAndTemplates
* @depends testCreateProject
*/
public function testCreateProjectSMTPTests($data): array
public function testCreateProjectSMTPTests(): void
{
$id = $data['projectId'];
// Create a team
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Create Project SMTP Tests Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
$teamId = $team['body']['$id'];
// Create a project
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => ID::unique(),
'name' => 'Project Test',
'teamId' => $teamId,
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
$id = $response['body']['$id'];
$response = $this->client->call(Client::METHOD_POST, '/projects/' . $id . '/smtp/tests', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
@@ -681,8 +760,6 @@ class ProjectsConsoleClientTest extends Scope
]);
$this->assertEquals(400, $response['headers']['status-code']);
return $data;
}
/**
@@ -794,7 +871,6 @@ class ProjectsConsoleClientTest extends Scope
/**
* Test for SUCCESS
*/
$response = $this->client->call(Client::METHOD_PATCH, '/projects/' . $id . '/auth/duration', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
@@ -951,10 +1027,32 @@ class ProjectsConsoleClientTest extends Scope
return ['projectId' => $projectId];
}
/** @depends testCreateProject */
public function testUpdateProjectInvalidateSessions($data): array
public function testUpdateProjectInvalidateSessions(): void
{
$id = $data['projectId'];
// Create a team for the test project
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Session Invalidation Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
// Create a test project
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => ID::unique(),
'name' => 'Session Invalidation Test Project',
'teamId' => $team['body']['$id'],
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
$id = $response['body']['$id'];
// Check defaults
$response = $this->client->call(Client::METHOD_GET, '/projects/' . $id, array_merge([
@@ -996,22 +1094,41 @@ class ProjectsConsoleClientTest extends Scope
$this->assertEquals(200, $response['headers']['status-code']);
$this->assertTrue($response['body']['authInvalidateSessions']);
return $data;
}
/**
* @depends testCreateProject
*/
public function testUpdateProjectOAuth($data): array
public function testUpdateProjectOAuth(): void
{
$id = $data['projectId'] ?? '';
// Create a team
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Update Project OAuth Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
$teamId = $team['body']['$id'];
// Create a project
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => ID::unique(),
'name' => 'Project Test',
'teamId' => $teamId,
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
$id = $response['body']['$id'];
$providers = require(__DIR__ . '/../../../../app/config/oAuthProviders.php');
/**
* Test for SUCCESS
*/
foreach ($providers as $key => $provider) {
$response = $this->client->call(Client::METHOD_PATCH, '/projects/' . $id . '/oauth2', array_merge([
'content-type' => 'application/json',
@@ -1096,7 +1213,6 @@ class ProjectsConsoleClientTest extends Scope
/**
* Test for FAILURE
*/
$response = $this->client->call(Client::METHOD_PATCH, '/projects/' . $id . '/oauth2', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
@@ -1107,18 +1223,37 @@ class ProjectsConsoleClientTest extends Scope
]);
$this->assertEquals(400, $response['headers']['status-code']);
return $data;
}
/**
* @depends testCreateProject
*/
public function testUpdateProjectAuthStatus($data): array
public function testUpdateProjectAuthStatus(): void
{
$id = $data['projectId'] ?? '';
$auth = require(__DIR__ . '/../../../../app/config/auth.php');
// Create a team
$team = $this->client->call(Client::METHOD_POST, '/teams', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'teamId' => ID::unique(),
'name' => 'Update Project Auth Status Test Team',
]);
$this->assertEquals(201, $team['headers']['status-code']);
$teamId = $team['body']['$id'];
// Create a project
$response = $this->client->call(Client::METHOD_POST, '/projects', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), [
'projectId' => ID::unique(),
'name' => 'Project Test',
'teamId' => $teamId,
'region' => System::getEnv('_APP_REGION', 'default')
]);
$this->assertEquals(201, $response['headers']['status-code']);
$id = $response['body']['$id'];
$auth = require(__DIR__ . '/../../../../app/config/auth.php');
$originalEmail = uniqid() . 'user@localhost.test';
$originalPassword = 'password';
$originalName = 'User Name';
@@ -1252,8 +1387,6 @@ class ProjectsConsoleClientTest extends Scope
'status' => true,
]);
}
return $data;
}
/**
@@ -1458,9 +1591,6 @@ class ProjectsConsoleClientTest extends Scope
$sessionCookie = $response['headers']['set-cookie'];
$sessionId2 = $response['body']['$id'];
// request was called in parallel and test failed
sleep(5);
/**
* List sessions
*/
@@ -3358,15 +3488,15 @@ class ProjectsConsoleClientTest extends Scope
{
$id = $data['projectId'] ?? '';
sleep(1);
$this->assertEventually(function () use ($id) {
$response = $this->client->call(Client::METHOD_GET, '/projects/' . $id . '/platforms', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), []);
$response = $this->client->call(Client::METHOD_GET, '/projects/' . $id . '/platforms', array_merge([
'content-type' => 'application/json',
'x-appwrite-project' => $this->getProject()['$id'],
], $this->getHeaders()), []);
$this->assertEquals(200, $response['headers']['status-code']);
$this->assertEquals(8, $response['body']['total']);
$this->assertEquals(200, $response['headers']['status-code']);
$this->assertEquals(8, $response['body']['total']);
});
/**
* Test for FAILURE
@@ -4016,16 +4146,16 @@ class ProjectsConsoleClientTest extends Scope
$this->assertEquals(204, $project1['headers']['status-code']);
\sleep(3);
// Ensure project 2 user is still there
$user2 = $this->client->call(Client::METHOD_GET, '/users/' . $user2['body']['$id'], [
'content-type' => 'application/json',
'x-appwrite-project' => $project2Id,
'x-appwrite-key' => $key2['body']['secret'],
]);
$this->assertEventually(function () use ($user2, $project2Id, $key2) {
$response = $this->client->call(Client::METHOD_GET, '/users/' . $user2['body']['$id'], [
'content-type' => 'application/json',
'x-appwrite-project' => $project2Id,
'x-appwrite-key' => $key2['body']['secret'],
]);
$this->assertEquals(200, $user2['headers']['status-code']);
$this->assertEquals(200, $response['headers']['status-code']);
});
// Create another user in project 2 in case read hits stale cache
$user3 = $this->client->call(Client::METHOD_POST, '/users', [
@@ -131,8 +131,8 @@ class SitesCustomClientTest extends Scope
$this->assertEquals('github', $template['body']['vcsProvider']);
$this->assertEquals('Simple React application integrated with Appwrite SDK.', $template['body']['tagline']);
$this->assertIsArray($template['body']['frameworks']);
$this->assertEquals('http://'. $hostname . '/images/sites/templates/starter-for-react-dark.png', $template['body']['screenshotDark']);
$this->assertEquals('http://' . $hostname . '/images/sites/templates/starter-for-react-light.png', $template['body']['screenshotLight']);
$this->assertStringContainsString('/images/sites/templates/starter-for-react-dark.png', $template['body']['screenshotDark']);
$this->assertStringContainsString('/images/sites/templates/starter-for-react-light.png', $template['body']['screenshotLight']);
/**
* Test for FAILURE
+49 -49
View File
@@ -147,25 +147,25 @@ trait WebhooksBase
$this->assertEquals($extra['body']['key'], 'extra');
// wait for database worker to kick in
sleep(10);
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals($webhook['method'], 'POST');
$this->assertEquals($webhook['headers']['Content-Type'], 'application/json');
$this->assertEquals($webhook['headers']['User-Agent'], 'Appwrite-Server vdev. Please report abuse at security@appwrite.io');
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.attributes.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.attributes.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.attributes.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.attributes.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertNotEmpty($webhook['data']['key']);
$this->assertEquals($webhook['data']['key'], 'extra');
$this->assertEventually(function () use ($databaseId, $actorsId) {
$webhook = $this->getLastRequest();
$this->assertNotEmpty($webhook);
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals($webhook['method'], 'POST');
$this->assertEquals($webhook['headers']['Content-Type'], 'application/json');
$this->assertEquals($webhook['headers']['User-Agent'], 'Appwrite-Server vdev. Please report abuse at security@appwrite.io');
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.attributes.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.attributes.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.attributes.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.attributes.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertNotEmpty($webhook['data']['key']);
$this->assertEquals($webhook['data']['key'], 'extra');
}, 15000, 500);
$removed = $this->client->call(Client::METHOD_DELETE, '/databases/' . $databaseId . '/collections/' . $data['actorsId'] . '/attributes/' . $extra['body']['key'], array_merge([
'content-type' => 'application/json',
@@ -498,25 +498,25 @@ trait WebhooksBase
$this->assertEquals($extra['body']['key'], 'extra');
// wait for database worker to kick in
sleep(10);
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals($webhook['method'], 'POST');
$this->assertEquals($webhook['headers']['Content-Type'], 'application/json');
$this->assertEquals($webhook['headers']['User-Agent'], 'Appwrite-Server vdev. Please report abuse at security@appwrite.io');
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.columns.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.columns.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.columns.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.columns.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertNotEmpty($webhook['data']['key']);
$this->assertEquals($webhook['data']['key'], 'extra');
$this->assertEventually(function () use ($databaseId, $actorsId) {
$webhook = $this->getLastRequest();
$this->assertNotEmpty($webhook);
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals($webhook['method'], 'POST');
$this->assertEquals($webhook['headers']['Content-Type'], 'application/json');
$this->assertEquals($webhook['headers']['User-Agent'], 'Appwrite-Server vdev. Please report abuse at security@appwrite.io');
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.columns.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.columns.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.columns.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.columns.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertNotEmpty($webhook['data']['key']);
$this->assertEquals($webhook['data']['key'], 'extra');
}, 15000, 500);
$removed = $this->client->call(Client::METHOD_DELETE, '/tablesdb/' . $databaseId . '/tables/' . $data['actorsId'] . '/columns/' . $extra['body']['key'], array_merge([
'content-type' => 'application/json',
@@ -1487,17 +1487,17 @@ trait WebhooksBase
$this->assertNotEmpty($newCollection['body']['$id']);
}
sleep(10);
$this->assertEventually(function () use ($projectId, $webhookId) {
$webhook = $this->client->call(Client::METHOD_GET, '/projects/' . $projectId . '/webhooks/' . $webhookId, array_merge([
'origin' => 'http://localhost',
'content-type' => 'application/json',
'cookie' => 'a_session_console=' . $this->getRoot()['session'],
'x-appwrite-project' => 'console',
]));
$webhook = $this->client->call(Client::METHOD_GET, '/projects/' . $projectId . '/webhooks/' . $webhookId, array_merge([
'origin' => 'http://localhost',
'content-type' => 'application/json',
'cookie' => 'a_session_console=' . $this->getRoot()['session'],
'x-appwrite-project' => 'console',
]));
// assert that the webhook is now disabled after 10 consecutive failures
$this->assertEquals($webhook['body']['enabled'], false);
$this->assertEquals($webhook['body']['attempts'], 10);
// assert that the webhook is now disabled after 10 consecutive failures
$this->assertEquals($webhook['body']['enabled'], false);
$this->assertEquals($webhook['body']['attempts'], 10);
}, 15000, 500);
}
}
@@ -2,6 +2,7 @@
namespace Tests\E2E\Services\Webhooks;
use Appwrite\Tests\Async;
use CURLFile;
use Tests\E2E\Client;
use Tests\E2E\Scopes\ProjectCustom;
@@ -15,6 +16,7 @@ use Utopia\Database\Validator\Datetime as DatetimeValidator;
class WebhooksCustomServerTest extends Scope
{
use Async;
use WebhooksBase;
use ProjectCustom;
use SideServer;
@@ -89,24 +91,24 @@ class WebhooksCustomServerTest extends Scope
$this->assertEquals('fullname', $index['body']['key']);
// wait for database worker to create index
sleep(5);
$this->assertEventually(function () use ($databaseId, $actorsId) {
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.indexes.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.indexes.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.indexes.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.indexes.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertTrue(empty($webhook['headers']['X-Appwrite-Webhook-User-Id'] ?? ''));
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.indexes.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.collections.*.indexes.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.indexes.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.collections.{$actorsId}.indexes.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertTrue(empty($webhook['headers']['X-Appwrite-Webhook-User-Id'] ?? ''));
}, 10000, 500);
// Remove index
$this->client->call(Client::METHOD_DELETE, '/databases/' . $databaseId . '/collections/' . $data['actorsId'] . '/indexes/' . $index['body']['key'], array_merge([
@@ -275,24 +277,24 @@ class WebhooksCustomServerTest extends Scope
$this->assertEquals('fullname', $index['body']['key']);
// wait for database worker to create index
sleep(5);
$this->assertEventually(function () use ($databaseId, $actorsId) {
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.indexes.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.indexes.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.indexes.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.indexes.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertTrue(empty($webhook['headers']['X-Appwrite-Webhook-User-Id'] ?? ''));
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.indexes.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString('databases.' . $databaseId . '.tables.*.indexes.*.create', $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.indexes.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertStringContainsString("databases.{$databaseId}.tables.{$actorsId}.indexes.*.create", $webhook['headers']['X-Appwrite-Webhook-Events']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertTrue(empty($webhook['headers']['X-Appwrite-Webhook-User-Id'] ?? ''));
}, 10000, 500);
// Remove index
$this->client->call(Client::METHOD_DELETE, '/tablesdb/' . $databaseId . '/tables/' . $data['actorsId'] . '/indexes/' . $index['body']['key'], array_merge([
@@ -735,27 +737,27 @@ class WebhooksCustomServerTest extends Scope
$this->assertNotEmpty($response['body']['$id']);
// Wait for deployment to be built.
sleep(5);
$this->assertEventually(function () use ($deploymentId, $id) {
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
// $this->assertStringContainsString('functions.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.deployments.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.deployments.*.update', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.deployments.{$deploymentId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.deployments.{$deploymentId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.*.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.{$deploymentId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.{$deploymentId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']); TODO @christyjacob4 : enable test once we allow functions.* events
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
// $this->assertStringContainsString('functions.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.deployments.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.deployments.*.update', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.deployments.{$deploymentId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.deployments.{$deploymentId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.*.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.{$deploymentId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.deployments.{$deploymentId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']); TODO @christyjacob4 : enable test once we allow functions.* events
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
}, 10000, 500);
/**
* Test for FAILURE
@@ -806,27 +808,27 @@ class WebhooksCustomServerTest extends Scope
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
// wait for timeout function to complete
sleep(20);
$this->assertEventually(function () use ($executionId, $id) {
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$webhook = $this->getLastRequest();
$signatureExpected = self::getWebhookSignature($webhook, $this->getProject()['signatureKey']);
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
// $this->assertStringContainsString('functions.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.executions.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.executions.*.update', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.executions.{$executionId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.executions.{$executionId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.*.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.{$executionId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.{$executionId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']); TODO @christyjacob4 : enable test once we allow functions.* events
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
$this->assertEquals('POST', $webhook['method']);
$this->assertEquals('application/json', $webhook['headers']['Content-Type']);
$this->assertEquals('Appwrite-Server vdev. Please report abuse at security@appwrite.io', $webhook['headers']['User-Agent']);
// $this->assertStringContainsString('functions.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.executions.*', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString('functions.*.executions.*.update', $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.executions.{$executionId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.*.executions.{$executionId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.*", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.*.update", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.{$executionId}", $webhook['headers']['X-Appwrite-Webhook-Events']);
// $this->assertStringContainsString("functions.{$id}.executions.{$executionId}.update", $webhook['headers']['X-Appwrite-Webhook-Events']); TODO @christyjacob4 : enable test once we allow functions.* events
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Signature'], $signatureExpected);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Id'] ?? '', $this->getProject()['webhookId']);
$this->assertEquals($webhook['headers']['X-Appwrite-Webhook-Project-Id'] ?? '', $this->getProject()['$id']);
}, 30000, 1000);
/**
* Test for FAILURE
@@ -0,0 +1,75 @@
<?php
namespace Tests\Unit\Platform\Modules\Compute\Validator;
use Appwrite\Platform\Modules\Compute\Specification as SpecificationConstants;
use Appwrite\Platform\Modules\Compute\Validator\Specification;
use PHPUnit\Framework\TestCase;
use Utopia\Config\Config;
class SpecificationTest extends TestCase
{
private array $specifications;
protected function setUp(): void
{
parent::setUp();
$this->specifications = Config::getParam('specifications', []);
}
public function testGetAllowedSpecificationsNoLimits(): void
{
$validator = new Specification(
plan: [],
specifications: $this->specifications,
maxCpus: 0,
maxMemory: 0
);
$allowed = $validator->getAllowedSpecifications();
$this->assertCount(count($this->specifications), $allowed);
$this->assertEquals(
$this->specifications[array_key_last($this->specifications)]['slug'],
$allowed[array_key_last($allowed)]
);
}
public function testGetAllowedSpecificationsWithMaxCpusAndMemory(): void
{
$validator = new Specification(
plan: [],
specifications: $this->specifications,
maxCpus: 2,
maxMemory: 2048
);
$allowed = $validator->getAllowedSpecifications();
$this->assertCount(4, $allowed);
$this->assertEquals(
SpecificationConstants::S_2VCPU_2GB,
$allowed[array_key_last($allowed)]
);
}
public function testGetAllowedSpecificationsWithPlanLimits(): void
{
$plan = [
'runtimeSpecifications' => [
SpecificationConstants::S_05VCPU_512MB,
SpecificationConstants::S_1VCPU_512MB
]
];
$validator = new Specification(
plan: $plan,
specifications: $this->specifications,
maxCpus: 0,
maxMemory: 0
);
$allowed = $validator->getAllowedSpecifications();
$this->assertCount(2, $allowed);
$this->assertContains(SpecificationConstants::S_05VCPU_512MB, $allowed);
$this->assertContains(SpecificationConstants::S_1VCPU_512MB, $allowed);
}
}