Add Contract to your App
Define a contract in your application to start working with it
About contract artifacts
Make sure your added SDK to your app and configured your Client before proceeding.
If you need to work with a previously deployed contract, you will need only its ABI and address. Get it in public repositories or ask the contract developer for it.
If you need to deploy a contract, then you will also need its tvc file. This file, along with ABI, is an artifact of contract compilation. Ask contract developer for this file.
If you plan to develop and compile the contracts yourself then these docs will help you:
Create contract wrapper
Use EVERDEV tool to generate contract wrapper that will have the following structure:
If you have tvc file, EVERDEV
will convert it into base64 that is suitable for SDK. If you don't have tvc, then this wrapper will be only useful for interaction with an already deployed contract.
Run this command:
The result name of the wrapper will be "ContractName||"Contract".js".
The result file will look like this:
You're all done!
Find out how to deploy and run your contract in the next sections.
Last updated