Interact with Discussions
Since QuickBuild 15.0, you can manage build discussions via RESTful APIs. The base URI for changes RESTful APIs is:
/rest/discussions
Show all APIs
| Method | URI | Response Type | Params |
|---|---|---|---|
| GET | /rest/discussions/help | text/html |
List discussions matching the criteria
| Method | URI | Response Type | Params |
|---|---|---|---|
| GET | /rest/discussions | application/json |
|
Delete discussions matching the criteria
| Method | URI | Response Type | Params |
|---|---|---|---|
| DELETE | /rest/discussions | status code: 204 |
|
Create a new discussion
| Method | URI | Response Type | Params |
|---|---|---|---|
| POST | /rest/discussions/build/{buildId} | application/json | buildId in which build to create discussion |
Post body example:
{
"comment": "raw-markup-text-comment",
"author": "someone"
}
here:
- comment: the raw markup text you want to add
- author: by default (leave empty) the author is the user you are using to access the API. If you want to set to a different author, the user accessing API need have
DISCUSSIONS_ADMIN_PERMISSION
Count discussions matching the criteria
| Method | URI | Response Type | Params |
|---|---|---|---|
| GET | /rest/discussions/count | number |
|
Get a discussion
| Method | URI | Response Type | Params |
|---|---|---|---|
| GET | /rest/discussions/{id} | application/json | id - PATH_PARAM Discussion id to list |
Delete a discussion
| Method | URI | Response Type | Params |
|---|---|---|---|
| DELETE | /rest/discussions/{id} | status code: 204 | id - PATH_PARAM Discussion id to list |