Make a Deploy Request
Initiate and manage contract deployments on Loki.code directly from your existing development environment, all while enjoying access to team approvals and an extensive suite of DevOps tools.
Last updated
Initiate and manage contract deployments on Loki.code directly from your existing development environment, all while enjoying access to team approvals and an extensive suite of DevOps tools.
Last updated
By connecting your GitHub account to Loki.code, you gain access to our platform's comprehensive suite of DevOps tools, including deployment history, contract playground, and team deployment approvals, each time you make a contract deployment.
For most developers, it is more convenient to use Loki.code in conjunction with their existing development environment, such as Hardhat or Foundry. This is where deploy requests come into play. Deploy requests allow you to initiate a deployment on Loki.code from your existing development environment and enable teams to delineate the roles of developers who initiate deployments and authorized individuals who approve those deployments (for instance, on the mainnet).
By incorporating one of our deploy request scripts into your project, you can send deploy requests for your contract to one of your projects on Loki.code. From there, you or an authorized team member can approve the deployment. Once approved, the deployment details will be added to the project's history, and you will have the ability to interact with it in Loki.code's playground.
Start in the dashboard.
Click the "Projects" tab in the side bar.
Select the project you want the deploy request to be associated with.
Click the "API Keys" tab in the side bar.
Click "Generate new token", and follow the steps.
Save your API key in a secure location.
Save the project ID on the top right of the page to use in the deploy request script.
Deploy requests are essentially API calls that transmit your contract data and deployment options to your project on Loki.code. To facilitate this process, you may refer to this repository, which includes examples of Hardhat and Foundry projects that implement this in a script.
If you already possess a project, click on the appropriate example script link in the README, and copy that file into your project. For instance, this is the script for Hardhat.
If you do not have a pre-existing project, click on the appropriate example project link and follow the instructions in that project's README file. For instance, this is the reference project for Hardhat.
Once you have successfully sent the deploy request to your project, return to your project's page on Loki.code's website.
Click on "Deploy" in the sidebar.
Select the "Deploy Requests" tab.
Within this tab, you will now see all of your deploy requests associated with this project.
Click the "Review" button.
Confirm the network for deployment.
Set constructor arguments if necessary.
Click the "Deploy" button to deploy your contract. If you are part of an organization, you may delegate the authorization for the final deployment decision.
You can now view the details and history of your deployment in the "Deployments" tab on the same page.