Skip to content

decodeIcrcAccount

decodeIcrcAccount(accountString): IcrcAccount

Defined in: packages/ledger-icrc/src/utils/ledger.utils.ts:67

Decodes a string into an Icrc-1 compatible account. Formatting Reference: https://github.com/dfinity/ICRC-1/blob/main/standards/ICRC-1/TextualEncoding.md

string

string

IcrcAccount

IcrcAccount { owner: Principal, subaccount?: Uint8Array }

Error if the string is not a valid Icrc-1 account