Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions modules/express/src/clientRoutes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -710,8 +710,8 @@ async function handleV2AcceptWalletShare(req: express.Request) {
*/
async function handleV2SignTxWallet(req: ExpressApiRouteRequest<'express.v2.wallet.signtx', 'post'>) {
const bitgo = req.bitgo;
const coin = bitgo.coin(req.params.coin);
const wallet = await coin.wallets().get({ id: req.params.id });
const coin = bitgo.coin(req.decoded.coin);
const wallet = await coin.wallets().get({ id: req.decoded.id });
try {
return await wallet.signTransaction(createSendParams(req));
} catch (error) {
Expand Down
4 changes: 2 additions & 2 deletions modules/express/src/typedRoutes/api/v2/walletSignTx.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as t from 'io-ts';
import { httpRoute, httpRequest, optional } from '@api-ts/io-ts-http';
import { TransactionRequest as TxRequestResponse } from '@bitgo/public-types';
import { TransactionRequest as TxRequestResponse, TransactionRequestApiVersion } from '@bitgo/public-types';
import { BitgoExpressError } from '../../schemas/error';

/**
Expand Down Expand Up @@ -58,7 +58,7 @@ export const WalletSignTxBody = {
/** Wallet passphrase for TSS wallets */
walletPassphrase: optional(t.string),
/** API version: 'lite' or 'full' */
apiVersion: optional(t.union([t.literal('lite'), t.literal('full')])),
apiVersion: optional(TransactionRequestApiVersion),
/** Multisig type version */
multisigTypeVersion: optional(t.literal('MPCv2')),
/** Gas limit for ETH transactions */
Expand Down