mirror of
https://github.com/labring/FastGPT.git
synced 2025-12-25 20:02:47 +00:00
* feat: add chat visibility controls and improve quote reader permissions (#6102) * feat: add chat visibility controls and improve quote reader permissions * fix test * zod * fix * test & openapi * frontend filter * update name * fix * fix * rename variables * fix * test * fix build * fix * fix --------- Co-authored-by: archer <545436317@qq.com> * app update time * recent app * fix * type * fix * context * perf: update app usingtime code * fix: ts * update parent * doc * perf: code per * unauth refresh --------- Co-authored-by: archer <545436317@qq.com>
32 lines
1.2 KiB
TypeScript
32 lines
1.2 KiB
TypeScript
import { z } from 'zod';
|
|
import type { HistoryItemType } from '../../core/chat/type.d';
|
|
import type { OutLinkSchema, PlaygroundVisibilityConfigType } from './type.d';
|
|
import { PlaygroundVisibilityConfigSchema } from './type.d';
|
|
|
|
export type AuthOutLinkInitProps = {
|
|
outLinkUid: string;
|
|
tokenUrl?: string;
|
|
};
|
|
export type AuthOutLinkChatProps = { ip?: string | null; outLinkUid: string; question: string };
|
|
export type AuthOutLinkLimitProps = AuthOutLinkChatProps & { outLink: OutLinkSchema };
|
|
export type AuthOutLinkResponse = {
|
|
uid: string;
|
|
};
|
|
|
|
export const UpdatePlaygroundVisibilityConfigBodySchema = PlaygroundVisibilityConfigSchema.extend({
|
|
appId: z.string().min(1, 'App ID is required')
|
|
});
|
|
export type UpdatePlaygroundVisibilityConfigBody = z.infer<
|
|
typeof UpdatePlaygroundVisibilityConfigBodySchema
|
|
>;
|
|
|
|
export const PlaygroundVisibilityConfigQuerySchema = z.object({
|
|
appId: z.string().min(1, 'App ID is required')
|
|
});
|
|
export type PlaygroundVisibilityConfigQuery = z.infer<typeof PlaygroundVisibilityConfigQuerySchema>;
|
|
|
|
export const PlaygroundVisibilityConfigResponseSchema = PlaygroundVisibilityConfigSchema;
|
|
export type PlaygroundVisibilityConfigResponse = z.infer<
|
|
typeof PlaygroundVisibilityConfigResponseSchema
|
|
>;
|