Skip to content

feat: SDK update for version 30.0.0 - #167

Merged
Meldiron merged 1 commit into
mainfrom
dev
Sep 25, 2026
Merged

Meldiron merged 1 commit into
mainfrom
dev

Conversation

@Meldiron

Copy link
Copy Markdown
Contributor

This PR contains updates to the SDK for version 30.0.0.

What's Changed

  • Breaking: account.listLogs, users.listLogs, Log and LogList removed
  • Breaking: organization key methods renamed to createEphemeralProjectKey, getProjectKey, listProjectKeys, updateProjectKey, deleteProjectKey, and OrganizationKeyScopes removed
  • Breaking: setDevKey client method, DevKey model and Project.devKeys removed
  • Breaking: region, reason, projectName, organizationId, organizationName, billingPlan removed from Block
  • Breaking: DedicatedDatabaseSpecificationList.pricing and DedicatedDatabaseSpecificationPricing removed; rates now live on each DedicatedDatabaseSpecification
  • Breaking: BillingPlanGroup.Starter replaced by Free and Start
  • Added: oauth2.introspect for RFC 7662 token introspection with an API key, returning the Oauth2Introspection model
  • Added: domains service for domains, DNS records, email presets, prices and transfers
  • Added: account.createIdTokenSession and email verification and recovery OTP methods
  • Added: messaging.createAppwriteProvider and messaging.updateAppwriteProvider
  • Added: project.updatePasswordPwnedPolicy with PolicyPasswordPwned model and User.passwordPwned
  • Added: Kakao and TikTok OAuth2 providers
  • Added: native client IDs on the Apple and Google OAuth2 providers
  • Added: reply-to on email messages, qos and expiry on topics
  • Added: ImageGravity.Auto, jaspr framework, and dart-3.13 and flutter-3.47 runtimes
  • Updated: requests send X-Appwrite-Response-Format 2.3.0

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

RetriggerConfidence Score: 3/5

[High risk] SDK update with breaking API changes and new service.

The PR is not ready to merge until positional calls retain their meanings, zone retrieval exposes the zone content correctly, and the repository’s observable-behavior testing requirement is met.

Fix All in Claude CodeFindings

  1. P1 Positional email arguments shift ▶
  2. P1 Zone content returned wrapped ▶
  3. P2 Domain tests mirror fixtures ▶
  4. P2 Nullable prices typed incorrectly ▶
Fix with agent prompt
### Issue 1
src/services/messaging.ts:249-253
If a caller uses the previous positional signature for `createEmail`, this overload reads the existing `draft` boolean as `replyToEmail` and shifts the later options. The request can fail or create an email with the wrong settings. `updateEmail` has the same issue, and the Apple and Google OAuth2 update overloads shift the existing `enabled` argument into `nativeClientIds`.

### Issue 2
src/services/domains.ts:4563-4568
When the server returns the requested DNS zone as plain text, `Client.call` wraps it in `{ message: text }`. `getZone` therefore returns an object rather than the zone-file content callers need, while its `Promise<{}>` type does not describe where that content went. The test supplies JSON, so it does not cover this response path.

### Issue 3
test/services/domains.test.js:381-407
These new tests return a mocked response and assert that the SDK returns the same fixture, without checking the request. The `createRecordAAAA` test even uses an A-record response, so it would pass with the wrong route, method, or payload. The repository requires tests of observable behavior rather than mirrored source or schemas; this requirement must be satisfied before merging. The added account and messaging tests repeat the pattern.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

### Issue 4
src/models.ts:8720-8722
The documentation says an unresolved price is `null`, but `price?: number` allows only a number or an absent value. The client preserves JSON `null`, so TypeScript callers checking only for `undefined` can still receive `null` where they expect a number. Including `null` in the type would prevent that mistake. `renewalPrice`, `transferStatus`, and `passwordPwned` have the same documented-null mismatch.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Summary

The PR updates the Node SDK for Appwrite 30.0.0, adding domains, token introspection, OTP and native sign-in APIs, messaging and project options, and revised models. It also changes positional argument handling and expands generated service tests.

Reviews (1) · Last reviewed commit: "chore: update Node.js SDK to 30.0.0"

Comment thread src/services/messaging.ts
Comment on lines +249 to +253
replyToEmail: rest[8] as string,
replyToName: rest[9] as string,
draft: rest[10] as boolean,
html: rest[11] as boolean,
scheduledAt: rest[12] as string,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Positional email arguments shift

If a caller uses the previous positional signature for createEmail, this overload reads the existing draft boolean as replyToEmail and shifts the later options. The request can fail or create an email with the wrong settings. updateEmail has the same issue, and the Apple and Google OAuth2 update overloads shift the existing enabled argument into nativeClientIds.

Prompt To Fix With AI
This is a comment left during a code review.
Path: src/services/messaging.ts
Line: 249-253

Comment:
**Positional email arguments shift**

If a caller uses the previous positional signature for `createEmail`, this overload reads the existing `draft` boolean as `replyToEmail` and shifts the later options. The request can fail or create an email with the wrong settings. `updateEmail` has the same issue, and the Apple and Google OAuth2 update overloads shift the existing `enabled` argument into `nativeClientIds`.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex

Comment thread src/services/domains.ts
Comment on lines +4563 to +4568
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
accept: 'text/plain',
};

return this.client.call('get', uri, apiHeaders, apiPayload);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Zone content returned wrapped

When the server returns the requested DNS zone as plain text, Client.call wraps it in { message: text }. getZone therefore returns an object rather than the zone-file content callers need, while its Promise<{}> type does not describe where that content went. The test supplies JSON, so it does not cover this response path.

Prompt To Fix With AI
This is a comment left during a code review.
Path: src/services/domains.ts
Line: 4563-4568

Comment:
**Zone content returned wrapped**

When the server returns the requested DNS zone as plain text, `Client.call` wraps it in `{ message: text }`. `getZone` therefore returns an object rather than the zone-file content callers need, while its `Promise<{}>` type does not describe where that content went. The test supplies JSON, so it does not cover this response path.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex

Comment on lines +381 to +407
test('test method createRecordAAAA()', async () => {
const data = {
'\\$id': '5f40a6e10c65e',
'\\$createdAt': '2020-10-15T06:38:00.000+00:00',
'\\$updatedAt': '2020-10-15T06:38:00.000+00:00',
type: 'A',
name: 'mail',
value: '192.0.2.1',
ttl: 86400,
priority: 10,
lock: true,
weight: 10,
port: 443,
comment: 'Mail server record',
};
mockedFetch.mockImplementation(() => Response.json(data));
const response = await domains.createRecordAAAA(
'<DOMAIN_ID>',
'',
'',
1,
);

// Remove custom toString method on the objects to allow for clean data comparison.
delete response.toString;

expect(response).toEqual(data);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Domain tests mirror fixtures

These new tests return a mocked response and assert that the SDK returns the same fixture, without checking the request. The createRecordAAAA test even uses an A-record response, so it would pass with the wrong route, method, or payload. The repository requires tests of observable behavior rather than mirrored source or schemas; this requirement must be satisfied before merging. The added account and messaging tests repeat the pattern.

Context Used: Call out and harshly judge implementation-coupled tests. We don't mirror source code, configuration, or version pins in assertions. We test observable behavior; use linters for syntax and schema checks. (source)

Prompt To Fix With AI
This is a comment left during a code review.
Path: test/services/domains.test.js
Line: 381-407

Comment:
**Domain tests mirror fixtures**

These new tests return a mocked response and assert that the SDK returns the same fixture, without checking the request. The `createRecordAAAA` test even uses an A-record response, so it would pass with the wrong route, method, or payload. The repository requires tests of observable behavior rather than mirrored source or schemas; this requirement must be satisfied before merging. The added account and messaging tests repeat the pattern.

**Context Used:** Call out and harshly judge implementation-coupled tests. We don't mirror source code, configuration, or version pins in assertions. We test observable behavior; use linters for syntax and schema checks. ([source](https://app.greptile.com/review/custom-context?memory=instruction-0))

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Fix in Claude Code Fix in Codex

Comment thread src/models.ts
Comment on lines +8720 to +8722
* Domain registration price. Null when the price could not be resolved, for example for an unsupported TLD.
*/
price?: number;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Nullable prices typed incorrectly

The documentation says an unresolved price is null, but price?: number allows only a number or an absent value. The client preserves JSON null, so TypeScript callers checking only for undefined can still receive null where they expect a number. Including null in the type would prevent that mistake. renewalPrice, transferStatus, and passwordPwned have the same documented-null mismatch.

Prompt To Fix With AI
This is a comment left during a code review.
Path: src/models.ts
Line: 8720-8722

Comment:
**Nullable prices typed incorrectly**

The documentation says an unresolved price is `null`, but `price?: number` allows only a number or an absent value. The client preserves JSON `null`, so TypeScript callers checking only for `undefined` can still receive `null` where they expect a number. Including `null` in the type would prevent that mistake. `renewalPrice`, `transferStatus`, and `passwordPwned` have the same documented-null mismatch.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex

@Meldiron
Meldiron merged commit a8d6685 into main Sep 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants