Review Request Last Update Resource¶
Provides information on the last update made to a review request.
Clients can periodically poll this to see if any new updates have been made.
Details¶
Name | last_update |
URI | /api/review-requests/{review_request_id}/last-update/ |
Token Policy ID | review_request_last_update |
HTTP Methods |
|
Parent Resource | |
Child Resources | None |
Fields¶
summaryString | A short summary of the update. This should be one of “Review request updated”, “Diff updated”, “New reply” or “New review”. |
timestamp | The timestamp of this most recent update. |
typeOne of review-request , diff , reply , review |
The type of the last update. |
userString | The username for the user who made the last update. |
Links¶
Name |
Method |
Resource |
---|---|---|
self | GET |
HTTP GET¶
Returns the last update made to the review request.
This shows the type of update that was made, the user who made the update, and when the update was made. Clients can use this to inform the user that the review request was updated, or automatically update it in the background.
This does not take into account changes to a draft review request, as that’s generally not update information that the owner of the draft is interested in. Only public updates are represented.
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. |
Examples¶
application/vnd.reviewboard.org.last-update+json¶
$ curl https://reviews.example.com/api/review-requests/10/last-update/ -H "Accept: application/json"
HTTP 200 OK
Content-Length: 1412
Content-Type: application/vnd.reviewboard.org.last-update+json
ETag: c039c89ab6df39fa4b4f4ddc6b7256e8b21de92c
Vary: Accept, Cookie
X-Content-Type-Options: nosniff
{
"last_update": {
"summary": "Diff updated",
"timestamp": "2018-08-10T22:16:47Z",
"type": "diff",
"user": {
"avatar_html": null,
"avatar_url": "https://secure.gravatar.com/avatar/b0f1ae4342591db2695fb11313114b3e?s=48&d=mm",
"avatar_urls": {
"1x": "https://secure.gravatar.com/avatar/b0f1ae4342591db2695fb11313114b3e?s=48&d=mm",
"2x": "https://secure.gravatar.com/avatar/b0f1ae4342591db2695fb11313114b3e?s=96&d=mm",
"3x": "https://secure.gravatar.com/avatar/b0f1ae4342591db2695fb11313114b3e?s=144&d=mm"
},
"email": "doc@example.com",
"first_name": "Doc",
"fullname": "Doc Dwarf",
"id": 2,
"is_active": true,
"last_name": "Dwarf",
"links": {
"api_tokens": {
"href": "https://reviews.example.com/api/users/doc/api-tokens/",
"method": "GET"
},
"archived_review_requests": {
"href": "https://reviews.example.com/api/users/doc/archived-review-requests/",
"method": "GET"
},
"muted_review_requests": {
"href": "https://reviews.example.com/api/users/doc/muted-review-requests/",
"method": "GET"
},
"self": {
"href": "https://reviews.example.com/api/users/doc/",
"method": "GET"
},
"update": {
"href": "https://reviews.example.com/api/users/doc/",
"method": "PUT"
},
"user_file_attachments": {
"href": "https://reviews.example.com/api/users/doc/user-file-attachments/",
"method": "GET"
},
"watched": {
"href": "https://reviews.example.com/api/users/doc/watched/",
"method": "GET"
}
},
"url": "/users/doc/",
"username": "doc"
}
},
"stat": "ok"
}