UNPKG

wowok_agent

Version:

Making It Easy for AI Agents to Communicate, Collaborate, Trade, and Trust.

785 lines (784 loc) 24.6 kB
import { z } from "zod"; export declare const WipConstraints: { readonly maxImageSize: number; readonly maxTotalSize: number; readonly maxImageCount: 10; readonly maxTextLength: 10000; readonly schemaUrl: "https://schema.wip.wowok.net/v1"; readonly version: "1.0.0"; }; export declare const TextFormatSchema: z.ZodUnion<[z.ZodLiteral<"plain">, z.ZodLiteral<"markdown">, z.ZodLiteral<"html">]>; export declare const ImageMimeTypeSchema: z.ZodUnion<[z.ZodLiteral<"image/png">, z.ZodLiteral<"image/jpeg">, z.ZodLiteral<"image/gif">, z.ZodLiteral<"image/webp">]>; export declare const HashAlgorithmSchema: z.ZodLiteral<"sha256">; export declare const SignatureAlgorithmSchema: z.ZodLiteral<"Ed25519">; export declare const WipContentSchema: z.ZodObject<{ text: z.ZodString; format: z.ZodUnion<[z.ZodLiteral<"plain">, z.ZodLiteral<"markdown">, z.ZodLiteral<"html">]>; }, "strip", z.ZodTypeAny, { text: string; format: "plain" | "markdown" | "html"; }, { text: string; format: "plain" | "markdown" | "html"; }>; export declare const WipMediaSchema: z.ZodObject<{ id: z.ZodString; type: z.ZodUnion<[z.ZodLiteral<"image/png">, z.ZodLiteral<"image/jpeg">, z.ZodLiteral<"image/gif">, z.ZodLiteral<"image/webp">]>; data: z.ZodString; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }, { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }>; export declare const WipPayloadSchema: z.ZodObject<{ content: z.ZodObject<{ text: z.ZodString; format: z.ZodUnion<[z.ZodLiteral<"plain">, z.ZodLiteral<"markdown">, z.ZodLiteral<"html">]>; }, "strip", z.ZodTypeAny, { text: string; format: "plain" | "markdown" | "html"; }, { text: string; format: "plain" | "markdown" | "html"; }>; media: z.ZodArray<z.ZodObject<{ id: z.ZodString; type: z.ZodUnion<[z.ZodLiteral<"image/png">, z.ZodLiteral<"image/jpeg">, z.ZodLiteral<"image/gif">, z.ZodLiteral<"image/webp">]>; data: z.ZodString; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }, { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }>, "many">; }, "strip", z.ZodTypeAny, { content: { text: string; format: "plain" | "markdown" | "html"; }; media: { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }[]; }, { content: { text: string; format: "plain" | "markdown" | "html"; }; media: { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }[]; }>; export declare const WipSignatureSchema: z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>; export declare const WipSignatureArraySchema: z.ZodUnion<[z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>, z.ZodArray<z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>, "many">]>; export declare const WipMetaSchema: z.ZodObject<{ type: z.ZodLiteral<"wip">; version: z.ZodString; created: z.ZodString; hash: z.ZodString; algorithm: z.ZodLiteral<"sha256">; signature: z.ZodOptional<z.ZodUnion<[z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>, z.ZodArray<z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>, "many">]>>; }, "strip", z.ZodTypeAny, { type: "wip"; version: string; algorithm: "sha256"; created: string; hash: string; signature?: { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; } | { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }[] | undefined; }, { type: "wip"; version: string; algorithm: "sha256"; created: string; hash: string; signature?: { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; } | { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }[] | undefined; }>; export declare const WipFileSchema: z.ZodObject<{ wip: z.ZodString; payload: z.ZodObject<{ content: z.ZodObject<{ text: z.ZodString; format: z.ZodUnion<[z.ZodLiteral<"plain">, z.ZodLiteral<"markdown">, z.ZodLiteral<"html">]>; }, "strip", z.ZodTypeAny, { text: string; format: "plain" | "markdown" | "html"; }, { text: string; format: "plain" | "markdown" | "html"; }>; media: z.ZodArray<z.ZodObject<{ id: z.ZodString; type: z.ZodUnion<[z.ZodLiteral<"image/png">, z.ZodLiteral<"image/jpeg">, z.ZodLiteral<"image/gif">, z.ZodLiteral<"image/webp">]>; data: z.ZodString; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }, { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }>, "many">; }, "strip", z.ZodTypeAny, { content: { text: string; format: "plain" | "markdown" | "html"; }; media: { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }[]; }, { content: { text: string; format: "plain" | "markdown" | "html"; }; media: { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }[]; }>; meta: z.ZodObject<{ type: z.ZodLiteral<"wip">; version: z.ZodString; created: z.ZodString; hash: z.ZodString; algorithm: z.ZodLiteral<"sha256">; signature: z.ZodOptional<z.ZodUnion<[z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>, z.ZodArray<z.ZodObject<{ value: z.ZodString; publicKey: z.ZodString; algorithm: z.ZodLiteral<"Ed25519">; address: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }, { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }>, "many">]>>; }, "strip", z.ZodTypeAny, { type: "wip"; version: string; algorithm: "sha256"; created: string; hash: string; signature?: { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; } | { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }[] | undefined; }, { type: "wip"; version: string; algorithm: "sha256"; created: string; hash: string; signature?: { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; } | { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }[] | undefined; }>; }, "strip", z.ZodTypeAny, { wip: string; payload: { content: { text: string; format: "plain" | "markdown" | "html"; }; media: { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }[]; }; meta: { type: "wip"; version: string; algorithm: "sha256"; created: string; hash: string; signature?: { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; } | { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }[] | undefined; }; }, { wip: string; payload: { content: { text: string; format: "plain" | "markdown" | "html"; }; media: { type: "image/png" | "image/jpeg" | "image/gif" | "image/webp"; id: string; data: string; filename?: string | undefined; }[]; }; meta: { type: "wip"; version: string; algorithm: "sha256"; created: string; hash: string; signature?: { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; } | { value: string; publicKey: string; algorithm: "Ed25519"; address?: string | undefined; }[] | undefined; }; }>; export declare const ImageSourceSchema: z.ZodObject<{ source: z.ZodString; id: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { source: string; id?: string | undefined; filename?: string | undefined; }, { source: string; id?: string | undefined; filename?: string | undefined; }>; export declare const WipGenerationOptionsSchema: z.ZodObject<{ markdown_text: z.ZodString; images: z.ZodOptional<z.ZodArray<z.ZodObject<{ source: z.ZodString; id: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { source: string; id?: string | undefined; filename?: string | undefined; }, { source: string; id?: string | undefined; filename?: string | undefined; }>, "many">>; account: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { markdown_text: string; images?: { source: string; id?: string | undefined; filename?: string | undefined; }[] | undefined; account?: string | undefined; }, { markdown_text: string; images?: { source: string; id?: string | undefined; filename?: string | undefined; }[] | undefined; account?: string | undefined; }>; export declare const WipSignatureVerificationSchema: z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>; export declare const WipVerificationResultSchema: z.ZodObject<{ valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>, "many">>; }, "strip", z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>, z.objectOutputType<{ valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>, "many">>; }, z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>, "strip">, z.objectInputType<{ valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>, "many">>; }, z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>, "strip">>; export declare const WipToHtmlOptionsSchema: z.ZodObject<{ title: z.ZodOptional<z.ZodString>; theme: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"light">, z.ZodLiteral<"dark">]>>; outputPath: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { title?: string | undefined; theme?: "light" | "dark" | undefined; outputPath?: string | undefined; }, { title?: string | undefined; theme?: "light" | "dark" | undefined; outputPath?: string | undefined; }>; export declare const GenerateWip_InputSchema: z.ZodObject<{ options: z.ZodObject<{ markdown_text: z.ZodString; images: z.ZodOptional<z.ZodArray<z.ZodObject<{ source: z.ZodString; id: z.ZodOptional<z.ZodString>; filename: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { source: string; id?: string | undefined; filename?: string | undefined; }, { source: string; id?: string | undefined; filename?: string | undefined; }>, "many">>; account: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { markdown_text: string; images?: { source: string; id?: string | undefined; filename?: string | undefined; }[] | undefined; account?: string | undefined; }, { markdown_text: string; images?: { source: string; id?: string | undefined; filename?: string | undefined; }[] | undefined; account?: string | undefined; }>; outputPath: z.ZodString; }, "strip", z.ZodTypeAny, { options: { markdown_text: string; images?: { source: string; id?: string | undefined; filename?: string | undefined; }[] | undefined; account?: string | undefined; }; outputPath: string; }, { options: { markdown_text: string; images?: { source: string; id?: string | undefined; filename?: string | undefined; }[] | undefined; account?: string | undefined; }; outputPath: string; }>; export declare const VerifyWip_InputSchema: z.ZodObject<{ wipFilePath: z.ZodString; hash_equal: z.ZodOptional<z.ZodString>; requireSignature: z.ZodOptional<z.ZodBoolean>; }, "strip", z.ZodTypeAny, { wipFilePath: string; hash_equal?: string | undefined; requireSignature?: boolean | undefined; }, { wipFilePath: string; hash_equal?: string | undefined; requireSignature?: boolean | undefined; }>; export declare const SignWip_InputSchema: z.ZodObject<{ wipFilePath: z.ZodString; account: z.ZodOptional<z.ZodString>; outputPath: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { wipFilePath: string; account?: string | undefined; outputPath?: string | undefined; }, { wipFilePath: string; account?: string | undefined; outputPath?: string | undefined; }>; export declare const Wip2Html_InputSchema: z.ZodObject<{ wipPath: z.ZodString; options: z.ZodOptional<z.ZodObject<{ title: z.ZodOptional<z.ZodString>; theme: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"light">, z.ZodLiteral<"dark">]>>; outputPath: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { title?: string | undefined; theme?: "light" | "dark" | undefined; outputPath?: string | undefined; }, { title?: string | undefined; theme?: "light" | "dark" | undefined; outputPath?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { wipPath: string; options?: { title?: string | undefined; theme?: "light" | "dark" | undefined; outputPath?: string | undefined; } | undefined; }, { wipPath: string; options?: { title?: string | undefined; theme?: "light" | "dark" | undefined; outputPath?: string | undefined; } | undefined; }>; export declare const GenerateWip_OutputSchema: z.ZodObject<{ filePath: z.ZodString; }, "strip", z.ZodTypeAny, { filePath: string; }, { filePath: string; }>; export declare const VerifyWip_OutputSchema: z.ZodObject<{ valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>, "many">>; }, "strip", z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>, z.objectOutputType<{ valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>, "many">>; }, z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>, "strip">, z.objectInputType<{ valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodObject<{ publicKey: z.ZodString; address: z.ZodOptional<z.ZodString>; valid: z.ZodBoolean; }, "strip", z.ZodTypeAny, { valid: boolean; publicKey: string; address?: string | undefined; }, { valid: boolean; publicKey: string; address?: string | undefined; }>, "many">>; }, z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean]>>, "strip">>; export declare const SignWip_OutputSchema: z.ZodObject<{ filePath: z.ZodString; }, "strip", z.ZodTypeAny, { filePath: string; }, { filePath: string; }>; export declare const Wip2Html_OutputSchema: z.ZodObject<{ html: z.ZodOptional<z.ZodString>; filePath: z.ZodOptional<z.ZodString>; files: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { html?: string | undefined; filePath?: string | undefined; files?: string[] | undefined; }, { html?: string | undefined; filePath?: string | undefined; files?: string[] | undefined; }>; export declare const WipOperationOutputSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{ type: z.ZodLiteral<"generate">; filePath: z.ZodString; }, "strip", z.ZodTypeAny, { type: "generate"; filePath: string; }, { type: "generate"; filePath: string; }>, z.ZodObject<{ type: z.ZodLiteral<"verify">; valid: z.ZodBoolean; error: z.ZodOptional<z.ZodString>; hashValid: z.ZodBoolean; signatureValid: z.ZodOptional<z.ZodBoolean>; hasSignature: z.ZodBoolean; signatures: z.ZodOptional<z.ZodArray<z.ZodAny, "many">>; }, "strip", z.ZodTypeAny, { valid: boolean; type: "verify"; hashValid: boolean; hasSignature: boolean; error?: string | undefined; signatureValid?: boolean | undefined; signatures?: any[] | undefined; }, { valid: boolean; type: "verify"; hashValid: boolean; hasSignature: boolean; error?: string | undefined; signatureValid?: boolean | undefined; signatures?: any[] | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"sign">; filePath: z.ZodString; }, "strip", z.ZodTypeAny, { type: "sign"; filePath: string; }, { type: "sign"; filePath: string; }>, z.ZodObject<{ type: z.ZodLiteral<"wip2html">; html: z.ZodOptional<z.ZodString>; filePath: z.ZodOptional<z.ZodString>; files: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { type: "wip2html"; html?: string | undefined; filePath?: string | undefined; files?: string[] | undefined; }, { type: "wip2html"; html?: string | undefined; filePath?: string | undefined; files?: string[] | undefined; }>]>;