( network: string, safe: string, infoDID: string, gasToken: string, mnemonic?: string )
| 94 | } |
| 95 | |
| 96 | export async function setSupplierInfoDID( |
| 97 | network: string, |
| 98 | safe: string, |
| 99 | infoDID: string, |
| 100 | gasToken: string, |
| 101 | mnemonic?: string |
| 102 | ): Promise<void> { |
| 103 | let web3 = await getWeb3(network, mnemonic); |
| 104 | let safes = await getSDK('Safes', web3); |
| 105 | let assets = await getSDK('Assets', web3); |
| 106 | let { symbol } = await assets.getTokenInfo(gasToken); |
| 107 | console.log(`setting the info DID for the supplier safe ${safe} to ${infoDID} using ${symbol} token to pay for gas`); |
| 108 | let result = await safes.setSupplierInfoDID(safe, infoDID, gasToken); |
| 109 | let blockExplorer = await getConstant('blockExplorer', web3); |
| 110 | console.log(`Transaction hash: ${blockExplorer}/tx/${result.ethereumTx.txHash}/token-transfers`); |
| 111 | } |
no test coverage detected