From b99a97acf8f73947c47a8d581416023294ebe750 Mon Sep 17 00:00:00 2001 From: Mahmoud Aboelenein Date: Tue, 12 Mar 2024 12:48:47 +0200 Subject: [PATCH 1/2] added getAccounts rpc method --- src/request/types/btcMethods.ts | 4 ++++ src/request/types/index.ts | 11 +++++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/src/request/types/btcMethods.ts b/src/request/types/btcMethods.ts index 092cdf0..f307d49 100644 --- a/src/request/types/btcMethods.ts +++ b/src/request/types/btcMethods.ts @@ -123,3 +123,7 @@ export type SignPsbtResult = { }; export type SignPsbt = MethodParamsAndResult; + +export type GetAccountResult = Address[] | Record | string[]; + +export type GetAccounts = MethodParamsAndResult; diff --git a/src/request/types/index.ts b/src/request/types/index.ts index 0610fd2..230ad46 100644 --- a/src/request/types/index.ts +++ b/src/request/types/index.ts @@ -1,5 +1,11 @@ -import { RpcSuccessResponse } from 'src/types'; -import { GetAddresses, GetInfo, SendTransfer, SignMessage, SignPsbt } from './btcMethods'; +import { + GetAccounts, + GetAddresses, + GetInfo, + SendTransfer, + SignMessage, + SignPsbt, +} from './btcMethods'; import { StxCallContract, StxDeployContract, @@ -27,6 +33,7 @@ export type StxRequestMethod = keyof StxRequests; export interface BtcRequests { getInfo: GetInfo; getAddresses: GetAddresses; + getAccounts: GetAccounts; signMessage: SignMessage; sendTransfer: SendTransfer; signPsbt: SignPsbt; From de95c7b54b5d7d07328b5f9b758400621e0626a5 Mon Sep 17 00:00:00 2001 From: Mahmoud Aboelenein Date: Tue, 12 Mar 2024 13:23:59 +0200 Subject: [PATCH 2/2] updated GetAccountResult --- src/request/types/btcMethods.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/request/types/btcMethods.ts b/src/request/types/btcMethods.ts index f307d49..3aa7412 100644 --- a/src/request/types/btcMethods.ts +++ b/src/request/types/btcMethods.ts @@ -124,6 +124,6 @@ export type SignPsbtResult = { export type SignPsbt = MethodParamsAndResult; -export type GetAccountResult = Address[] | Record | string[]; +export type GetAccountResult = Address[]; export type GetAccounts = MethodParamsAndResult;