Skip to content

Commit

Permalink
feat: add optional tags definition for scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
DASPRiD committed Apr 26, 2024
1 parent b683662 commit 6426d08
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/script.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { z } from "zod";
export type ScriptHandler<T> = (parameter: T) => Promise<ScriptHandlerResult>;

export type ScriptDefinition = {
tags?: string[];
description: string;
requestSchema: SchemaObject;
responseSchema: SchemaObject;
Expand Down Expand Up @@ -67,6 +68,7 @@ export const scriptHandlerProxy =
export const buildScriptPathItemObject = (definition: ScriptDefinition): PathItemObject => {
return {
post: {
tags: definition.tags,
description: definition.description,
requestBody: {
required: true,
Expand Down

0 comments on commit 6426d08

Please sign in to comment.