You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit d507cd1
Browse filesBrowse the repository at this point in the historyBrowse files
docs: update CloudSync management API database registration
Document the required projectId field for database registration and clarify how SQLite Cloud hosts, API keys, and databaseName are used in the quickstart.
Also document filtered database lookup with projectId and database query parameters, and note that SQLite Cloud operations switch to databaseName while Postgres requires the connection string to target the database.
Use `managedDatabaseId`as `MGMT_DB_ID` in the next calls. The response also includes additional database metadata, such as `projectId`, `databaseName`, auth settings, and timestamps.
82
87
83
88
```bash
84
89
export MGMT_DB_ID="db_xxxxxxxxxxxxxxxxxxxxxxxx"
@@ -155,10 +160,12 @@ Required fields:
155
160
-`connectionString`
156
161
-`provider` — `postgres` or `sqlitecloud`
157
162
-`flavor` — for example `vanilla`, `supabase`, or `sqlitecloud`
163
+
-`projectId` — SQLite Cloud project identifier for the managed database. For SQLite Cloud connection strings, this must match the project ID parsed from the connection string.
158
164
-`databaseName`
159
165
160
166
Optional fields:
161
167
168
+
-`workspaceId` — not supported with workspace-scoped keys; the workspace is derived from the key
162
169
-`schemaName` — Postgres only
163
170
-`jwtAllowedIssuers`
164
171
-`jwtExpectedAudiences`
@@ -172,19 +179,33 @@ Important behavior for workspace-scoped keys:
172
179
173
180
CloudSync verifies the tenant database connection before registration is persisted. If verification fails, the database is not registered.
174
181
182
+
For SQLite Cloud databases, `databaseName` identifies the target database and CloudSync switches to it when running CloudSync operations. For Postgres databases, the `connectionString` must point to the target database.
183
+
175
184
Common database failure codes include `database_paused`, `database_auth_failed`, `database_unreachable`, `database_permission_denied`, `database_cloudsync_not_ready`, and `database_error`.
176
185
177
186
### `GET /v1/databases`
178
187
179
188
Lists managed databases visible to the key.
180
189
190
+
Query parameters:
191
+
192
+
-`projectId` — filter by project ID
193
+
-`database` — filter by database name; requires `projectId`
0 commit comments