Introducing Algorder

Algorder
Algorder
7 min readJun 17, 2021

--

Algorder is a decentralized OMS (Order Management System) build on Avalanche. Users are able to save orders with algorithmic conditions, and when those conditions are met orders will be sent to DEXs to be executed.

In the example above user is saving an order: “If AVAXUSDT is less than 12$, SWAP my 1000 PEFI to PNG”. Once the user saved this order, he/she can close the screen and leave the rest to Algorder. When the condition is met Algorder will send this order to the chosen DEX.

User are able to create orders like:

  • IF AVAX<12 , SWAP USDT to AVAX
  • IF AVAX >20, SWAP AVAX to USDT
  • IF ETH/AVAX < 150, SWAP PNG to USDT

Let's say there is a new token called “XYZ” that will be listed on Pangolin (IDO). Before the listing, users could save order on Algorder:

  • IF XYZ/USDT< 1.2$, SWAP AVAX to XYZ

So even before the initial listing, the user could save an order to buy XYZ, only if the price of a single XYZ is less than 1.2$. We believe that this will be a huge weapon for real users against bots on IDOs.

How does it work?

In order for users to use Algorder, first, they need to create an Algorder Account. You could think Algorder Account as a new wallet.

When you create an Account, a smart contract is deployed to Avalanche Network where you are the owner of the contract. Only the owner of the Account have rights to:

  • Save an order
  • Delete an order
  • Withdraw AVAX or tokens from the account balance.

So nobody can withdraw your balance, or submit an order for you.

Ok. You created an Account, saved an order. How this order’s condition will be checked and sent to DEX.

Algorthics

Algorthics are users that check all Algorder accounts (smart contracts), and trigger them for sending orders to DEXs if the condition is met. Anybody could be an Algorthic if they hold 10.000 ALGOR tokens.

Each Algorder Account smart contract has a sendOrder function. This function could only be triggered if:

  • Order’s condition is met.
  • There is enough balance on the Algorder Account for the swap operation. For example, if there is an order for swapping 100 PNG with AVAX. There should exist 100 PNG in the account balance.
  • There should exist 0.1 AVAX on the user balance. This amount will be paid to Algorthic who pays the gas to triggers the user’s order and send it to DEX.
  • The address that triggers this function should hold 10.000 ALGOR tokens. (He/she should be an Algorthic)

Summary

Let's summarize the flow again:

There are two types of profiles on Algorder.

  1. Users: they are the main users of Algorder. They save orders.
  2. Algorthics: they are the ones that trigger Algorder to check orders and submit them to DEX if conditions are met.

For example:

User: John,
Algorthic: Michelle

  1. User John created an order “IF AVAX/USDT is less than 12$, SWAP 1000 PNG tokens with USDT.
  2. John deposited 1000 PNG for swap operation to his Algorder Account.
  3. John deposited 0.1 AVAX as a tip for Algorthics to his Algorder Account.
  4. Algorthic Michelle is constantly trying to send John’s order to DEX. But Algorder smart contract only lets the order be submitted if the conditions are met.
  5. Let’s say several days passed and AVAX/USDT really become less than 12$. At that moment the Michelle triggered John’s smart contract to send the order will pay the gas fee. And the order will be submitted to DEX to be executed. Since Michelle paid the gas fee for sending John’s order to DEX, he will be tipped 0.1 AVAX from John’s Algorder account balance.
  6. So John didn’t paid a gas fee for sending the order to DEX. Instead, he paid Michelle 0.1 AVAX (tip) for triggering his order.
  7. Michelle earned 0.1 AVAX for submitting John’s order.

So Algorthics motivations are to earn 0.1 AVAX per order they triggered. And user’s motivations are they will able to create algorithmic orders for Avalanche DEXs.

ALGOR Token

There are 10.000.000 ALGOR tokens. ALGOR is an ERC20 token.

It is already created and verified on Avalanche Explorer:
https://cchain.explorer.avax.network/address/0xA0ebcB85157F59684Cf243dC8057184f2BBA5b9b

Token distribution:
%14 is dedicated to contributors: There were 7 contributors that helped to build Algorder. Each gets a %2 (200.000 ALGOR tokens).

We will be distributing %85 of ALGOR tokens as airdrop equally to the first 850 users that participate in our Beta Phase.

We will be distributing %1 of ALGOR tokens as an airdrop to a Twitter campaign that we will launch soon.

The reason behind this approach is we are not developing Algorder for profit-oriented reasons. We are developing it because we need it as users. We love Avalanche and we love DeFi and DEXs. We believe this is a tool/project that this ecosystem needs.

Our code is verified on Avalanche Explorer for anyone to check. We are more than happy to get feedback and suggestions for improvements. We will be releasing our website (UI) and a nodejs app(for algorthics that automatically checks all accounts and trigger orders) on our GitHub page soon. Our door is always open for every developer in Avalanche Community. Please check our code, give feedback, introduce your improvement ideas, submit pull requests, and so on. We want every user to feel like an owner of this product.

Beta Phase

Currently, Algorder is live at https://algorder.app . We are in the beta phase. Even though we think it is a well tested product, there could be bugs we missed. So please use it at your own risk. If you see any bugs please report us on our social media platforms.

Since we will be equally distributing ALGOR tokens as airdrop to all users that created an account on Algorder, there may be persons to get an advantage from this situation. A bot could come and create thousands of accounts in order to receive the majority of ALGOR tokens. For this reasons, we decide to go with a symbolic fee of 1 AVAX for creating accounts on Algorder during the beta phase. This fee will be increasing up to 4AVAX automatically as a number of accounts created increases.

0–100: 1 AVAX,
100–300: 2 AVAX,
300–600: 3 AVAX,
600–850: 4 AVAX,
850+ : 0AVAX FREE

This way we believe it will solve two problems.

  1. Nobody could create unlimited accounts for free programmatically.
  2. Even though a user willing the pay 1 AVAX and creates hundreds of accounts, he will need to pay 4AVAX per account, while the earlier adapters only paid 1 AVAX.

If you don’t want to pay any fee for creating accounts please wait for the beta phase to end, and then you will be able to create your Algorder account without a fee.

We are planning for ending the beta phase on July 15, 2021. Before the beta phase ends, we will release a dashboard for distributing ALGOR token airdrop and release our node.js application for Algorthics on our GitHub page.

This date could change depending on the beta phase feedbacks. We could end sooner or later than this. We will announce it from all of our social media channels if it changes.

Roadmap

  • Until July 15, 2021 we will be distributing ALGOR token as an airdrop to all our early adopters.
  • We will release an application for Algorthics for triggering orders and earning tips.
  • Meanwhile, we are developing more complex order structures.
    We will introduce chain orders. Where users will able to link orders after each other. For example, if order1 is executed then start checking Order2. This way users will able to perform actions like
    Order1: IF AVAX< 10 , swap 1000USDT with AVAX
    Order2: IF Order1 executed AND AVAX > 20, swap 100 AVAX with USDT
  • Another order type we are working on is re-enabling orders. Currently, when an order is sent, it is deleted from active orders. We want users to able to create re-enabling conditions.
    This way users will able to perform actions like
    “IF AVAX < 10, swap 1000 USDT with AVAX . If it is executed AND AVAX>20 re-enable this order”. So if the price goes below 10$ user order will be executed, and if the price goes above 20$, it will re-enable and start checking the price to go below 10$ in order to send it again.
    A user could create an algorithmic-trading order that never ends. Buy if AVAX is less than 10$, sell if AVAX is greater than. 20$.
  • These are the current in-progress items we are working on. But again we are willing for you to (whether you are a coder or not) give feedback, share your ideas, help us to code new features on Algorder.

Transparency

Our smart contracts are verified on Avalanche Explorer. So all of our smart contracts code is open for anyone to check

Algorder:

https://cchain.explorer.avax.network/address/0x95d294bc407beD9AD34F040405D6cDBe5f952DD4

AlgorToken:
https://cchain.explorer.avax.network/address/0xA0ebcB85157F59684Cf243dC8057184f2BBA5b9b

Our website is a client-side website (javascript) so all of the code is visible for anyone now. We will also publish it on our GitHub page when we completed the documentation.

Before the end of the beta phase, a node.js application for Algorthics will be published on our GitHub page too.

Thanks

This is Algorder! A brand new decentralized OMS with algorithm support build on Avalanche.

--

--