Create your own Geyser

Devin Conley
GYSR
Published in
2 min readDec 28, 2020

--

The GYSR platform allows anyone to configure and deploy their own yield farm with just a few clicks. By making this core technology reusable, secure, and accessible, we can help accelerate the exploration of ideas and development for many new projects.

This tutorial will walk through the actual process of creating, funding, and verifying a new Geyser.

If you are not familiar with how Geysers are typically used in the wild, the article GYSR use cases and solutions is a good place to start.

Create a Geyser

In this video we walk through the steps to create a Geyser using the GYSR web app. We will:

  • Define the distribution and staking tokens
  • Configure the time-based multipliers that users can earn
  • Fund the Geyser with the distribution token
  • Set it to launch in the future so that users can stake in the boiler beforehand
Create a Geyser

Verification

After launching your new Geyser, you will want to verify the contract on Etherscan. This will prove to your users that the contract is indeed an authentic GYSR staking contract, which has been audited and thoroughly tested.

Note: we are working with Etherscan to have this contract done automatically. This manual step may not be required in the future.

Go to your new Geyser contract in Etherscan (e.g. https://etherscan.io/address/0x6C1FFDecC6520571D2C41087726611938a9Ae99f)

Unverified contract on Etherscan

Click “Verify and Publish” and fill in the initial options:

  • Compiler type: Solidity (Single file)
  • Compiler version: 0.6.12
  • Open source license type: MIT

Click “Continue” and fill in the contract source code options:

  • Optimization: Yes
  • Enter solidity contract code > “Fetch from Gist” > Enter Gist ID: 19c711d86d69c3024388fa59cff3178a
  • This should automatically fill in the source code for your contract

Constructor arguments - ABI encoding:

  • Go to: https://abi.hashex.org/
  • Enter parameters manually
  • Select function type: constructor
  • Address: your staking token
  • Address: your reward token
  • Uint256: minimum time bonus
    where value = (<your_min_time_bonus> - 1) * 10¹⁸
    (e.g. 1X in the UI is 0)
  • Uint256: maximum time bonus
    where value = (<your_max_time_bonus> - 1) * 10¹⁸
    (e.g. 3X in the UI is 2e18)
  • Uint256: time bonus period (in seconds)
  • Address: GYSR address (0xbEa98c05eEAe2f3bC8c3565Db7551Eb738c8CCAb)
ABI encoding of constructor arguments

Copy this ABI encoded block and paste into the field back on the Etherscan verification page.

Populated source code verification form on Etherscan

Under Misc Settings, fill in:

  • Runs: 10000

Finally… hit Verify and Publish

--

--