imgur

package
v0.0.0-...-a1f28de Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2017 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ClientID = ""
)

Functions

func Delete

func Delete(hash string) (*bool, error)

Types

type Answer

type Answer struct {
	Data    json.RawMessage `json:"data"`
	Success bool            `json:"success"`
	Status  int             `json:"status"`
}

type Data

type Data struct {
	ID          string   `json:"id"`
	Title       string   `json:"title"`
	Description string   `json:"description"`
	DateTime    int      `json:"datetime"`
	Type        string   `json:"type"`
	Animated    bool     `json:"animated"`
	Width       int      `json:"width"`
	Height      int      `json:"height"`
	Size        int      `json:"size"`
	Views       int      `json:"views"`
	Bandwidth   int      `json:"bandwidth"`
	Vote        string   `json:"vote"`
	Favorite    bool     `json:"favorite"`
	Nsfw        string   `json:"nsfw"`
	Section     string   `json:"section"`
	AccountURL  string   `json:"account_url"`
	AccountID   int      `json:"account_id"`
	IsAd        bool     `json:"is_ad"`
	InMostViral bool     `json:"in_most_viral"`
	Tags        []string `json:"tags"`
	AdType      int      `json:"ad_type"`
	AdURL       string   `json:"ad_url"`
	InGallery   bool     `json:"in_gallery"`
	DeleteHash  string   `json:"deletehash"`
	Name        string   `json:"name"`
	Link        string   `json:"link"`
}

func Upload

func Upload(filename string) (*Data, error)

type Error

type Error struct {
	Error   string `json:"error"`
	Request string `json:"request"`
	Method  string `json:"method"`
}

Jump to

Keyboard shortcuts

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