7
7
- url : /
8
8
tags :
9
9
- name : Project
10
+ - name : Branch
10
11
- name : Commit
11
12
- name : Element
12
13
- name : Relationship
@@ -135,9 +136,9 @@ paths:
135
136
tags :
136
137
- Project
137
138
x-accepts : application/json
138
- /projects/{projectId}/commits :
139
+ /projects/{projectId}/branches :
139
140
get :
140
- operationId : getCommitsByProject
141
+ operationId : getBranchesByProject
141
142
parameters :
142
143
- description : ID of the project
143
144
in : path
@@ -167,7 +168,7 @@ paths:
167
168
application/json :
168
169
schema :
169
170
items :
170
- $ref : ' #/components/schemas/Commit '
171
+ $ref : ' #/components/schemas/Branch '
171
172
type : array
172
173
description : Ok
173
174
" 404 " :
@@ -188,12 +189,12 @@ paths:
188
189
default :
189
190
content : {}
190
191
description : Unexpected response.
191
- summary : Get commits by project
192
+ summary : Get branches by project
192
193
tags :
193
- - Commit
194
+ - Branch
194
195
x-accepts : application/json
195
196
post :
196
- operationId : postCommitByProject
197
+ operationId : postBranchByProject
197
198
parameters :
198
199
- description : ID of the project
199
200
in : path
@@ -206,14 +207,14 @@ paths:
206
207
content :
207
208
application/json :
208
209
schema :
209
- $ref : ' #/components/schemas/Commit '
210
+ $ref : ' #/components/schemas/Branch '
210
211
required : true
211
212
responses :
212
213
" 201 " :
213
214
content :
214
215
application/json :
215
216
schema :
216
- $ref : ' #/components/schemas/Commit '
217
+ $ref : ' #/components/schemas/Branch '
217
218
description : Created
218
219
" 415 " :
219
220
content :
@@ -230,15 +231,15 @@ paths:
230
231
default :
231
232
content : {}
232
233
description : Unexpected response.
233
- summary : Create commit by project
234
+ summary : Create branch by project
234
235
tags :
235
- - Commit
236
+ - Branch
236
237
x-codegen-request-body-name : body
237
238
x-contentType : application/json
238
239
x-accepts : application/json
239
- /projects/{projectId}/commits/{commitId } :
240
+ /projects/{projectId}/branches/{branchId } :
240
241
get :
241
- operationId : getCommitByProjectAndId
242
+ operationId : getBranchesByProjectAndId
242
243
parameters :
243
244
- description : ID of the project
244
245
in : path
@@ -247,9 +248,9 @@ paths:
247
248
schema :
248
249
format : uuid
249
250
type : string
250
- - description : ID of the commit
251
+ - description : ID of the branch
251
252
in : path
252
- name : commitId
253
+ name : branchId
253
254
required : true
254
255
schema :
255
256
format : uuid
@@ -259,7 +260,7 @@ paths:
259
260
content :
260
261
application/json :
261
262
schema :
262
- $ref : ' #/components/schemas/Commit '
263
+ $ref : ' #/components/schemas/Branch '
263
264
description : Ok
264
265
" 404 " :
265
266
content : {}
@@ -279,13 +280,120 @@ paths:
279
280
default :
280
281
content : {}
281
282
description : Unexpected response.
282
- summary : Get commit by project and ID
283
+ summary : Get branch by project and ID
284
+ tags :
285
+ - Branch
286
+ x-accepts : application/json
287
+ /projects/{projectId}/commits :
288
+ get :
289
+ operationId : getCommitsByProject
290
+ parameters :
291
+ - description : ID of the project
292
+ in : path
293
+ name : projectId
294
+ required : true
295
+ schema :
296
+ format : uuid
297
+ type : string
298
+ - description : Page after
299
+ in : query
300
+ name : page[after]
301
+ schema :
302
+ type : string
303
+ - description : Page before
304
+ in : query
305
+ name : page[before]
306
+ schema :
307
+ type : string
308
+ - description : Page size
309
+ in : query
310
+ name : page[size]
311
+ schema :
312
+ type : integer
313
+ responses :
314
+ " 200 " :
315
+ content :
316
+ application/json :
317
+ schema :
318
+ items :
319
+ $ref : ' #/components/schemas/Commit'
320
+ type : array
321
+ description : Ok
322
+ " 404 " :
323
+ content : {}
324
+ description : Not found.
325
+ " 415 " :
326
+ content :
327
+ application/json :
328
+ schema :
329
+ $ref : ' #/components/schemas/Error'
330
+ description : The requested content type is not acceptable.
331
+ " 500 " :
332
+ content :
333
+ application/json :
334
+ schema :
335
+ $ref : ' #/components/schemas/Error'
336
+ description : Internal server error.
337
+ default :
338
+ content : {}
339
+ description : Unexpected response.
340
+ summary : Get commits by project
283
341
tags :
284
342
- Commit
285
343
x-accepts : application/json
286
- /projects/{projectId}/head :
344
+ post :
345
+ operationId : postCommitByProject
346
+ parameters :
347
+ - description : ID of the project
348
+ in : path
349
+ name : projectId
350
+ required : true
351
+ schema :
352
+ format : uuid
353
+ type : string
354
+ - description : ID of the branch - project's default branch if unspecified
355
+ in : query
356
+ name : branchId
357
+ schema :
358
+ format : uuid
359
+ type : string
360
+ requestBody :
361
+ content :
362
+ application/json :
363
+ schema :
364
+ $ref : ' #/components/schemas/Commit'
365
+ required : true
366
+ responses :
367
+ " 201 " :
368
+ content :
369
+ application/json :
370
+ schema :
371
+ $ref : ' #/components/schemas/Commit'
372
+ description : Created
373
+ " 415 " :
374
+ content :
375
+ application/json :
376
+ schema :
377
+ $ref : ' #/components/schemas/Error'
378
+ description : The requested content type is not acceptable.
379
+ " 500 " :
380
+ content :
381
+ application/json :
382
+ schema :
383
+ $ref : ' #/components/schemas/Error'
384
+ description : Internal server error.
385
+ default :
386
+ content : {}
387
+ description : Unexpected response.
388
+ summary : Create commit by project
389
+ tags :
390
+ - Commit
391
+ x-codegen-request-body-name : body
392
+ x-contentType : application/json
393
+ x-accepts : application/json
394
+ /projects/{projectId}/commits/{commitId} :
287
395
get :
288
- operationId : getHeadCommitByProject
396
+ operationId : getCommitByProjectAndId
289
397
parameters :
290
398
- description : ID of the project
291
399
in : path
@@ -294,6 +402,13 @@ paths:
294
402
schema :
295
403
format : uuid
296
404
type : string
405
+ - description : ID of the commit
406
+ in : path
407
+ name : commitId
408
+ required : true
409
+ schema :
410
+ format : uuid
411
+ type : string
297
412
responses :
298
413
" 200 " :
299
414
content :
@@ -319,7 +434,7 @@ paths:
319
434
default :
320
435
content : {}
321
436
description : Unexpected response.
322
- summary : Get head commit by project
437
+ summary : Get commit by project and ID
323
438
tags :
324
439
- Commit
325
440
x-accepts : application/json
@@ -1002,27 +1117,47 @@ components:
1002
1117
content : {}
1003
1118
description : Ok
1004
1119
schemas :
1005
- Record :
1120
+ Project :
1006
1121
example :
1122
+ ' @type ' : Project
1123
+ defaultBranch :
1124
+ id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1125
+ name : name
1126
+ description : description
1007
1127
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1008
1128
properties :
1129
+ ' @type ' :
1130
+ enum :
1131
+ - Project
1132
+ type : string
1133
+ defaultBranch :
1134
+ $ref : ' #/components/schemas/Project_defaultBranch'
1135
+ description :
1136
+ type : string
1009
1137
id :
1010
1138
format : uuid
1011
1139
type : string
1140
+ name :
1141
+ type : string
1012
1142
type : object
1013
- Project :
1143
+ Branch :
1014
1144
example :
1015
- ' @type ' : Project
1145
+ head :
1146
+ id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1147
+ ' @type ' : Branch
1016
1148
name : name
1017
- description : description
1018
1149
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1150
+ owningProject :
1151
+ id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1019
1152
properties :
1020
1153
' @type ' :
1021
1154
enum :
1022
- - Project
1023
- type : string
1024
- description :
1155
+ - Branch
1025
1156
type : string
1157
+ head :
1158
+ $ref : ' #/components/schemas/Branch_head'
1159
+ owningProject :
1160
+ $ref : ' #/components/schemas/Branch_owningProject'
1026
1161
id :
1027
1162
format : uuid
1028
1163
type : string
@@ -1054,7 +1189,7 @@ components:
1054
1189
previousCommit :
1055
1190
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1056
1191
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1057
- containingProject :
1192
+ owningProject :
1058
1193
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1059
1194
properties :
1060
1195
' @type ' :
@@ -1065,13 +1200,13 @@ components:
1065
1200
items :
1066
1201
$ref : ' #/components/schemas/ElementVersion'
1067
1202
type : array
1068
- containingProject :
1069
- $ref : ' #/components/schemas/Commit_containingProject '
1203
+ owningProject :
1204
+ $ref : ' #/components/schemas/Branch_owningProject '
1070
1205
id :
1071
1206
format : uuid
1072
1207
type : string
1073
1208
previousCommit :
1074
- $ref : ' #/components/schemas/Record '
1209
+ $ref : ' #/components/schemas/Branch_head '
1075
1210
type : object
1076
1211
ElementVersion :
1077
1212
example :
@@ -1179,15 +1314,15 @@ components:
1179
1314
where :
1180
1315
' @type ' : PrimitiveConstraint
1181
1316
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1182
- containingProject :
1317
+ owningProject :
1183
1318
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1184
1319
properties :
1185
1320
' @type ' :
1186
1321
enum :
1187
1322
- Query
1188
1323
type : string
1189
- containingProject :
1190
- $ref : ' #/components/schemas/Commit_containingProject '
1324
+ owningProject :
1325
+ $ref : ' #/components/schemas/Branch_owningProject '
1191
1326
id :
1192
1327
format : uuid
1193
1328
type : string
@@ -1259,7 +1394,24 @@ components:
1259
1394
error :
1260
1395
type : string
1261
1396
type : object
1262
- Commit_containingProject :
1397
+ Project_defaultBranch :
1398
+ description : Branch
1399
+ example :
1400
+ id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1401
+ properties :
1402
+ id :
1403
+ format : uuid
1404
+ type : string
1405
+ Branch_head :
1406
+ description : Commit
1407
+ example :
1408
+ id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1409
+ properties :
1410
+ id :
1411
+ format : uuid
1412
+ type : string
1413
+ Branch_owningProject :
1414
+ description : Project
1263
1415
example :
1264
1416
id : 046b6c7f-0b8a-43b9-b35d-6489e6daee91
1265
1417
properties :
0 commit comments