1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
|
// SonarQube, open source software quality management tool.
// Copyright (C) 2008-2016 SonarSource
// mailto:contact AT sonarsource DOT com
//
// SonarQube is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 3 of the License, or (at your option) any later version.
//
// SonarQube is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with this program; if not, write to the Free Software Foundation,
// Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
syntax = "proto2";
package sonarqube.ws.issues;
import "ws-commons.proto";
option java_package = "org.sonarqube.ws";
option java_outer_classname = "Issues";
option optimize_for = SPEED;
// Response of GET api/issues/search
message SearchWsResponse {
reserved 5;
optional int64 total = 1;
optional int64 p = 2;
optional int32 ps = 3;
optional sonarqube.ws.commons.Paging paging = 4;
// Total amount of effort, only when the facet "total" is enabled
optional int64 effortTotal = 13;
repeated Issue issues = 6;
repeated Component components = 7;
optional sonarqube.ws.commons.Rules rules = 8;
optional Users users = 9;
// Deprecated since 5.5, action plan has been removed
optional ActionPlans unusedActionPlans = 10;
optional Languages languages = 11;
optional sonarqube.ws.commons.Facets facets = 12;
}
message Operation {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message AddCommentResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message AssignResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message DeleteCommentResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message DoTransitionResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message SetSeverityResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message SetTagsResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message SetTypeResponse {
optional Issue issue = 1;
repeated Component components = 2;
repeated sonarqube.ws.commons.Rule rules = 3;
repeated sonarqube.ws.commons.User users = 4;
}
message TagsResponse {
repeated string tags = 1;
}
message Issue {
reserved 29; //drop organization
optional string key = 1;
optional string rule = 2;
optional sonarqube.ws.commons.Severity severity = 3;
optional string component = 4;
optional int64 unusedComponentId = 5;
optional string project = 6;
reserved 7; // drop subProject
optional int32 line = 8;
optional string hash = 31;
optional sonarqube.ws.commons.TextRange textRange = 9;
repeated sonarqube.ws.commons.Flow flows = 10;
optional string resolution = 11;
optional string status = 12;
optional string message = 13;
optional string effort = 28;
// Deprecated since 5.5, replaced by effort
optional string debt = 14;
optional string assignee = 15;
// Unused since 5.5, manual issues feature has been removed
optional string unusedReporter = 16;
// SCM login of the committer who introduced the issue
optional string author = 17;
// Deprecated since 5.5, action plan has been removed
optional string actionPlan = 18;
repeated string tags = 19;
// the transitions allowed for the requesting user.
optional Transitions transitions = 20;
// the actions allowed for the requesting user.
optional Actions actions = 21;
optional Comments comments = 22;
optional string creationDate = 23;
optional string updateDate = 24;
optional string fUpdateAge = 25;
optional string closeDate = 26;
optional sonarqube.ws.commons.RuleType type = 27;
optional string branch = 30;
optional string pullRequest = 32;
optional string externalRuleEngine = 33;
reserved 34; //drop fromHotspot
optional string scope = 35;
optional bool quickFixAvailable = 36;
optional string ruleDescriptionContextKey = 37;
}
message Transitions {
repeated string transitions = 1;
}
message Actions {
repeated string actions = 1;
}
message Comments {
repeated sonarqube.ws.commons.Comment comments = 1;
}
// Deprecated since 5.5
message ActionPlan {
optional string key = 1;
optional string name = 2;
// TODO define enum
optional string status = 3;
optional string deadLine = 4;
// TODO to be renamed, is it id or key ?
optional string project = 5;
}
// Deprecated since 5.5
message ActionPlans {
repeated ActionPlan actionPlans = 1;
}
message Language {
optional string key = 1;
optional string name = 2;
}
message Languages {
repeated Language languages = 1;
}
message Component {
reserved 3, 11; //drop organization
optional int64 deprecatedId = 1;
optional string key = 2;
optional bool enabled = 4;
optional string qualifier = 5;
optional string name = 6;
optional string longName = 7;
optional string path = 8;
optional int64 unusedProjectId = 9;
optional int64 unusedSubProjectId = 10;
optional string branch = 12;
optional string pullRequest = 13;
}
// Response of GET api/issues/changelog
message ChangelogWsResponse {
repeated sonarqube.ws.commons.Changelog changelog = 1;
}
// Response of POST api/issues/bulk_change
message BulkChangeWsResponse {
optional int64 total = 1;
optional int64 success = 2;
optional int64 ignored = 3;
optional int64 failures = 4;
}
message Users {
repeated sonarqube.ws.commons.User users = 1;
}
// Response of GET api/issues/authors
message AuthorsResponse {
repeated string authors = 1;
}
// Response of GET api/issues/pull
message IssuesPullQueryTimestamp {
required int64 queryTimestamp = 1;
}
message TextRange {
optional int32 startLine = 1;
optional int32 startLineOffset = 2;
optional int32 endLine = 3;
optional int32 endLineOffset = 4;
optional string hash = 5;
}
message Location {
optional string filePath = 1;
optional string message = 2;
optional TextRange textRange = 3;
}
message IssueLite {
required string key = 1;
optional int64 creationDate = 2;
optional bool resolved = 3;
optional string ruleKey = 4;
optional sonarqube.ws.commons.Severity userSeverity = 5;
optional sonarqube.ws.commons.RuleType type = 6;
optional Location mainLocation = 7;
optional bool closed = 8;
}
// Response of GET api/issues/pull_taint
message TaintVulnerabilityPullQueryTimestamp {
required int64 queryTimestamp = 1;
}
message TaintVulnerabilityLite {
required string key = 1;
optional int64 creationDate = 2;
optional bool resolved = 3;
optional string ruleKey = 4;
optional sonarqube.ws.commons.Severity severity = 5;
optional sonarqube.ws.commons.RuleType type = 6;
optional Location mainLocation = 7;
optional bool closed = 8;
repeated Flow flows = 9;
optional bool assignedToSubscribedUser = 10;
}
message Flow {
repeated Location locations = 1;
optional string description = 2;
optional sonarqube.ws.commons.FlowType type = 3;
}
|