Repository navigation
fix(sdks): expose migrations to server SDKs - #14882
Conversation
|
Review complete. 🟡 1 medium 📍 Findings outside the diff (1) — 🟡 1 medium — defects on lines GitHub can't attach comments to🟡 Medium — No e2e test rejects key without migrations scope · MigrationsBase.php:203–264 · // tests/e2e/Services/Migrations/MigrationsBase.php
203 public function performMigrationSync(array $body): array
204 {
205 $migration = $this->client->call(Client::METHOD_POST, '/migrations/appwrite', [
206 'content-type' => 'application/json',
207 'x-appwrite-project' => $this->getDestinationProject()['$id'],
208 'x-appwrite-key' => $this->getDestinationProject()['apiKey'],
209 ], $body);
210
211 $this->assertEquals(202, $migration['headers']['status-code'], $migration['body']['message'] ?? '');
212 $this->assertNotEmpty($migration['body']);
213 $this->assertNotEmpty($migration['body']['$id']);
214 The patch makes the migrations routes key-authenticatable ( 🧹 Nitpicks (1) — 🟢 1 low
The change grants API-key access to the Migrations API uniformly: every route now lists
Reviewed commit: 712725d |
🟢 Tier S · Ready to merge
Adds API-key authentication metadata alongside admin authentication to the 16 Migrations methods, exposing the service in generated server SDKs while retaining its console SDK surface. The parameter-order lock now records the server SDK method signatures as well. Latest changes: The newest commit adds all 16 Migrations method parameter lists to the server section of the SDK parameter lock.
📂 Walkthrough · 2
Reviewed the commits since |
Security rulesNo new WARNING or ERROR findings from security rules. 6 existing findings tracked in
|
✨ Benchmark resultsComparing
Per-scenario breakdown & investigation detailsMetrics below reflect the current branch (after). Δ P95 compares against the base.
Top API waits (after)
|
…r-sdk fix(sdks): expose migrations to server SDKs (cherry picked from commit 1467f65)
What does this PR do?
Migrations endpoints declare only console authentication in SDK metadata, so server SDK generation omits the entire service. This also prevents the Go-based CLI from offering migration commands.
Add
AuthType::KEYalongsideAuthType::ADMINon all 16 Migrations methods. Runtime authentication already accepts project API keys withmigrations.readormigrations.write; these declarations make the generated SDK surface reflect that support.Test Plan
2.6.xspecs and verified 16 Migrations operations in both server and console specs, and none in the client spec. Generated specs and examples are ignored artifacts, so they are not committed here.Related PRs and Issues
Prerequisite for the planned Go SDK
v7.15.0and CLI28.9.0releases with Migrations support. Cloud's overridden Appwrite migration report declaration needs the matching change when it consumes this CE update.Checklist
Related: appwrite-labs/cloud#6667