@revisium/client 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +188 -134
- package/dist/branch-scope.d.ts +37 -0
- package/dist/branch-scope.d.ts.map +1 -0
- package/dist/data-operations.d.ts +99 -8
- package/dist/data-operations.d.ts.map +1 -1
- package/dist/index.cjs +759 -270
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +7 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +756 -270
- package/dist/index.mjs.map +1 -1
- package/dist/org-scope.d.ts +24 -0
- package/dist/org-scope.d.ts.map +1 -0
- package/dist/project-scope.d.ts +34 -0
- package/dist/project-scope.d.ts.map +1 -0
- package/dist/revision-scope.d.ts +122 -0
- package/dist/revision-scope.d.ts.map +1 -0
- package/dist/revisium-client.d.ts +14 -65
- package/dist/revisium-client.d.ts.map +1 -1
- package/dist/scope-owner.d.ts +7 -0
- package/dist/scope-owner.d.ts.map +1 -0
- package/package.json +1 -1
- package/dist/revisium-scope.d.ts +0 -82
- package/dist/revisium-scope.d.ts.map +0 -1
package/README.md
CHANGED
|
@@ -23,17 +23,18 @@ npm install @revisium/client
|
|
|
23
23
|
import { RevisiumClient } from '@revisium/client';
|
|
24
24
|
|
|
25
25
|
const client = new RevisiumClient({ baseUrl: 'http://localhost:8080' });
|
|
26
|
+
await client.login('admin', 'admin');
|
|
26
27
|
|
|
27
|
-
//
|
|
28
|
-
await client.
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
revision: 'draft',
|
|
28
|
+
// Navigate to a revision scope
|
|
29
|
+
const scope = await client.revision({
|
|
30
|
+
org: 'admin',
|
|
31
|
+
project: 'my-project',
|
|
32
|
+
// branch: 'master', // default
|
|
33
|
+
// revision: 'draft', // default
|
|
33
34
|
});
|
|
34
35
|
|
|
35
36
|
// Create table with schema
|
|
36
|
-
await
|
|
37
|
+
await scope.createTable('posts', {
|
|
37
38
|
type: 'object',
|
|
38
39
|
properties: {
|
|
39
40
|
title: { type: 'string', default: '' },
|
|
@@ -44,32 +45,22 @@ await client.createTable('posts', {
|
|
|
44
45
|
});
|
|
45
46
|
|
|
46
47
|
// Create row
|
|
47
|
-
await
|
|
48
|
+
await scope.createRow('posts', 'post-1', {
|
|
48
49
|
title: 'Hello World',
|
|
49
50
|
published: true,
|
|
50
51
|
});
|
|
51
52
|
|
|
52
53
|
// Read data
|
|
53
|
-
const rows = await
|
|
54
|
-
const row = await
|
|
54
|
+
const rows = await scope.getRows('posts', { first: 100 });
|
|
55
|
+
const row = await scope.getRow('posts', 'post-1');
|
|
55
56
|
|
|
56
57
|
// Commit changes
|
|
57
|
-
await
|
|
58
|
-
|
|
59
|
-
// Read committed data (head revision)
|
|
60
|
-
await client.setContext({
|
|
61
|
-
organizationId: 'admin',
|
|
62
|
-
projectName: 'my-project',
|
|
63
|
-
revision: 'head',
|
|
64
|
-
});
|
|
65
|
-
const tables = await client.getTables();
|
|
58
|
+
await scope.commit('Initial content');
|
|
66
59
|
```
|
|
67
60
|
|
|
68
61
|
## API
|
|
69
62
|
|
|
70
|
-
### Authentication
|
|
71
|
-
|
|
72
|
-
Authentication is not required when the server runs in no-auth mode. If auth is enabled:
|
|
63
|
+
### Authentication
|
|
73
64
|
|
|
74
65
|
```typescript
|
|
75
66
|
await client.login('username', 'password');
|
|
@@ -77,177 +68,240 @@ await client.login('username', 'password');
|
|
|
77
68
|
client.loginWithToken('jwt-token');
|
|
78
69
|
|
|
79
70
|
client.isAuthenticated(); // boolean
|
|
80
|
-
|
|
81
71
|
const user = await client.me(); // { id, username, email, hasPassword }
|
|
82
72
|
```
|
|
83
73
|
|
|
84
|
-
###
|
|
74
|
+
### Scope Hierarchy
|
|
75
|
+
|
|
76
|
+
The client provides a hierarchical navigation model:
|
|
77
|
+
|
|
78
|
+
```
|
|
79
|
+
RevisiumClient
|
|
80
|
+
└── OrgScope — organization-level operations
|
|
81
|
+
└── ProjectScope — project-level operations
|
|
82
|
+
└── BranchScope — branch-level operations, holds head + draft revision IDs
|
|
83
|
+
└── RevisionScope — all data operations (tables, rows, migrations)
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
Each level is created synchronously except `BranchScope` (fetches head + draft revision IDs) and `RevisionScope` via `branch.revision(id)` (validates the revision exists).
|
|
87
|
+
|
|
88
|
+
### Shortcuts
|
|
89
|
+
|
|
90
|
+
For common cases, skip intermediate scopes with shortcuts on `RevisiumClient`:
|
|
85
91
|
|
|
86
92
|
```typescript
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
93
|
+
// Jump directly to a branch
|
|
94
|
+
const branch = await client.branch({
|
|
95
|
+
org: 'admin',
|
|
96
|
+
project: 'my-project',
|
|
97
|
+
branch: 'master', // default
|
|
92
98
|
});
|
|
93
99
|
|
|
94
|
-
|
|
95
|
-
client.
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
100
|
+
// Jump directly to a revision scope
|
|
101
|
+
const scope = await client.revision({
|
|
102
|
+
org: 'admin',
|
|
103
|
+
project: 'my-project',
|
|
104
|
+
branch: 'master', // default
|
|
105
|
+
revision: 'draft', // 'draft' | 'head' | '<revisionId>', default: 'draft'
|
|
106
|
+
});
|
|
99
107
|
```
|
|
100
108
|
|
|
101
|
-
###
|
|
109
|
+
### Full Hierarchy Navigation
|
|
102
110
|
|
|
103
111
|
```typescript
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
await
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
await
|
|
112
|
+
const org = client.org('admin');
|
|
113
|
+
const project = org.project('my-project');
|
|
114
|
+
const branch = await project.branch('master');
|
|
115
|
+
|
|
116
|
+
const draft = branch.draft(); // RevisionScope for draft revision
|
|
117
|
+
const head = branch.head(); // RevisionScope for head revision
|
|
118
|
+
const rev = await branch.revision('some-revision-id'); // specific revision
|
|
111
119
|
```
|
|
112
120
|
|
|
113
|
-
###
|
|
121
|
+
### OrgScope
|
|
122
|
+
|
|
123
|
+
```typescript
|
|
124
|
+
const org = client.org('admin');
|
|
125
|
+
|
|
126
|
+
await org.getProjects({ first: 100, after: 'cursor' });
|
|
127
|
+
await org.createProject({ projectName: 'new-project', branchName: 'master' });
|
|
128
|
+
await org.getUsers();
|
|
129
|
+
await org.addUser(userId, 'developer');
|
|
130
|
+
await org.removeUser(userId);
|
|
131
|
+
```
|
|
114
132
|
|
|
115
|
-
|
|
133
|
+
### ProjectScope
|
|
116
134
|
|
|
117
135
|
```typescript
|
|
136
|
+
const project = client.org('admin').project('my-project');
|
|
137
|
+
|
|
138
|
+
await project.get();
|
|
139
|
+
await project.update({ isPublic: true });
|
|
140
|
+
await project.delete();
|
|
141
|
+
await project.getBranches();
|
|
142
|
+
await project.getRootBranch();
|
|
143
|
+
await project.createBranch('feature', revisionId);
|
|
144
|
+
await project.getUsers();
|
|
145
|
+
await project.addUser(userId, 'editor');
|
|
146
|
+
await project.removeUser(userId);
|
|
147
|
+
await project.getEndpoints();
|
|
148
|
+
await project.createEndpoint({ type: 'GRAPHQL' });
|
|
149
|
+
await project.deleteEndpoint(endpointId);
|
|
150
|
+
await project.getEndpointRelatives(endpointId);
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
### BranchScope
|
|
154
|
+
|
|
155
|
+
```typescript
|
|
156
|
+
const branch = await client.branch({ org: 'admin', project: 'my-project' });
|
|
157
|
+
|
|
158
|
+
branch.headRevisionId; // string
|
|
159
|
+
branch.draftRevisionId; // string
|
|
160
|
+
|
|
161
|
+
await branch.get();
|
|
162
|
+
await branch.delete();
|
|
163
|
+
await branch.getTouched();
|
|
164
|
+
await branch.getRevisions({ first: 100 });
|
|
165
|
+
await branch.getStartRevision();
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
### RevisionScope — Read Operations
|
|
169
|
+
|
|
170
|
+
```typescript
|
|
171
|
+
const scope = await client.revision({ org: 'admin', project: 'my-project' });
|
|
172
|
+
|
|
118
173
|
// Tables
|
|
119
|
-
await
|
|
120
|
-
await
|
|
121
|
-
await
|
|
122
|
-
await
|
|
174
|
+
await scope.getTables({ first: 100, after: 'cursor' });
|
|
175
|
+
await scope.getTable('posts');
|
|
176
|
+
await scope.getTableSchema('posts');
|
|
177
|
+
await scope.getTableCountRows('posts');
|
|
178
|
+
await scope.getTableForeignKeysBy('posts');
|
|
179
|
+
await scope.getTableForeignKeysTo('posts');
|
|
123
180
|
|
|
124
181
|
// Rows
|
|
125
|
-
await
|
|
126
|
-
await
|
|
127
|
-
await
|
|
128
|
-
await
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
await
|
|
132
|
-
await
|
|
133
|
-
await
|
|
134
|
-
await client.renameRow('posts', 'row-1', 'post-1');
|
|
182
|
+
await scope.getRows('posts', { first: 100 });
|
|
183
|
+
await scope.getRow('posts', 'post-1');
|
|
184
|
+
await scope.getRowForeignKeysBy('posts', 'post-1', 'comments');
|
|
185
|
+
await scope.getRowForeignKeysTo('posts', 'post-1', 'authors');
|
|
186
|
+
|
|
187
|
+
// Changes
|
|
188
|
+
await scope.getChanges();
|
|
189
|
+
await scope.getTableChanges({ changeTypes: ['ADDED', 'MODIFIED'] });
|
|
190
|
+
await scope.getRowChanges({ tableId: 'posts' });
|
|
135
191
|
|
|
136
192
|
// Migrations
|
|
137
|
-
await
|
|
138
|
-
{ type: 'init', tableId: 'posts', schema },
|
|
139
|
-
]);
|
|
193
|
+
await scope.getMigrations();
|
|
140
194
|
```
|
|
141
195
|
|
|
142
|
-
###
|
|
196
|
+
### RevisionScope — Endpoint Operations
|
|
197
|
+
|
|
198
|
+
Endpoint operations work on any revision (draft, head, or explicit).
|
|
143
199
|
|
|
144
200
|
```typescript
|
|
145
|
-
|
|
146
|
-
await
|
|
201
|
+
await scope.getEndpoints();
|
|
202
|
+
await scope.getEndpointRelatives(endpointId);
|
|
203
|
+
await scope.createEndpoint({ type: 'GRAPHQL' });
|
|
204
|
+
await scope.deleteEndpoint(endpointId);
|
|
147
205
|
```
|
|
148
206
|
|
|
149
|
-
###
|
|
207
|
+
### RevisionScope — Write Operations (draft only)
|
|
150
208
|
|
|
151
|
-
|
|
209
|
+
Write methods throw if the scope is not a draft revision.
|
|
152
210
|
|
|
153
211
|
```typescript
|
|
154
|
-
const
|
|
155
|
-
await client.login('admin', 'admin');
|
|
212
|
+
const draft = branch.draft();
|
|
156
213
|
|
|
157
|
-
//
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
});
|
|
214
|
+
// Tables
|
|
215
|
+
await draft.createTable('posts', schema);
|
|
216
|
+
await draft.updateTable('posts', patches);
|
|
217
|
+
await draft.deleteTable('posts');
|
|
218
|
+
await draft.renameTable('posts', 'articles');
|
|
163
219
|
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
220
|
+
// Rows
|
|
221
|
+
await draft.createRow('posts', 'row-1', data);
|
|
222
|
+
await draft.createRows('posts', [{ rowId: 'r1', data }, { rowId: 'r2', data }]);
|
|
223
|
+
await draft.createRows('posts', rows, { isRestore: true });
|
|
224
|
+
await draft.updateRow('posts', 'row-1', data);
|
|
225
|
+
await draft.updateRows('posts', [{ rowId: 'r1', data }]);
|
|
226
|
+
await draft.patchRow('posts', 'row-1', [{ op: 'replace', path: 'title', value: 'New' }]);
|
|
227
|
+
await draft.patchRows('posts', { rows: [...] });
|
|
228
|
+
await draft.deleteRow('posts', 'row-1');
|
|
229
|
+
await draft.deleteRows('posts', ['row-1', 'row-2']);
|
|
230
|
+
await draft.renameRow('posts', 'row-1', 'post-1');
|
|
169
231
|
|
|
170
|
-
//
|
|
171
|
-
await
|
|
172
|
-
await
|
|
232
|
+
// Migrations
|
|
233
|
+
await draft.applyMigrations([{ changeType: 'init', tableId: 'posts', ... }]);
|
|
234
|
+
const results = await draft.applyMigrationsWithStatus(migrations);
|
|
173
235
|
|
|
174
|
-
//
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
236
|
+
// File upload
|
|
237
|
+
await draft.uploadFile('posts', 'post-1', 'avatar', file);
|
|
238
|
+
```
|
|
239
|
+
|
|
240
|
+
### Version Control (draft only)
|
|
241
|
+
|
|
242
|
+
```typescript
|
|
243
|
+
const revision = await draft.commit('my changes');
|
|
244
|
+
await draft.revertChanges();
|
|
245
|
+
```
|
|
246
|
+
|
|
247
|
+
After `commit`, `revertChanges`, or `applyMigrations`, the scope automatically refreshes its `revisionId` and marks sibling scopes on the same branch as stale.
|
|
248
|
+
|
|
249
|
+
### Stale Scopes
|
|
250
|
+
|
|
251
|
+
When one scope commits or reverts, all sibling scopes (created from the same `BranchScope`) on the same branch are marked stale.
|
|
252
|
+
|
|
253
|
+
```typescript
|
|
254
|
+
const branch = await client.branch({ org: 'admin', project: 'my-project' });
|
|
255
|
+
const scopeA = branch.draft();
|
|
256
|
+
const scopeB = branch.draft();
|
|
180
257
|
|
|
181
258
|
await scopeA.commit('changes');
|
|
182
|
-
//
|
|
259
|
+
// scopeB.isStale === true — auto-refreshes revisionId on next data access
|
|
183
260
|
|
|
184
|
-
//
|
|
185
|
-
scopeA.dispose();
|
|
261
|
+
scopeA.dispose(); // unregister from BranchScope tracking
|
|
186
262
|
scopeB.dispose();
|
|
187
|
-
scopeC.dispose();
|
|
188
263
|
```
|
|
189
264
|
|
|
190
|
-
|
|
265
|
+
- Stale scopes auto-refresh their `revisionId` on the next data method call
|
|
266
|
+
- Scopes with explicit `revisionId` (via `branch.revision(id)`) never go stale
|
|
267
|
+
- Concurrent reads on a stale scope share a single refresh call (promise dedup)
|
|
268
|
+
|
|
269
|
+
### RevisionScope Properties
|
|
191
270
|
|
|
192
271
|
```typescript
|
|
193
272
|
scope.organizationId; // string
|
|
194
273
|
scope.projectName; // string
|
|
195
274
|
scope.branchName; // string
|
|
196
|
-
scope.revisionId; // string
|
|
275
|
+
scope.revisionId; // string
|
|
197
276
|
scope.isDraft; // boolean
|
|
198
|
-
scope.isStale; // boolean
|
|
277
|
+
scope.isStale; // boolean
|
|
199
278
|
scope.isDisposed; // boolean
|
|
200
|
-
scope.client; // underlying HTTP client
|
|
279
|
+
scope.client; // underlying HTTP client
|
|
201
280
|
```
|
|
202
281
|
|
|
203
|
-
#### Scope Methods
|
|
204
|
-
|
|
205
|
-
```typescript
|
|
206
|
-
// Same data methods as RevisiumClient
|
|
207
|
-
await scope.getTables();
|
|
208
|
-
await scope.createRow('posts', 'row-1', data);
|
|
209
|
-
await scope.getMigrations();
|
|
210
|
-
await scope.applyMigrations(migrations);
|
|
211
|
-
await scope.commit('message');
|
|
212
|
-
// ... all other read/write/version-control methods
|
|
213
|
-
|
|
214
|
-
// Scope-specific
|
|
215
|
-
scope.markStale(); // manually mark as stale
|
|
216
|
-
await scope.refresh(); // manually refresh revisionId
|
|
217
|
-
scope.dispose(); // unregister from parent tracking
|
|
218
|
-
```
|
|
219
|
-
|
|
220
|
-
#### Stale Behavior
|
|
221
|
-
|
|
222
|
-
- When one scope commits or reverts, all sibling scopes on the same branch are marked stale
|
|
223
|
-
- Stale scopes auto-refresh their `revisionId` on the next data method call
|
|
224
|
-
- Scopes with explicit `revisionId` (not `'draft'` or `'head'`) never go stale
|
|
225
|
-
- Concurrent reads on a stale scope share a single refresh API call (promise dedup)
|
|
226
|
-
|
|
227
282
|
## Error Handling
|
|
228
283
|
|
|
229
|
-
|
|
284
|
+
Methods throw on errors instead of returning `{ data, error }`:
|
|
230
285
|
|
|
231
286
|
```typescript
|
|
232
|
-
|
|
287
|
+
const branch = await client.branch({ org: 'admin', project: 'my-project' });
|
|
288
|
+
|
|
289
|
+
// Mutations in read-only revision
|
|
290
|
+
const head = branch.head();
|
|
233
291
|
try {
|
|
234
|
-
await
|
|
292
|
+
await head.createRow('posts', 'row-1', { title: 'Hello' });
|
|
235
293
|
} catch (err) {
|
|
236
|
-
console.error(err.message);
|
|
294
|
+
console.error(err.message);
|
|
295
|
+
// "Mutations are only allowed in draft revision."
|
|
237
296
|
}
|
|
238
297
|
|
|
239
|
-
//
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
projectName: 'my-project',
|
|
243
|
-
revision: 'head', // or explicit revisionId
|
|
244
|
-
});
|
|
245
|
-
|
|
298
|
+
// Disposed scope
|
|
299
|
+
const scope = branch.draft();
|
|
300
|
+
scope.dispose();
|
|
246
301
|
try {
|
|
247
|
-
await
|
|
302
|
+
await scope.getTables();
|
|
248
303
|
} catch (err) {
|
|
249
|
-
console.error(err.message);
|
|
250
|
-
// "Mutations are only allowed in draft revision. Use setContext({ revision: "draft" })."
|
|
304
|
+
console.error(err.message); // "Scope has been disposed."
|
|
251
305
|
}
|
|
252
306
|
```
|
|
253
307
|
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { Client } from './generated/client/index.js';
|
|
2
|
+
import type { BranchModel, RevisionsConnection, RevisionModel, TouchedModelDto } from './generated/types.gen.js';
|
|
3
|
+
import type { BranchContext } from './data-operations.js';
|
|
4
|
+
import { RevisionScope } from './revision-scope.js';
|
|
5
|
+
import type { ScopeOwner } from './scope-owner.js';
|
|
6
|
+
export declare class BranchScope implements ScopeOwner {
|
|
7
|
+
private readonly _client;
|
|
8
|
+
private readonly _branch;
|
|
9
|
+
private _headRevisionId;
|
|
10
|
+
private _draftRevisionId;
|
|
11
|
+
private readonly _scopes;
|
|
12
|
+
private constructor();
|
|
13
|
+
static create(client: Client, branch: BranchContext): Promise<BranchScope>;
|
|
14
|
+
get organizationId(): string;
|
|
15
|
+
get projectName(): string;
|
|
16
|
+
get branchName(): string;
|
|
17
|
+
get headRevisionId(): string;
|
|
18
|
+
get draftRevisionId(): string;
|
|
19
|
+
get client(): Client;
|
|
20
|
+
draft(): RevisionScope;
|
|
21
|
+
head(): RevisionScope;
|
|
22
|
+
revision(revisionId: string): Promise<RevisionScope>;
|
|
23
|
+
get(): Promise<BranchModel>;
|
|
24
|
+
delete(): Promise<void>;
|
|
25
|
+
getTouched(): Promise<TouchedModelDto>;
|
|
26
|
+
getRevisions(options?: {
|
|
27
|
+
first?: number;
|
|
28
|
+
after?: string;
|
|
29
|
+
before?: string;
|
|
30
|
+
inclusive?: boolean;
|
|
31
|
+
}): Promise<RevisionsConnection>;
|
|
32
|
+
getStartRevision(): Promise<RevisionModel>;
|
|
33
|
+
notifyBranchChanged(branchKey: string, excludeScope?: RevisionScope): void;
|
|
34
|
+
unregisterScope(scope: RevisionScope): void;
|
|
35
|
+
refreshRevisionIds(): Promise<void>;
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=branch-scope.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"branch-scope.d.ts","sourceRoot":"","sources":["../src/branch-scope.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAC1D,OAAO,KAAK,EACV,WAAW,EACX,mBAAmB,EACnB,aAAa,EACb,eAAe,EAChB,MAAM,0BAA0B,CAAC;AAElC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,qBAAa,WAAY,YAAW,UAAU;IAM1C,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,OAAO,CAAC,QAAQ,CAAC,OAAO;IAN1B,OAAO,CAAC,eAAe,CAAS;IAChC,OAAO,CAAC,gBAAgB,CAAS;IACjC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA4B;IAEpD,OAAO;WAUM,MAAM,CACjB,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,aAAa,GACpB,OAAO,CAAC,WAAW,CAAC;IAQvB,IAAW,cAAc,IAAI,MAAM,CAElC;IAED,IAAW,WAAW,IAAI,MAAM,CAE/B;IAED,IAAW,UAAU,IAAI,MAAM,CAE9B;IAED,IAAW,cAAc,IAAI,MAAM,CAElC;IAED,IAAW,eAAe,IAAI,MAAM,CAEnC;IAED,IAAW,MAAM,IAAI,MAAM,CAE1B;IAED,KAAK,IAAI,aAAa;IAatB,IAAI,IAAI,aAAa;IAaf,QAAQ,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,aAAa,CAAC;IAkBpD,GAAG,IAAI,OAAO,CAAC,WAAW,CAAC;IAI3B,MAAM,IAAI,OAAO,CAAC,IAAI,CAAC;IAIvB,UAAU,IAAI,OAAO,CAAC,eAAe,CAAC;IAItC,YAAY,CAAC,OAAO,CAAC,EAAE;QAC3B,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,SAAS,CAAC,EAAE,OAAO,CAAC;KACrB,GAAG,OAAO,CAAC,mBAAmB,CAAC;IAI1B,gBAAgB,IAAI,OAAO,CAAC,aAAa,CAAC;IAQhD,mBAAmB,CAAC,SAAS,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,aAAa,GAAG,IAAI;IAY1E,eAAe,CAAC,KAAK,EAAE,aAAa,GAAG,IAAI;IAIrC,kBAAkB,IAAI,OAAO,CAAC,IAAI,CAAC;CAQ1C"}
|
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
import type { Client } from './generated/client/index.js';
|
|
2
|
-
import type { CreateRowResponse, CreateRowsResponse, CreateTableResponse, GetTableRowsDto, InitMigrationDto,
|
|
3
|
-
export interface
|
|
2
|
+
import type { ApplyMigrationsResponse, BranchesConnection, BranchModel, CountModelDto, CreateEndpointDto, CreateProjectDto, CreateRowResponse, CreateRowsResponse, CreateTableResponse, EndpointModel, GetEndpointResultDto, GetTableRowsDto, InitMigrationDto, MigrationsResponse, PatchRow, PatchRowResponse, PatchRowsDto, PatchRowsResponse, ProjectModel, ProjectsConnection, RemoveMigrationDto, RenameMigrationDto, RenameRowResponse, RenameTableResponse, RevisionChangesResponse, RevisionModel, RevisionsConnection, RowChangesConnection, RowModel, RowsConnection, TableChangesConnection, TableModel, TablesConnection, TouchedModelDto, UpdateMigrationDto, UpdateProjectDto, UpdateRowResponse, UpdateRowsResponse, UpdateTableResponse, UploadFileResponse, UsersOrganizationConnection, UsersProjectConnection, MeModel } from './generated/types.gen.js';
|
|
3
|
+
export interface OrgContext {
|
|
4
|
+
readonly client: Client;
|
|
4
5
|
readonly organizationId: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ProjectContext extends OrgContext {
|
|
5
8
|
readonly projectName: string;
|
|
9
|
+
}
|
|
10
|
+
export interface BranchContext extends ProjectContext {
|
|
6
11
|
readonly branchName: string;
|
|
7
12
|
}
|
|
8
13
|
export interface ScopeContext {
|
|
@@ -18,21 +23,84 @@ export declare function unwrap<T>(result: {
|
|
|
18
23
|
export declare function assertDraft(ctx: ScopeContext): void;
|
|
19
24
|
export declare function assertContext(ctx: ScopeContext): void;
|
|
20
25
|
export declare function me(client: Client): Promise<MeModel>;
|
|
26
|
+
export declare function getProjects(ctx: OrgContext, options?: {
|
|
27
|
+
first?: number;
|
|
28
|
+
after?: string;
|
|
29
|
+
}): Promise<ProjectsConnection>;
|
|
30
|
+
export declare function createProject(ctx: OrgContext, body: CreateProjectDto): Promise<ProjectModel>;
|
|
31
|
+
export declare function getOrgUsers(ctx: OrgContext, options?: {
|
|
32
|
+
first?: number;
|
|
33
|
+
after?: string;
|
|
34
|
+
}): Promise<UsersOrganizationConnection>;
|
|
35
|
+
export declare function addOrgUser(ctx: OrgContext, userId: string, roleId: 'organizationOwner' | 'organizationAdmin' | 'developer' | 'editor' | 'reader'): Promise<void>;
|
|
36
|
+
export declare function removeOrgUser(ctx: OrgContext, userId: string): Promise<void>;
|
|
37
|
+
export declare function getProject(ctx: ProjectContext): Promise<ProjectModel>;
|
|
38
|
+
export declare function updateProject(ctx: ProjectContext, body: UpdateProjectDto): Promise<void>;
|
|
39
|
+
export declare function deleteProject(ctx: ProjectContext): Promise<void>;
|
|
40
|
+
export declare function getBranches(ctx: ProjectContext, options?: {
|
|
41
|
+
first?: number;
|
|
42
|
+
after?: string;
|
|
43
|
+
}): Promise<BranchesConnection>;
|
|
44
|
+
export declare function getRootBranch(ctx: ProjectContext): Promise<BranchModel>;
|
|
45
|
+
export declare function getProjectUsers(ctx: ProjectContext, options?: {
|
|
46
|
+
first?: number;
|
|
47
|
+
after?: string;
|
|
48
|
+
}): Promise<UsersProjectConnection>;
|
|
49
|
+
export declare function addProjectUser(ctx: ProjectContext, userId: string, roleId: 'developer' | 'editor' | 'reader'): Promise<void>;
|
|
50
|
+
export declare function removeProjectUser(ctx: ProjectContext, userId: string): Promise<void>;
|
|
51
|
+
export declare function getBranch(client: Client, branch: BranchContext): Promise<BranchModel>;
|
|
52
|
+
export declare function createBranch(client: Client, revisionId: string, branchName: string): Promise<BranchModel>;
|
|
53
|
+
export declare function deleteBranch(client: Client, branch: BranchContext): Promise<void>;
|
|
54
|
+
export declare function getBranchTouched(client: Client, branch: BranchContext): Promise<TouchedModelDto>;
|
|
55
|
+
export declare function getRevisions(client: Client, branch: BranchContext, options?: {
|
|
56
|
+
first?: number;
|
|
57
|
+
after?: string;
|
|
58
|
+
before?: string;
|
|
59
|
+
inclusive?: boolean;
|
|
60
|
+
}): Promise<RevisionsConnection>;
|
|
61
|
+
export declare function getRevision(client: Client, revisionId: string): Promise<RevisionModel>;
|
|
62
|
+
export declare function getParentRevision(client: Client, revisionId: string): Promise<RevisionModel>;
|
|
63
|
+
export declare function getChildRevision(client: Client, revisionId: string): Promise<RevisionModel>;
|
|
64
|
+
export declare function getStartRevision(client: Client, branch: BranchContext): Promise<RevisionModel>;
|
|
65
|
+
export declare function fetchDraftRevisionId(client: Client, branch: BranchContext): Promise<string>;
|
|
66
|
+
export declare function fetchHeadRevisionId(client: Client, branch: BranchContext): Promise<string>;
|
|
67
|
+
export declare function validateRevisionId(client: Client, revisionId: string): Promise<void>;
|
|
21
68
|
export declare function getMigrations(ctx: ScopeContext): Promise<MigrationsResponse>;
|
|
22
69
|
export declare function applyMigrations(ctx: ScopeContext, migrations: Array<InitMigrationDto | UpdateMigrationDto | RenameMigrationDto | RemoveMigrationDto>): Promise<void>;
|
|
70
|
+
export declare function applyMigrationsWithStatus(ctx: ScopeContext, migrations: Array<InitMigrationDto | UpdateMigrationDto | RenameMigrationDto | RemoveMigrationDto>): Promise<ApplyMigrationsResponse>;
|
|
23
71
|
export declare function getTables(ctx: ScopeContext, options?: {
|
|
24
72
|
first?: number;
|
|
25
73
|
after?: string;
|
|
26
74
|
}): Promise<TablesConnection>;
|
|
27
75
|
export declare function getTable(ctx: ScopeContext, tableId: string): Promise<TableModel>;
|
|
28
76
|
export declare function getTableSchema(ctx: ScopeContext, tableId: string): Promise<object>;
|
|
29
|
-
export declare function
|
|
30
|
-
export declare function
|
|
31
|
-
|
|
77
|
+
export declare function getTableCountRows(ctx: ScopeContext, tableId: string): Promise<CountModelDto>;
|
|
78
|
+
export declare function getTableForeignKeysBy(ctx: ScopeContext, tableId: string, options?: {
|
|
79
|
+
first?: number;
|
|
80
|
+
after?: string;
|
|
81
|
+
}): Promise<TablesConnection>;
|
|
82
|
+
export declare function getTableForeignKeysTo(ctx: ScopeContext, tableId: string, options?: {
|
|
83
|
+
first?: number;
|
|
84
|
+
after?: string;
|
|
85
|
+
}): Promise<TablesConnection>;
|
|
86
|
+
export declare function getTableCountForeignKeysBy(ctx: ScopeContext, tableId: string): Promise<CountModelDto>;
|
|
87
|
+
export declare function getTableCountForeignKeysTo(ctx: ScopeContext, tableId: string): Promise<CountModelDto>;
|
|
32
88
|
export declare function createTable(ctx: ScopeContext, tableId: string, schema: object): Promise<CreateTableResponse>;
|
|
33
89
|
export declare function updateTable(ctx: ScopeContext, tableId: string, patches: object[]): Promise<UpdateTableResponse>;
|
|
34
90
|
export declare function deleteTable(ctx: ScopeContext, tableId: string): Promise<void>;
|
|
35
91
|
export declare function renameTable(ctx: ScopeContext, tableId: string, nextTableId: string): Promise<RenameTableResponse>;
|
|
92
|
+
export declare function getRows(ctx: ScopeContext, tableId: string, options?: GetTableRowsDto): Promise<RowsConnection>;
|
|
93
|
+
export declare function getRow(ctx: ScopeContext, tableId: string, rowId: string): Promise<RowModel>;
|
|
94
|
+
export declare function getRowForeignKeysBy(ctx: ScopeContext, tableId: string, rowId: string, foreignKeyByTableId: string, options?: {
|
|
95
|
+
first?: number;
|
|
96
|
+
after?: string;
|
|
97
|
+
}): Promise<RowsConnection>;
|
|
98
|
+
export declare function getRowForeignKeysTo(ctx: ScopeContext, tableId: string, rowId: string, foreignKeyToTableId: string, options?: {
|
|
99
|
+
first?: number;
|
|
100
|
+
after?: string;
|
|
101
|
+
}): Promise<RowsConnection>;
|
|
102
|
+
export declare function getRowCountForeignKeysBy(ctx: ScopeContext, tableId: string, rowId: string): Promise<CountModelDto>;
|
|
103
|
+
export declare function getRowCountForeignKeysTo(ctx: ScopeContext, tableId: string, rowId: string): Promise<CountModelDto>;
|
|
36
104
|
export declare function createRow(ctx: ScopeContext, tableId: string, rowId: string, data: object): Promise<CreateRowResponse>;
|
|
37
105
|
export declare function createRows(ctx: ScopeContext, tableId: string, rows: Array<{
|
|
38
106
|
rowId: string;
|
|
@@ -48,12 +116,35 @@ export declare function updateRows(ctx: ScopeContext, tableId: string, rows: Arr
|
|
|
48
116
|
isRestore?: boolean;
|
|
49
117
|
}): Promise<UpdateRowsResponse>;
|
|
50
118
|
export declare function patchRow(ctx: ScopeContext, tableId: string, rowId: string, patches: PatchRow[]): Promise<PatchRowResponse>;
|
|
119
|
+
export declare function patchRows(ctx: ScopeContext, tableId: string, body: PatchRowsDto): Promise<PatchRowsResponse>;
|
|
51
120
|
export declare function deleteRow(ctx: ScopeContext, tableId: string, rowId: string): Promise<void>;
|
|
52
121
|
export declare function deleteRows(ctx: ScopeContext, tableId: string, rowIds: string[]): Promise<void>;
|
|
53
122
|
export declare function renameRow(ctx: ScopeContext, tableId: string, rowId: string, nextRowId: string): Promise<RenameRowResponse>;
|
|
123
|
+
export declare function getChanges(ctx: ScopeContext): Promise<RevisionChangesResponse>;
|
|
124
|
+
export declare function getTableChanges(ctx: ScopeContext, options?: {
|
|
125
|
+
first?: number;
|
|
126
|
+
after?: string;
|
|
127
|
+
compareWithRevisionId?: string;
|
|
128
|
+
changeTypes?: Array<'ADDED' | 'MODIFIED' | 'REMOVED' | 'RENAMED' | 'RENAMED_AND_MODIFIED'>;
|
|
129
|
+
search?: string;
|
|
130
|
+
withSchemaMigrations?: boolean;
|
|
131
|
+
includeSystem?: boolean;
|
|
132
|
+
}): Promise<TableChangesConnection>;
|
|
133
|
+
export declare function getRowChanges(ctx: ScopeContext, options?: {
|
|
134
|
+
first?: number;
|
|
135
|
+
after?: string;
|
|
136
|
+
compareWithRevisionId?: string;
|
|
137
|
+
tableId?: string;
|
|
138
|
+
changeTypes?: Array<'ADDED' | 'MODIFIED' | 'REMOVED' | 'RENAMED' | 'RENAMED_AND_MODIFIED'>;
|
|
139
|
+
search?: string;
|
|
140
|
+
includeSystem?: boolean;
|
|
141
|
+
}): Promise<RowChangesConnection>;
|
|
54
142
|
export declare function commit(ctx: ScopeContext, comment?: string): Promise<RevisionModel>;
|
|
55
143
|
export declare function revertChanges(ctx: ScopeContext): Promise<void>;
|
|
56
|
-
export declare function
|
|
57
|
-
export declare function
|
|
58
|
-
export declare function
|
|
144
|
+
export declare function getEndpoints(ctx: ScopeContext): Promise<EndpointModel[]>;
|
|
145
|
+
export declare function createEndpoint(ctx: ScopeContext, body: CreateEndpointDto): Promise<EndpointModel>;
|
|
146
|
+
export declare function deleteEndpoint(client: Client, endpointId: string): Promise<void>;
|
|
147
|
+
export declare function getEndpointRelatives(client: Client, endpointId: string): Promise<GetEndpointResultDto>;
|
|
148
|
+
export declare function uploadFile(ctx: ScopeContext, tableId: string, rowId: string, fileId: string, file: Blob | File): Promise<UploadFileResponse>;
|
|
149
|
+
export type { MeModel } from './generated/types.gen.js';
|
|
59
150
|
//# sourceMappingURL=data-operations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data-operations.d.ts","sourceRoot":"","sources":["../src/data-operations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAE1D,OAAO,KAAK,EACV,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,eAAe,EACf,gBAAgB,EAChB,
|
|
1
|
+
{"version":3,"file":"data-operations.d.ts","sourceRoot":"","sources":["../src/data-operations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAE1D,OAAO,KAAK,EACV,uBAAuB,EACvB,kBAAkB,EAClB,WAAW,EACX,aAAa,EACb,iBAAiB,EACjB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,aAAa,EACb,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EAClB,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,iBAAiB,EACjB,YAAY,EACZ,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,iBAAiB,EACjB,mBAAmB,EACnB,uBAAuB,EACvB,aAAa,EACb,mBAAmB,EACnB,oBAAoB,EACpB,QAAQ,EACR,cAAc,EACd,sBAAsB,EACtB,UAAU,EACV,gBAAgB,EAChB,eAAe,EACf,kBAAkB,EAClB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAClB,2BAA2B,EAC3B,sBAAsB,EACtB,OAAO,EACR,MAAM,0BAA0B,CAAC;AAMlC,MAAM,WAAW,UAAU;IACzB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;CACjC;AAED,MAAM,WAAW,cAAe,SAAQ,UAAU;IAChD,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;CAC9B;AAED,MAAM,WAAW,aAAc,SAAQ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