Create a smart contract template
Follow these steps to create a smart contract template using MARCO Console.
Before you begin
Before you start, you must have:
- A user with the
MANAGER
role at the organization level or higher permissions. - The smart contract template specification compressed in ZIP format.
- A project created on your organization.
1. Register the smart contract template
To register the smart contract template:
- Open MARCO Console.
- On the left sidebar, go to Smart Contracts Templates > Create Template.
- Enter the smart contract template name and a description.
- Click on Create Template.
The smart contract template is registered on MARCO. Now, you can add a specification to the smart contract template.
2. Add a specification
To add a specification to a smart contract template:
On the left sidebar, go to Smart Contracts > Templates > List template.
Select the smart contract template you want to add a specification to.
Click Add Specification.
Enter the specification details:
- Tag: The version of the smart contract specification using semantic versioning. Choose a version in the format
MAJOR.MINOR.PATCH
to avoid errors. - Compilation language: The programming language used to write the smart contract specification.
- Description: A description of the smart contract specification.
- Tag: The version of the smart contract specification using semantic versioning. Choose a version in the format
Next to the Select your file label, click Upload source code and select the smart contract specification compressed in ZIP format.
infoTo learn more about the smart contract specification format, see Smart contracts templates.
Click Create Specification.
Wait for the smart contract specification to be Compiled.
The compilation process can take a few minutes, and you need to refresh the page to see the updated status.
Next steps
Now that you have deployed a smart contract template, you can deploy a smart contract instance to a ledger.