ghify-request
Create a Request wrapper to interact with the GitHub API
const ghifyRequest = ;const request = ; const ghifiedRequest = ;
Installation
npm install ghify-request
API
const ghifyRequest = ;
ghifyRequest(request[, options])
request: Function
(Request
function)
options: Object
(Request
options)
Return: Function
(new Request
wrapper)
It returns a Request
wrapper that defaults to the options for easily interacting with the GitHub API.
options.token
Type: String
Default: process.env.GITHUB_TOKEN
Use specific GitHub access token.
const ghifyRequest = ;const request = ; // https://developer.github.com/v3/gists/#star-a-gist;
options.baseUrl
Type: String
Default: process.env.GITHUB_ENDPOINT
if available, otherwise 'https://api.github.com'
Use the different endpoint to support Github enterprise.
License
Copyright (c) 2015 - 2016 Shinnosuke Watanabe
Licensed under the MIT License.