const op = await contract.methods
.buy(contractParams?.height, contractParams?.width)
.send();
I have a buy
entrypoint and would like to pass in some parameters and some tez at the same time. How should this be done?
Tezos Stack Exchange is a question and answer site for users, experts, and developers of the Tezos blockchain project. It only takes a minute to sign up.
Sign up to join this communityNeed to include the amount in the send call
const op = await contract.methods
.buy(contractParams?.height, contractParams?.width)
.send({ amount: 1});
mutez
instead of tez
, for example, .send({ amount: 1})
is going to send 1 tez but .send({ amount: 1000000, mutez: true})
is going to send 1.000.000 mutez.
Apr 6, 2021 at 6:58