mirror of
https://github.com/spacebarchat/spacebarchat.git
synced 2024-11-25 20:02:55 +01:00
added docs
This commit is contained in:
parent
f2b3fea9b9
commit
c02ec1eea5
@ -10,6 +10,10 @@ class GithubNotionSync {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns array of urls in the following form:
|
||||
* https://api.github.com/repos/${this.org}/${repo_name}/issues
|
||||
*/
|
||||
async getAllIssueUrls() {
|
||||
let repos = await fetch(`${this.urls.base}orgs/${this.org}/repos`, {
|
||||
headers: {
|
||||
@ -22,6 +26,21 @@ class GithubNotionSync {
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param repoIssueUrl element of array returned by `getAllIssueUrls()`
|
||||
* @returns array of issues for the given repo in the following json form:
|
||||
* ```
|
||||
* {
|
||||
* url: 'https://api.github.com/repos/fosscord/fosscord-api/issues/78',
|
||||
* title: '[Route] /guilds/:id/regions',
|
||||
* body: '- [ ] regions',
|
||||
* number: 78,
|
||||
* state: 'open',
|
||||
* label: 'Route',
|
||||
* assignee: 'Stylix58'
|
||||
* }
|
||||
* ```
|
||||
*/
|
||||
async getAllIssuesPerRepo(repoIssueUrl) {
|
||||
let issues = await fetch(repoIssueUrl, {
|
||||
headers: {
|
||||
|
Loading…
Reference in New Issue
Block a user