Review Reply Resource¶
Provides information on a reply to a review.
A reply is much like a review, but is always tied to exactly one parent review. Every comment associated with a reply is also tied to a parent comment.
Details¶
Name | reply |
URI | /api/review-requests/{review_request_id}/reviews/{review_id}/replies/{reply_id}/ |
Token Policy ID | review_reply |
HTTP Methods | |
Parent Resource | Review Reply List Resource |
Child Resources | |
Anonymous Access | Yes, if anonymous site access is enabled |
Fields¶
body_bottomRich Text | The response to the review content below the comments. |
body_bottom_text_typeOne of plain , markdown , html |
The current or forced text type for the body_bottom field. Added in 2.0.12 |
body_topRich Text | The response to the review content above the comments. |
body_top_text_typeOne of plain , markdown , html |
The current or forced text type for the body_top field. Added in 2.0.12 |
extra_dataDictionary | Extra data as part of the reply. This can be set by the API or extensions. Added in 2.0 |
idInteger | The numeric ID of the reply. |
publicBoolean | Whether or not the reply is currently visible to other users. |
text_typeOne of plain , markdown , html |
Deprecated Formerly responsible for indicating the text type for text fields. Replaced by body_top_text_type and body_bottom_text_type in 2.0.12. Added in 2.0 Deprecated in 2.0.12 |
timestampString | The date and time that the reply was posted (in YYYY-MM-DD HH:MM:SS format). |
userUser Resource | The user who wrote the reply. |
Links¶
Name | Method | Resource |
---|---|---|
delete | DELETE | Review Reply Resource |
diff_comments | GET | Review Reply Diff Comment List Resource |
file_attachment_comments | GET | Review Reply File Attachment Comment List Resource |
screenshot_comments | GET | Review Reply Screenshot Comment List Resource |
self | GET | Review Reply Resource |
update | PUT | Review Reply Resource |
HTTP DELETE¶
Deletes the draft review.
This only works for draft reviews, not public reviews. It will delete the review and all comments on it. This cannot be undone.
Only the user who owns the draft can delete it.
Upon deletion, 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 |
HTTP GET¶
Returns information on a particular reply.
If the reply is not public, then the client’s logged in user must either be the owner of the reply. Otherwise, an error will be returned.
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 |
HTTP PUT¶
Updates a reply.
This updates the fields of a draft reply. Published replies cannot be updated.
Only the owner of a reply can make changes. One or more fields can be updated at once.
The only special field is public
, which, if set to true, will
publish the reply. The reply will then be made publicly visible. Once
public, the reply cannot be modified or made private again.
Extra data can be stored on the reply for later lookup by passing
extra_data.key_name=value
. The key_name
and value
can
be any valid strings. Passing a blank value
will remove the key.
The extra_data.
prefix is required.
Request Parameters¶
body_bottomRich Text | The response to the review content below the comments. |
body_bottom_text_typeOne of plain , markdown |
The text type used for the body_bottom field. Added in 2.0.12 |
body_topRich Text | The response to the review content above the comments. |
body_top_text_typeOne of plain , markdown |
The text type used for the body_top field. Added in 2.0.12 |
force_text_typeOne of plain , markdown , html |
The text type, if any, to force for returned text fields. The contents will be converted to the requested type in the payload, but will not be saved as that type. Added in 2.0.9 |
publicBoolean | Whether or not to make the reply public. If a reply is public, it cannot be made private again. |
text_typeOne of plain , markdown |
Deprecated The mode for the body_top and body_bottom text fields. This is deprecated. Please use body_top_text_type and body_bottom_text_type instead. Added in 2.0 Deprecated in 2.0.12 |
trivialBoolean | If true, the review does not send an email. Added in 2.5 |
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 |
Examples¶
application/vnd.reviewboard.org.review-reply+json¶
$ curl http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/ -H "Accept: application/json"
Vary: Accept, Cookie
ETag: 2ddaa08449ab3d8baff7e61d24deba3bb8240598
Content-Type: application/vnd.reviewboard.org.review-reply+json
X-Content-Type-Options: nosniff
{
"reply": {
"body_bottom": "",
"body_bottom_text_type": "plain",
"body_top": "Excellent point.",
"body_top_text_type": "plain",
"extra_data": {},
"id": 10,
"links": {
"delete": {
"href": "http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/",
"method": "DELETE"
},
"diff_comments": {
"href": "http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/diff-comments/",
"method": "GET"
},
"file_attachment_comments": {
"href": "http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/file-attachment-comments/",
"method": "GET"
},
"screenshot_comments": {
"href": "http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/screenshot-comments/",
"method": "GET"
},
"self": {
"href": "http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/",
"method": "GET"
},
"update": {
"href": "http://reviews.example.com/api/review-requests/8/reviews/8/replies/10/",
"method": "PUT"
},
"user": {
"href": "http://reviews.example.com/api/users/admin/",
"method": "GET",
"title": "admin"
}
},
"public": true,
"text_type": null,
"timestamp": "2010-08-28T02:26:47Z"
},
"stat": "ok"
}