mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
This commit is contained in:
parent
5ff8bf4479
commit
46ab6005d1
1 changed files with 8 additions and 2 deletions
|
|
@ -13,7 +13,8 @@ export const proofSchema: z.ZodType<{
|
||||||
amount: z.number(),
|
amount: z.number(),
|
||||||
secret: z.string(),
|
secret: z.string(),
|
||||||
C: z.string(),
|
C: z.string(),
|
||||||
dleq: z.object({ s: z.string(), e: z.string(), r: z.string().optional() }).optional(),
|
dleq: z.object({ s: z.string(), e: z.string(), r: z.string().optional() })
|
||||||
|
.optional(),
|
||||||
dleqValid: z.boolean().optional(),
|
dleqValid: z.boolean().optional(),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -29,7 +30,12 @@ export const tokenEventSchema: z.ZodType<{
|
||||||
});
|
});
|
||||||
|
|
||||||
/** Ditto Cashu wallet */
|
/** Ditto Cashu wallet */
|
||||||
export const walletSchema = z.object({
|
export const walletSchema: z.ZodType<{
|
||||||
|
pubkey_p2pk: string;
|
||||||
|
mints: string[];
|
||||||
|
relays: string[];
|
||||||
|
balance: number;
|
||||||
|
}> = z.object({
|
||||||
pubkey_p2pk: n.id(),
|
pubkey_p2pk: n.id(),
|
||||||
mints: z.array(z.string().url()).nonempty().transform((val) => {
|
mints: z.array(z.string().url()).nonempty().transform((val) => {
|
||||||
return [...new Set(val)];
|
return [...new Set(val)];
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue