1.0.0 • Published 6 years ago
octokit-rest-plugin-add-endpoints v1.0.0
octokit-rest-plugin-add-endpoints
@octokit/rest plugin to add endpoint methods based on a routes.json file
Usage
const octokit = require('@octokit/rest')()
octokit.plugin(require('octokit-rest-plugin-add-endpoints'))
octokit.addEndpoints(require('./my-routes.json'))
octokit.repos.newEndpointGet({
owner: 'octokit',
repo: 'welcome',
foo: 'bar'
})
The my-routes.json
file has to follow the format of @octokit/rest/lib/routes.json
.
License
1.0.0
6 years ago