dblgo

package module
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2019 License: MIT Imports: 6 Imported by: 0

README

Discord Bot List Go API

Simple client for Discord Bot List API, used by Discord Bot Designer app.
Currently only basic operations are possible, but I'm aiming for 100% coverage.

Usage example:

import dblGo

api := dblGo.NewDBLApi("accessToken")
err := api.PostStatsSimple(576) // Send guild count
if err != nil {
	panic(err)
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DBLApi

type DBLApi struct {
	AccessToken    string        // DBL access token
	RequestTimeout time.Duration // Timeout for all requests
}

DBLApi is base api client struct

func NewDBLApi

func NewDBLApi(accessToken string) DBLApi

NewDBLApi returns new DBLApi struct initialized with optimal values

func (DBLApi) PostStatsSimple

func (d DBLApi) PostStatsSimple(guildCount int) error

PostStatsSimple sends bot guild count to the website

Jump to

Keyboard shortcuts

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