cli

package
v0.0.0-...-91404a6 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2022 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterCommands

func RegisterCommands(app *cobra.Command, c *client.Client)

RegisterCommands registers the resource action CLI commands.

Types

type CreateMusicCommand

type CreateMusicCommand struct {
	Payload     string
	ContentType string
	PrettyPrint bool
}

CreateMusicCommand is the command line data structure for the create action of music

func (*CreateMusicCommand) RegisterFlags

func (cmd *CreateMusicCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*CreateMusicCommand) Run

func (cmd *CreateMusicCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the CreateMusicCommand command.

type CreateUserCommand

type CreateUserCommand struct {
	Payload     string
	ContentType string
	PrettyPrint bool
}

CreateUserCommand is the command line data structure for the create action of user

func (*CreateUserCommand) RegisterFlags

func (cmd *CreateUserCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*CreateUserCommand) Run

func (cmd *CreateUserCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the CreateUserCommand command.

type DownloadCommand

type DownloadCommand struct {
	// OutFile is the path to the download output file.
	OutFile string
}

DownloadCommand is the command line data structure for the download command.

func (*DownloadCommand) Run

func (cmd *DownloadCommand) Run(c *client.Client, args []string) error

Run downloads files with given paths.

type FollowUserCommand

type FollowUserCommand struct {
	Payload     string
	ContentType string
	FolloweeID  string
	ID          string
	PrettyPrint bool
}

FollowUserCommand is the command line data structure for the follow action of user

func (*FollowUserCommand) RegisterFlags

func (cmd *FollowUserCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*FollowUserCommand) Run

func (cmd *FollowUserCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the FollowUserCommand command.

type ListMusicCommand

type ListMusicCommand struct {
	Limit       int
	Offset      int
	PrettyPrint bool
}

ListMusicCommand is the command line data structure for the list action of music

func (*ListMusicCommand) RegisterFlags

func (cmd *ListMusicCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*ListMusicCommand) Run

func (cmd *ListMusicCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the ListMusicCommand command.

type ListUserCommand

type ListUserCommand struct {
	Limit       int
	Offset      int
	PrettyPrint bool
}

ListUserCommand is the command line data structure for the list action of user

func (*ListUserCommand) RegisterFlags

func (cmd *ListUserCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*ListUserCommand) Run

func (cmd *ListUserCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the ListUserCommand command.

type ListenUserCommand

type ListenUserCommand struct {
	Payload     string
	ContentType string
	ID          string
	MusicID     string
	PrettyPrint bool
}

ListenUserCommand is the command line data structure for the listen action of user

func (*ListenUserCommand) RegisterFlags

func (cmd *ListenUserCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*ListenUserCommand) Run

func (cmd *ListenUserCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the ListenUserCommand command.

type RecommendRecommendationsCommand

type RecommendRecommendationsCommand struct {
	// Maximum number of recommendations to be returned to the user. Set to zero to use server's default.
	Limit int
	// ID of the user these recommendations are meant for.
	UserID      string
	PrettyPrint bool
}

RecommendRecommendationsCommand is the command line data structure for the recommend action of recommendations

func (*RecommendRecommendationsCommand) RegisterFlags

func (cmd *RecommendRecommendationsCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*RecommendRecommendationsCommand) Run

Run makes the HTTP request corresponding to the RecommendRecommendationsCommand command.

type ShowMusicCommand

type ShowMusicCommand struct {
	ID          string
	PrettyPrint bool
}

ShowMusicCommand is the command line data structure for the show action of music

func (*ShowMusicCommand) RegisterFlags

func (cmd *ShowMusicCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*ShowMusicCommand) Run

func (cmd *ShowMusicCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the ShowMusicCommand command.

type ShowUserCommand

type ShowUserCommand struct {
	ID          string
	PrettyPrint bool
}

ShowUserCommand is the command line data structure for the show action of user

func (*ShowUserCommand) RegisterFlags

func (cmd *ShowUserCommand) RegisterFlags(cc *cobra.Command, c *client.Client)

RegisterFlags registers the command flags with the command line.

func (*ShowUserCommand) Run

func (cmd *ShowUserCommand) Run(c *client.Client, args []string) error

Run makes the HTTP request corresponding to the ShowUserCommand command.

Jump to

Keyboard shortcuts

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