Skip to main content

Interface: TokenNameResolver

GalaChain core SDK 1.0.0-rc.8


GalaChain core SDK 1.0.0-rc.8 / index / TokenNameResolver

Interface: TokenNameResolver

Defined in: packages/gala-core-sdk/dist/index.d.ts:2417

Turns a product's token NAME (a launchpad token's name, say) into the chain key a write signs. Optional: it is consulted only for inputs that name a token by tokenName; a tokenClassKey never needs it. A rejection is TOKEN_NAME_RESOLUTION_FAILED (pre-send, the original error as cause); an SDK error it throws passes through as it is.

Methods​

resolveTokenClassKey()​

resolveTokenClassKey(tokenName): Promise<GalaChainTokenClassKey>

Defined in: packages/gala-core-sdk/dist/index.d.ts:2419

The class key tokenName stands for; the write moves its fungible instance "0".

Parameters​

tokenName​

string

Returns​

Promise<GalaChainTokenClassKey>


resolveTokenInstance()?​

optional resolveTokenInstance(tokenName): Promise<GalaChainTokenInstanceKey>

Defined in: packages/gala-core-sdk/dist/index.d.ts:2424

The instance key tokenName stands for, when the product names a specific instance. When present it is used instead of resolveTokenClassKey.

Parameters​

tokenName​

string

Returns​

Promise<GalaChainTokenInstanceKey>