@superdoc-dev/sdk 1.1.0-next.16 → 1.1.0-next.17
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 +4 -0
- package/dist/generated/client.d.ts +33 -3
- package/dist/generated/client.d.ts.map +1 -1
- package/dist/generated/contract.cjs +199 -5
- package/dist/generated/contract.d.ts.map +1 -1
- package/dist/generated/contract.js +199 -5
- package/dist/index.d.ts +6 -9
- package/dist/index.d.ts.map +1 -1
- package/package.json +6 -6
- package/tools/__pycache__/__init__.cpython-312.pyc +0 -0
- package/tools/__pycache__/intent_dispatch_generated.cpython-312.pyc +0 -0
package/README.md
CHANGED
|
@@ -81,6 +81,10 @@ await doc.save(params)
|
|
|
81
81
|
await doc.close(params)
|
|
82
82
|
```
|
|
83
83
|
|
|
84
|
+
### Collaboration sessions
|
|
85
|
+
|
|
86
|
+
The SDK supports collaborative editing with `y-websocket`, `hocuspocus`, and `liveblocks` providers. Pass `collabUrl` for the websocket shorthand or a `collaboration` object for explicit provider config. See the [full collaboration docs](https://docs.superdoc.dev/document-engine/sdks#collaboration-sessions) for examples and all options.
|
|
87
|
+
|
|
84
88
|
### Operations
|
|
85
89
|
|
|
86
90
|
| Category | Operations |
|
|
@@ -9129,7 +9129,30 @@ export interface DocDiffApplyParams {
|
|
|
9129
9129
|
export interface DocOpenParams {
|
|
9130
9130
|
doc?: string;
|
|
9131
9131
|
sessionId?: string;
|
|
9132
|
-
collaboration?:
|
|
9132
|
+
collaboration?: ({
|
|
9133
|
+
providerType: "y-websocket" | "hocuspocus";
|
|
9134
|
+
url: string;
|
|
9135
|
+
documentId?: string;
|
|
9136
|
+
tokenEnv?: string;
|
|
9137
|
+
syncTimeoutMs?: number;
|
|
9138
|
+
onMissing?: "seedFromDoc" | "blank" | "error";
|
|
9139
|
+
bootstrapSettlingMs?: number;
|
|
9140
|
+
}) | ({
|
|
9141
|
+
providerType: "liveblocks";
|
|
9142
|
+
roomId: string;
|
|
9143
|
+
publicApiKey: string;
|
|
9144
|
+
syncTimeoutMs?: number;
|
|
9145
|
+
onMissing?: "seedFromDoc" | "blank" | "error";
|
|
9146
|
+
bootstrapSettlingMs?: number;
|
|
9147
|
+
}) | ({
|
|
9148
|
+
providerType: "liveblocks";
|
|
9149
|
+
roomId: string;
|
|
9150
|
+
authEndpoint: string;
|
|
9151
|
+
authHeadersEnv?: string;
|
|
9152
|
+
syncTimeoutMs?: number;
|
|
9153
|
+
onMissing?: "seedFromDoc" | "blank" | "error";
|
|
9154
|
+
bootstrapSettlingMs?: number;
|
|
9155
|
+
});
|
|
9133
9156
|
collabDocumentId?: string;
|
|
9134
9157
|
collabUrl?: string;
|
|
9135
9158
|
contentOverride?: string;
|
|
@@ -14421,7 +14444,8 @@ export type DocOpenResult = {
|
|
|
14421
14444
|
};
|
|
14422
14445
|
dirty?: boolean;
|
|
14423
14446
|
collaboration?: {
|
|
14424
|
-
|
|
14447
|
+
providerType: "y-websocket" | "hocuspocus" | "liveblocks";
|
|
14448
|
+
documentId: string;
|
|
14425
14449
|
url?: string;
|
|
14426
14450
|
};
|
|
14427
14451
|
bootstrap?: {
|
|
@@ -14480,7 +14504,8 @@ export type DocStatusResult = {
|
|
|
14480
14504
|
revision?: number;
|
|
14481
14505
|
};
|
|
14482
14506
|
collaboration?: {
|
|
14483
|
-
|
|
14507
|
+
providerType: "y-websocket" | "hocuspocus" | "liveblocks";
|
|
14508
|
+
documentId: string;
|
|
14484
14509
|
url?: string;
|
|
14485
14510
|
};
|
|
14486
14511
|
openedAt?: string;
|
|
@@ -14513,6 +14538,11 @@ export type DocSessionListResult = {
|
|
|
14513
14538
|
sessionType?: string;
|
|
14514
14539
|
dirty?: boolean;
|
|
14515
14540
|
revision?: number;
|
|
14541
|
+
collaboration?: {
|
|
14542
|
+
providerType: "y-websocket" | "hocuspocus" | "liveblocks";
|
|
14543
|
+
documentId: string;
|
|
14544
|
+
url?: string;
|
|
14545
|
+
};
|
|
14516
14546
|
}>;
|
|
14517
14547
|
total?: number;
|
|
14518
14548
|
};
|