File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 99
1010import { BitGoAPI } from '@bitgo/sdk-api' ;
1111import { MessageStandardType } from "@bitgo/sdk-core" ;
12- import { MIDNIGHT_TNC_HASH } from "@bitgo/account-lib/dist/src/utils" ;
1312import { Hteth } from "@bitgo/sdk-coin-eth" ;
13+ import { MIDNIGHT_TNC_HASH } from "@bitgo/account-lib" ;
1414require ( 'dotenv' ) . config ( { path : '../../.env' } ) ;
1515
1616const bitgo = new BitGoAPI ( {
Original file line number Diff line number Diff line change 55 */
66import { BitGo } from 'bitgo' ;
77import { MessageStandardType } from '@bitgo/sdk-core' ;
8+ import { MIDNIGHT_TNC_HASH } from "@bitgo/account-lib" ;
89
910const bitgo = new BitGo ( { env : 'test' } ) ;
1011
@@ -18,9 +19,12 @@ async function signMessage(): Promise<void> {
1819 await bitgo . authenticateWithAccessToken ( { accessToken } ) ;
1920 const walletInstance = await basecoin . wallets ( ) . get ( { id : walletId } ) ;
2021
22+ const adaTestnetDestinationAddress = 'addr_test1vz7xs7ceu4xx9n5xn57lfe86vrwddqpp77vjwq5ptlkh49cqy3wur' ;
23+ const testnetMessageRaw = `STAR 12345678 to ${ adaTestnetDestinationAddress } ${ MIDNIGHT_TNC_HASH } ` ;
24+
2125 const messageTxn = await walletInstance . signMessage ( {
2226 message : {
23- messageRaw : 'Hello BitGo!' ,
27+ messageRaw : testnetMessageRaw ,
2428 messageStandardType : MessageStandardType . EIP191 ,
2529 } ,
2630 walletPassphrase,
Original file line number Diff line number Diff line change @@ -203,7 +203,8 @@ export { Soneium };
203203import * as Vet from '@bitgo/sdk-coin-vet' ;
204204export { Vet } ;
205205
206- import { validateAgainstMessageTemplates } from './utils' ;
206+ import { validateAgainstMessageTemplates , MIDNIGHT_TNC_HASH } from './utils' ;
207+ export { MIDNIGHT_TNC_HASH } ;
207208
208209const coinBuilderMap = {
209210 trx : Trx . WrappedBuilder ,
You can’t perform that action at this time.
0 commit comments