Reference / Modules / node-api / Queries
Class: Queries
node-api.Queries
Table of contents
Constructors
Properties
Accessors
Methods
- computeAvailableRegions
- getAccountData
- getActiveRecovery
- getAvailableRegions
- getCoinBalances
- getCollectionItem
- getCollectionItems
- getCollectionSize
- getDefaultRegion
- getGuestsOf
- getLegalOfficerCase
- getLegalOfficerData
- getLegalOfficerVerifiedIssuers
- getProxy
- getRecoveryConfig
- getSponsorship
- getValidAccountId
- isInvitedContributorOf
- isValidAccountId
- buildCoinBalance
- getCoin
- of
Constructors
constructor
• new Queries(api
, adapters
): Queries
Parameters
Name | Type |
---|---|
api | ApiPromise |
adapters | Adapters |
Returns
Defined in
Properties
adapters
• Private
adapters: Adapters
Defined in
api
• Private
api: ApiPromise
Defined in
availableRegions
• Private
Optional
availableRegions: "Europe"
[]
Defined in
DOT_BALANCE
▪ Static
Readonly
DOT_BALANCE: CoinBalance
Defined in
Accessors
ss58Prefix
• get
ss58Prefix(): number
Returns
number
Defined in
Methods
computeAvailableRegions
▸ computeAvailableRegions(): "Europe"
[]
Returns
"Europe"
[]
Defined in
getAccountData
▸ getAccountData(accountId
): Promise
<TypesAccountData
>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<TypesAccountData
>
Defined in
getActiveRecovery
▸ getActiveRecovery(sourceAccountId
, destinationAccountId
): Promise
<undefined
| TypesRecoveryConfig
>
Parameters
Name | Type |
---|---|
sourceAccountId | ValidAccountId |
destinationAccountId | ValidAccountId |
Returns
Promise
<undefined
| TypesRecoveryConfig
>
Defined in
getAvailableRegions
▸ getAvailableRegions(): "Europe"
[]
Returns
"Europe"
[]
Defined in
getCoinBalances
▸ getCoinBalances(accountId
): Promise
<CoinBalance
[]>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<CoinBalance
[]>
Defined in
getCollectionItem
▸ getCollectionItem(locId
, itemId
): Promise
<undefined
| CollectionItem
>
Parameters
Name | Type |
---|---|
locId | UUID |
itemId | Hash |
Returns
Promise
<undefined
| CollectionItem
>
Defined in
getCollectionItems
▸ getCollectionItems(locId
): Promise
<CollectionItem
[]>
Parameters
Name | Type |
---|---|
locId | UUID |
Returns
Promise
<CollectionItem
[]>
Defined in
getCollectionSize
▸ getCollectionSize(locId
): Promise
<undefined
| number
>
Parameters
Name | Type |
---|---|
locId | UUID |
Returns
Promise
<undefined
| number
>
Defined in
getDefaultRegion
▸ getDefaultRegion(): "Europe"
Returns
"Europe"
Defined in
getGuestsOf
▸ getGuestsOf(accountId
): Promise
<string
[]>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<string
[]>
Defined in
getLegalOfficerCase
▸ getLegalOfficerCase(locId
): Promise
<undefined
| LegalOfficerCase
>
Parameters
Name | Type |
---|---|
locId | UUID |
Returns
Promise
<undefined
| LegalOfficerCase
>
Defined in
getLegalOfficerData
▸ getLegalOfficerData(accountId
): Promise
<LegalOfficerData
>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<LegalOfficerData
>
Defined in
getLegalOfficerVerifiedIssuers
▸ getLegalOfficerVerifiedIssuers(accountId
): Promise
<VerifiedIssuerType
[]>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<VerifiedIssuerType
[]>
Defined in
getProxy
▸ getProxy(accountId
): Promise
<undefined
| ValidAccountId
>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<undefined
| ValidAccountId
>
Defined in
getRecoveryConfig
▸ getRecoveryConfig(accountId
): Promise
<undefined
| TypesRecoveryConfig
>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
Returns
Promise
<undefined
| TypesRecoveryConfig
>
Defined in
getSponsorship
▸ getSponsorship(sponsorshipId
): Promise
<undefined
| Sponsorship
>
Parameters
Name | Type |
---|---|
sponsorshipId | UUID |
Returns
Promise
<undefined
| Sponsorship
>
Defined in
getValidAccountId
▸ getValidAccountId(accountId
, type
): ValidAccountId
Parameters
Name | Type |
---|---|
accountId | string |
type | AccountType |
Returns
Defined in
isInvitedContributorOf
▸ isInvitedContributorOf(accountId
, locId
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
accountId | ValidAccountId |
locId | UUID |
Returns
Promise
<boolean
>
Defined in
isValidAccountId
▸ isValidAccountId(accountId?
, type?
): boolean
Parameters
Name | Type |
---|---|
accountId? | null | string |
type? | AccountType |
Returns
boolean
Defined in
buildCoinBalance
▸ buildCoinBalance(args
): CoinBalance
Parameters
Name | Type |
---|---|
args | Object |
args.available | PrefixedNumber |
args.coinId | string |
args.level | number |
args.reserved | PrefixedNumber |
args.total | PrefixedNumber |
Returns
Defined in
getCoin
▸ getCoin(coinId
): Coin
Parameters
Name | Type |
---|---|
coinId | string |
Returns
Defined in
of
▸ of(apiPromise
): Promise
<Queries
>
Parameters
Name | Type |
---|---|
apiPromise | Promise <ApiPromise > |
Returns
Promise
<Queries
>