feat: add OAuth2 server settings card and update SDK #3067
Conversation
Greptile SummaryThis PR adds a new OAuth2 authorization server settings card to the project settings page, gated behind a
Confidence Score: 5/5Safe to merge; the change is entirely additive and feature-flagged, so no existing project settings are affected until the flag is enabled. The new OAuth2 settings card is isolated behind a flag, all previously identified defects are fixed, and the rest of the touched files (analytics, flags, page layout, lock file) are straightforward additions following established patterns. updateOAuth2Server.svelte deserves a second look on the null ?? undefined duration handling once the backend API contract for that field is confirmed. Important Files Changed
Reviews (8): Last reviewed commit: "chore: bump SDK to 666231b, fix enum ren..." | Re-trigger Greptile |
3368ff9 to
21aefc0
Compare
- New updateOAuth2Server.svelte card in project settings for configuring the project as an OAuth2 authorization server (enabled toggle, authorization URL, scopes, per-client-type token durations, PKCE enforcement) - Add ProjectUpdateOAuth2Server analytics event - Fix enum renames introduced by SDK bump: Status→ProjectStatus, StatusCode→RedirectStatusCode, Adapter→SiteAdapter, BuildRuntime→SiteBuildRuntime, Framework→SiteFramework, Runtime→FunctionRuntime, Scopes→ProjectKeyScopes, Addon→OrganizationAddon
The new SDK renamed top-level enums (Status→ProjectStatus, StatusCode→RedirectStatusCode, Adapter→SiteAdapter, etc.) but kept Models.* names unchanged (Models.Framework, Models.Runtime). Also removed Scopes in favour of ProjectKeyScopes. - Models.SiteFramework → Models.Framework - Models.FunctionRuntime → Models.Runtime - VCSDetectionType.SiteFramework → VCSDetectionType.Framework - VCSDetectionType.FunctionRuntime → VCSDetectionType.Runtime - Scopes → ProjectKeyScopes in function files (enum removed from SDK) - Fix updateScopes.svelte: restore Scopes component import, remove duplicate type alias
- New updateOAuth2Server.svelte card in project settings
- Enable/disable toggle, authorization URL, scopes, per-client token
durations with unit selectors, PKCE enforcement
- min={1} on all duration inputs, scopes sent directly to allow clearing
- Add ProjectUpdateOAuth2Server analytics event
Note: awaiting SDK with updateOAuth2Server method and correct enum names
5ce0d15 to
dd8887a
Compare
…re flag - Update @appwrite.io/console to 666231b - Scopes → ProjectKeyScopes in all function/overview files - StatusCode.MovedPermanently301/Found302/TemporaryRedirect307/PermanentRedirect308 → MovedPermanently/Found/TemporaryRedirect/PermanentRedirect - Add oauth2Server feature flag to flags.ts - Wire UpdateOAuth2Server card into project settings behind oauth2-server flag - Type-cast missing oAuth2Server fields and updateOAuth2Server method until SDK ships them - Add Submit.ProjectUpdateOAuth2Server analytics event
dd8887a to
01273a1
Compare
What does this PR do?
Test Plan
(Write your test plan here. If you changed any code, please provide us with clear instructions on how you verified your changes work.)
Related PRs and Issues
(If this PR is related to any other PR or resolves any issue or related to any issue link all related PR and issues here.)
Have you read the Contributing Guidelines on issues?
(Write your answer here.)