Documentation ¶
Index ¶
Constants ¶
View Source
const ( // RNSRestApiUrl is the base url for the RNS REST API RNSRestApiUrl = "https://rns.rest" // RNSRestApiHeaderName is the header name for the RNS REST API RNSRestApiHeaderName = "X-LIB" // RNSRestApiHeaderNameValue is the header value for the RNS REST API RNSRestApiHeaderNameValue = "rns.go lib" // RNSLabelSuffix is the suffix for RNS labels RNSLabelSuffix = ".ron" // RoninAddressPrefix is the prefix for Ronin addresses RoninAddressPrefix = "ronin:" // EthAddressPrefix is the prefix for Ethereum addresses EthAddressPrefix = "0x" // ErrInvalidName Error Invalid Name ErrInvalidName = "invalid_name" // ErrInvalidAddress Error Invalid Address ErrInvalidAddress = "invalid_address" // ErrInvalidBatchRequest Error Invalid Batch Request ErrInvalidBatchRequest = "invalid_batch_request" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BatchAddressRequest ¶
type BatchAddressRequest struct {
Addresses []Address `json:"addresses"`
}
func (*BatchAddressRequest) Route ¶
func (b *BatchAddressRequest) Route() string
type BatchAddressResponse ¶
type BatchNameRequest ¶
type BatchNameRequest struct {
Names []Name `json:"names"`
}
func (*BatchNameRequest) Route ¶
func (b *BatchNameRequest) Route() string
type BatchNameResponse ¶
type BatchRequest ¶
type BatchRequest interface {
Route() string
}
type RNS ¶
type RNS struct {
// contains filtered or unexported fields
}
func (*RNS) GetAddressBatch ¶
func (r *RNS) GetAddressBatch(names []Name) (BatchAddressResponse, error)
func (*RNS) GetNameBatch ¶
func (r *RNS) GetNameBatch(addresses []Address) (BatchNameResponse, error)
Click to show internal directories.
Click to hide internal directories.