export type * from "./types"
export {
DEFAULT_GITHUB_ACCOUNT,
GITHUB_API_BASE_URL,
GitHubRequestError,
accounts,
getAccountInfo,
getViewer,
resolveIntegrationName,
graphql,
paginate,
request,
} from "./core"
import { DEFAULT_GITHUB_ACCOUNT, accounts } from "./core"
/**
* Describe the GitHub package and its documented export surface.
*/
export default async function describeGithubPackage() {
return {
package: "@kentcdodds/github",
kodyId: "github",
formerly: ["github-toolkit", "github-pr-tools"],
purpose: "Account-aware GitHub REST, GraphQL, and pull request helpers for Kody agents.",
defaultAccount: DEFAULT_GITHUB_ACCOUNT,
accounts: accounts(),
exports: {
request: "Make a normalized GitHub REST request.",
graphql: "Make a normalized GitHub GraphQL request.",
paginate: "Follow GitHub REST Link pagination for array endpoints.",
getViewer: "Verify which GitHub identity a selected account uses.",
accounts: "List account aliases and selection guidance.",
"pr/get-info": "Fetch pull request details.",
"pr/get-checks": "Fetch check-run status for a pull request's head commit.",
"pr/merge": "Merge a pull request.",
"pr/set-review-status": "Set a pull request to draft, ready-for-review, or toggle between them.",
"actions/put-secret": "Create or update a GitHub Actions secret without returning the plaintext.",
},
}
}