Status Update Resource¶
Added in 3.0
Provides status updates on review requests.
A status update is a way for a third-party service or extension to mark some kind of status on a review request. Examples of this could include static analysis tools or continuous integration services.
Status updates may optionally be associated with a change description, in which case they will be shown in that change description box on the review request page. Otherwise, the status update will be shown in a box immediately below the review request details.
Details¶
| Name | status_update |
| URI | /api/review-requests/{review_request_id}/status-updates/{status_update_id}/ |
| Required Features |
|
| Token Policy ID | status_update |
| HTTP Methods | |
| Parent Resource | Status Update List Resource |
| Child Resources | None |
Fields¶
| changeChange Resource | The change to a review request which this status update applies to (for example, the change adding a diff that was built by CI). If this is blank, the status update is for the review request as initially published. |
| descriptionString | A user-visible description of the status update. |
| extra_dataDictionary | Extra data as part of the status update. This can be set by the API or extensions. |
| idInteger | The ID of the status update. |
| reviewReview Resource | A review which corresponds to this status update. |
| service_idString | A unique identifier for the service providing the status update. |
stateOne of pending, done_success, done_failure, error, timed-out |
The current state of the status update. |
| summaryString | A user-visible short summary of the status update. |
| timeoutInteger | An optional timeout for pending status updates, measured in seconds. |
| urlString | An optional URL to link to for more details about the status update. |
| url_textString | The text to use for the link. |
Links¶
| Name | Method | Resource |
|---|---|---|
| delete | DELETE | Status Update Resource |
| self | GET | Status Update Resource |
| update | PUT | Status Update Resource |
HTTP DELETE¶
Deletes the status update permanently.
After a successful delete, this will return HTTP 204 No Content.
Errors¶
| 100 - Does Not ExistHTTP 404 - Not Found | Object does not exist |
| 101 - Permission DeniedHTTP 403 - Forbidden | You don’t have permission for this |
| 103 - Not Logged InHTTP 401 - Unauthorized | You are not logged in |
| 112 - OAuth2 Missing Scope ErrorHTTP 403 - Forbidden | Your OAuth2 token lacks the necessary scopes for this request. |
| 113 - OAuth2 Access Denied ErrorHTTP 403 - Forbidden | OAuth2 token access for this resource is prohibited. |
HTTP GET¶
Returns information on a single status update.
Errors¶
| 100 - Does Not ExistHTTP 404 - Not Found | Object does not exist |
| 101 - Permission DeniedHTTP 403 - Forbidden | You don’t have permission for this |
| 103 - Not Logged InHTTP 401 - Unauthorized | You are not logged in |
| 112 - OAuth2 Missing Scope ErrorHTTP 403 - Forbidden | Your OAuth2 token lacks the necessary scopes for this request. |
| 113 - OAuth2 Access Denied ErrorHTTP 403 - Forbidden | OAuth2 token access for this resource is prohibited. |
HTTP PUT¶
Updates the status update.
Only the owner of a status update can make changes. One or more fields can be updated at once.
Extra data can be stored later lookup. See Storing/Accessing Extra Data for more information.
Request Parameters¶
| change_idInteger | The change to a review request which this status update applies to (for example, the change adding a diff that was built by CI). If this is blank, the status update is for the review request as initially published. |
| descriptionString | A user-visible description of the status update. |
| review_idInteger | A review which corresponds to this status update. |
| service_idString | A unique identifier for the service providing the status update. |
stateOne of pending, not-yet-run, request-run, done-success, done-failure, error |
The current state of the status update. |
| summaryString | A user-visible short summary of the status update. |
| timeoutInteger | An optional timeout for pending status updates, measured in seconds. |
| urlString | A URL to link to for more details about the status update. |
| url_textString | The text to use for the link. |
Errors¶
| 100 - Does Not ExistHTTP 404 - Not Found | Object does not exist |
| 101 - Permission DeniedHTTP 403 - Forbidden | You don’t have permission for this |
| 103 - Not Logged InHTTP 401 - Unauthorized | You are not logged in |
| 105 - Invalid Form DataHTTP 400 - Bad Request | One or more fields had errors |
| 112 - OAuth2 Missing Scope ErrorHTTP 403 - Forbidden | Your OAuth2 token lacks the necessary scopes for this request. |
| 113 - OAuth2 Access Denied ErrorHTTP 403 - Forbidden | OAuth2 token access for this resource is prohibited. |
Examples¶
application/vnd.reviewboard.org.status-update+json¶
$ curl https://reviews.example.com/api/review-requests/8/status-updates/1/ -H "Accept: application/json"
HTTP 200 OK
Content-Length: 714
Content-Type: application/vnd.reviewboard.org.status-update+json
ETag: a7a3021eb66c1f42ec0133d743db57da88aa0d5c
Vary: Accept, Cookie
X-Content-Type-Options: nosniff
{
"stat": "ok",
"status_update": {
"description": "running...",
"extra_data": {},
"id": 1,
"links": {
"change": {
"href": "https://reviews.example.com/api/review-requests/8/changes/1/",
"method": "GET",
"title": "Added a second diff for the interdiff test."
},
"delete": {
"href": "https://reviews.example.com/api/review-requests/8/status-updates/1/",
"method": "DELETE"
},
"self": {
"href": "https://reviews.example.com/api/review-requests/8/status-updates/1/",
"method": "GET"
},
"update": {
"href": "https://reviews.example.com/api/review-requests/8/status-updates/1/",
"method": "PUT"
}
},
"review": null,
"service_id": "reviewbot.pep8",
"state": "timed-out",
"summary": "PEP-8",
"timeout": 20,
"url": "",
"url_text": ""
}
}