Skip to content

Commit

Permalink
✨ feat: add setting config
Browse files Browse the repository at this point in the history
  • Loading branch information
arvinxx committed Aug 24, 2023
1 parent ec7ffe5 commit 180e713
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/manifest.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { z } from 'zod';

const JSONSchema = z.object({
properties: z.object({}),
type: z.enum(['object']),
});
export const pluginApiSchema = z.object({
description: z.string(),
name: z.string(),
parameters: z.object({
properties: z.object({}),
type: z.enum(['object']),
}),
parameters: JSONSchema,
url: z.string().url(),
});

Expand All @@ -15,6 +16,7 @@ export const pluginManifestSchema = z.object({
identifier: z.string(),
openapi: z.string().optional(),

settings: JSONSchema.optional(),
ui: z
.object({
url: z.string().optional(),
Expand Down
1 change: 1 addition & 0 deletions src/types/manifest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ export interface LobeChatPluginManifest {
*/
identifier: string;
openapi?: string;
settings?: PluginSchema;
/**
* plugin ui on user side
* @desc The type of rendering for the plugin
Expand Down

0 comments on commit 180e713

Please sign in to comment.