Deploy Contract
API Specification
Deploy Contract
Name
Type
Description
Request Body
Name
Type
Description
curl -X POST http://localhost:8889/wallet/deployContract \
-H "Content-Type: application/json" \
-H "ChainId: xxxx" \
-d '{
"walletId": "xxxxxxxxxxx",
"byteCode": "",
"abi": "",
"params": [],
"chainId":"xxxx"
}'const axios = require('axios');
const apiUrl = 'http://localhost:8889/wallet/deployContract';
const headers = {
'Content-Type': 'application/json',
'ChainId': 'xxxx',
};
const requestData = {
abi: 'Base64 of the abi',
byteCode: 'byte code of the contract',
walletId: 'xxxxxxxxxxxx',
ChainId: 'xxxx',
params: [],
};
axios.post(apiUrl, requestData, { headers })
.then((response) => {
console.log('Response:', response.data);
})
.catch((error) => {
console.error('Error:', error);
});
Last updated
Was this helpful?