commands

package
v0.0.0-...-d86747b Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2021 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CLI

type CLI struct {
	Config   configCmd   `kong:"cmd,name='config',help='create, update or use a config'"`
	Coinbase coinbaseCmd `kong:"cmd,name='coinbase',aliases='cb',help='use the coinbasepro api'"`
	LogLevel logLevel    `` /* 130-byte string literal not displayed */
}

type DepositFilter

type DepositFilter struct {
	// ProfileID limits the list of Deposit to the ProfileID
	ProfileID string `kong:"name='profile',short='p',help='filter by profile id'"`
	// Type identifies the type of the Deposit (`deposit` or `internal_deposit`)
	Type coinbasepro.DepositType `` /* 126-byte string literal not displayed */
}

func (DepositFilter) Filter

type HistoricRateParams

type HistoricRateParams struct {
	Granularity coinbasepro.TimesliceParam `` /* 245-byte string literal not displayed */
	End         coinbasepro.Time           `kong:"name='end',short='e',help='end time in RFC3339 compatible format (21-04-14T12:35:00Z)'"`
	Start       coinbasepro.Time           `kong:"name='start',short='s',help='start time in RFC3339 compatible format (21-04-14T12:35:00Z)'"`
}

func (*HistoricRateParams) Params

type Output

type Output struct {
	Output OutputType `kong:"name='output',short='o',default='json',enum='json,yaml,none'"`
	// contains filtered or unexported fields
}

func (*Output) BeforeApply

func (o *Output) BeforeApply(ktx *kong.Context) error

func (*Output) Encode

func (o *Output) Encode(value interface{}) (capture error)

type OutputType

type OutputType string
const (
	// OutputTypeNone suppresses all output
	OutputTypeNone OutputType = "none"
	// OutputTypeJSON encodes all output to json (default)
	OutputTypeJSON OutputType = "json"
	// OutputTypeYAML encodes all output to yaml
	OutputTypeYAML OutputType = "yaml"
)

type Pagination

type Pagination struct {
	Before string `kong:"name='prev',short='p',help='retrieve the page before this token'"`
	After  string `kong:"name='next',short='n',help='retrieve the page after this token'"`
	Limit  int    `kong:"name='limit',short='l',help='limit retrieval to at most this many results, max 100, default 100'"`
}

func (Pagination) Empty

func (p Pagination) Empty() bool

func (Pagination) Params

func (Pagination) Validate

func (p Pagination) Validate() error

type TimestampFilterPagination

type TimestampFilterPagination struct {
	// After limits the list of Deposits to those created before the after timestamp, sorted by newest
	After coinbasepro.Time `kong:"name='after',short='a',help='filter retrieval to deposits created before the after timestamp'"`
	// Before limits the list of Deposits to those created after the before timestamp, sorted by oldest creation date.
	Before coinbasepro.Time `kong:"name='before',short='b',help='filter retrieval to deposits created after the before timestamp'"`
	// Limit limits the number of Deposit returned to the Limit. Max 100. Default 100.
	Limit int `kong:"name='limit',short='l',help='limit retrieval to at most this many deposits, max 100, default 100'"`
}

func (TimestampFilterPagination) Params

func (*TimestampFilterPagination) Validate

func (d *TimestampFilterPagination) Validate() error

type WithdrawalFilter

type WithdrawalFilter struct {
	// Type identifies the type of the Withdrawal (`withdraw` or `internal_withdraw`)
	Type coinbasepro.WithdrawalType `` /* 133-byte string literal not displayed */
	// ProfileID limits the list of Withdrawals to the ProfileID
	ProfileID string `kong:"name='profile',short='p',help='filter retrieval by profile id'"`
}

func (WithdrawalFilter) Filter

Jump to

Keyboard shortcuts

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