Getting Started
This guide will walk you through the process of setting up your first Deployment on the Almanak platform. By the end, you'll have a fully functional Deployment ready to execute your trading strategy.
Prerequisites
Before you begin, make sure you have:
- Python 3.11 or 3.12 installed
- A modern web browser
- About $5 USD worth of ETH on either Base or Arbitrum
Step 1: Install the Almanak SDK
First, let's install the Almanak SDK, which provides all the tools you need to create and manage your strategies.
pip install almanak
Step 2: Authorize the SDK with the Platform
Next, you'll need to authorize your local SDK to communicate with the Almanak platform.
almanak auth
This will open a browser window where you can generate an API key, which you can paste into the terminal.
Step 3: Create a Template Strategy
Now, let's create a new strategy using one of the available templates. The template provides a starting point for you to customize for your specific needs.
almanak strat new
This will create a new directory with the strategy code and configuration files. The template includes comments explaining each component and how to customize it.
Step 4: Create a new Strategy repository
In the UI, under Strategies
,click on the Create Strategy button. Give it a name and description.
Copy the resulting push
command.
Step 5: Push Your Strategy to the Platform
Once you've customized your strategy, push it to the Almanak platform where it can be executed by an Deployment.
Paste the push
command from the UI into your terminal.
Step 6: Create a Wallet
Now that your strategy is on the platform, you need to create a wallet for your Deployment to use.
- Navigate to the Wallets section in the Almanak dashboard
- Click Create Wallet
- Give it a name and select the network where you want to deploy your wallet. Choose the network that you have at least $5 USD worth of ETH on.
- Review the wallet creation details and click Confirm
- Sign the three transactions that are generated in your wallet. For more information on what these transactions do, see the Wallets page.
The wallet creation process may take a few minutes to complete as the necessary smart contracts are deployed.
Step 7: Enable Autonomous Execution
To operate on the blockchain, your Deployment requires Almanak's Autonomous Execution Service. This service covers all operational costs, including the network gas needed for your agent to perform transactions.
-
In the Deployments section, find your newly created AI Agent.
-
Locate the Autonomous Execution Service and click "Enable"
-
Select how much of the service you'd like to purchase. For this tutorial, we'll purchase 2$ worth of ETH.
-
Approve and complete the service fee payment from your personal wallet.
Step 8: Add Funds to Your Wallet
Now, add the funds that your strategy will manage.
- Still in the Wallets section, click on the Deposit button
- Select the token you want to add
- Enter the amount. For this tutorial, we'll add $2 USD worth of ETH.
- Complete the transaction from your personal User wallet
Step 9: (Optional) Connect your Telegram account
You can connect your Telegram account to your Almanak account to receive notifications on your Telegram account when your Deployment is executing a transaction.
- Go to the Settings section in the dashboard
- Click Notifications
- Follow the instructions to connect your Telegram account
Step 10: Start Your Deployment!
Finally, let's start your Deployment and watch your strategy in action.
- Go to the Deployments section in the dashboard
- Click Create Deployment
- Select your strategy from the dropdown
- Select your newly created wallet
- Configure any strategy-specific parameters
- Click Create Deployment
- Confirm the permission settings
Your Deployment is now live and will begin executing your strategy according to its programming. You can monitor its performance in the Deployments dashboard, which provides real-time updates on transactions, performance metrics, and any issues that might arise.
Next Steps
Congratulations! You've successfully set up your first Deployment on the Almanak platform. Here are some next steps to consider:
- Explore the Strategy Tutorials to learn more advanced strategy patterns
- Learn how to Test your Strategy locally before deploying to the platform
- Learn how to Troubleshoot a Deployment if you encounter any issues
- Understand more about Wallet Permissions to fine-tune your Deployment's capabilities
- Join our Discord community to connect with other users and get support
Happy automating!