@sentry/junior-github 0.297.0 → 0.298.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { type PluginEgress } from "@sentry/junior-plugin-api";
|
|
2
|
+
/** Add the App bot's reaction to an issue or pull request itself. */
|
|
3
|
+
export declare function createGitHubReactToIssueTool(egress: PluginEgress): import("@sentry/junior-plugin-api").PluginToolDefinition<{
|
|
4
|
+
repo: string;
|
|
5
|
+
number: number;
|
|
6
|
+
content: "+1" | "-1" | "confused" | "eyes" | "heart" | "hooray" | "laugh" | "rocket";
|
|
7
|
+
}, {
|
|
8
|
+
[x: string]: unknown;
|
|
9
|
+
objectAnnotations?: {
|
|
10
|
+
kind: "object";
|
|
11
|
+
key: string;
|
|
12
|
+
label: string;
|
|
13
|
+
objectType: "automation" | "calendar_event" | "code_change" | "deployment" | "item" | "task";
|
|
14
|
+
title: string;
|
|
15
|
+
url: string | null;
|
|
16
|
+
description?: string | undefined;
|
|
17
|
+
status?: string | undefined;
|
|
18
|
+
trigger?: string | undefined;
|
|
19
|
+
warning?: string | undefined;
|
|
20
|
+
displayType?: string | undefined;
|
|
21
|
+
sourceUpdatedAt?: string | undefined;
|
|
22
|
+
facts?: {
|
|
23
|
+
type: "code_change";
|
|
24
|
+
author?: string | undefined;
|
|
25
|
+
sourceBranch?: string | undefined;
|
|
26
|
+
targetBranch?: string | undefined;
|
|
27
|
+
reviewers?: string[] | undefined;
|
|
28
|
+
review?: "approved" | "changes_requested" | "required" | undefined;
|
|
29
|
+
checks?: {
|
|
30
|
+
passed: number;
|
|
31
|
+
failed: number;
|
|
32
|
+
pending: number;
|
|
33
|
+
} | undefined;
|
|
34
|
+
mergeable?: boolean | undefined;
|
|
35
|
+
changedFiles?: number | undefined;
|
|
36
|
+
additions?: number | undefined;
|
|
37
|
+
deletions?: number | undefined;
|
|
38
|
+
} | {
|
|
39
|
+
type: "task";
|
|
40
|
+
assignees?: string[] | undefined;
|
|
41
|
+
priority?: string | undefined;
|
|
42
|
+
project?: string | undefined;
|
|
43
|
+
cycle?: string | undefined;
|
|
44
|
+
dueDate?: string | undefined;
|
|
45
|
+
labels?: string[] | undefined;
|
|
46
|
+
} | {
|
|
47
|
+
type: "deployment";
|
|
48
|
+
project?: string | undefined;
|
|
49
|
+
environment?: string | undefined;
|
|
50
|
+
revision?: string | undefined;
|
|
51
|
+
branch?: string | undefined;
|
|
52
|
+
} | {
|
|
53
|
+
type: "calendar_event";
|
|
54
|
+
when?: string | undefined;
|
|
55
|
+
attendees?: string[] | undefined;
|
|
56
|
+
} | undefined;
|
|
57
|
+
}[] | undefined;
|
|
58
|
+
reply?: {
|
|
59
|
+
text: string;
|
|
60
|
+
url?: string | undefined;
|
|
61
|
+
} | undefined;
|
|
62
|
+
truncated?: boolean | undefined;
|
|
63
|
+
continuation?: {
|
|
64
|
+
arguments: Record<string, unknown>;
|
|
65
|
+
reason?: string | undefined;
|
|
66
|
+
} | undefined;
|
|
67
|
+
target: "reactToIssue";
|
|
68
|
+
repo: string;
|
|
69
|
+
number: number;
|
|
70
|
+
content: "+1" | "-1" | "confused" | "eyes" | "heart" | "hooray" | "laugh" | "rocket";
|
|
71
|
+
reaction_id: number;
|
|
72
|
+
}, {
|
|
73
|
+
[x: string]: unknown;
|
|
74
|
+
objectAnnotations?: {
|
|
75
|
+
kind: "object";
|
|
76
|
+
key: string;
|
|
77
|
+
label: string;
|
|
78
|
+
objectType: "automation" | "calendar_event" | "code_change" | "deployment" | "item" | "task";
|
|
79
|
+
title: string;
|
|
80
|
+
url: string | null;
|
|
81
|
+
description?: string | undefined;
|
|
82
|
+
status?: string | undefined;
|
|
83
|
+
trigger?: string | undefined;
|
|
84
|
+
warning?: string | undefined;
|
|
85
|
+
displayType?: string | undefined;
|
|
86
|
+
sourceUpdatedAt?: string | undefined;
|
|
87
|
+
facts?: {
|
|
88
|
+
type: "code_change";
|
|
89
|
+
author?: string | undefined;
|
|
90
|
+
sourceBranch?: string | undefined;
|
|
91
|
+
targetBranch?: string | undefined;
|
|
92
|
+
reviewers?: string[] | undefined;
|
|
93
|
+
review?: "approved" | "changes_requested" | "required" | undefined;
|
|
94
|
+
checks?: {
|
|
95
|
+
passed: number;
|
|
96
|
+
failed: number;
|
|
97
|
+
pending: number;
|
|
98
|
+
} | undefined;
|
|
99
|
+
mergeable?: boolean | undefined;
|
|
100
|
+
changedFiles?: number | undefined;
|
|
101
|
+
additions?: number | undefined;
|
|
102
|
+
deletions?: number | undefined;
|
|
103
|
+
} | {
|
|
104
|
+
type: "task";
|
|
105
|
+
assignees?: string[] | undefined;
|
|
106
|
+
priority?: string | undefined;
|
|
107
|
+
project?: string | undefined;
|
|
108
|
+
cycle?: string | undefined;
|
|
109
|
+
dueDate?: string | undefined;
|
|
110
|
+
labels?: string[] | undefined;
|
|
111
|
+
} | {
|
|
112
|
+
type: "deployment";
|
|
113
|
+
project?: string | undefined;
|
|
114
|
+
environment?: string | undefined;
|
|
115
|
+
revision?: string | undefined;
|
|
116
|
+
branch?: string | undefined;
|
|
117
|
+
} | {
|
|
118
|
+
type: "calendar_event";
|
|
119
|
+
when?: string | undefined;
|
|
120
|
+
attendees?: string[] | undefined;
|
|
121
|
+
} | undefined;
|
|
122
|
+
}[] | undefined;
|
|
123
|
+
reply?: {
|
|
124
|
+
text: string;
|
|
125
|
+
url?: string | undefined;
|
|
126
|
+
} | undefined;
|
|
127
|
+
truncated?: boolean | undefined;
|
|
128
|
+
continuation?: {
|
|
129
|
+
arguments: Record<string, unknown>;
|
|
130
|
+
reason?: string | undefined;
|
|
131
|
+
} | undefined;
|
|
132
|
+
target: "reactToIssue";
|
|
133
|
+
repo: string;
|
|
134
|
+
number: number;
|
|
135
|
+
content: "+1" | "-1" | "confused" | "eyes" | "heart" | "hooray" | "laugh" | "rocket";
|
|
136
|
+
reaction_id: number;
|
|
137
|
+
}>;
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
import { type PluginEgress } from "@sentry/junior-plugin-api";
|
|
2
|
+
/**
|
|
3
|
+
* Replace the body of an issue or pull request conversation comment that the
|
|
4
|
+
* App bot posted. Comments by other users are refused before the write.
|
|
5
|
+
*/
|
|
6
|
+
export declare function createGitHubUpdateIssueCommentTool(egress: PluginEgress, botEmail: string | undefined): import("@sentry/junior-plugin-api").PluginToolDefinition<{
|
|
7
|
+
repo: string;
|
|
8
|
+
comment_id: number;
|
|
9
|
+
body: string;
|
|
10
|
+
}, {
|
|
11
|
+
[x: string]: unknown;
|
|
12
|
+
objectAnnotations?: {
|
|
13
|
+
kind: "object";
|
|
14
|
+
key: string;
|
|
15
|
+
label: string;
|
|
16
|
+
objectType: "automation" | "calendar_event" | "code_change" | "deployment" | "item" | "task";
|
|
17
|
+
title: string;
|
|
18
|
+
url: string | null;
|
|
19
|
+
description?: string | undefined;
|
|
20
|
+
status?: string | undefined;
|
|
21
|
+
trigger?: string | undefined;
|
|
22
|
+
warning?: string | undefined;
|
|
23
|
+
displayType?: string | undefined;
|
|
24
|
+
sourceUpdatedAt?: string | undefined;
|
|
25
|
+
facts?: {
|
|
26
|
+
type: "code_change";
|
|
27
|
+
author?: string | undefined;
|
|
28
|
+
sourceBranch?: string | undefined;
|
|
29
|
+
targetBranch?: string | undefined;
|
|
30
|
+
reviewers?: string[] | undefined;
|
|
31
|
+
review?: "approved" | "changes_requested" | "required" | undefined;
|
|
32
|
+
checks?: {
|
|
33
|
+
passed: number;
|
|
34
|
+
failed: number;
|
|
35
|
+
pending: number;
|
|
36
|
+
} | undefined;
|
|
37
|
+
mergeable?: boolean | undefined;
|
|
38
|
+
changedFiles?: number | undefined;
|
|
39
|
+
additions?: number | undefined;
|
|
40
|
+
deletions?: number | undefined;
|
|
41
|
+
} | {
|
|
42
|
+
type: "task";
|
|
43
|
+
assignees?: string[] | undefined;
|
|
44
|
+
priority?: string | undefined;
|
|
45
|
+
project?: string | undefined;
|
|
46
|
+
cycle?: string | undefined;
|
|
47
|
+
dueDate?: string | undefined;
|
|
48
|
+
labels?: string[] | undefined;
|
|
49
|
+
} | {
|
|
50
|
+
type: "deployment";
|
|
51
|
+
project?: string | undefined;
|
|
52
|
+
environment?: string | undefined;
|
|
53
|
+
revision?: string | undefined;
|
|
54
|
+
branch?: string | undefined;
|
|
55
|
+
} | {
|
|
56
|
+
type: "calendar_event";
|
|
57
|
+
when?: string | undefined;
|
|
58
|
+
attendees?: string[] | undefined;
|
|
59
|
+
} | undefined;
|
|
60
|
+
}[] | undefined;
|
|
61
|
+
reply?: {
|
|
62
|
+
text: string;
|
|
63
|
+
url?: string | undefined;
|
|
64
|
+
} | undefined;
|
|
65
|
+
truncated?: boolean | undefined;
|
|
66
|
+
continuation?: {
|
|
67
|
+
arguments: Record<string, unknown>;
|
|
68
|
+
reason?: string | undefined;
|
|
69
|
+
} | undefined;
|
|
70
|
+
target: "updateIssueComment";
|
|
71
|
+
repo: string;
|
|
72
|
+
comment_id: number;
|
|
73
|
+
url: string;
|
|
74
|
+
}, {
|
|
75
|
+
[x: string]: unknown;
|
|
76
|
+
objectAnnotations?: {
|
|
77
|
+
kind: "object";
|
|
78
|
+
key: string;
|
|
79
|
+
label: string;
|
|
80
|
+
objectType: "automation" | "calendar_event" | "code_change" | "deployment" | "item" | "task";
|
|
81
|
+
title: string;
|
|
82
|
+
url: string | null;
|
|
83
|
+
description?: string | undefined;
|
|
84
|
+
status?: string | undefined;
|
|
85
|
+
trigger?: string | undefined;
|
|
86
|
+
warning?: string | undefined;
|
|
87
|
+
displayType?: string | undefined;
|
|
88
|
+
sourceUpdatedAt?: string | undefined;
|
|
89
|
+
facts?: {
|
|
90
|
+
type: "code_change";
|
|
91
|
+
author?: string | undefined;
|
|
92
|
+
sourceBranch?: string | undefined;
|
|
93
|
+
targetBranch?: string | undefined;
|
|
94
|
+
reviewers?: string[] | undefined;
|
|
95
|
+
review?: "approved" | "changes_requested" | "required" | undefined;
|
|
96
|
+
checks?: {
|
|
97
|
+
passed: number;
|
|
98
|
+
failed: number;
|
|
99
|
+
pending: number;
|
|
100
|
+
} | undefined;
|
|
101
|
+
mergeable?: boolean | undefined;
|
|
102
|
+
changedFiles?: number | undefined;
|
|
103
|
+
additions?: number | undefined;
|
|
104
|
+
deletions?: number | undefined;
|
|
105
|
+
} | {
|
|
106
|
+
type: "task";
|
|
107
|
+
assignees?: string[] | undefined;
|
|
108
|
+
priority?: string | undefined;
|
|
109
|
+
project?: string | undefined;
|
|
110
|
+
cycle?: string | undefined;
|
|
111
|
+
dueDate?: string | undefined;
|
|
112
|
+
labels?: string[] | undefined;
|
|
113
|
+
} | {
|
|
114
|
+
type: "deployment";
|
|
115
|
+
project?: string | undefined;
|
|
116
|
+
environment?: string | undefined;
|
|
117
|
+
revision?: string | undefined;
|
|
118
|
+
branch?: string | undefined;
|
|
119
|
+
} | {
|
|
120
|
+
type: "calendar_event";
|
|
121
|
+
when?: string | undefined;
|
|
122
|
+
attendees?: string[] | undefined;
|
|
123
|
+
} | undefined;
|
|
124
|
+
}[] | undefined;
|
|
125
|
+
reply?: {
|
|
126
|
+
text: string;
|
|
127
|
+
url?: string | undefined;
|
|
128
|
+
} | undefined;
|
|
129
|
+
truncated?: boolean | undefined;
|
|
130
|
+
continuation?: {
|
|
131
|
+
arguments: Record<string, unknown>;
|
|
132
|
+
reason?: string | undefined;
|
|
133
|
+
} | undefined;
|
|
134
|
+
target: "updateIssueComment";
|
|
135
|
+
repo: string;
|
|
136
|
+
comment_id: number;
|
|
137
|
+
url: string;
|
|
138
|
+
}>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sentry/junior-github",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.298.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"drizzle-orm": "^0.45.2",
|
|
33
33
|
"marked": "^18.1.2",
|
|
34
34
|
"zod": "^4.5.4",
|
|
35
|
-
"@sentry/junior-plugin-api": "0.
|
|
35
|
+
"@sentry/junior-plugin-api": "0.298.0"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
38
|
"@oxlint/plugins": "1.79.0",
|
|
@@ -5,7 +5,7 @@ description: Create, update, comment on, label, and inspect GitHub issues with c
|
|
|
5
5
|
|
|
6
6
|
# GitHub Issue Operations
|
|
7
7
|
|
|
8
|
-
Create issues with `github_createIssue`. Read one issue with `github_getIssue`. Update issue title, body, or state with `github_updateIssue`. Comment with `github_commentOnIssue`. Use `gh` for reading comments, labels, and issue lists.
|
|
8
|
+
Create issues with `github_createIssue`. Read one issue with `github_getIssue`. Update issue title, body, or state with `github_updateIssue`. Comment with `github_commentOnIssue`, and edit your own comment with `github_updateIssueComment`. Use `gh` for reading comments, labels, and issue lists.
|
|
9
9
|
Use only for GitHub issues. For pull requests, branches, pushes, or PR creation order questions, load `github-code` instead.
|
|
10
10
|
|
|
11
11
|
## Reference loading
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# GitHub Issue API Surface
|
|
2
2
|
|
|
3
|
-
Issue creation uses `github_createIssue`, one-issue reads use `github_getIssue`, title, body, and state updates use `github_updateIssue`,
|
|
3
|
+
Issue creation uses `github_createIssue`, one-issue reads use `github_getIssue`, title, body, and state updates use `github_updateIssue`, new comments use `github_commentOnIssue`, edits of your own comments use `github_updateIssueComment`, and reactions on an issue use `github_reactToIssue`. Comment reads, labels, assignees, and issue lists use `gh`; generic GraphQL-backed `gh issue` mutations are not supported.
|
|
4
4
|
|
|
5
5
|
## Repo scoping
|
|
6
6
|
|
|
@@ -28,6 +28,8 @@ Treat explicit repo flags as command-targeting safety rails, not as a credential
|
|
|
28
28
|
| Add assignees | `gh api repos/owner/repo/issues/NUMBER/assignees --method POST --input assignees.json` |
|
|
29
29
|
| Remove assignees | `gh api repos/owner/repo/issues/NUMBER/assignees --method DELETE --input assignees.json` |
|
|
30
30
|
| Add comment | `github_commentOnIssue({ repo: "owner/repo", number: NUMBER, body: "..." })` |
|
|
31
|
+
| Edit own comment | `github_updateIssueComment({ repo: "owner/repo", comment_id: ID, body: "..." })` |
|
|
32
|
+
| React to issue | `github_reactToIssue({ repo: "owner/repo", number: NUMBER, content: "eyes" })` |
|
|
31
33
|
| List issues | `gh issue list --repo owner/repo --json number,title,state,url --limit 20` |
|
|
32
34
|
| Read issue | `github_getIssue({ repo: "owner/repo", number: NUMBER })` |
|
|
33
35
|
| Read comments | `gh api /repos/owner/repo/issues/NUMBER/comments --method GET --header "Accept: application/vnd.github+json"` |
|