Documentation
¶
Index ¶
Constants ¶
View Source
const ( // API routes DevPath string = "dev" DepositDataMetaPath string = "deposit-data/meta" DepositDataPath string = "deposit-data" ValidatorsPath string = "validators" NoncePath string = "nonce" LoginPath string = "login" RegisterPath string = "node-address" // Admin routes AdminSnapshotPath string = "snapshot" AdminRevertPath string = "revert" AdminCycleSetPath string = "cycle-set" AdminAddUserPath string = "add-user" AdminWhitelistNodePath string = "whitelist-node" AdminRegisterNodePath string = "register-node" AdminAddVaultPath string = "add-vault" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DepositDataData ¶ added in v0.2.0
type DepositDataData struct { Version int `json:"version"` DepositData []beacon.ExtendedDepositData `json:"depositData"` }
Response to a deposit data request
type DepositDataMetaData ¶ added in v0.2.0
type DepositDataMetaData struct {
Version int `json:"version"`
}
Response to a deposit data meta request
type ExitData ¶
type ExitData struct { Pubkey string `json:"pubkey"` ExitMessage ExitMessage `json:"exit_message"` }
Data for a pubkey's voluntary exit message
type ExitMessage ¶
type ExitMessage struct { Message ExitMessageDetails `json:"message"` Signature string `json:"signature"` }
Voluntary exit message
type ExitMessageDetails ¶
type ExitMessageDetails struct { Epoch string `json:"epoch"` ValidatorIndex string `json:"validator_index"` }
Details of an exit message
type LoginData ¶ added in v0.2.0
type LoginData struct {
Token string `json:"token"`
}
Response to a login request
type LoginRequest ¶ added in v0.2.0
type LoginRequest struct { Nonce string `json:"nonce"` Address string `json:"address"` Signature string `json:"signature"` // Must be 0x-prefixed hex encoded }
Request to log into the NodeSet server
type NodeSetResponse ¶ added in v0.2.0
type NodeSetResponse[DataType any] struct { OK bool `json:"ok"` Message string `json:"message,omitempty"` Data DataType `json:"data,omitempty"` Error string `json:"error,omitempty"` }
All responses from the NodeSet API will have this format `message` may or may not be populated (but should always be populated if `ok` is false) `data` should be populated if `ok` is true, and will be omitted if `ok` is false
type RegisterNodeRequest ¶ added in v0.2.0
type RegisterNodeRequest struct { Email string `json:"email"` NodeAddress string `json:"node_address"` Signature string `json:"signature"` // Must be 0x-prefixed hex encoded }
Request to register a node with the NodeSet server
type StakeWiseStatus ¶
type StakeWiseStatus string
Status types for StakeWise validators
const ( // DepositData hasn't been uploaded to NodeSet yet StakeWiseStatus_Unknown StakeWiseStatus = "UNKNOWN" // DepositData uploaded to NodeSet, but hasn't been made part of a deposit data set yet StakeWiseStatus_Pending StakeWiseStatus = "PENDING" // DepositData uploaded to NodeSet, uploaded to StakeWise, but hasn't been activated on Beacon yet StakeWiseStatus_Uploaded StakeWiseStatus = "UPLOADED" // DepositData uploaded to NodeSet, uploaded to StakeWise, and the validator is active on Beacon StakeWiseStatus_Registered StakeWiseStatus = "REGISTERED" // DepositData uploaded to NodeSet, uploaded to StakeWise, and the validator is exited on Beacon StakeWiseStatus_Removed StakeWiseStatus = "REMOVED" )
type ValidatorStatus ¶
type ValidatorStatus struct { Pubkey beacon.ValidatorPubkey `json:"pubkey"` Status string `json:"status"` ExitMessageUploaded bool `json:"exitMessage"` }
Validator status info
type ValidatorsData ¶ added in v0.2.0
type ValidatorsData struct {
Validators []ValidatorStatus `json:"validators"`
}
Response to a validators request
Click to show internal directories.
Click to hide internal directories.