Class: WalletExtService
Table of contents
Constructors
Properties
Methods
Constructors
constructor
• new WalletExtService(_debug, _trpc)
Parameters
| Name | Type |
|---|---|
_debug | DebugService |
_trpc | TrpcService |
Properties
_debug
• Private _debug: DebugService
_trpc
• Private _trpc: TrpcService
Methods
auth
▸ auth(params): Promise<undefined | { app: string ; stake: string }>
Parameters
| Name | Type |
|---|---|
params | Object |
params.app | string |
params.key? | string |
params.signature | string |
Returns
Promise<undefined | { app: string ; stake: string }>
getAccountAssets
▸ getAccountAssets(params): Promise<({ assetName: string ; available?: null | boolean ; policyId: string ; quantity?: number ; rarity?: null | number ; unit: string } | { assetName: string ; available: null | boolean ; id: number ; metadata: null | {} ; policyId: string ; rarity: null | number ; unit: string })[]>
Parameters
| Name | Type |
|---|---|
params | Object |
params.policies | string[] |
params.stakeAddress | string |
Returns
Promise<({ assetName: string ; available?: null | boolean ; policyId: string ; quantity?: number ; rarity?: null | number ; unit: string } | { assetName: string ; available: null | boolean ; id: number ; metadata: null | {} ; policyId: string ; rarity: null | number ; unit: string })[]>
getAccountBalanceByPolicies
▸ getAccountBalanceByPolicies(params): Promise<{}>
Parameters
| Name | Type |
|---|---|
params | Object |
params.stakeAddress | string |
Returns
Promise<{}>
getAssets
▸ getAssets(params): Promise<never[] | ({ assetName: string ; available?: null | boolean ; policyId: string ; quantity?: number ; rarity?: null | number ; unit: string } | { assetName: string ; available: null | boolean ; id: number ; metadata: null | {} ; policyId: string ; rarity: null | number ; unit: string })[]>
Parameters
| Name | Type |
|---|---|
params | Object |
params.policies | string[] |
params.utxos | string[] |
Returns
Promise<never[] | ({ assetName: string ; available?: null | boolean ; policyId: string ; quantity?: number ; rarity?: null | number ; unit: string } | { assetName: string ; available: null | boolean ; id: number ; metadata: null | {} ; policyId: string ; rarity: null | number ; unit: string })[]>
getAuthPayload
▸ getAuthPayload(params): Promise<string>
Parameters
| Name | Type |
|---|---|
params | Object |
params.app | string |
Returns
Promise<string>
sendAssets
▸ sendAssets(params): Promise<string>
Parameters
| Name | Type |
|---|---|
params | Object |
params.changeAddress | string |
params.outputs | { address: string ; assets: { quantity: string | number ; unit: string }[] }[] |
params.recipient? | Object |
params.recipient.note | string |
params.utxos | Object |
Returns
Promise<string>
submit
▸ submit(params): Promise<{ submittedTx: string ; transactionHash: string }>
Parameters
| Name | Type |
|---|---|
params | Object |
params.mainnet? | boolean |
params.signature | string |
params.transaction | string |
Returns
Promise<{ submittedTx: string ; transactionHash: string }>