query

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package query implements functions for working with Github API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetOrgs

func GetOrgs(tkn string) ([]byte, error)

GetOrgs returns body of request to "https://api.github.com/organizations" for provided Github API access token. Access token should be presented as string. Body is presented as byte array. If http.Get or bodyutil.ReadResponseBody occurs any error, this will be returned.

func GetScopes

func GetScopes(tkn string) ([]string, error)

GetScopes returns scopes provided Github API access token. Acces token should be presented as string. Scopes is presented as string array. If http.Get or headerutil.ReadResponseHeader occurs any error, this will be returned.

func GetUser

func GetUser(tkn string) ([]byte, error)

GetUser returns body of request to "https://api.github.com/user" for provided Github API access token. Access token should be presented as string. Body is presented as byte array. If http.Get or bodyutil.ReadResponseBody occurs any error, this will be returned.

Types

This section is empty.

Jump to

Keyboard shortcuts

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