requests

package
v0.0.0-...-11fd557 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddVote

func AddVote(poll *polls.Poll, vote interface{}) error

AddVote adds your vote to a poll

func ClosePoll

func ClosePoll(id int, api string) error

ClosePoll closes survey poll to further answers (reversible)

func CreatePoll

func CreatePoll(poll interface{}, api string) (int, error)

Creates a new poll with a generic poll interface{} and returns the poll_id

func DeletePoll

func DeletePoll(id int, api string) error

DeletePoll deletes a poll

func EditPoll

func EditPoll(id int, api, privacy string, settings *polls.Settings) error

EditPoll edits settings of an existing poll

func EditVote

func EditVote(poll *polls.Poll, vote interface{}) error

EditVote edits your vote to a poll

func GetActivePolls

func GetActivePolls(api string) ([]*polls.Poll, error)

Returns only active polls stored in MasterPoll database.

func GetAllPolls

func GetAllPolls(api string) ([]*polls.Poll, error)

Returns all your polls stored in MasterPoll database.

func GetGraph

func GetGraph(id int, color, typeChart, api string) (string, error)

GetGraph returns a graph URL representing the poll

func GetPoll

func GetPoll(id int, api string) (*polls.Poll, error)

Gets an existent Poll from its id

func Me

func Me(api string) ([]string, error)

Me returns information about you stored in MasterPoll database.

func OpenPoll

func OpenPoll(id int, api string) error

OpenPoll opens a closed poll

func RemoveVote

func RemoveVote(poll *polls.Poll, choice string) error

RemoveVote removes your vote to a poll

func Status

func Status() bool

Status returns status of the API as bool

func Subscribers

func Subscribers(api string) (int, error)

Subscribers returns current bot subscribers

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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