Skip to main content

index/interfaces/TokenNameResolver.md

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>

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

Parameters​

ParameterType
tokenNamestring

Returns​

Promise<GalaChainTokenClassKey>


resolveTokenInstance()?​

optional resolveTokenInstance(tokenName): Promise<GalaChainTokenInstanceKey>

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

Parameters​

ParameterType
tokenNamestring

Returns​

Promise<GalaChainTokenInstanceKey>