Package Exports
- @octokit/plugin-rest-endpoint-methods
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@octokit/plugin-rest-endpoint-methods) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
plugin-rest-endpoint-methods.js
Octokit plugin adding one method for all of api.github.com REST API endpoints
Usage
Browsers |
Load <script type="module">
import { Octokit } from "https://cdn.pika.dev/@octokit/core";
import { restEndpointMethods } from "https://cdn.pika.dev/@octokit/plugin-rest-endpoint-methods";
</script> |
---|---|
Node |
Install with const { Octokit } = require("@octokit/core");
const {
restEndpointMethods
} = require("@octokit/plugin-rest-endpoint-methods"); |
const MyOctokit = Octokit.plugin(restEndpointMethods);
const octokit = new MyOctokit({ auth: "secret123" });
// https://developer.github.com/v3/users/#get-the-authenticated-user
octokit.users.getAuthenticated();
There is one method for each REST API endpoint documented at https://developer.github.com/v3. All endpoint methods are documented in the docs/ folder, e.g. docs/users/getAuthenticated.md
Contributing
See CONTRIBUTING.md