How to create a review via REST API

Darren Yeates April 23, 2012

I would like to create a review via the Crucible REST API.

I have an existing changelist ID from Perforce, I would like to create a review, give it an existing changelist ID and for a review to be created and the review ID be returned to me. I would like to do this via the REST API as I am integrating this into a post-commit trigger on Perforce.

Can anyone advise as to how this could be achieved?

2 answers

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

0 votes
Renjith Pillai
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 23, 2012

I am assuming that you referred to the REST documentation here

http://docs.atlassian.com/fisheye-crucible/latest/wadl/crucible.html#d2e116 and http://docs.atlassian.com/fisheye-crucible/latest/wadl/crucible.html#d2e220

Are you facing any problems in using this?

Darren Yeates April 24, 2012

Sure, i've seen that, but its merely a dump of all the available options I could post. In my case, I want to provide a minimal set. What sub-elements are required, and what are optional? Also, I don't want to have to give it individual files for the review, if possible I just want to point it at an changelist.

i.e I post review name, review description, review author, reviewers, change list id

What would be the json post command for this?

Renjith Pillai
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 24, 2012

There is nothing much to skip in that format except for patch and permaId (I guess this id is returned in the response). And provide the content under 'changesets' for specifying the change set that u need.

TAGS
AUG Leaders

Atlassian Community Events