@sparkelf/dsh-dataops-managed 0.3.13 → 0.3.15
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/lib/client.js +367 -161
- package/lib/client.js.map +1 -1
- package/lib/index.js +270 -33
- package/lib/types/client/ManagedDataOpsSection.d.ts +2 -4
- package/lib/types/client/locales.d.ts +15 -19
- package/lib/types/client/workspace-limits-client.d.ts +36 -0
- package/lib/types/index.d.ts +37 -4
- package/lib/types/workspace-limits.d.ts +71 -0
- package/package.json +3 -3
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/** Read and write the DataOps workspace limits this deployment enforces. */
|
|
2
|
+
import type { Context } from '@deepseek-ai/cordis';
|
|
3
|
+
/** The two byte ceilings one workspace size setting carries. */
|
|
4
|
+
export interface WorkspaceSizeLimits {
|
|
5
|
+
/** Largest file a sidebar download or agent read may carry. */
|
|
6
|
+
fileReadMaxBytes: number;
|
|
7
|
+
/** Largest file an upload may carry. */
|
|
8
|
+
uploadMaxBytes: number;
|
|
9
|
+
}
|
|
10
|
+
/** What the Settings panel reads. */
|
|
11
|
+
export interface WorkspaceLimitsStatus {
|
|
12
|
+
/** Current ceilings. */
|
|
13
|
+
limits: WorkspaceSizeLimits;
|
|
14
|
+
/** Whether the signed-in user may change them. */
|
|
15
|
+
canWrite: boolean;
|
|
16
|
+
/** Why the limits are read-only, when they are. */
|
|
17
|
+
readOnlyReason: string | null;
|
|
18
|
+
}
|
|
19
|
+
/** Configuration the host half receives from the profile. */
|
|
20
|
+
export interface WorkspaceLimitsConfig {
|
|
21
|
+
/** DataOps browser/API origin reachable from the DSH Host. */
|
|
22
|
+
baseUrl: string;
|
|
23
|
+
/** DSH credential reference holding the current DataOps access JWT. */
|
|
24
|
+
credentialRef: string;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* A rejection DataOps answered with, carrying its status and message.
|
|
28
|
+
*
|
|
29
|
+
* Without this the caller can only tell that something failed, and a value DataOps refused —
|
|
30
|
+
* which the user can correct — is indistinguishable from a fault in the request path.
|
|
31
|
+
*/
|
|
32
|
+
export declare class WorkspaceLimitsRejection extends Error {
|
|
33
|
+
/** HTTP status DataOps answered with. */
|
|
34
|
+
readonly status: number;
|
|
35
|
+
constructor(
|
|
36
|
+
/** HTTP status DataOps answered with. */
|
|
37
|
+
status: number, message: string);
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* The workspace limits an administrator sets in DataOps.
|
|
41
|
+
*
|
|
42
|
+
* The plugin holds the DataOps JWT, so the browser cannot read these itself; this class is the
|
|
43
|
+
* only path from the Settings panel to that document.
|
|
44
|
+
*/
|
|
45
|
+
export declare class WorkspaceLimits {
|
|
46
|
+
private readonly ctx;
|
|
47
|
+
private readonly config;
|
|
48
|
+
constructor(ctx: Context, config: WorkspaceLimitsConfig);
|
|
49
|
+
/**
|
|
50
|
+
* Read the DataOps JWT this workspace is currently authorized with.
|
|
51
|
+
* @returns The token, or undefined when the workspace has no session yet.
|
|
52
|
+
*/
|
|
53
|
+
private token;
|
|
54
|
+
/** The DataOps API origin this workspace reports to. */
|
|
55
|
+
private apiBase;
|
|
56
|
+
/**
|
|
57
|
+
* Read the current ceilings.
|
|
58
|
+
* @returns The status, or undefined when the workspace is not authorized.
|
|
59
|
+
*/
|
|
60
|
+
status(): Promise<WorkspaceLimitsStatus | undefined>;
|
|
61
|
+
/**
|
|
62
|
+
* Write new ceilings.
|
|
63
|
+
* @param limits - The ceilings to store.
|
|
64
|
+
* @returns The stored status.
|
|
65
|
+
*/
|
|
66
|
+
save(limits: WorkspaceSizeLimits): Promise<WorkspaceLimitsStatus | undefined>;
|
|
67
|
+
}
|
|
68
|
+
/** @param next - Instance to publish, or undefined to clear. */
|
|
69
|
+
export declare function setWorkspaceLimits(next: WorkspaceLimits | undefined): void;
|
|
70
|
+
/** @returns The live workspace-limits instance, when the plugin activated. */
|
|
71
|
+
export declare function currentWorkspaceLimits(): WorkspaceLimits | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sparkelf/dsh-dataops-managed",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.15",
|
|
4
4
|
"description": "DataOps JWT intake and credential-backed MCP tools for managed DeepSeek Harness workspaces.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./lib/index.js",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"@deepseek-ai/dsh-settings": ">=0.1.7-rc.2",
|
|
74
74
|
"@deepseek-ai/dsh-skill": ">=0.2.0-rc.2",
|
|
75
75
|
"@deepseek-ai/dsh-tools": ">=0.1.7-rc.2",
|
|
76
|
-
"@deepseek-ai/schemastery": ">=3.18.
|
|
76
|
+
"@deepseek-ai/schemastery": ">=3.18.4",
|
|
77
77
|
"@sparkelf/dsh-plugin-mcp-credentials": ">=0.1.0-rc.14",
|
|
78
78
|
"react": ">=18.2.0 <20"
|
|
79
79
|
},
|
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
"@deepseek-ai/dsh-settings": "0.1.7-rc.2",
|
|
92
92
|
"@deepseek-ai/dsh-skill": "0.2.0-rc.2",
|
|
93
93
|
"@deepseek-ai/dsh-tools": "0.1.7-rc.2",
|
|
94
|
-
"@deepseek-ai/schemastery": "3.18.
|
|
94
|
+
"@deepseek-ai/schemastery": "3.18.4",
|
|
95
95
|
"@sparkelf/dsh-client-ui-skill-center": "0.2.0-rc.46",
|
|
96
96
|
"@sparkelf/dsh-plugin-mcp-credentials": "0.1.0-rc.14",
|
|
97
97
|
"@types/react": "~18.3.1",
|