Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[skip ci] wip: chainflip swapper #8049

Draft
wants to merge 84 commits into
base: develop
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 79 commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
f9cf7a9
feat: add chainflip swagger schema
CumpsD Oct 22, 2024
b0fef83
feat: add chainflip icon
CumpsD Oct 23, 2024
6f4b2cd
feat: add chainflip env settings
CumpsD Oct 23, 2024
ae0d083
feat: start chainflip swapper
CumpsD Oct 23, 2024
56a4003
fix: forgot a missing type
CumpsD Oct 23, 2024
53cfa9f
feat: build sell and buy asset strings
CumpsD Oct 23, 2024
8515f51
fix: dont add chainflip to unchained
CumpsD Oct 23, 2024
c4131d5
feat: add supported chains and assets for chainflip
CumpsD Oct 23, 2024
159650a
feat: add chainflip csp
CumpsD Oct 23, 2024
cca5688
feat: fetch chainflip quote
CumpsD Oct 23, 2024
09b820d
feat: add fees to quotes
CumpsD Oct 23, 2024
9f60594
feat: add boost swaps
CumpsD Oct 23, 2024
8bab08e
fix: correct commissionBPs
CumpsD Oct 23, 2024
09b9b02
feat: first steps to get gas prices displayed
CumpsD Oct 23, 2024
e6a43ac
fix: correct arb to eth
CumpsD Oct 23, 2024
9c2f447
refactor: cleanup const and types
CumpsD Oct 23, 2024
20216d6
chore: add todo wrt minimum amounts
CumpsD Oct 23, 2024
d5b9fee
fix: deal with SellAmountBelowTradeFee error
CumpsD Oct 23, 2024
2861ba3
refactor: cleanup chainflip feature flag
CumpsD Oct 23, 2024
57e08d1
refactor: move default chainflip settings to env
CumpsD Oct 23, 2024
2207d5b
chore: newline eof
CumpsD Oct 23, 2024
56697f1
refactor: consistent order of swapper imports
CumpsD Oct 23, 2024
9507b73
fix: allowanceContract 0x0
CumpsD Oct 23, 2024
668856f
feat: filter out assets even more
CumpsD Oct 23, 2024
1765b86
feat: provide gaslimits for simple asset sends
CumpsD Oct 23, 2024
7b3cc26
chore: newline at eof
CumpsD Oct 23, 2024
a6d42f9
feat: support amount to low
CumpsD Oct 23, 2024
dfa6a3a
refactor: delete unneeded generated openai models
CumpsD Oct 23, 2024
ef79b52
chore: remove polkadot todo
CumpsD Oct 23, 2024
fea992c
refactor: clarify networkfee crypto base unit naming
CumpsD Oct 23, 2024
ee0d7bd
refactor: turn asset symbols into asset ids
CumpsD Oct 23, 2024
572135d
Merge branch 'develop' into add-chainflip
CumpsD Oct 23, 2024
089fff0
feat: use correct caip-19s
CumpsD Oct 23, 2024
1d25ce9
feat: place dca swaps behind feature toggle
CumpsD Oct 24, 2024
a1661cd
chore: pull magic values into constants
CumpsD Oct 25, 2024
72f1c7e
fix: pass pubkey for utxo estimation
CumpsD Oct 25, 2024
3fd7b62
fix: pass accountNumber
CumpsD Oct 25, 2024
519546b
refactor: cleanup swapsource and rate code
CumpsD Oct 25, 2024
799320f
Merge branch 'shapeshift:develop' into add-chainflip
CumpsD Oct 25, 2024
708a826
fix: add feature flag to tests
CumpsD Oct 25, 2024
8a17ba6
fix: unwanted quote char snuck in
CumpsD Oct 26, 2024
12ae967
style: be consistent in quotes style
CumpsD Oct 26, 2024
c090d43
chore: make prettier happy
CumpsD Oct 26, 2024
34ea201
fix: populate receiveAddress to get swap preview
CumpsD Oct 26, 2024
b253f4b
refactor: make code consistent with styling and restructure folders
CumpsD Oct 26, 2024
630f8ef
fix: correct swapper path
CumpsD Oct 26, 2024
e931c5b
refactor: move files around
CumpsD Oct 28, 2024
8f4b47a
feat: start unsigned evm tx
CumpsD Oct 28, 2024
8662c0d
chore: add todo
CumpsD Oct 28, 2024
3517d98
feat: add unsigned utxo
CumpsD Oct 28, 2024
ae28709
feat: add executeUtxoTransaction
CumpsD Oct 28, 2024
1251fa3
Merge branch 'shapeshift:develop' into add-chainflip
CumpsD Oct 28, 2024
15a0499
fix: check for undefined accountNumber
CumpsD Oct 28, 2024
c3c1745
wip: stuck at getUnsignedEvmTransaction
CumpsD Oct 28, 2024
1e57f3d
Merge branch 'shapeshift:develop' into add-chainflip
CumpsD Oct 28, 2024
4a227c5
refactor: move to buildSendApiTransaction to get rid of wallet
CumpsD Oct 28, 2024
22372ed
feat: estimate maxFeePerGas
CumpsD Oct 28, 2024
0c309d4
style: quotes
CumpsD Oct 28, 2024
3997245
refactor: add getGasLimit
CumpsD Oct 28, 2024
2cce1db
feat: use getErc20Data to get data
CumpsD Oct 28, 2024
5626b31
feat: return signing request
CumpsD Oct 28, 2024
5b4a64d
fix: no need for toHex
CumpsD Oct 28, 2024
f69ae34
chore: add slippage reference code
CumpsD Oct 28, 2024
a906812
Merge remote-tracking branch 'origin/develop' into add-chainflip
gomesalexandre Oct 30, 2024
4924c16
feat: lint and cleanup some
gomesalexandre Oct 30, 2024
1fd442b
feat: improve types
gomesalexandre Oct 30, 2024
dccd703
feat: cleanup unused models
gomesalexandre Oct 30, 2024
206a337
feat: cleanup
gomesalexandre Oct 30, 2024
7cfe7c2
feat: cleanup some more
gomesalexandre Oct 31, 2024
c2def52
feat: more prgorammatic
gomesalexandre Oct 31, 2024
5ef0169
feat: clean diff up
gomesalexandre Oct 31, 2024
2e77080
feat: cleanup consts
gomesalexandre Oct 31, 2024
c32b370
feat: consistency
gomesalexandre Oct 31, 2024
9a10db4
feat: stopping point
gomesalexandre Oct 31, 2024
19f5fcd
feat: false in base
gomesalexandre Oct 31, 2024
3111366
feat: stopping point for real this time
gomesalexandre Oct 31, 2024
820283b
fix: lint
gomesalexandre Oct 31, 2024
8c25692
Merge remote-tracking branch 'origin/develop' into add-chainflip
gomesalexandre Nov 4, 2024
ddd1339
fix: ci
gomesalexandre Nov 4, 2024
1c1b711
feat: split quotes/rates
gomesalexandre Nov 4, 2024
3172d80
feat: cleanup
gomesalexandre Nov 4, 2024
388b4dc
feat: trade status
gomesalexandre Nov 4, 2024
267eb4f
feat: flip polling and messaging
gomesalexandre Nov 4, 2024
ae0dd35
feat: improve btc things
gomesalexandre Nov 4, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .env.base
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ REACT_APP_FEATURE_DYNAMIC_LP_ASSETS=false
REACT_APP_FEATURE_READ_ONLY_ASSETS=true

# swapper feature flags - other .env files will override these
REACT_APP_FEATURE_CHAINFLIP=false
REACT_APP_FEATURE_CHAINFLIP_DCA=false
REACT_APP_FEATURE_COWSWAP=true
REACT_APP_FEATURE_LIFI_SWAP=true
REACT_APP_FEATURE_THOR_SWAP=true
Expand Down Expand Up @@ -170,3 +172,7 @@ REACT_APP_ZERION_BASE_URL=https://api.proxy.shapeshift.com/api/v1/zerion

# 0x
REACT_APP_ZRX_BASE_URL=https://api.proxy.shapeshift.com/api/v1/zrx/

# chainflip
REACT_APP_CHAINFLIP_API_KEY=6ba154d4-e219-472a-9674-5fa5b1300ccf
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Give me a ping to set up Shapeshift's API key when going forward, this is currently mine for testing! :) The best person to reach out to me for this would be the one who will be responsible for redeeming affiliate rewards in the future. The one controlling the wallet to sign Chainflip transactions that is (redeeming is a chainflip tx)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good @CumpsD! Is there any reason we should wait for go-live to get an actual API key here, or can we already get one? Will get the convs going already

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The key in there right now is actually the one from my swapping Discord bot https://swappy.be/ :) It works, you can test with it, but it charges 0.15% fee (0.05 BaaS + 0.10 Swappy). I can make you a temp one that does only 0.05 (BaaS fee + 0% partner) if you want. You can go live with that as well and swap it out to the Shapeshift one afterwards. lmk

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@CumpsD just to be sure, we can parametrize fee bps right i.e this isn't tied to the API key used?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Current one for dev is absolutely fine, so long as we go live on prod (and ideally on develop as a follow-up) with a proper API key 🙏🏽

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@CumpsD just to be sure, we can parametrize fee bps right i.e this isn't tied to the API key used?

Yes, you can pass in commissionBps for both quote and opening a deposit channel (I think I added that in the PR already even! taking in affiliateBps from shapeshift)

REACT_APP_CHAINFLIP_API_URL=https://chainflip-broker.io
2 changes: 2 additions & 0 deletions .env.dev
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# feature flags
REACT_APP_FEATURE_CHAINFLIP=true
REACT_APP_FEATURE_CHAINFLIP_DCA=false
REACT_APP_FEATURE_PUBLIC_TRADE_ROUTE=false

# logging
Expand Down
13 changes: 9 additions & 4 deletions packages/caip/src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,22 @@ export const arbitrumNovaAssetId: AssetId = 'eip155:42170/slip44:60'
export const baseAssetId: AssetId = 'eip155:8453/slip44:60'
export const solAssetId: AssetId = 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp/slip44:501'

export const foxatarAssetId: AssetId =
'eip155:137/erc721:0x2e727c425a11ce6b8819b3004db332c12d2af2a2'

export const foxyAssetId: AssetId = 'eip155:1/erc20:0xdc49108ce5c57bc3408c3a5e95f3d864ec386ed3'
export const foxOnGnosisAssetId: AssetId =
'eip155:100/erc20:0x21a42669643f45bc0e086b8fc2ed70c23d67509d'
export const foxOnArbitrumOneAssetId: AssetId =
'eip155:42161/erc20:0xf929de51d91c77e42f5090069e0ad7a09e513c73'
export const foxAssetId: AssetId = 'eip155:1/erc20:0xc770eefad204b5180df6a14ee197d99d808ee52d'
export const foxatarAssetId: AssetId =
'eip155:137/erc721:0x2e727c425a11ce6b8819b3004db332c12d2af2a2'
export const foxyAssetId: AssetId = 'eip155:1/erc20:0xdc49108ce5c57bc3408c3a5e95f3d864ec386ed3'

export const usdtAssetId: AssetId = 'eip155:1/erc20:0xdac17f958d2ee523a2206206994597c13d831ec7'
export const usdcAssetId: AssetId = 'eip155:1/erc20:0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48'
export const usdcOnArbitrumOneAssetId: AssetId =
'eip155:42161/erc20:0xaf88d065e77c8cc2239327c5edb3a432268e5831'
export const usdcOnSolanaAssetId: AssetId =
'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp/token:EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v'
export const flipAssetId: AssetId = 'eip155:1/erc20:0x826180541412d574cf1336d22c0c0a287822678a'

export const cosmosAssetId: AssetId = 'cosmos:cosmoshub-4/slip44:118'
export const thorchainAssetId: AssetId = 'cosmos:thorchain-1/slip44:931'
Expand Down
12 changes: 12 additions & 0 deletions packages/swapper/src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ import { assertUnreachable } from '@shapeshiftoss/utils'
import { arbitrumBridgeSwapper } from './swappers/ArbitrumBridgeSwapper/ArbitrumBridgeSwapper'
import { arbitrumBridgeApi } from './swappers/ArbitrumBridgeSwapper/endpoints'
import { ARBITRUM_BRIDGE_SUPPORTED_CHAIN_IDS } from './swappers/ArbitrumBridgeSwapper/utils/constants'
import { chainflipSwapper } from './swappers/ChainflipSwapper/ChainflipSwapper'
import { CHAINFLIP_SUPPORTED_CHAIN_IDS } from './swappers/ChainflipSwapper/constants'
import { chainflipApi } from './swappers/ChainflipSwapper/endpoints'
import { cowSwapper } from './swappers/CowSwapper/CowSwapper'
import { cowApi } from './swappers/CowSwapper/endpoints'
import { COW_SWAP_SUPPORTED_CHAIN_IDS } from './swappers/CowSwapper/utils/constants'
Expand Down Expand Up @@ -76,6 +79,12 @@ export const swappers: Record<
supportedChainIds: PORTALS_SUPPORTED_CHAIN_IDS,
pollingInterval: DEFAULT_GET_TRADE_QUOTE_POLLING_INTERVAL,
},
[SwapperName.Chainflip]: {
...chainflipSwapper,
...chainflipApi,
supportedChainIds: CHAINFLIP_SUPPORTED_CHAIN_IDS,
pollingInterval: DEFAULT_GET_TRADE_QUOTE_POLLING_INTERVAL,
},
[SwapperName.Test]: undefined,
}

Expand All @@ -86,6 +95,7 @@ const DEFAULT_PORTALS_SLIPPAGE_DECIMAL_PERCENTAGE = '0.01' // 1%
const DEFAULT_LIFI_SLIPPAGE_DECIMAL_PERCENTAGE = '0.005' // .5%
const DEFAULT_THOR_SLIPPAGE_DECIMAL_PERCENTAGE = '0.01' // 1%
const DEFAULT_ARBITRUM_BRIDGE_SLIPPAGE_DECIMAL_PERCENTAGE = '0' // no slippage for Arbitrum Bridge, so no slippage tolerance
const DEFAULT_CHAINFLIP_SLIPPAGE_DECIMAL_PERCENTAGE = '0.02' // 2%

export const getDefaultSlippageDecimalPercentageForSwapper = (
swapperName?: SwapperName,
Expand All @@ -105,6 +115,8 @@ export const getDefaultSlippageDecimalPercentageForSwapper = (
return DEFAULT_THOR_SLIPPAGE_DECIMAL_PERCENTAGE
case SwapperName.ArbitrumBridge:
return DEFAULT_ARBITRUM_BRIDGE_SLIPPAGE_DECIMAL_PERCENTAGE
case SwapperName.Chainflip:
return DEFAULT_CHAINFLIP_SLIPPAGE_DECIMAL_PERCENTAGE
default:
assertUnreachable(swapperName)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import type { AssetId } from '@shapeshiftoss/caip'
import type { BTCSignTx } from '@shapeshiftoss/hdwallet-core'
import type { Asset } from '@shapeshiftoss/types'

import type { BuyAssetBySellIdInput, Swapper, UtxoTransactionExecutionProps } from '../../types'
import { executeEvmTransaction } from '../../utils'
import { CHAINFLIP_SUPPORTED_CHAIN_IDS } from './constants'
import { isSupportedAssetId } from './utils/helpers'

export const chainflipSwapper: Swapper = {
executeEvmTransaction,

executeUtxoTransaction: async (
txToSign: BTCSignTx,
{ signAndBroadcastTransaction }: UtxoTransactionExecutionProps,
): Promise<string> => {
return await signAndBroadcastTransaction(txToSign)
},

filterAssetIdsBySellable: (assets: Asset[]): Promise<AssetId[]> => {
return Promise.resolve(
assets
.filter(asset => CHAINFLIP_SUPPORTED_CHAIN_IDS.sell.includes(asset.chainId))
.filter(asset => isSupportedAssetId(asset.chainId, asset.assetId))
.map(asset => asset.assetId),
)
},

filterBuyAssetsBySellAssetId: (input: BuyAssetBySellIdInput): Promise<AssetId[]> => {
return Promise.resolve(
input.assets
.filter(asset => CHAINFLIP_SUPPORTED_CHAIN_IDS.buy.includes(asset.chainId))
.filter(asset => isSupportedAssetId(asset.chainId, asset.assetId))
.map(asset => asset.assetId),
)
},
}
69 changes: 69 additions & 0 deletions packages/swapper/src/swappers/ChainflipSwapper/constants.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
import {
arbitrumAssetId,
type AssetId,
btcAssetId,
type ChainId,
ethAssetId,
flipAssetId,
solAssetId,
usdcAssetId,
usdcOnArbitrumOneAssetId,
usdcOnSolanaAssetId,
usdtAssetId,
} from '@shapeshiftoss/caip'
import type { Asset } from '@shapeshiftoss/types'
import { KnownChainIds } from '@shapeshiftoss/types'

import type { SupportedChainIds, SwapSource } from '../../types'
import { SwapperName } from '../../types'

export const CHAINFLIP_REGULAR_QUOTE = 'regular'
export const CHAINFLIP_DCA_QUOTE = 'dca'
export const CHAINFLIP_BAAS_COMMISSION = 5

export const ChainflipSupportedChainIds = [
KnownChainIds.EthereumMainnet,
KnownChainIds.ArbitrumMainnet,
KnownChainIds.BitcoinMainnet,
KnownChainIds.SolanaMainnet,
] as const

export type ChainflipSupportedChainId = (typeof ChainflipSupportedChainIds)[number]

export const ChainflipSupportedAssetIdsByChainId: Partial<Record<KnownChainIds, AssetId[]>> = {
[KnownChainIds.EthereumMainnet]: [ethAssetId, flipAssetId, usdcAssetId, usdtAssetId],
[KnownChainIds.ArbitrumMainnet]: [arbitrumAssetId, usdcOnArbitrumOneAssetId],
[KnownChainIds.BitcoinMainnet]: [btcAssetId],
[KnownChainIds.SolanaMainnet]: [solAssetId, usdcOnSolanaAssetId],
}

export const chainIdToChainflipNetwork: Partial<Record<ChainId, string>> = {
[KnownChainIds.EthereumMainnet]: 'eth',
[KnownChainIds.ArbitrumMainnet]: 'arb',
[KnownChainIds.BitcoinMainnet]: 'btc',
[KnownChainIds.SolanaMainnet]: 'sol',
}

export const CHAINFLIP_SUPPORTED_CHAIN_IDS: SupportedChainIds = {
sell: ChainflipSupportedChainIds as unknown as ChainId[],
buy: ChainflipSupportedChainIds as unknown as ChainId[],
}

export const CHAINFLIP_SWAP_SOURCE: SwapSource = SwapperName.Chainflip
export const CHAINFLIP_BOOST_SWAP_SOURCE: SwapSource = `${SwapperName.Chainflip} • Boost`
export const CHAINFLIP_DCA_SWAP_SOURCE: SwapSource = `${SwapperName.Chainflip} • DCA`
export const CHAINFLIP_DCA_BOOST_SWAP_SOURCE: SwapSource = `${SwapperName.Chainflip} • DCA • Boost`

export const usdcAsset: Asset = {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A fyi, the reason I copied this here is because the usdcAsset in caip is only the assetId, but where I've used it, it also needed precision (in the protocol fees calculations)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's absolutely fine @CumpsD!
Just to disambiguate here, what's the two actual flows when fees will be denominated in USDC? i.e i can see the condition is fee.type === 'network'and fee.type === 'liquidity' && fee.asset === 'usdc.eth' but not sure what this means exactly.

Asking because we may be able to simply use buyAsset / sellAsset if one of these is USDC

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Network fee is always USDC, it is the 0.10% buy & burn fee the chainflip network uses.

Liquidity is the LP fee, which I would have to double check but I believe the second leg is always USDC. It's possible this if (fee.type === 'liquidity' && fee.asset === buyChainflipChainKey) return buyAsset might actually never be hit.

Will double check!

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, so the second leg seems to be always usdc.eth for the liquidity fee.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Happy to keep the second branch for the sake of paranoia. Tyvm for disambiguating this! Looks like indeed, we need usdc as a static asset then, which means keeping it here as a const is absolutely fine.

Copy link

@CumpsD CumpsD Nov 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Happy to keep the second branch for the sake of paranoia.

Pretty much the reason I added all branches too :D

assetId: 'eip155:1/erc20:0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48',
chainId: KnownChainIds.EthereumMainnet,
color: '#2373CB',
explorer: 'https://etherscan.io',
explorerAddressLink: 'https://etherscan.io/address/',
explorerTxLink: 'https://etherscan.io/tx/',
icon: 'https://rawcdn.githack.com/trustwallet/assets/master/blockchains/ethereum/assets/0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48/logo.png',
name: 'USDC on Ethereum',
precision: 6,
relatedAssetKey: 'eip155:1/erc20:0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48',
symbol: 'USDC',
}
30 changes: 30 additions & 0 deletions packages/swapper/src/swappers/ChainflipSwapper/endpoints.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import { TxStatus } from '@shapeshiftoss/unchained-client'
import type { InterpolationOptions } from 'node-polyglot'

import type { SwapperApi } from '../../types'
import { getTradeQuote } from './swapperApi/getTradeQuote'
import { getUnsignedEvmTransaction } from './swapperApi/getUnsignedEvmTransaction'
import { getUnsignedUtxoTransaction } from './swapperApi/getUnsignedUtxoTransaction'

export const chainflipApi: SwapperApi = {
getTradeQuote,
// @ts-ignore TODO(gomes): this won't work with the public trade routes flag on, split me once we got this working
getTradeRate: undefined,
getUnsignedEvmTransaction,
getUnsignedUtxoTransaction,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should come back to this module as well since we'll need to add to trade quote meta for status polling

checkTradeStatus: (
_input,
): Promise<{
status: TxStatus
buyTxHash: string | undefined
message: string | [string, InterpolationOptions] | undefined
}> => {
// TODO(gomes): implement me
return {
// @ts-ignore TODO(gomes): implement me
buyTxHash: undefined,
status: TxStatus.Unknown,
message: undefined,
}
},
}
Loading
Loading