-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: fetching account balance for initial accounts
- Loading branch information
1 parent
75f3708
commit 6d11f3a
Showing
9 changed files
with
169 additions
and
227 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
export type Balance = { | ||
denom: string; | ||
amount: string; | ||
}; | ||
|
||
interface PubKey { | ||
'@type': string; | ||
key: string; | ||
} | ||
|
||
export type BaseAccount = { | ||
'@type': string; | ||
address: string; | ||
pub_key: PubKey | null; | ||
account_number: string; | ||
sequence: string; | ||
}; | ||
|
||
export type ModuleAccount = { | ||
'@type': string; | ||
base_account: { | ||
address: string; | ||
pub_key: PubKey | null; | ||
account_number: string; | ||
sequence: string; | ||
}; | ||
name: string; | ||
permissions: string[]; | ||
}; | ||
|
||
type Pagination = { | ||
next_key: string | null; | ||
total: string; | ||
}; | ||
|
||
export type BalancesResponse = { | ||
balances: Balance[]; | ||
pagination: Pagination; | ||
}; | ||
|
||
export type AccountsResponse = { | ||
accounts: (BaseAccount | ModuleAccount)[]; | ||
pagination: Pagination; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.