faucet

package
v0.0.0-...-07d62d3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 4, 2024 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FaucetRequest

type FaucetRequest struct {
	Address   string                    `json:"address"`
	Time      time.Time                 `json:"time"`
	Amount    misc.BigInt               `json:"amount"`
	Network   network.BlockchainNetwork `json:"network"`
	TokenName FaucetSupportedToken      `json:"token_name"`
}

FaucetRequest that's sent on our wire to make sure that a user gets a transfer amount sent to them

type FaucetSupportedToken

type FaucetSupportedToken string
const (
	TokenfUSDT FaucetSupportedToken = `fUSDT`
	TokenfUSDC FaucetSupportedToken = `fUSDC`
	TokenfDAI  FaucetSupportedToken = `fDAI`
)

func TokenFromString

func TokenFromString(s string) (FaucetSupportedToken, error)

TokenFromString to safely convert a string to a supported token

func (FaucetSupportedToken) TokenDecimals

func (token FaucetSupportedToken) TokenDecimals() (int64, error)

type FaucetUser

type FaucetUser struct {
	Address string `json:"address"`

	// UniqueAddress that must be tweeted to use the faucet
	UniqueAddress string `json:"unique_address"`

	IpAddress string                    `json:"ip_address"`
	Network   network.BlockchainNetwork `json:"network"`
	LastUsed  time.Time                 `json:"last_used"`

	// TokenName for the type of token this address is related to
	TokenName FaucetSupportedToken `json:"token_name"`
}

FaucetUser and the last time that they used the faucet

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL