Skip to content

Latest commit

 

History

History
1645 lines (1181 loc) · 59.6 KB

api-reference-erc20.md

File metadata and controls

1645 lines (1181 loc) · 59.6 KB

Classes

ERC20_Base

ERC20 Base

ERC20_InboundERC20_Base

ERC20 Inbound

ERC20_OutboundERC20_Base

ERC20 Outbound

ERC20_Base

ERC20 Base

Kind: global class


ERC20_Base.storemanQuota(opts, skipValidation) ⇒ Promise

Make storeman quota call on Wanchain

Kind: instance method of ERC20_Base Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.storemanInfo(opts, skipValidation) ⇒ Promise

Make storeman info call on Wanchain

Kind: instance method of ERC20_Base Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.tokenInfo(opts, skipValidation) ⇒ Promise

Make token info call on Wanchain

Kind: instance method of ERC20_Base Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.buildStoremanQuotaTx(opts, skipValidation) ⇒ Object

Build storeman quota call

Kind: instance method of ERC20_Base Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.buildTokenKeyTx(opts, skipValidation) ⇒ Object

Build token manager mapKey call

Kind: instance method of ERC20_Base Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.buildTokenInfoTx(opts, skipValidation) ⇒ Object

Build token manager mapTokenInfo call

Kind: instance method of ERC20_Base Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.token Object Token info
opts.token.key string Token key
skipValidation boolean

ERC20_Base.buildStoremanInfoTx(opts, skipValidation) ⇒ Object

Build storeman group admin mapStoremanGroup call

Kind: instance method of ERC20_Base Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token info
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.buildStoremanQuotaData(opts, skipValidation) ⇒ string

Get data hex string for storeman quota call

Kind: instance method of ERC20_Base Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.buildTokenInfoData(opts, skipValidation) ⇒ string

Get data hex string for token mapTokenInfo call

Kind: instance method of ERC20_Base Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.token Object Token info
opts.token.key string Token key
skipValidation boolean

ERC20_Base.buildTokenKeyData(opts, skipValidation) ⇒ string

Get data hex string for token mapKey call

Kind: instance method of ERC20_Base Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Base.buildStoremanInfoData(opts, skipValidation) ⇒ string

Get data hex string for storeman mapStoremanGroup call

Kind: instance method of ERC20_Base Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound ⇐ ERC20_Base

ERC20 Inbound

Kind: global class Extends: ERC20_Base


ERC20_Inbound.send(opts, skipValidation) ⇒ Promise

Complete crosschain transaction (lock + redeem)

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Inbound.lock(opts, skipValidation) ⇒ Promise

Lock transaction and confirmation

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Inbound.redeem(opts, skipValidation) ⇒ Promise

Redeem transaction and confirmation

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
skipValidation boolean

ERC20_Inbound.sendApprove(opts, skipValidation) ⇒ Promise

Send approve tx on Ethereum

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.value string Tx value
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.sendLock(opts, skipValidation) ⇒ Promise

Send lock tx on Ethereum

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Inbound.sendRedeem(opts, skipValidation) ⇒ Promise

Send redeem tx on Wanchain

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.sendRevoke(opts, skipValidation) ⇒ Promise

Send revoke tx on Ethereum

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.listenLock(opts, skipValidation) ⇒ Promise

Listen for storeman lock confirmation on Wanchain

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Inbound.listenRedeem(opts, skipValidation) ⇒ Promise

Listen for storeman redeem confirmation on Ethereum

Kind: instance method of ERC20_Inbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Inbound.buildApproveTx(opts, skipValidation) ⇒ Object

Build approve tx

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.value string Tx value
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildLockTx(opts, skipValidation) ⇒ Object

Build lock tx

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Inbound.buildRedeemTx(opts, skipValidation) ⇒ Object

Build redeem tx

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
skipValidation boolean

ERC20_Inbound.buildRevokeTx(opts, skipValidation) ⇒ Object

Build redeem tx

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Inbound.buildLockScanOpts(opts, skipValidation) ⇒ Object

Build lock scan opts

Kind: instance method of ERC20_Inbound Returns: Object - Call opts object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Inbound.buildRedeemScanOpts(opts, skipValidation) ⇒ Object

Build redeem scan opts

Kind: instance method of ERC20_Inbound Returns: Object - Call opts object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Inbound.buildApproveData(opts, skipValidation) ⇒ string

Get data hex string for approve call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.value string | number Tx value
skipValidation boolean

ERC20_Inbound.buildLockData(opts, skipValidation) ⇒ string

Get data hex string for lock call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token address pair
opts.token.eth string Token eth address
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.eth string Storeman eth address
opts.to string Destination address
opts.value string | number Tx value
skipValidation boolean

ERC20_Inbound.buildRedeemData(opts, skipValidation) ⇒ string

Get data hex string for redeem call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token address pair
opts.token.eth string Token eth address
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
skipValidation boolean

ERC20_Inbound.buildRevokeData(opts, skipValidation) ⇒ string

Get data hex string for revoke call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token address pair
opts.token.eth string Token eth address
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Inbound.storemanQuota(opts, skipValidation) ⇒ Promise

Make storeman quota call on Wanchain

Kind: instance method of ERC20_Inbound Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.storemanInfo(opts, skipValidation) ⇒ Promise

Make storeman info call on Wanchain

Kind: instance method of ERC20_Inbound Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.tokenInfo(opts, skipValidation) ⇒ Promise

Make token info call on Wanchain

Kind: instance method of ERC20_Inbound Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildStoremanQuotaTx(opts, skipValidation) ⇒ Object

Build storeman quota call

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildTokenKeyTx(opts, skipValidation) ⇒ Object

Build token manager mapKey call

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildTokenInfoTx(opts, skipValidation) ⇒ Object

Build token manager mapTokenInfo call

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.token Object Token info
opts.token.key string Token key
skipValidation boolean

ERC20_Inbound.buildStoremanInfoTx(opts, skipValidation) ⇒ Object

Build storeman group admin mapStoremanGroup call

Kind: instance method of ERC20_Inbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token info
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildStoremanQuotaData(opts, skipValidation) ⇒ string

Get data hex string for storeman quota call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildTokenInfoData(opts, skipValidation) ⇒ string

Get data hex string for token mapTokenInfo call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.token Object Token info
opts.token.key string Token key
skipValidation boolean

ERC20_Inbound.buildTokenKeyData(opts, skipValidation) ⇒ string

Get data hex string for token mapKey call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Inbound.buildStoremanInfoData(opts, skipValidation) ⇒ string

Get data hex string for storeman mapStoremanGroup call

Kind: instance method of ERC20_Inbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound ⇐ ERC20_Base

ERC20 Outbound

Kind: global class Extends: ERC20_Base


ERC20_Outbound.send(opts, skipValidation) ⇒ Promise

Complete crosschain transaction (lock + redeem)

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Outbound.lock(opts, skipValidation) ⇒ Promise

Lock transaction and confirmation

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Outbound.redeem(opts, skipValidation) ⇒ Promise

Redeem transaction and confirmation

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
skipValidation boolean

ERC20_Outbound.getOutboundFee(opts, skipValidation) ⇒ Promise

Get outbound fee amount

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
skipValidation boolean

ERC20_Outbound.sendApprove(opts, skipValidation) ⇒ Promise

Send approve tx on Ethereum

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
skipValidation boolean

ERC20_Outbound.sendLock(opts, skipValidation) ⇒ Promise

Send lock tx on Wanchain

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.outboundFee string Tx outbound fee
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Outbound.sendRedeem(opts, skipValidation) ⇒ Promise

Send redeem tx on Ethereum

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.sendRevoke(opts, skipValidation) ⇒ Promise

Send revoke tx on Wanchain

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.listenLock(opts, skipValidation) ⇒ Promise

Listen for storeman lock confirmation on Ethereum

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Outbound.listenRedeem(opts, skipValidation) ⇒ Promise

Listen for storeman redeem confirmation on Wanchain

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Outbound.buildOutboundFeeTx(opts, skipValidation) ⇒ Promise

Build outbound fee tx

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
skipValidation boolean

ERC20_Outbound.buildApproveTx(opts, skipValidation) ⇒ Object

Build approve tx

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.value string Tx value
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
skipValidation boolean

ERC20_Outbound.buildLockTx(opts, skipValidation) ⇒ Promise

Build lock tx

Kind: instance method of ERC20_Outbound Returns: Promise - Promise object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.to string Destination address
opts.value string Tx value
opts.outboundFee string Tx outbound fee
opts.token Object Token pair
opts.token.wan string Token address on Wanchain
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.storeman.eth string Storeman Ethereum address
skipValidation boolean

ERC20_Outbound.buildRedeemTx(opts, skipValidation) ⇒ Object

Build redeem tx

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.to string Destination address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
skipValidation boolean

ERC20_Outbound.buildRevokeTx(opts, skipValidation) ⇒ Object

Build redeem tx

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.from string Sender address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Outbound.buildLockScanOpts(opts, skipValidation) ⇒ Object

Build lock scan opts

Kind: instance method of ERC20_Outbound Returns: Object - Call opts object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Outbound.buildRedeemScanOpts(opts, skipValidation) ⇒ Object

Build redeem scan opts

Kind: instance method of ERC20_Outbound Returns: Object - Call opts object

Param Type Description
opts Object Tx options
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Outbound.buildApproveData(opts, skipValidation) ⇒ string

Get data hex string for approve call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.value string | number Tx value
skipValidation boolean

ERC20_Outbound.buildLockData(opts, skipValidation) ⇒ string

Get data hex string for lock call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token addr pair
opts.token.eth string Token eth addr
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
opts.storeman Object Storeman addr pair
opts.storeman.wan string Storeman wan addr
opts.to string Destination address
opts.value string | number Tx value
skipValidation boolean

ERC20_Outbound.buildRedeemData(opts, skipValidation) ⇒ string

Get data hex string for redeem call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token addr pair
opts.token.eth string Token eth addr
opts.redeemKey Object Redeem key pair
opts.redeemKey.x string Redeem key x
skipValidation boolean

ERC20_Outbound.buildRevokeData(opts, skipValidation) ⇒ string

Get data hex string for revoke call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token addr pair
opts.token.eth string Token eth addr
opts.redeemKey Object Redeem key pair
opts.redeemKey.xHash string Redeem key xHash
skipValidation boolean

ERC20_Outbound.buildOutboundFeeData(opts, skipValidation) ⇒ string

Get data hex string for outboundFee call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Tx options
opts.token Object Token addr pair
opts.token.eth string Token eth addr
opts.storeman Object Storeman addr pair
opts.storeman.wan string Storeman wan addr
opts.value number | string Tx value
skipValidation boolean

ERC20_Outbound.storemanQuota(opts, skipValidation) ⇒ Promise

Make storeman quota call on Wanchain

Kind: instance method of ERC20_Outbound Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.storemanInfo(opts, skipValidation) ⇒ Promise

Make storeman info call on Wanchain

Kind: instance method of ERC20_Outbound Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.tokenInfo(opts, skipValidation) ⇒ Promise

Make token info call on Wanchain

Kind: instance method of ERC20_Outbound Returns: Promise - Promise returning object

Param Type Description
opts Object Tx options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.buildStoremanQuotaTx(opts, skipValidation) ⇒ Object

Build storeman quota call

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.buildTokenKeyTx(opts, skipValidation) ⇒ Object

Build token manager mapKey call

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.buildTokenInfoTx(opts, skipValidation) ⇒ Object

Build token manager mapTokenInfo call

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.token Object Token info
opts.token.key string Token key
skipValidation boolean

ERC20_Outbound.buildStoremanInfoTx(opts, skipValidation) ⇒ Object

Build storeman group admin mapStoremanGroup call

Kind: instance method of ERC20_Outbound Returns: Object - Tx object

Param Type Description
opts Object Tx options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token info
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.buildStoremanQuotaData(opts, skipValidation) ⇒ string

Get data hex string for storeman quota call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.buildTokenInfoData(opts, skipValidation) ⇒ string

Get data hex string for token mapTokenInfo call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.token Object Token info
opts.token.key string Token key
skipValidation boolean

ERC20_Outbound.buildTokenKeyData(opts, skipValidation) ⇒ string

Get data hex string for token mapKey call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean

ERC20_Outbound.buildStoremanInfoData(opts, skipValidation) ⇒ string

Get data hex string for storeman mapStoremanGroup call

Kind: instance method of ERC20_Outbound Returns: string - Data hex string

Param Type Description
opts Object Data options
opts.storeman Object Storeman address pair
opts.storeman.wan string Storeman Wanchain address
opts.token Object Token pair
opts.token.eth string Token address on Ethereum
skipValidation boolean