api

package
v1.0.0-beta Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2024 License: AGPL-3.0 Imports: 0 Imported by: 1

Documentation

Index

Constants

View Source
const (
	ErrCodeInternalServerError = "E01"
	ErrCodeInvalidJSON         = "E02"
	ErrCodeInvalidAPIKey       = "E03"
	ErrCodeValidationFailed    = "E04"
	ErrCodeAccountNotExists    = "E05"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrResponse

type ErrResponse struct {
	Ok          bool   `json:"ok"`
	Description string `json:"description"`
	ErrCode     string `json:"errorCode"`
}

type OKResponse

type OKResponse struct {
	Ok          bool           `json:"ok"`
	Description string         `json:"description"`
	Result      map[string]any `json:"result"`
}

type TransferRequest

type TransferRequest struct {
	From         string `json:"from" validate:"required,eth_addr_checksum"`
	To           string `json:"to" validate:"required,eth_addr_checksum"`
	TokenAddress string `json:"tokenAddress" validate:"required,eth_addr_checksum"`
	Amount       string `json:"amount" validate:"number,gt=0"`
}

Jump to

Keyboard shortcuts

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