prepare-migrate-contract
Prepare a transaction to migrate a smart contract to new code on the Osmosis blockchain by specifying the contract address, new code ID, and migration message.
Instructions
Prepares a transaction to migrate a contract to new code
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"sender": "<sender>",
"contractAddress": "<contractAddress>",
"newCodeId": "<newCodeId>",
"migrateMsg": "<migrateMsg>"
},
"name": "prepare-migrate-contract"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sender | Yes | The sender's Osmosis address (must be admin) | |
| contractAddress | Yes | The contract address to migrate | |
| newCodeId | Yes | The new code ID to migrate to | |
| migrateMsg | Yes | The migration message as a JSON object |