openoracle

package
v0.71.3 Latest Latest
Warning

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

Go to latest
Published: May 2, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Verify

func Verify(oresp OracleResponse) ([]string, map[string]string, error)

Types

type OracleResponse

type OracleResponse struct {
	Timestamp  string            `json:"timestamp"`
	Messages   []string          `json:"messages"`
	Signatures []string          `json:"signatures"`
	Prices     map[string]string `json:"prices"`
}

func Unmarshal

func Unmarshal(payload []byte) (*OracleResponse, error)

func UnmarshalVerify

func UnmarshalVerify(payload []byte, address string) (*OracleResponse, error)

UnmarshalVerify will unmarshal a json raw payload into and OracleResponse if the unmarshal is successful then the content is verified.

Jump to

Keyboard shortcuts

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