gas-github
v0.0.10
Published
Github API client for Google Apps Script
Downloads
5
Readme
GitHub API client for Google Apps Script
Usage
$npm install gas-github
# or
$yarn add gas-github
import * as issues from 'gas-github/lib/issues'
// or
// import { createIssue } from 'gas-github'
declare let global: any
function postIssue() {
const setting = { owner: 'org', repo: 'repo', pat: 'token' }
const issue = issues.createIssue(setting, {title: 'test', body: 'body', labels: ['bug', 'documentation']})
Logger.log(`issue created: ${issue}`)
}
global.postIssue = postIssue
API
/lib/issues
- createIssue
- ref: https://docs.github.com/en/rest/reference/issues#create-an-issue
- listMilestones
- ref: https://docs.github.com/en/rest/reference/issues#list-milestones
/lib/projects
- listRepositoryProjects
- ref: https://docs.github.com/en/rest/reference/projects#list-repository-projects
- listProjectColumns
- ref: https://docs.github.com/en/rest/reference/projects#list-project-columns
- addProjectCardFromIssue
- ref: https://docs.github.com/en/rest/reference/projects#create-a-project-card
Contribution
Welcome contributions and feedbacks!