Conversation
Greptile SummaryThis PR updates the Node.js SDK to version 25.0.0, introducing three new services (
Confidence Score: 3/5The new services are well-formed, but two issues in the exported enum surface make this risky to ship without fixes. The
Important Files Changed
Reviews (1): Last reviewed commit: "chore: update Node.js SDK to 25.0.0" | Re-trigger Greptile |
| @@ -72,6 +78,7 @@ export { IndexStatus } from './enums/index-status'; | |||
| export { DeploymentStatus } from './enums/deployment-status'; | |||
There was a problem hiding this comment.
Duplicate enum export causing type mismatch
OAuth2GooglePrompt (exported here, used in Models.OAuth2Google.prompt) and ProjectOAuth2GooglePrompt (line 52, used in Project.updateOAuth2Google) are two separate enums with identical string values. Because TypeScript enums are nominally typed, a value of one enum cannot be assigned to the other. A user reading result.prompt from the updateOAuth2Google response (typed OAuth2GooglePrompt[]) and passing it back in a subsequent call (which expects ProjectOAuth2GooglePrompt[]) will get a compile-time type error even though the runtime values are identical. One of these enums should be consolidated — models.ts should import ProjectOAuth2GooglePrompt for the OAuth2Google.prompt field, or the service should accept OAuth2GooglePrompt[], eliminating the duplicate.
| Yandex = 'yandex', | ||
| Zoho = 'zoho', | ||
| Zoom = 'zoom', | ||
| GithubImagine = 'githubImagine', | ||
| GoogleImagine = 'googleImagine', | ||
| } No newline at end of file |
There was a problem hiding this comment.
Undocumented removal of
GithubImagine and GoogleImagine from OAuthProvider
The PR description only documents removing the AuthProvider model, but the still-exported OAuthProvider enum silently loses GithubImagine and GoogleImagine members. Any existing code using OAuthProvider.GithubImagine or OAuthProvider.GoogleImagine will break at compile time without a migration path in the changelog. These two members are present in the new ProjectOAuthProviderId enum, but OAuthProvider is not deprecated here — it remains a first-class export — so users have no indication they should switch. This should be explicitly called out as a breaking change, or the members should be kept in OAuthProvider with a deprecation notice.
This PR contains updates to the Node.js SDK for version 25.0.0.
What's Changed
AuthMethodenum toProjectAuthMethodIdEmailTemplateTypetoProjectEmailTemplateIdandEmailTemplateLocaletoProjectEmailTemplateLocaleServiceIdtoProjectServiceId,ProtocolIdtoProjectProtocolId,SecuretoProjectSMTPSecure,ProjectPolicytoProjectPolicyIdScopesenum withProjectKeyScopesfor project key endpointsupdateDenyCanonicalEmailPolicy; replaced withupdateDenyAliasedEmailPolicy,updateDenyDisposableEmailPolicy, andupdateDenyFreeEmailPolicyAuthProvidermodel; use newProjectOAuthProviderIdenum insteadProject.getmethod to fetch current project detailsAdvisor,Presences, andUsageservicesInsight,Presence,Report,UsageEvent, andUsageGaugemodels with list variantsProjectAuthMethod,ProjectProtocol, andProjectServicemodelsProjectOAuthProviderIdandProjectOAuth2GooglePromptenumsProject,Database, andOAuth2Googlemodel schemasX-Appwrite-Response-Formatheader to1.9.5