From 4494354edffb03dfb0a72b308d87afb024e30582 Mon Sep 17 00:00:00 2001 From: Tomek Marciniak Date: Sun, 27 Oct 2024 10:54:19 +0100 Subject: [PATCH] fix(providers): fix exports --- packages/providers/src/validation.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/packages/providers/src/validation.ts b/packages/providers/src/validation.ts index a76432c..c7bca01 100644 --- a/packages/providers/src/validation.ts +++ b/packages/providers/src/validation.ts @@ -32,7 +32,7 @@ export const AccountsRequestParamsSchema = z method: z.literal("mina_accounts"), }) .strict(); -export const ReqquestAccountsRequestParamsSchema = z +export const RequestAccountsRequestParamsSchema = z .object({ method: z.literal("mina_requestAccounts"), }) @@ -108,6 +108,12 @@ export const AccountsRequestReturnSchema = z result: z.array(PublicKeySchema), }) .strict(); +export const RequestAccountsRequestReturnSchema = z + .object({ + method: z.literal("mina_requestAccounts"), + result: z.array(PublicKeySchema), + }) + .strict(); export const ChainIdRequestReturnSchema = z .object({ method: z.literal("mina_chainId"), @@ -183,6 +189,7 @@ export const GetStateRequestReturnSchema = z export const RpcReturnTypesUnion = z.discriminatedUnion("method", [ AccountsRequestReturnSchema, + RequestAccountsRequestReturnSchema, ChainIdRequestReturnSchema, ChainInformationRequestReturnSchema, GetBalanceRequestReturnSchema, @@ -199,6 +206,7 @@ export const RpcReturnTypesUnion = z.discriminatedUnion("method", [ export const ProviderRequestParamsUnion = z.discriminatedUnion("method", [ AccountsRequestParamsSchema, + RequestAccountsRequestParamsSchema, ChainIdRequestParamsSchema, ChainInformationRequestParamsSchema, GetBalanceRequestParamsSchema,