minauth
Version:
A TypeScript library for building authentication systems on top of the Mina blockchain and other zero-knowledge proofs solutions.
38 lines (37 loc) • 1.08 kB
TypeScript
import { z } from 'zod';
/**
* A zod schema against which o1js JsonProof objects can be validated.
*/
export declare const JsonProofSchema: z.ZodObject<{
publicInput: z.ZodArray<z.ZodString, "many">;
publicOutput: z.ZodArray<z.ZodString, "many">;
maxProofsVerified: z.ZodUnion<[z.ZodLiteral<0>, z.ZodLiteral<1>, z.ZodLiteral<2>]>;
proof: z.ZodString;
}, "strip", z.ZodTypeAny, {
publicInput: string[];
publicOutput: string[];
maxProofsVerified: 0 | 2 | 1;
proof: string;
}, {
publicInput: string[];
publicOutput: string[];
maxProofsVerified: 0 | 2 | 1;
proof: string;
}>;
/**
* A zod schema for proof objects that can be verified by the plugin server.
*/
export declare const MinAuthPluginInputSchema: z.ZodObject<{
plugin: z.ZodString;
input: z.ZodUnknown;
}, "strip", z.ZodTypeAny, {
plugin: string;
input?: unknown;
}, {
plugin: string;
input?: unknown;
}>;
/**
* A type for proof objects that can be verified by the plugin server.
*/
export type MinAuthProof = z.infer<typeof MinAuthPluginInputSchema>;