librechat-data-provider 0.8.406 → 0.8.407
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/dist/index.es.js +1 -1
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/react-query/index.es.js +1 -1
- package/dist/react-query/index.es.js.map +1 -1
- package/dist/types/api-endpoints.d.ts +1 -0
- package/dist/types/config.d.ts +110 -129
- package/dist/types/data-service.d.ts +1 -0
- package/dist/types/keys.d.ts +1 -0
- package/dist/types/roles.d.ts +2 -0
- package/dist/types/types/assistants.d.ts +18 -0
- package/dist/types/types/queries.d.ts +10 -0
- package/package.json +4 -4
|
@@ -230,6 +230,7 @@ export declare function updatePromptLabels(variables: t.TUpdatePromptLabelsReque
|
|
|
230
230
|
export declare function deletePromptGroup(id: string): Promise<t.TDeletePromptGroupResponse>;
|
|
231
231
|
export declare function getCategories(): Promise<t.TGetCategoriesResponse>;
|
|
232
232
|
export declare function getRandomPrompts(variables: t.TGetRandomPromptsRequest): Promise<t.TGetRandomPromptsResponse>;
|
|
233
|
+
export declare function listRoles(): Promise<q.ListRolesResponse>;
|
|
233
234
|
export declare function getRole(roleName: string): Promise<r.TRole>;
|
|
234
235
|
export declare function updatePromptPermissions(variables: m.UpdatePromptPermVars): Promise<m.UpdatePermResponse>;
|
|
235
236
|
export declare function updateAgentPermissions(variables: m.UpdateAgentPermVars): Promise<m.UpdatePermResponse>;
|
package/dist/types/keys.d.ts
CHANGED
package/dist/types/roles.d.ts
CHANGED
|
@@ -420,6 +420,8 @@ export declare const roleSchema: z.ZodObject<{
|
|
|
420
420
|
};
|
|
421
421
|
}>;
|
|
422
422
|
export type TRole = z.infer<typeof roleSchema>;
|
|
423
|
+
/** Case-insensitive check for reserved system role names. */
|
|
424
|
+
export declare function isSystemRoleName(name: string | undefined | null): boolean;
|
|
423
425
|
export declare const roleDefaults: {
|
|
424
426
|
ADMIN: {
|
|
425
427
|
name: SystemRoles.ADMIN;
|
|
@@ -487,6 +487,24 @@ export type TContentData = StreamContentData & {
|
|
|
487
487
|
};
|
|
488
488
|
export declare const actionDelimiter = "_action_";
|
|
489
489
|
export declare const actionDomainSeparator = "---";
|
|
490
|
+
/**
|
|
491
|
+
* Checks whether a tool name is an OpenAPI action tool.
|
|
492
|
+
*
|
|
493
|
+
* Action format: `operationId_action_normalizedDomain`
|
|
494
|
+
* MCP format: `toolName_mcp_serverName`
|
|
495
|
+
*
|
|
496
|
+
* Cross-delimiter collision: an MCP tool like `get_action_mcp_srv` contains
|
|
497
|
+
* `_action_` as a false positive. Guarded by checking whether `_mcp_` appears
|
|
498
|
+
* after `_action_`. In the collision case the `_mcp_` suffix always follows
|
|
499
|
+
* `_action_`; in a valid action tool whose operationId contains `_mcp_`, the
|
|
500
|
+
* `_mcp_` precedes `_action_`.
|
|
501
|
+
*
|
|
502
|
+
* Theoretical limitation: a non-RFC-compliant domain containing literal
|
|
503
|
+
* underscores that form `_mcp_` (e.g. `api_mcp_internal.com`) would produce
|
|
504
|
+
* a false negative. RFC 952/1123 prohibit underscores in hostnames, so this
|
|
505
|
+
* is not expected in practice.
|
|
506
|
+
*/
|
|
507
|
+
export declare function isActionTool(toolName: string): boolean;
|
|
490
508
|
export declare const hostImageIdSuffix = "_host_copy";
|
|
491
509
|
export declare const hostImageNamePrefix = "host_copy_";
|
|
492
510
|
export type AssistantAvatar = {
|
|
@@ -139,6 +139,16 @@ export type AccessRole = {
|
|
|
139
139
|
permBits: number;
|
|
140
140
|
};
|
|
141
141
|
export type AccessRolesResponse = AccessRole[];
|
|
142
|
+
export type ListRolesResponse = {
|
|
143
|
+
roles: Array<{
|
|
144
|
+
_id?: string;
|
|
145
|
+
name: string;
|
|
146
|
+
description?: string;
|
|
147
|
+
}>;
|
|
148
|
+
total: number;
|
|
149
|
+
limit: number;
|
|
150
|
+
offset?: number;
|
|
151
|
+
};
|
|
142
152
|
export interface MCPServerStatus {
|
|
143
153
|
requiresOAuth: boolean;
|
|
144
154
|
connectionState: 'disconnected' | 'connecting' | 'connected' | 'error';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "librechat-data-provider",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.407",
|
|
4
4
|
"description": "data services for librechat apps",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.es.js",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
},
|
|
44
44
|
"homepage": "https://librechat.ai",
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"axios": "
|
|
46
|
+
"axios": "1.13.6",
|
|
47
47
|
"dayjs": "^1.11.13",
|
|
48
48
|
"js-yaml": "^4.1.1",
|
|
49
49
|
"zod": "^3.22.4"
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
"@rollup/plugin-json": "^6.1.0",
|
|
58
58
|
"@rollup/plugin-node-resolve": "^15.1.0",
|
|
59
59
|
"@rollup/plugin-replace": "^5.0.5",
|
|
60
|
-
"@rollup/plugin-terser": "^0.
|
|
60
|
+
"@rollup/plugin-terser": "^1.0.0",
|
|
61
61
|
"@types/jest": "^29.5.2",
|
|
62
62
|
"@types/js-yaml": "^4.0.9",
|
|
63
63
|
"@types/node": "^20.3.0",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"rimraf": "^6.1.3",
|
|
70
70
|
"rollup": "^4.34.9",
|
|
71
71
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
72
|
-
"rollup-plugin-typescript2": "^0.
|
|
72
|
+
"rollup-plugin-typescript2": "^0.37.0",
|
|
73
73
|
"typescript": "^5.0.4"
|
|
74
74
|
},
|
|
75
75
|
"peerDependencies": {
|