quote

package
v0.0.0-...-2b78ec0 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Quoter

type Quoter interface {
	Quote(ctx context.Context, report *ReportData) (string, error)
}

Quoter is an interface for getting a quote.

type ReportData

type ReportData struct {
	Address         *felt.Felt
	ContractAddress *felt.Felt
	TwitterUsername string
}

ReportData is the data that is sent to the Quoter to get a quote.

func (*ReportData) MarshalBinary

func (r *ReportData) MarshalBinary() ([]byte, error)

MarshalBinary marshals the ReportData to binary.

func (*ReportData) MarshalJSON

func (r *ReportData) MarshalJSON() ([]byte, error)

MarshalJSON marshals the ReportData to JSON.

func (*ReportData) ToTappdQuoteField

func (r *ReportData) ToTappdQuoteField(tag string) ([64]byte, error)

type TappdQuoter

type TappdQuoter struct {
	// contains filtered or unexported fields
}

TappdQuoter is a quoter that uses the Tappd API to get a quote.

func NewTappdQuoter

func NewTappdQuoter(client *tappd.TappdClient) *TappdQuoter

NewTappdQuoter creates a new TappdQuoter.

func (*TappdQuoter) Quote

func (q *TappdQuoter) Quote(ctx context.Context, report *ReportData) (string, error)

Quote returns a quote for the given report.

Jump to

Keyboard shortcuts

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