Crucible REST API

This is the reference section of the Crucible REST API.

For information about Crucible Plugin Development, visit the Development Hub.

This documentation was automatically generated from the WADL.

The REST resources described on this page produce and consume serialized objects whose structure is described in XML Schema: crucible.xsd.

Paged APIs

FishEye uses paging to conserve server resources and limit response size for resources that return potentially large collections of items. A request to a paged API will result in a values array wrapped in a JSON object with some paging metadata, like this:


                    {
                    "start": 3,
                    "size": 3,
                    "limit": 100,
                    "lastPage": true,
                    "values": [
                        { /* result 0 */ },
                        { /* result 1 */ },
                        { /* result 2 */ }
                    ]
                    }
                

Clients can use the limit and start query parameters to retrieve the desired number of results.

The limit parameter indicates how many results to return per page. Most APIs default to returning 100 if the limit is left unspecified. A resource can have a hard limit. It's always best practice to check the limit attribute on the response to see what limit has been applied. The request to get a page with desired size should look like this:


                    http://host:port/context/rest/api/api-version/path/to/resource?limit={desired size of page}
                

For example:


                    http://fecru.atlassian.com/rest/api/1.0/rest-service-fecru/users?limit=50
                

The start parameter indicates which item should be used as the first item in the page of results. All paged responses contain a lastPage attribute indicating whether another page of items exists. If a paged response has a property lastPage set to false, the next page start should be calculated by adding current page start and size. The request to get a subsequent page should look like this:


                    http://host:port/context/path/to/resource?start={start of last page}+{size of last page}&limit={desired size of page}
                

For example:


                    http://fecru.atlassian.com/rest/api/1.0/rest-service-fecru/users?size=50&limit=50
                

Resources

/rest-service/users-v1?username=<value>

Methods

GET

Get a list of all the users. You can also ask for a set of users.

request query parameters
parameter value description

username

string

a username (or a few) to limit the number of returned entries. It will return only existing users.

available response representations:

  • 200 - application/xml (users) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <users>
        <userData>
            <avatarUrl>http://foo.com/avatarfred</avatarUrl>
            <displayName>Fred Nurk</displayName>
            <userName>fred</userName>
        </userData>
        <userData>
            <avatarUrl>http://foo.com/avatarjoe</avatarUrl>
            <displayName>Joe Bloggs</displayName>
            <userName>joe</userName>
        </userData>
        <errors>
            <entry>
                <key>adam</key>
                <value>No user named 'adam'</value>
            </entry>
        </errors>
    </users>
    

    a list of users

  • 200 - application/json (users) [expand]

    Example
    {
      "userData" : [ {
        "userName" : "fred",
        "displayName" : "Fred Nurk",
        "avatarUrl" : "http://foo.com/avatarfred"
      }, {
        "userName" : "joe",
        "displayName" : "Joe Bloggs",
        "avatarUrl" : "http://foo.com/avatarjoe"
      } ],
      "errors" : {
        "adam" : "No user named 'adam'"
      }
    }

    a list of users

  • 403 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the user list

  • 403 - application/json [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the user list

/rest-service/users-v1/{repository}/{username}

resource-wide template parameters
parameter value description

username

string

the name of the committer

repository

string

the name of the repository

Methods

GET

Returns the user details of the user mapped to a committer in a repository.

available response representations:

  • 200 - application/xml (userData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <userData>
        <avatarUrl>http://foo.com/avatarfred</avatarUrl>
        <displayName>Fred Nurk</displayName>
        <userName>fred</userName>
    </userData>
    

    user data for a for a user that is mapped to a committer in a FishEye repository

    XML Schema

    Source: crucible.xsd

    <xs:element name="userData" type="userData"/>
  • 200 - application/json (userData) [expand]

    Example
    {
      "userName" : "fred",
      "displayName" : "Fred Nurk",
      "avatarUrl" : "http://foo.com/avatarfred"
    }

    user data for a for a user that is mapped to a committer in a FishEye repository

    XML Schema

    Source: crucible.xsd

    <xs:element name="userData" type="userData"/>
  • 403 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not logged in or anonymous access is not allowed, or you are not allowed to access the repository

  • 403 - application/json [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not logged in or anonymous access is not allowed, or you are not allowed to access the repository

  • 404 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the committer does not exist

  • 404 - application/json [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the committer does not exist

/rest-service/users-v1/{username}

resource-wide template parameters
parameter value description

username

string

the username of the user

Methods

GET

Returns the user's profile details.

available response representations:

  • 200 - application/xml (restUserProfileData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <restUserProfileData>
        <avatarUrl>/foo/avatar/j_doe</avatarUrl>
        <email>joe@example.org</email>
        <mappedCommitters>
            <committers>
                <committerName>jbloggs</committerName>
                <repositoryName>svnrepo</repositoryName>
            </committers>
            <committers>
                <committerName>joe</committerName>
                <repositoryName>cvsrepo</repositoryName>
            </committers>
            <committers>
                <committerName>jbloggs</committerName>
                <repositoryName>cvsrepo</repositoryName>
            </committers>
        </mappedCommitters>
        <preferences>
            <elements value="100" key="maxFilesPerChangeset"/>
            <elements value="UTF-8" key="uploadcharset"/>
            <elements value="patch" key="uploadtype"/>
            <elements value="3" key="context"/>
            <elements value="true" key="enableIde"/>
            <elements value="30" key="changesetsPerPage"/>
            <elements value="4" key="tabWidth"/>
            <elements value="51235" key="ideConnectorPort"/>
            <elements value="file" key="uploadmethod"/>
            <elements value="instant" key="watchMode"/>
            <elements value="html" key="emailFormat"/>
        </preferences>
        <timeZone>
            <name>Europe/Warsaw</name>
            <rawOffset>3600000</rawOffset>
        </timeZone>
        <userData>
            <avatarUrl>http://foo.com/avatarjoe</avatarUrl>
            <displayName>Joe Bloggs</displayName>
            <userName>joe</userName>
        </userData>
    </restUserProfileData>
    

    profile data for a crucible user

  • 200 - application/json (restUserProfileData) [expand]

    Example
    {
      "userData" : {
        "userName" : "joe",
        "displayName" : "Joe Bloggs",
        "avatarUrl" : "http://foo.com/avatarjoe"
      },
      "timeZone" : {
        "name" : "Europe/Warsaw",
        "rawOffset" : 3600000
      },
      "mappedCommitters" : {
        "committers" : [ {
          "committerName" : "jbloggs",
          "repositoryName" : "svnrepo"
        }, {
          "committerName" : "joe",
          "repositoryName" : "cvsrepo"
        }, {
          "committerName" : "jbloggs",
          "repositoryName" : "cvsrepo"
        } ]
      },
      "email" : "joe@example.org",
      "avatarUrl" : "/foo/avatar/j_doe",
      "preferences" : {
        "elements" : [ {
          "key" : "maxFilesPerChangeset",
          "value" : "100"
        }, {
          "key" : "uploadcharset",
          "value" : "UTF-8"
        }, {
          "key" : "uploadtype",
          "value" : "patch"
        }, {
          "key" : "context",
          "value" : "3"
        }, {
          "key" : "enableIde",
          "value" : "true"
        }, {
          "key" : "changesetsPerPage",
          "value" : "30"
        }, {
          "key" : "tabWidth",
          "value" : "4"
        }, {
          "key" : "ideConnectorPort",
          "value" : "51235"
        }, {
          "key" : "uploadmethod",
          "value" : "file"
        }, {
          "key" : "watchMode",
          "value" : "instant"
        }, {
          "key" : "emailFormat",
          "value" : "html"
        } ]
      }
    }

    profile data for a crucible user

  • 403 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    when you are not permitted to view the user's profile, either because

    • you are not logged in as that user, or
    • you are not an administrator.

  • 403 - application/json [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    when you are not permitted to view the user's profile, either because

    • you are not logged in as that user, or
    • you are not an administrator.

  • 404 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the user does not exist

  • 404 - application/json [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the user does not exist

/rest-service/search-v1

Provides an API for searching reviews.

Methods

/rest-service/search-v1/reviews?term=<value>&maxReturn=<value>

Methods

GET

Search for reviews where the name, description, state or permaId contain the specified term.

request query parameters
parameter value description

term

string

a search term.

maxReturn

string

the maximum number of reviews to return.

available response representations:

  • 200 - application/xml (reviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    The result of a review search action.

  • 200 - application/json (reviews) [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    The result of a review search action.

/rest-service/search-v1/reviewsForIssue?jiraKey=<value>&maxReturn=<value>

Methods

GET

Get a list of all reviews that have been linked to the specified JIRA issue key.

request query parameters
parameter value description

jiraKey

string

a Jira issue key (e.g. "FOO-3453")

maxReturn

string

the maximum number of reviews to return.

available response representations:

  • 200 - application/xml (reviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    The result of a search action for reviews that are linked to a specific Jira issue.

  • 200 - application/json (reviews) [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    The result of a search action for reviews that are linked to a specific Jira issue.

/rest-service/reviews-v1?state=<value>

Methods

GET

Get all reviews as a list of ReviewData structures. Note that this may return a lot of data, so using /reviews-v1/filter/<filter> is usually better.

The state parameter is a comma separated list of state names from the set Draft, Approval, Review, Summarize, Closed, Dead, Rejected, Unknown.

request query parameters
parameter value description

state

string

only return reviews that are in these states.

available response representations:

  • 200 - application/xml (reviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    A list of reviews, without any details such as comments or review items.

  • 200 - application/json (reviews) [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      }, {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    A list of reviews, without any details such as comments or review items.

POST

Create a review from the given createReview element.

The sub-elements of the createReview element determine what type of review is created and how it is populated. The following rules govern which sub-elemnts can be present and how they are used in the review creation process

  • If the snippet element is specified a reviewData element must be supplied and no other elements may be supplied.
  • At least one of reviewData and detailedReviewData must be supplied. If both are supplied, the reviewers element of the detailedReviewData element is used. All other elements of detailedReviewData are ignored.
  • If the state element is present and has the value of "Review" in the reviewData (or detailedReviewData if used), then the review will be approved at creation, where allowed
  • The changesets and path elements can be supplied with either the reviewData or detailedReviewData elements.

The reponse includes the Location header that contains the URL of the newly created entity.

acceptable request representations:

  • application/xml (createReview) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <createReview>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
        <patch>Index: emptytests/notempty/a.txt
    ===================================================================
    diff -u -N -r1.31 -r1.32
    --- emptytests/notempty/a.txt	22 Sep 2004 00:38:15 -0000	1.31
    +++ emptytests/notempty/a.txt	5 Dec 2004 01:04:25 -0000	1.32
    @@ -4,4 +4,5 @@
     hello there :D
     CRU-123
     http://madbean.com/blog/
    -!
    \ No newline at end of file
    +!
    +foobie
    \ No newline at end of file
    Index: test/a.txt
    ===================================================================
    diff -u -N -r1.31 -r1.32
    --- test/a.txt	22 Sep 2004 00:38:15 -0000	1.31
    +++ test/a.txt	5 Dec 2004 01:04:25 -0000	1.32
    @@ -4,4 +4,5 @@
     hello there :D
     CRU-123
     http://madbean.com/blog/
    -!
    \ No newline at end of file
    +!
    +foobie
    \ No newline at end of file</patch>
        <anchor>
            <anchorPath>/</anchorPath>
            <anchorRepository>REPO</anchorRepository>
            <stripCount>2</stripCount>
        </anchor>
        <changesets>
            <changesetData>
                <id>63452</id>
            </changesetData>
            <repository>REPO</repository>
        </changesets>
    </createReview>
    

    Example of a request document used to create a new review from a changeset.

  • application/json (createReview) [expand]

    Example
    {
      "reviewData" : {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      },
      "patch" : "Index: emptytests/notempty/a.txt\n===================================================================\ndiff -u -N -r1.31 -r1.32\n--- emptytests/notempty/a.txt\t22 Sep 2004 00:38:15 -0000\t1.31\n+++ emptytests/notempty/a.txt\t5 Dec 2004 01:04:25 -0000\t1.32\n@@ -4,4 +4,5 @@\n hello there :D\n CRU-123\n http://madbean.com/blog/\n-!\n\\ No newline at end of file\n+!\n+foobie\n\\ No newline at end of file\nIndex: test/a.txt\n===================================================================\ndiff -u -N -r1.31 -r1.32\n--- test/a.txt\t22 Sep 2004 00:38:15 -0000\t1.31\n+++ test/a.txt\t5 Dec 2004 01:04:25 -0000\t1.32\n@@ -4,4 +4,5 @@\n hello there :D\n CRU-123\n http://madbean.com/blog/\n-!\n\\ No newline at end of file\n+!\n+foobie\n\\ No newline at end of file",
      "anchor" : {
        "anchorPath" : "/",
        "anchorRepository" : "REPO",
        "stripCount" : 2
      },
      "changesets" : {
        "changesetData" : [ {
          "id" : "63452"
        } ],
        "repository" : "REPO"
      }
    }

    Example of a request document used to create a new review from a changeset.

available response representations:

  • 200 - application/xml (reviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
    </reviewData>
    

    A reviewData element with the permId attribute set to the id of the review which was just created.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 200 - application/json (reviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754"
    }

    A reviewData element with the permId attribute set to the id of the review which was just created.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 409 - application/xml (conflict) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

  • 409 - application/json (conflict) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

/rest-service/reviews-v1/metrics/{version}

resource-wide template parameters
parameter value description

version

string

a metrics version.

Methods

GET

Get comment metrics metadata for the specified metrics version.

available response representations:

  • 200 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <metrics>
        <metricsData>
            <configVersion>4</configVersion>
            <defaultValue>
                <name>Major</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">0</value>
            </defaultValue>
            <label>Rank</label>
            <type>INTEGER</type>
            <values>
                <name>Major</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">0</value>
            </values>
            <values>
                <name>Minor</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1</value>
            </values>
        </metricsData>
        <metricsData>
            <configVersion>4</configVersion>
            <defaultValue>
                <name>Inconsistent</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">3</value>
            </defaultValue>
            <label>Classification</label>
            <type>INTEGER</type>
            <values>
                <name>Missing</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">0</value>
            </values>
            <values>
                <name>Extra (superfluous)</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1</value>
            </values>
            <values>
                <name>Ambiguous</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">2</value>
            </values>
            <values>
                <name>Inconsistent</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">3</value>
            </values>
            <values>
                <name>Improvement desirable</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">4</value>
            </values>
            <values>
                <name>Not conforming to standards</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">5</value>
            </values>
            <values>
                <name>Risk-Prone</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">6</value>
            </values>
            <values>
                <name>Factually incorrect</name>
                <value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">7</value>
            </values>
        </metricsData>
    </metrics>
    

    A comment metrics configuration.

  • 200 - application/json [expand]

    Example
    {
      "metricsData" : [ {
        "type" : "INTEGER",
        "configVersion" : 4,
        "label" : "Rank",
        "defaultValue" : {
          "name" : "Major",
          "value" : 0
        },
        "values" : [ {
          "name" : "Major",
          "value" : 0
        }, {
          "name" : "Minor",
          "value" : 1
        } ]
      }, {
        "type" : "INTEGER",
        "configVersion" : 4,
        "label" : "Classification",
        "defaultValue" : {
          "name" : "Inconsistent",
          "value" : 3
        },
        "values" : [ {
          "name" : "Missing",
          "value" : 0
        }, {
          "name" : "Extra (superfluous)",
          "value" : 1
        }, {
          "name" : "Ambiguous",
          "value" : 2
        }, {
          "name" : "Inconsistent",
          "value" : 3
        }, {
          "name" : "Improvement desirable",
          "value" : 4
        }, {
          "name" : "Not conforming to standards",
          "value" : 5
        }, {
          "name" : "Risk-Prone",
          "value" : 6
        }, {
          "name" : "Factually incorrect",
          "value" : 7
        } ]
      } ]
    }

    A comment metrics configuration.

/rest-service/reviews-v1/{id}/comments/{cId}?render=<value>

resource-wide template parameters
parameter value description

id

string

the review perma id

cId

string

the comment perma id

Methods

GET

Gets the given comment.

request query parameters
parameter value description

render

boolean

Default: false

true if the wiki text should be rendered into html, into the field <messageAsHtml>.

available response representations:

  • 200 - application/xml (comment) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <versionedLineCommentData>
        <createDate>2014-12-04T10:57:08.447+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>*bold* message</message>
        <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
        <parentCommentId/>
        <readStatus>READ</readStatus>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Fred Veiligheidspet</displayName>
            <userName>fred</userName>
        </user>
        <permaId/>
        <reviewItemId>
            <id>CRFX-1234</id>
        </reviewItemId>
        <fromLineRange>10</fromLineRange>
        <toLineRange>20</toLineRange>
    </versionedLineCommentData>
    

    comment

  • 200 - application/json (comment) [expand]

    Example
    {
      "message" : "*bold* message",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "READ",
      "user" : {
        "userName" : "fred",
        "displayName" : "Fred Veiligheidspet",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : 1417687028447,
      "messageAsHtml" : "<p><b>bold</b> message</p>",
      "reviewItemId" : {
        "id" : "CRFX-1234"
      },
      "fromLineRange" : "10",
      "toLineRange" : "20"
    }

    comment

  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>PermaIdFormat</code>
        <message>Malformed PermId.</message>
        <stacktrace>com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:33)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review perma-id is not well-formed

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "PermaIdFormat",
      "message" : "Malformed PermId.",
      "stacktrace" : "com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:33)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review perma-id is not well-formed

  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

POST

Updates the comment given by the perma id to the new comment posted.

acceptable request representations:

  • application/xml (newComment) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>true</draft>
        <message>I thought you said you were going to remove this line?</message>
        <parentCommentId/>
        <permId/>
        <permaId/>
    </generalCommentData>
    

  • application/json (newComment) [expand]

    Example
    {
      "message" : "I thought you said you were going to remove this line?",
      "draft" : true,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "permaId" : {
      },
      "permId" : {
      },
      "parentCommentId" : {
      }
    }

DELETE

Deletes the given comment.

/rest-service/reviews-v1/{id}/addFile

resource-wide template parameters
parameter value description

id

string

the review perma id to add the file

Methods

POST

Adds a file to the review, optionally diff'ed to a second file.

In contrast to a patch, files can be either binary or text. Depending on the filetype, size and contents, Crucible may be able to display either parts, or the entire file in the review. It is possible to upload two versions of the file, in which case Crucible will display a diff and report that the file was modified. When only a single file is uploaded, Crucible treats the file as newly added.

This action returns the ReviewData document on success.

This resources uses multipart form-data to receive the file(s), character set indication and optional comments (it does not expect an XML document with embedded files, as that would require the client to first encode the files in Base64). Making a multipart form-data request can be done manually, but you will probably want to use a library.

During testing it is convenient to let your browser generate the requests using the test html form below:

 <html>
 <head><title>Rest File Upload Test</title></head>
 <body>
     <form action="http://localhost:8060/rest-service/reviews-v1/CR-4/addFile" enctype="multipart/form-data" method="POST">
         <table>
             <tr>
                 <td>File (required):</td>
                 <td><input name="file" type="file"/></td>
             </tr>
 

<tr> <td>Diff to (optional):</td> <td><input name="diffFile" type="file"/></td> </tr> <tr> <td>Character Set (optional):</td> <td><input name="charset" type="text" value="UTF-8"/></td> </tr>

<tr> <td>Comments (optional):</td> <td><input type="text" name="comments"/></td> </tr> <tr><td><input type="submit" value="Upload"/></td></tr> </table> </form> </body> </html>

available response representations:

  • 200 - application/xml (reviewItem) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    The response is the reviewItemData structure describing the new item. Also, the Location response header is present and contains the PermId URL of the new item.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • 200 - application/json (reviewItem) [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    The response is the reviewItemData structure describing the new item. Also, the Location response header is present and contains the PermId URL of the new item.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first.

/rest-service/reviews-v1/versionInfo

Methods

GET

Returns Crucible version information.

available response representations:

  • 200 - application/xml (versionInfo) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <versionInfo>
        <releaseNumber>3.6.2</releaseNumber>
        <buildDate>2014-12-03</buildDate>
    </versionInfo>
    

    The product version.

    XML Schema

    Source: crucible.xsd

    <xs:element name="versionInfo" type="versionInfo"/>
  • 200 - application/json (versionInfo) [expand]

    Example
    {
      "releaseNumber" : "3.6.2",
      "buildDate" : "2014-12-03"
    }

    The product version.

    XML Schema

    Source: crucible.xsd

    <xs:element name="versionInfo" type="versionInfo"/>

/rest-service/reviews-v1/details?state=<value>

Methods

GET

Retrieves all reviews that are in one of the the specified states. For each review all details are included (review items + comments). The wiki rendered comments will be available via the <messageAsHtml> element

request query parameters
parameter value description

state

string

the review states to match.

available response representations:

  • 200 - application/xml (detailedReviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
        <actions>
            <actionData>
                <displayName>Abandon</displayName>
                <name>action:abandonReview</name>
            </actionData>
            <actionData>
                <displayName>Approve</displayName>
                <name>action:approveReview</name>
            </actionData>
            <actionData>
                <displayName>Comment</displayName>
                <name>action:commentOnReview</name>
            </actionData>
            <actionData>
                <displayName>Complete</displayName>
                <name>action:completeReview</name>
            </actionData>
            <actionData>
                <displayName>Edit Review Details</displayName>
                <name>action:modifyReviewFiles</name>
            </actionData>
        </actions>
        <generalComments>
            <generalCommentData>
                <createDate>2014-12-04T10:57:08.419+0100</createDate>
                <defectApproved>false</defectApproved>
                <defectRaised>false</defectRaised>
                <deleted>false</deleted>
                <draft>false</draft>
                <message>I thought you said you were going to *remove* this line?</message>
                <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                <metrics/>
                <parentCommentId/>
                <readStatus>UNREAD</readStatus>
                <replies/>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Joe Bloggs</displayName>
                    <userName>joe</userName>
                </user>
                <permId>
                    <id>CR:1</id>
                </permId>
                <permaId>
                    <id>CR:1</id>
                </permaId>
            </generalCommentData>
        </generalComments>
        <reviewItems>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-239</id>
                </permId>
                <anchorData>
                    <anchorPath>trunk</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                <fromPath>dir238/a.txt</fromPath>
                <fromRevision>239</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                <toPath>dir238/a.txt</toPath>
                <toRevision>2391</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-240</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                <fromPath>dir239/d.txt</fromPath>
                <fromRevision>240</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                <toPath>dir239/d.txt</toPath>
                <toRevision>2401</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-241</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                <fromPath>dir240/c.txt</fromPath>
                <fromRevision>241</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                <toPath>dir240/c.txt</toPath>
                <toRevision>2411</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-242</id>
                </permId>
                <anchorData>
                    <anchorPath>tags/tag1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                <fromPath>dir241/b.txt</fromPath>
                <fromRevision>242</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                <toPath>dir241/b.txt</toPath>
                <toRevision>2421</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-243</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                <fromPath>dir242/d.txt</fromPath>
                <fromRevision>243</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                <toPath>dir242/d.txt</toPath>
                <toRevision>2431</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-244</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                <fromPath>dir243/e.txt</fromPath>
                <fromRevision>244</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                <toPath>dir243/e.txt</toPath>
                <toRevision>2441</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-245</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                <fromPath>dir244/f.txt</fromPath>
                <fromRevision>245</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                <toPath>dir244/f.txt</toPath>
                <toRevision>2451</toRevision>
            </reviewItem>
        </reviewItems>
        <transitions>
            <transitionData>
                <displayName>Summarize</displayName>
                <name>action:summarizeReview</name>
            </transitionData>
        </transitions>
    </detailedReviewData>
    

    Reviews which are in a particular state. These reviews contains the details, such as the comments (and also the wiki rendered html), the review items and other information.

  • 200 - application/json (detailedReviews) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754",
      "reviewItems" : {
        "reviewItem" : [ {
          "permId" : {
            "id" : "CFR-239"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir238/a.txt",
          "fromRevision" : "239",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
          "toPath" : "dir238/a.txt",
          "toRevision" : "2391",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "anchorData" : {
            "anchorPath" : "trunk",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-240"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir239/d.txt",
          "fromRevision" : "240",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
          "toPath" : "dir239/d.txt",
          "toRevision" : "2401",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-241"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir240/c.txt",
          "fromRevision" : "241",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
          "toPath" : "dir240/c.txt",
          "toRevision" : "2411",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-242"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir241/b.txt",
          "fromRevision" : "242",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
          "toPath" : "dir241/b.txt",
          "toRevision" : "2421",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "tags/tag1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-243"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir242/d.txt",
          "fromRevision" : "243",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
          "toPath" : "dir242/d.txt",
          "toRevision" : "2431",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-244"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir243/e.txt",
          "fromRevision" : "244",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
          "toPath" : "dir243/e.txt",
          "toRevision" : "2441",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-245"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir244/f.txt",
          "fromRevision" : "245",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
          "toPath" : "dir244/f.txt",
          "toRevision" : "2451",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        } ]
      },
      "generalComments" : {
        "comments" : [ {
          "metrics" : {
          },
          "message" : "I thought you said you were going to *remove* this line?",
          "draft" : false,
          "deleted" : false,
          "defectRaised" : false,
          "defectApproved" : false,
          "readStatus" : "UNREAD",
          "user" : {
            "userName" : "joe",
            "displayName" : "Joe Bloggs",
            "avatarUrl" : "http://foo.com/avatar"
          },
          "createDate" : "2014-12-04T10:57:08.419+0100",
          "permaId" : {
            "id" : "CR:1"
          },
          "replies" : [ ],
          "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
          "permId" : {
            "id" : "CR:1"
          },
          "parentCommentId" : {
          }
        } ]
      },
      "transitions" : {
        "transitionData" : [ {
          "name" : "action:summarizeReview",
          "displayName" : "Summarize"
        } ]
      },
      "actions" : {
        "actionData" : [ {
          "name" : "action:abandonReview",
          "displayName" : "Abandon"
        }, {
          "name" : "action:approveReview",
          "displayName" : "Approve"
        }, {
          "name" : "action:commentOnReview",
          "displayName" : "Comment"
        }, {
          "name" : "action:completeReview",
          "displayName" : "Complete"
        }, {
          "name" : "action:modifyReviewFiles",
          "displayName" : "Edit Review Details"
        } ]
      }
    }

    Reviews which are in a particular state. These reviews contains the details, such as the comments (and also the wiki rendered html), the review items and other information.

/rest-service/reviews-v1/filter/{filter}

resource-wide template parameters
parameter value description

filter

string

a predefined filter type.

Available filter names are:

  • allReviews - All reviews for everyone.
  • allOpenReviews - Open reviews for everyone.
  • allClosedReviews - Closed reviews for everyone.
  • draftReviews - Draft reviews for everyone.
  • toReview - Reviews on which the current user is an uncompleted reviewer.
  • requireMyApproval - Reviews waiting to be approved by the current user.
  • toSummarize - Completed reviews which are ready for the current user to summarize.
  • outForReview - Reviews with uncompleted reviewers, on which the current reviewer is the moderator.
  • drafts - Draft reviews created by the current user.
  • open - Open reviews created by the current user.
  • completed - Open reviews where the current user is a completed reviewer.
  • closed - Closed reviews created by the current user.
  • trash - Abandoned reviews created by the current user.

Methods

GET

Get all the reviews which match the given filter, for the current user.

available response representations:

  • 200 - application/xml (reviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    The list of reviews that match the specified pre-defined filter. Does not contain the review details (such as comments, review items etc).

  • 200 - application/json (reviews) [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      }, {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    The list of reviews that match the specified pre-defined filter. Does not contain the review details (such as comments, review items etc).

/rest-service/reviews-v1/filter/{filter}/details

resource-wide template parameters
parameter value description

filter

string

a predefined filter type.

Available filter names are:

  • allReviews - All reviews for everyone.
  • allOpenReviews - Open reviews for everyone.
  • allClosedReviews - Closed reviews for everyone.
  • draftReviews - Draft reviews for everyone.
  • toReview - Reviews on which the current user is an uncompleted reviewer.
  • requireMyApproval - Reviews waiting to be approved by the current user.
  • toSummarize - Completed reviews which are ready for the current user to summarize.
  • outForReview - Reviews with uncompleted reviewers, on which the current reviewer is the moderator.
  • drafts - Draft reviews created by the current user.
  • open - Open reviews created by the current user.
  • closed - Closed reviews created by the current user.
  • trash - Abandoned reviews created by the current user.

Methods

GET

Gets a list of all the reviews that match the specified filter criteria.

For each review all details are included (review items + comments).

available response representations:

  • 200 - application/xml (filter) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviews>
        <detailedReviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
            <actions>
                <actionData>
                    <displayName>Abandon</displayName>
                    <name>action:abandonReview</name>
                </actionData>
                <actionData>
                    <displayName>Approve</displayName>
                    <name>action:approveReview</name>
                </actionData>
                <actionData>
                    <displayName>Comment</displayName>
                    <name>action:commentOnReview</name>
                </actionData>
                <actionData>
                    <displayName>Complete</displayName>
                    <name>action:completeReview</name>
                </actionData>
                <actionData>
                    <displayName>Edit Review Details</displayName>
                    <name>action:modifyReviewFiles</name>
                </actionData>
            </actions>
            <generalComments>
                <generalCommentData>
                    <createDate>2014-12-04T10:57:08.419+0100</createDate>
                    <defectApproved>false</defectApproved>
                    <defectRaised>false</defectRaised>
                    <deleted>false</deleted>
                    <draft>false</draft>
                    <message>I thought you said you were going to *remove* this line?</message>
                    <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                    <metrics/>
                    <parentCommentId/>
                    <readStatus>UNREAD</readStatus>
                    <replies/>
                    <user>
                        <avatarUrl>http://foo.com/avatar</avatarUrl>
                        <displayName>Joe Bloggs</displayName>
                        <userName>joe</userName>
                    </user>
                    <permId>
                        <id>CR:1</id>
                    </permId>
                    <permaId>
                        <id>CR:1</id>
                    </permaId>
                </generalCommentData>
            </generalComments>
            <reviewItems>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-239</id>
                    </permId>
                    <anchorData>
                        <anchorPath>trunk</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                    <fromPath>dir238/a.txt</fromPath>
                    <fromRevision>239</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                    <toPath>dir238/a.txt</toPath>
                    <toRevision>2391</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-240</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                    <fromPath>dir239/d.txt</fromPath>
                    <fromRevision>240</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                    <toPath>dir239/d.txt</toPath>
                    <toRevision>2401</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-241</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                    <fromPath>dir240/c.txt</fromPath>
                    <fromRevision>241</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                    <toPath>dir240/c.txt</toPath>
                    <toRevision>2411</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-242</id>
                    </permId>
                    <anchorData>
                        <anchorPath>tags/tag1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                    <fromPath>dir241/b.txt</fromPath>
                    <fromRevision>242</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                    <toPath>dir241/b.txt</toPath>
                    <toRevision>2421</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-243</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                    <fromPath>dir242/d.txt</fromPath>
                    <fromRevision>243</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                    <toPath>dir242/d.txt</toPath>
                    <toRevision>2431</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-244</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                    <fromPath>dir243/e.txt</fromPath>
                    <fromRevision>244</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                    <toPath>dir243/e.txt</toPath>
                    <toRevision>2441</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-245</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                    <fromPath>dir244/f.txt</fromPath>
                    <fromRevision>245</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                    <toPath>dir244/f.txt</toPath>
                    <toRevision>2451</toRevision>
                </reviewItem>
            </reviewItems>
            <transitions>
                <transitionData>
                    <displayName>Summarize</displayName>
                    <name>action:summarizeReview</name>
                </transitionData>
            </transitions>
        </detailedReviewData>
    </detailedReviews>
    

    The detailed list of reviews that match the specified pre-defined filter, with the details of the review, such as comments (and its wiki rendered html), and review items.

  • 200 - application/json (filter) [expand]

    Example
    {
      "detailedReviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754",
        "reviewItems" : {
          "reviewItem" : [ {
            "permId" : {
              "id" : "CFR-239"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir238/a.txt",
            "fromRevision" : "239",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
            "toPath" : "dir238/a.txt",
            "toRevision" : "2391",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "anchorData" : {
              "anchorPath" : "trunk",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-240"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir239/d.txt",
            "fromRevision" : "240",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
            "toPath" : "dir239/d.txt",
            "toRevision" : "2401",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-241"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir240/c.txt",
            "fromRevision" : "241",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
            "toPath" : "dir240/c.txt",
            "toRevision" : "2411",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-242"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir241/b.txt",
            "fromRevision" : "242",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
            "toPath" : "dir241/b.txt",
            "toRevision" : "2421",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "tags/tag1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-243"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir242/d.txt",
            "fromRevision" : "243",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
            "toPath" : "dir242/d.txt",
            "toRevision" : "2431",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-244"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir243/e.txt",
            "fromRevision" : "244",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
            "toPath" : "dir243/e.txt",
            "toRevision" : "2441",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-245"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir244/f.txt",
            "fromRevision" : "245",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
            "toPath" : "dir244/f.txt",
            "toRevision" : "2451",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          } ]
        },
        "generalComments" : {
          "comments" : [ {
            "metrics" : {
            },
            "message" : "I thought you said you were going to *remove* this line?",
            "draft" : false,
            "deleted" : false,
            "defectRaised" : false,
            "defectApproved" : false,
            "readStatus" : "UNREAD",
            "user" : {
              "userName" : "joe",
              "displayName" : "Joe Bloggs",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "createDate" : "2014-12-04T10:57:08.419+0100",
            "permaId" : {
              "id" : "CR:1"
            },
            "replies" : [ ],
            "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
            "permId" : {
              "id" : "CR:1"
            },
            "parentCommentId" : {
            }
          } ]
        },
        "transitions" : {
          "transitionData" : [ {
            "name" : "action:summarizeReview",
            "displayName" : "Summarize"
          } ]
        },
        "actions" : {
          "actionData" : [ {
            "name" : "action:abandonReview",
            "displayName" : "Abandon"
          }, {
            "name" : "action:approveReview",
            "displayName" : "Approve"
          }, {
            "name" : "action:commentOnReview",
            "displayName" : "Comment"
          }, {
            "name" : "action:completeReview",
            "displayName" : "Complete"
          }, {
            "name" : "action:modifyReviewFiles",
            "displayName" : "Edit Review Details"
          } ]
        }
      } ]
    }

    The detailed list of reviews that match the specified pre-defined filter, with the details of the review, such as comments (and its wiki rendered html), and review items.

/rest-service/reviews-v1/filter?title=<value>&author=<value>&moderator=<value>&creator=<value>&states=<value>&reviewer=<value>&orRoles=<value>&complete=<value>&allReviewersComplete=<value>&project=<value>&fromDate=<value>&toDate=<value>

Methods

GET

Returns all reviews that satisfy the specified filter parameters and are accessible under the provided credentials.

To ignore a property, omit it from the query string.
request query parameters
parameter value description

title

string

a string that will be searched for in review titles.

author

string

reviews authored by this user.

moderator

string

reviews moderated by this user.

creator

string

reviews created by this user.

states

string

comma-separated list of amy of the following strings: (Draft, Approval, Review, Summarize, Closed, Dead, Rejected, Unknown).

reviewer

string

reviews reviewed by this user.

orRoles

boolean

whether the value of author, creator, moderator and reviewer should be OR'd (orRoles=true) or AND'd (orRoles=false) together.

complete

boolean

reviews that the specified reviewer has completed.

allReviewersComplete

boolean

Reviews that all reviewers have completed.

project

string

reviews for the specified project.

fromDate

long

from time in millis, inclusive.

toDate

long

to time in millis, exclusive.

available response representations:

  • 200 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    A set of reviews that matches the filter. Does not contain the review's details.

  • 200 - application/json [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      }, {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    A set of reviews that matches the filter. Does not contain the review's details.

POST

This method should no longer be used, as it uses a POST for a read-only retrieval operation and is provided for backward compatibility only.

Do a GET instead.

acceptable request representations:

  • application/xml (customFilterData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <customFilterData>
        <fromDate>0</fromDate>
        <orRoles>false</orRoles>
        <project>Project 1</project>
        <title>title of the review</title>
        <toDate>0</toDate>
    </customFilterData>
    

    A custom filter definition.

    XML Schema

    Source: crucible.xsd

    <xs:element name="customFilterData" type="customFilterData"/>
  • application/json (customFilterData) [expand]

    Example
    {
      "title" : "title of the review",
      "orRoles" : false,
      "project" : "Project 1",
      "fromDate" : 0,
      "toDate" : 0
    }

    A custom filter definition.

    XML Schema

    Source: crucible.xsd

    <xs:element name="customFilterData" type="customFilterData"/>

available response representations:

  • 200 - application/xml (reviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    The list of reviews that match the filter criteria.

  • 200 - application/json (reviews) [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      }, {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    The list of reviews that match the filter criteria.

/rest-service/reviews-v1/filter/details?title=<value>&author=<value>&moderator=<value>&creator=<value>&states=<value>&reviewer=<value>&orRoles=<value>&complete=<value>&allReviewersComplete=<value>&project=<value>&fromDate=<value>&toDate=<value>

Methods

GET

Returns all (detailed) information of all reviews that satisfy the specified filter parameters and are accessible under the provided credentials.

To ignore a property, omit it from the query string.
request query parameters
parameter value description

title

string

a string that will be searched for in review titles.

author

string

reviews authored by this user.

moderator

string

reviews moderated by this user.

creator

string

reviews created by this user.

states

string

comma-separated list of amy of the following strings: (Draft, Approval, Review, Summarize, Closed, Dead, Rejected, Unknown).

reviewer

string

reviews reviewed by this user.

orRoles

boolean

whether the value of author, creator, moderator and reviewer should be OR'd (orRoles=true) or AND'd (orRoles=false) together.

complete

boolean

reviews that the specified reviewer has completed.

allReviewersComplete

boolean

Reviews that all reviewers have completed.

project

string

reviews for the specified project.

fromDate

long

from time in millis, inclusive.

toDate

long

to time in millis, exclusive.

available response representations:

  • 200 - application/xml (detailedReviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviews>
        <detailedReviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
            <actions>
                <actionData>
                    <displayName>Abandon</displayName>
                    <name>action:abandonReview</name>
                </actionData>
                <actionData>
                    <displayName>Approve</displayName>
                    <name>action:approveReview</name>
                </actionData>
                <actionData>
                    <displayName>Comment</displayName>
                    <name>action:commentOnReview</name>
                </actionData>
                <actionData>
                    <displayName>Complete</displayName>
                    <name>action:completeReview</name>
                </actionData>
                <actionData>
                    <displayName>Edit Review Details</displayName>
                    <name>action:modifyReviewFiles</name>
                </actionData>
            </actions>
            <generalComments>
                <generalCommentData>
                    <createDate>2014-12-04T10:57:08.419+0100</createDate>
                    <defectApproved>false</defectApproved>
                    <defectRaised>false</defectRaised>
                    <deleted>false</deleted>
                    <draft>false</draft>
                    <message>I thought you said you were going to *remove* this line?</message>
                    <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                    <metrics/>
                    <parentCommentId/>
                    <readStatus>UNREAD</readStatus>
                    <replies/>
                    <user>
                        <avatarUrl>http://foo.com/avatar</avatarUrl>
                        <displayName>Joe Bloggs</displayName>
                        <userName>joe</userName>
                    </user>
                    <permId>
                        <id>CR:1</id>
                    </permId>
                    <permaId>
                        <id>CR:1</id>
                    </permaId>
                </generalCommentData>
            </generalComments>
            <reviewItems>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-239</id>
                    </permId>
                    <anchorData>
                        <anchorPath>trunk</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                    <fromPath>dir238/a.txt</fromPath>
                    <fromRevision>239</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                    <toPath>dir238/a.txt</toPath>
                    <toRevision>2391</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-240</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                    <fromPath>dir239/d.txt</fromPath>
                    <fromRevision>240</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                    <toPath>dir239/d.txt</toPath>
                    <toRevision>2401</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-241</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                    <fromPath>dir240/c.txt</fromPath>
                    <fromRevision>241</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                    <toPath>dir240/c.txt</toPath>
                    <toRevision>2411</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-242</id>
                    </permId>
                    <anchorData>
                        <anchorPath>tags/tag1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                    <fromPath>dir241/b.txt</fromPath>
                    <fromRevision>242</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                    <toPath>dir241/b.txt</toPath>
                    <toRevision>2421</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-243</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                    <fromPath>dir242/d.txt</fromPath>
                    <fromRevision>243</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                    <toPath>dir242/d.txt</toPath>
                    <toRevision>2431</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-244</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                    <fromPath>dir243/e.txt</fromPath>
                    <fromRevision>244</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                    <toPath>dir243/e.txt</toPath>
                    <toRevision>2441</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-245</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                    <fromPath>dir244/f.txt</fromPath>
                    <fromRevision>245</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                    <toPath>dir244/f.txt</toPath>
                    <toRevision>2451</toRevision>
                </reviewItem>
            </reviewItems>
            <transitions>
                <transitionData>
                    <displayName>Summarize</displayName>
                    <name>action:summarizeReview</name>
                </transitionData>
            </transitions>
        </detailedReviewData>
    </detailedReviews>
    

    The detailed list of reviews that match the filter criteria, with the details of the review, such as comments (and its wiki rendered html), and review items.

  • 200 - application/json (detailedReviews) [expand]

    Example
    {
      "detailedReviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754",
        "reviewItems" : {
          "reviewItem" : [ {
            "permId" : {
              "id" : "CFR-239"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir238/a.txt",
            "fromRevision" : "239",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
            "toPath" : "dir238/a.txt",
            "toRevision" : "2391",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "anchorData" : {
              "anchorPath" : "trunk",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-240"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir239/d.txt",
            "fromRevision" : "240",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
            "toPath" : "dir239/d.txt",
            "toRevision" : "2401",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-241"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir240/c.txt",
            "fromRevision" : "241",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
            "toPath" : "dir240/c.txt",
            "toRevision" : "2411",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-242"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir241/b.txt",
            "fromRevision" : "242",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
            "toPath" : "dir241/b.txt",
            "toRevision" : "2421",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "tags/tag1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-243"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir242/d.txt",
            "fromRevision" : "243",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
            "toPath" : "dir242/d.txt",
            "toRevision" : "2431",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-244"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir243/e.txt",
            "fromRevision" : "244",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
            "toPath" : "dir243/e.txt",
            "toRevision" : "2441",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-245"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir244/f.txt",
            "fromRevision" : "245",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
            "toPath" : "dir244/f.txt",
            "toRevision" : "2451",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          } ]
        },
        "generalComments" : {
          "comments" : [ {
            "metrics" : {
            },
            "message" : "I thought you said you were going to *remove* this line?",
            "draft" : false,
            "deleted" : false,
            "defectRaised" : false,
            "defectApproved" : false,
            "readStatus" : "UNREAD",
            "user" : {
              "userName" : "joe",
              "displayName" : "Joe Bloggs",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "createDate" : "2014-12-04T10:57:08.419+0100",
            "permaId" : {
              "id" : "CR:1"
            },
            "replies" : [ ],
            "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
            "permId" : {
              "id" : "CR:1"
            },
            "parentCommentId" : {
            }
          } ]
        },
        "transitions" : {
          "transitionData" : [ {
            "name" : "action:summarizeReview",
            "displayName" : "Summarize"
          } ]
        },
        "actions" : {
          "actionData" : [ {
            "name" : "action:abandonReview",
            "displayName" : "Abandon"
          }, {
            "name" : "action:approveReview",
            "displayName" : "Approve"
          }, {
            "name" : "action:commentOnReview",
            "displayName" : "Comment"
          }, {
            "name" : "action:completeReview",
            "displayName" : "Complete"
          }, {
            "name" : "action:modifyReviewFiles",
            "displayName" : "Edit Review Details"
          } ]
        }
      } ]
    }

    The detailed list of reviews that match the filter criteria, with the details of the review, such as comments (and its wiki rendered html), and review items.

POST

This method should no longer be used, as it uses a POST for a read-only retrieval operation and is provided for backward compatibility only.

Do a GET instead.

acceptable request representations:

  • application/xml (customFilterData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <customFilterData>
        <fromDate>0</fromDate>
        <orRoles>false</orRoles>
        <project>Project 1</project>
        <title>title of the review</title>
        <toDate>0</toDate>
    </customFilterData>
    

    A custom filter definition.

    XML Schema

    Source: crucible.xsd

    <xs:element name="customFilterData" type="customFilterData"/>
  • application/json (customFilterData) [expand]

    Example
    {
      "title" : "title of the review",
      "orRoles" : false,
      "project" : "Project 1",
      "fromDate" : 0,
      "toDate" : 0
    }

    A custom filter definition.

    XML Schema

    Source: crucible.xsd

    <xs:element name="customFilterData" type="customFilterData"/>

available response representations:

  • 200 - application/xml (detailedReviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviews>
        <detailedReviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
            <actions>
                <actionData>
                    <displayName>Abandon</displayName>
                    <name>action:abandonReview</name>
                </actionData>
                <actionData>
                    <displayName>Approve</displayName>
                    <name>action:approveReview</name>
                </actionData>
                <actionData>
                    <displayName>Comment</displayName>
                    <name>action:commentOnReview</name>
                </actionData>
                <actionData>
                    <displayName>Complete</displayName>
                    <name>action:completeReview</name>
                </actionData>
                <actionData>
                    <displayName>Edit Review Details</displayName>
                    <name>action:modifyReviewFiles</name>
                </actionData>
            </actions>
            <generalComments>
                <generalCommentData>
                    <createDate>2014-12-04T10:57:08.419+0100</createDate>
                    <defectApproved>false</defectApproved>
                    <defectRaised>false</defectRaised>
                    <deleted>false</deleted>
                    <draft>false</draft>
                    <message>I thought you said you were going to *remove* this line?</message>
                    <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                    <metrics/>
                    <parentCommentId/>
                    <readStatus>UNREAD</readStatus>
                    <replies/>
                    <user>
                        <avatarUrl>http://foo.com/avatar</avatarUrl>
                        <displayName>Joe Bloggs</displayName>
                        <userName>joe</userName>
                    </user>
                    <permId>
                        <id>CR:1</id>
                    </permId>
                    <permaId>
                        <id>CR:1</id>
                    </permaId>
                </generalCommentData>
            </generalComments>
            <reviewItems>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-239</id>
                    </permId>
                    <anchorData>
                        <anchorPath>trunk</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                    <fromPath>dir238/a.txt</fromPath>
                    <fromRevision>239</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                    <toPath>dir238/a.txt</toPath>
                    <toRevision>2391</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-240</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                    <fromPath>dir239/d.txt</fromPath>
                    <fromRevision>240</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                    <toPath>dir239/d.txt</toPath>
                    <toRevision>2401</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-241</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                    <fromPath>dir240/c.txt</fromPath>
                    <fromRevision>241</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                    <toPath>dir240/c.txt</toPath>
                    <toRevision>2411</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-242</id>
                    </permId>
                    <anchorData>
                        <anchorPath>tags/tag1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                    <fromPath>dir241/b.txt</fromPath>
                    <fromRevision>242</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                    <toPath>dir241/b.txt</toPath>
                    <toRevision>2421</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-243</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                    <fromPath>dir242/d.txt</fromPath>
                    <fromRevision>243</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                    <toPath>dir242/d.txt</toPath>
                    <toRevision>2431</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-244</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                    <fromPath>dir243/e.txt</fromPath>
                    <fromRevision>244</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                    <toPath>dir243/e.txt</toPath>
                    <toRevision>2441</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-245</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                    <fromPath>dir244/f.txt</fromPath>
                    <fromRevision>245</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                    <toPath>dir244/f.txt</toPath>
                    <toRevision>2451</toRevision>
                </reviewItem>
            </reviewItems>
            <transitions>
                <transitionData>
                    <displayName>Summarize</displayName>
                    <name>action:summarizeReview</name>
                </transitionData>
            </transitions>
        </detailedReviewData>
    </detailedReviews>
    

    The detailed list of reviews that match the filter criteria.

  • 200 - application/json (detailedReviews) [expand]

    Example
    {
      "detailedReviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754",
        "reviewItems" : {
          "reviewItem" : [ {
            "permId" : {
              "id" : "CFR-239"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir238/a.txt",
            "fromRevision" : "239",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
            "toPath" : "dir238/a.txt",
            "toRevision" : "2391",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "anchorData" : {
              "anchorPath" : "trunk",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-240"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir239/d.txt",
            "fromRevision" : "240",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
            "toPath" : "dir239/d.txt",
            "toRevision" : "2401",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-241"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir240/c.txt",
            "fromRevision" : "241",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
            "toPath" : "dir240/c.txt",
            "toRevision" : "2411",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-242"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir241/b.txt",
            "fromRevision" : "242",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
            "toPath" : "dir241/b.txt",
            "toRevision" : "2421",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "tags/tag1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-243"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir242/d.txt",
            "fromRevision" : "243",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
            "toPath" : "dir242/d.txt",
            "toRevision" : "2431",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-244"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir243/e.txt",
            "fromRevision" : "244",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
            "toPath" : "dir243/e.txt",
            "toRevision" : "2441",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-245"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir244/f.txt",
            "fromRevision" : "245",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
            "toPath" : "dir244/f.txt",
            "toRevision" : "2451",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          } ]
        },
        "generalComments" : {
          "comments" : [ {
            "metrics" : {
            },
            "message" : "I thought you said you were going to *remove* this line?",
            "draft" : false,
            "deleted" : false,
            "defectRaised" : false,
            "defectApproved" : false,
            "readStatus" : "UNREAD",
            "user" : {
              "userName" : "joe",
              "displayName" : "Joe Bloggs",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "createDate" : "2014-12-04T10:57:08.419+0100",
            "permaId" : {
              "id" : "CR:1"
            },
            "replies" : [ ],
            "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
            "permId" : {
              "id" : "CR:1"
            },
            "parentCommentId" : {
            }
          } ]
        },
        "transitions" : {
          "transitionData" : [ {
            "name" : "action:summarizeReview",
            "displayName" : "Summarize"
          } ]
        },
        "actions" : {
          "actionData" : [ {
            "name" : "action:abandonReview",
            "displayName" : "Abandon"
          }, {
            "name" : "action:approveReview",
            "displayName" : "Approve"
          }, {
            "name" : "action:commentOnReview",
            "displayName" : "Comment"
          }, {
            "name" : "action:completeReview",
            "displayName" : "Complete"
          }, {
            "name" : "action:modifyReviewFiles",
            "displayName" : "Edit Review Details"
          } ]
        }
      } ]
    }

    The detailed list of reviews that match the filter criteria.

/rest-service/reviews-v1/search/{repository}?path=<value>

resource-wide template parameters
parameter value description

repository

string

reposiotry to search for file

Methods

GET

Return a list of Reviews which include a particular file.

The path parameter must be the full path name of a file in repository, with no leading slash.

request query parameters
parameter value description

path

string

path to find in reviews

available response representations:

  • 200 - application/xml (reviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviews>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
        <reviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
        </reviewData>
    </reviews>
    

    The list of reviews containing the specified file. Does not contain the review details.

  • 200 - application/json (reviews) [expand]

    Example
    {
      "reviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      }, {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754"
      } ]
    }

    The list of reviews containing the specified file. Does not contain the review details.

/rest-service/reviews-v1/search/{repository}/details?path=<value>

resource-wide template parameters
parameter value description

repository

string

repository to search for file.

Methods

GET

Return a list of Reviews which include a particular file.

The path parameter must be the full path name of a file in repository, with no leading slash.

For each review all details are included (review items + comments).

request query parameters
parameter value description

path

string

path to find in reviews.

available response representations:

  • 200 - application/xml (detailedReviews) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviews>
        <detailedReviewData>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <author>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </author>
            <createDate>2014-12-04T10:57:08.409+0100</createDate>
            <creator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Krustofski</displayName>
                <userName>joe</userName>
            </creator>
            <description>Description or statement of objectives for this example review.</description>
            <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
            <jiraIssueKey>FOO-6754</jiraIssueKey>
            <metricsVersion>4</metricsVersion>
            <moderator>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Scott the Moderator</displayName>
                <userName>scott</userName>
            </moderator>
            <name>Example review.</name>
            <permaId>
                <id>CR-FOO-21</id>
            </permaId>
            <permaIdHistory>CR-FOO-21</permaIdHistory>
            <projectKey>CR-FOO</projectKey>
            <type>REVIEW</type>
            <actions>
                <actionData>
                    <displayName>Abandon</displayName>
                    <name>action:abandonReview</name>
                </actionData>
                <actionData>
                    <displayName>Approve</displayName>
                    <name>action:approveReview</name>
                </actionData>
                <actionData>
                    <displayName>Comment</displayName>
                    <name>action:commentOnReview</name>
                </actionData>
                <actionData>
                    <displayName>Complete</displayName>
                    <name>action:completeReview</name>
                </actionData>
                <actionData>
                    <displayName>Edit Review Details</displayName>
                    <name>action:modifyReviewFiles</name>
                </actionData>
            </actions>
            <generalComments>
                <generalCommentData>
                    <createDate>2014-12-04T10:57:08.419+0100</createDate>
                    <defectApproved>false</defectApproved>
                    <defectRaised>false</defectRaised>
                    <deleted>false</deleted>
                    <draft>false</draft>
                    <message>I thought you said you were going to *remove* this line?</message>
                    <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                    <metrics/>
                    <parentCommentId/>
                    <readStatus>UNREAD</readStatus>
                    <replies/>
                    <user>
                        <avatarUrl>http://foo.com/avatar</avatarUrl>
                        <displayName>Joe Bloggs</displayName>
                        <userName>joe</userName>
                    </user>
                    <permId>
                        <id>CR:1</id>
                    </permId>
                    <permaId>
                        <id>CR:1</id>
                    </permaId>
                </generalCommentData>
            </generalComments>
            <reviewItems>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-239</id>
                    </permId>
                    <anchorData>
                        <anchorPath>trunk</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                    <fromPath>dir238/a.txt</fromPath>
                    <fromRevision>239</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                    <toPath>dir238/a.txt</toPath>
                    <toRevision>2391</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-240</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                    <fromPath>dir239/d.txt</fromPath>
                    <fromRevision>240</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                    <toPath>dir239/d.txt</toPath>
                    <toRevision>2401</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-241</id>
                    </permId>
                    <anchorData>
                        <anchorPath>branches/branch1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                    <fromPath>dir240/c.txt</fromPath>
                    <fromRevision>241</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                    <toPath>dir240/c.txt</toPath>
                    <toRevision>2411</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-242</id>
                    </permId>
                    <anchorData>
                        <anchorPath>tags/tag1</anchorPath>
                        <anchorRepository>REPO</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchorData>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                    <fromPath>dir241/b.txt</fromPath>
                    <fromRevision>242</fromRevision>
                    <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                    <toPath>dir241/b.txt</toPath>
                    <toRevision>2421</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-243</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                    <fromPath>dir242/d.txt</fromPath>
                    <fromRevision>243</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>true</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                    <toPath>dir242/d.txt</toPath>
                    <toRevision>2431</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-244</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                    <fromPath>dir243/e.txt</fromPath>
                    <fromRevision>244</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                    <toPath>dir243/e.txt</toPath>
                    <toRevision>2441</toRevision>
                </reviewItem>
                <reviewItem>
                    <participants>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Fred Eaglesmith</displayName>
                                <userName>fred</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                        <participant>
                            <user>
                                <avatarUrl>http://foo.com/avatar</avatarUrl>
                                <displayName>Corb Lund</displayName>
                                <userName>clund</userName>
                            </user>
                            <completed>false</completed>
                        </participant>
                    </participants>
                    <permId>
                        <id>CFR-245</id>
                    </permId>
                    <authorName>evzijst</authorName>
                    <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                    <commitType>Modified</commitType>
                    <fileType>File</fileType>
                    <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                    <fromPath>dir244/f.txt</fromPath>
                    <fromRevision>245</fromRevision>
                    <repositoryName>REPO</repositoryName>
                    <showAsDiff>false</showAsDiff>
                    <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                    <toPath>dir244/f.txt</toPath>
                    <toRevision>2451</toRevision>
                </reviewItem>
            </reviewItems>
            <transitions>
                <transitionData>
                    <displayName>Summarize</displayName>
                    <name>action:summarizeReview</name>
                </transitionData>
            </transitions>
        </detailedReviewData>
    </detailedReviews>
    

    The detailed list of reviews containing the specified file, with the details of the review, such as comments (and its wiki rendered html), and review items.

  • 200 - application/json (detailedReviews) [expand]

    Example
    {
      "detailedReviewData" : [ {
        "projectKey" : "CR-FOO",
        "name" : "Example review.",
        "description" : "Description or statement of objectives for this example review.",
        "author" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "moderator" : {
          "userName" : "scott",
          "displayName" : "Scott the Moderator",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "creator" : {
          "userName" : "joe",
          "displayName" : "Joe Krustofski",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "permaId" : {
          "id" : "CR-FOO-21"
        },
        "permaIdHistory" : [ "CR-FOO-21" ],
        "type" : "REVIEW",
        "allowReviewersToJoin" : true,
        "metricsVersion" : 4,
        "createDate" : "2014-12-04T10:57:08.409+0100",
        "dueDate" : "2014-12-05T10:57:08.409+0100",
        "jiraIssueKey" : "FOO-6754",
        "reviewItems" : {
          "reviewItem" : [ {
            "permId" : {
              "id" : "CFR-239"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir238/a.txt",
            "fromRevision" : "239",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
            "toPath" : "dir238/a.txt",
            "toRevision" : "2391",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "anchorData" : {
              "anchorPath" : "trunk",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-240"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir239/d.txt",
            "fromRevision" : "240",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
            "toPath" : "dir239/d.txt",
            "toRevision" : "2401",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-241"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir240/c.txt",
            "fromRevision" : "241",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
            "toPath" : "dir240/c.txt",
            "toRevision" : "2411",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "branches/branch1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-242"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir241/b.txt",
            "fromRevision" : "242",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
            "toPath" : "dir241/b.txt",
            "toRevision" : "2421",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
            "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "anchorData" : {
              "anchorPath" : "tags/tag1",
              "anchorRepository" : "REPO",
              "stripCount" : 0
            },
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-243"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir242/d.txt",
            "fromRevision" : "243",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
            "toPath" : "dir242/d.txt",
            "toRevision" : "2431",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : true,
            "commitDate" : 1417687028444,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-244"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir243/e.txt",
            "fromRevision" : "244",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
            "toPath" : "dir243/e.txt",
            "toRevision" : "2441",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          }, {
            "permId" : {
              "id" : "CFR-245"
            },
            "participants" : [ {
              "user" : {
                "userName" : "fred",
                "displayName" : "Fred Eaglesmith",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            }, {
              "user" : {
                "userName" : "clund",
                "displayName" : "Corb Lund",
                "avatarUrl" : "http://foo.com/avatar"
              },
              "completed" : false
            } ],
            "repositoryName" : "REPO",
            "fromPath" : "dir244/f.txt",
            "fromRevision" : "245",
            "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
            "toPath" : "dir244/f.txt",
            "toRevision" : "2451",
            "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
            "fileType" : "File",
            "commitType" : "Modified",
            "authorName" : "evzijst",
            "showAsDiff" : false,
            "commitDate" : 1417687028445,
            "expandedRevisions" : [ ]
          } ]
        },
        "generalComments" : {
          "comments" : [ {
            "metrics" : {
            },
            "message" : "I thought you said you were going to *remove* this line?",
            "draft" : false,
            "deleted" : false,
            "defectRaised" : false,
            "defectApproved" : false,
            "readStatus" : "UNREAD",
            "user" : {
              "userName" : "joe",
              "displayName" : "Joe Bloggs",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "createDate" : "2014-12-04T10:57:08.419+0100",
            "permaId" : {
              "id" : "CR:1"
            },
            "replies" : [ ],
            "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
            "permId" : {
              "id" : "CR:1"
            },
            "parentCommentId" : {
            }
          } ]
        },
        "transitions" : {
          "transitionData" : [ {
            "name" : "action:summarizeReview",
            "displayName" : "Summarize"
          } ]
        },
        "actions" : {
          "actionData" : [ {
            "name" : "action:abandonReview",
            "displayName" : "Abandon"
          }, {
            "name" : "action:approveReview",
            "displayName" : "Approve"
          }, {
            "name" : "action:commentOnReview",
            "displayName" : "Comment"
          }, {
            "name" : "action:completeReview",
            "displayName" : "Complete"
          }, {
            "name" : "action:modifyReviewFiles",
            "displayName" : "Edit Review Details"
          } ]
        }
      } ]
    }

    The detailed list of reviews containing the specified file, with the details of the review, such as comments (and its wiki rendered html), and review items.

/rest-service/reviews-v1/{id}

resource-wide template parameters
parameter value description

id

string

the permId of the review to delete (e.g. "CR-45").

Methods

GET

Get a single review by its permId (e.g. "CR-45"). If the review does not exist, a 404 is returned.

The moderator element may not exist if the review does not have a Moderator.

available response representations:

  • 200 - application/xml (reviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
    </reviewData>
    

    A ReviewData instance containing the attributes of the review. Does not contain the details of the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 200 - application/json (reviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754"
    }

    A ReviewData instance containing the attributes of the review. Does not contain the details of the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review does not exist.

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review does not exist.

DELETE

Permanently deletes the specified review. The review must have been abandoned.

/rest-service/reviews-v1/{id}/details

resource-wide template parameters
parameter value description

id

string

the permId of the review (e.g. "CR-45").

Methods

GET

Returns the specified review.

All details are included (review items + comments).

available response representations:

  • 200 - application/xml (detailedReviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
        <actions>
            <actionData>
                <displayName>Abandon</displayName>
                <name>action:abandonReview</name>
            </actionData>
            <actionData>
                <displayName>Approve</displayName>
                <name>action:approveReview</name>
            </actionData>
            <actionData>
                <displayName>Comment</displayName>
                <name>action:commentOnReview</name>
            </actionData>
            <actionData>
                <displayName>Complete</displayName>
                <name>action:completeReview</name>
            </actionData>
            <actionData>
                <displayName>Edit Review Details</displayName>
                <name>action:modifyReviewFiles</name>
            </actionData>
        </actions>
        <generalComments>
            <generalCommentData>
                <createDate>2014-12-04T10:57:08.419+0100</createDate>
                <defectApproved>false</defectApproved>
                <defectRaised>false</defectRaised>
                <deleted>false</deleted>
                <draft>false</draft>
                <message>I thought you said you were going to *remove* this line?</message>
                <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                <metrics/>
                <parentCommentId/>
                <readStatus>UNREAD</readStatus>
                <replies/>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Joe Bloggs</displayName>
                    <userName>joe</userName>
                </user>
                <permId>
                    <id>CR:1</id>
                </permId>
                <permaId>
                    <id>CR:1</id>
                </permaId>
            </generalCommentData>
        </generalComments>
        <reviewItems>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-239</id>
                </permId>
                <anchorData>
                    <anchorPath>trunk</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                <fromPath>dir238/a.txt</fromPath>
                <fromRevision>239</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                <toPath>dir238/a.txt</toPath>
                <toRevision>2391</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-240</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                <fromPath>dir239/d.txt</fromPath>
                <fromRevision>240</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                <toPath>dir239/d.txt</toPath>
                <toRevision>2401</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-241</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                <fromPath>dir240/c.txt</fromPath>
                <fromRevision>241</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                <toPath>dir240/c.txt</toPath>
                <toRevision>2411</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-242</id>
                </permId>
                <anchorData>
                    <anchorPath>tags/tag1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                <fromPath>dir241/b.txt</fromPath>
                <fromRevision>242</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                <toPath>dir241/b.txt</toPath>
                <toRevision>2421</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-243</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                <fromPath>dir242/d.txt</fromPath>
                <fromRevision>243</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                <toPath>dir242/d.txt</toPath>
                <toRevision>2431</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-244</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                <fromPath>dir243/e.txt</fromPath>
                <fromRevision>244</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                <toPath>dir243/e.txt</toPath>
                <toRevision>2441</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-245</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                <fromPath>dir244/f.txt</fromPath>
                <fromRevision>245</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                <toPath>dir244/f.txt</toPath>
                <toRevision>2451</toRevision>
            </reviewItem>
        </reviewItems>
        <transitions>
            <transitionData>
                <displayName>Summarize</displayName>
                <name>action:summarizeReview</name>
            </transitionData>
        </transitions>
    </detailedReviewData>
    

    A detailedReviewData element containing the attributes of the review, with the details of the review, such as comments (and its wiki rendered html), and review items.

    XML Schema

    Source: crucible.xsd

    <xs:element name="detailedReviewData" type="detailedReviewData"/>
  • 200 - application/json (detailedReviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754",
      "reviewItems" : {
        "reviewItem" : [ {
          "permId" : {
            "id" : "CFR-239"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir238/a.txt",
          "fromRevision" : "239",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
          "toPath" : "dir238/a.txt",
          "toRevision" : "2391",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "anchorData" : {
            "anchorPath" : "trunk",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-240"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir239/d.txt",
          "fromRevision" : "240",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
          "toPath" : "dir239/d.txt",
          "toRevision" : "2401",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-241"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir240/c.txt",
          "fromRevision" : "241",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
          "toPath" : "dir240/c.txt",
          "toRevision" : "2411",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-242"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir241/b.txt",
          "fromRevision" : "242",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
          "toPath" : "dir241/b.txt",
          "toRevision" : "2421",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "tags/tag1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-243"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir242/d.txt",
          "fromRevision" : "243",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
          "toPath" : "dir242/d.txt",
          "toRevision" : "2431",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-244"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir243/e.txt",
          "fromRevision" : "244",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
          "toPath" : "dir243/e.txt",
          "toRevision" : "2441",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-245"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir244/f.txt",
          "fromRevision" : "245",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
          "toPath" : "dir244/f.txt",
          "toRevision" : "2451",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        } ]
      },
      "generalComments" : {
        "comments" : [ {
          "metrics" : {
          },
          "message" : "I thought you said you were going to *remove* this line?",
          "draft" : false,
          "deleted" : false,
          "defectRaised" : false,
          "defectApproved" : false,
          "readStatus" : "UNREAD",
          "user" : {
            "userName" : "joe",
            "displayName" : "Joe Bloggs",
            "avatarUrl" : "http://foo.com/avatar"
          },
          "createDate" : "2014-12-04T10:57:08.419+0100",
          "permaId" : {
            "id" : "CR:1"
          },
          "replies" : [ ],
          "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
          "permId" : {
            "id" : "CR:1"
          },
          "parentCommentId" : {
          }
        } ]
      },
      "transitions" : {
        "transitionData" : [ {
          "name" : "action:summarizeReview",
          "displayName" : "Summarize"
        } ]
      },
      "actions" : {
        "actionData" : [ {
          "name" : "action:abandonReview",
          "displayName" : "Abandon"
        }, {
          "name" : "action:approveReview",
          "displayName" : "Approve"
        }, {
          "name" : "action:commentOnReview",
          "displayName" : "Comment"
        }, {
          "name" : "action:completeReview",
          "displayName" : "Complete"
        }, {
          "name" : "action:modifyReviewFiles",
          "displayName" : "Edit Review Details"
        } ]
      }
    }

    A detailedReviewData element containing the attributes of the review, with the details of the review, such as comments (and its wiki rendered html), and review items.

    XML Schema

    Source: crucible.xsd

    <xs:element name="detailedReviewData" type="detailedReviewData"/>

/rest-service/reviews-v1/{id}/actions

resource-wide template parameters
parameter value description

id

string

the permId of the a review (e.g. "CR-45").

Methods

GET

Get a list of the actions which the current user is allowed to perform on the review.

This shows actions the user has permission to perform - the review may not be in a suitable state for all these actions to be performed.

available response representations:

  • 200 - application/xml (actions) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <actions>
        <actionData>
            <displayName>Abandon</displayName>
            <name>action:abandonReview</name>
        </actionData>
        <actionData>
            <displayName>Approve</displayName>
            <name>action:approveReview</name>
        </actionData>
        <actionData>
            <displayName>Comment</displayName>
            <name>action:commentOnReview</name>
        </actionData>
        <actionData>
            <displayName>Complete</displayName>
            <name>action:completeReview</name>
        </actionData>
        <actionData>
            <displayName>Edit Review Details</displayName>
            <name>action:modifyReviewFiles</name>
        </actionData>
    </actions>
    

    The list of all actions in the review's workflow.

    XML Schema

    Source: crucible.xsd

    <xs:element name="actions" type="actions"/>
  • 200 - application/json (actions) [expand]

    Example
    {
      "actionData" : [ {
        "name" : "action:abandonReview",
        "displayName" : "Abandon"
      }, {
        "name" : "action:approveReview",
        "displayName" : "Approve"
      }, {
        "name" : "action:commentOnReview",
        "displayName" : "Comment"
      }, {
        "name" : "action:completeReview",
        "displayName" : "Complete"
      }, {
        "name" : "action:modifyReviewFiles",
        "displayName" : "Edit Review Details"
      } ]
    }

    The list of all actions in the review's workflow.

    XML Schema

    Source: crucible.xsd

    <xs:element name="actions" type="actions"/>

/rest-service/reviews-v1/{id}/transitions

resource-wide template parameters
parameter value description

id

string

the permId of the a review (e.g. "CR-45").

Methods

GET

Get a list of the actions which the current user can perform on this review, given its current state and the user's permissions.

available response representations:

  • 200 - application/xml (transitions) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <transitions>
        <transitionData>
            <displayName>Summarize</displayName>
            <name>action:summarizeReview</name>
        </transitionData>
    </transitions>
    

    The list of the state transitions that are available in the review's current workflow state.

    XML Schema

    Source: crucible.xsd

    <xs:element name="transitions" type="transitions"/>
  • 200 - application/json (transitions) [expand]

    Example
    {
      "transitionData" : [ {
        "name" : "action:summarizeReview",
        "displayName" : "Summarize"
      } ]
    }

    The list of the state transitions that are available in the review's current workflow state.

    XML Schema

    Source: crucible.xsd

    <xs:element name="transitions" type="transitions"/>

/rest-service/reviews-v1/{id}/addChangeset

resource-wide template parameters
parameter value description

id

string

the perm id of the review to add the patch to

Methods

POST

acceptable request representations:

  • application/xml (addChangeset) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <addChangeset>
        <repository>repo1</repository>
        <changesets>
            <changesetData>
                <id>68f730e</id>
            </changesetData>
            <changesetData>
                <id>2b177b2</id>
            </changesetData>
        </changesets>
    </addChangeset>
    

    Example of a request document used to add a changeset to a review

  • application/json (addChangeset) [expand]

    Example
    {
      "repository" : "repo1",
      "changesets" : {
        "changesetData" : [ {
          "id" : "68f730e"
        }, {
          "id" : "2b177b2"
        } ]
      }
    }

    Example of a request document used to add a changeset to a review

available response representations:

  • 200 - application/xml (reviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
    </reviewData>
    

    The response is the reviewData containing the added changeset

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 200 - application/json (reviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754"
    }

    The response is the reviewData containing the added changeset

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 400 (error) [expand]

    If a repository name is not specified

  • 409 (error) [expand]

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

/rest-service/reviews-v1/{id}/patch

resource-wide template parameters
parameter value description

id

string

the review id to get the patches for

Methods

POST

Add the revisions in a patch to an existing review.

If the anchor field is filled Crucible will attempt to anchor the patch to the specified repository/path

If the source field is filled Crucible will attempt to add the patch to the existing patch with the given source name. Both patches need to be anchored to the same repository. Use GET reviews-v1/{id}/patch to get a list of valid sources.

acceptable request representations:

  • application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <addPatch>
        <patch>Index: emptytests/notempty/a.txt
    ===================================================================
    diff -u -N -r1.31 -r1.32
    --- emptytests/notempty/a.txt	22 Sep 2004 00:38:15 -0000	1.31
    +++ emptytests/notempty/a.txt	5 Dec 2004 01:04:25 -0000	1.32
    @@ -4,4 +4,5 @@
     hello there :D
     CRU-123
     http://madbean.com/blog/
    -!
    \ No newline at end of file
    +!
    +foobie
    \ No newline at end of file
    Index: test/a.txt
    ===================================================================
    diff -u -N -r1.31 -r1.32
    --- test/a.txt	22 Sep 2004 00:38:15 -0000	1.31
    +++ test/a.txt	5 Dec 2004 01:04:25 -0000	1.32
    @@ -4,4 +4,5 @@
     hello there :D
     CRU-123
     http://madbean.com/blog/
    -!
    \ No newline at end of file
    +!
    +foobie
    \ No newline at end of file</patch>
        <anchor>
            <anchorPath>/</anchorPath>
            <anchorRepository>REPO</anchorRepository>
            <stripCount>2</stripCount>
        </anchor>
        <source>PATCH:10</source>
    </addPatch>
    

    Example of a request document used to create a new review with a patch

  • application/json [expand]

    Example
    {
      "patch" : "Index: emptytests/notempty/a.txt\n===================================================================\ndiff -u -N -r1.31 -r1.32\n--- emptytests/notempty/a.txt\t22 Sep 2004 00:38:15 -0000\t1.31\n+++ emptytests/notempty/a.txt\t5 Dec 2004 01:04:25 -0000\t1.32\n@@ -4,4 +4,5 @@\n hello there :D\n CRU-123\n http://madbean.com/blog/\n-!\n\\ No newline at end of file\n+!\n+foobie\n\\ No newline at end of file\nIndex: test/a.txt\n===================================================================\ndiff -u -N -r1.31 -r1.32\n--- test/a.txt\t22 Sep 2004 00:38:15 -0000\t1.31\n+++ test/a.txt\t5 Dec 2004 01:04:25 -0000\t1.32\n@@ -4,4 +4,5 @@\n hello there :D\n CRU-123\n http://madbean.com/blog/\n-!\n\\ No newline at end of file\n+!\n+foobie\n\\ No newline at end of file",
      "anchor" : {
        "anchorPath" : "/",
        "anchorRepository" : "REPO",
        "stripCount" : 2
      },
      "source" : "PATCH:10"
    }

    Example of a request document used to create a new review with a patch

available response representations:

  • 200 - application/xml (reviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
    </reviewData>
    

    The response is the reviewData structure for the review being updated

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 200 - application/json (reviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754"
    }

    The response is the reviewData structure for the review being updated

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

GET

Get a list of patches and their details for the given review

available response representations:

  • 200 - application/xml (patchGroups) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <patchGroups>
        <patchGroup>
            <displayName>diff1.patch (6 minutes ago)</displayName>
            <patches>
                <patch>
                    <fileName>diff1.patch</fileName>
                    <id>5</id>
                    <uploadDate>2014-12-04T10:57:08.451+01:00</uploadDate>
                    <url>crucible/cru/CR-1/downloadpatch/5/diff1.patch</url>
                </patch>
            </patches>
            <sourceName>PATCH:5</sourceName>
        </patchGroup>
        <patchGroup>
            <displayName>diff2-iteration1.patch (46 minutes ago) - 3 iterations</displayName>
            <patches>
                <patch>
                    <anchor>
                        <anchorPath>/</anchorPath>
                        <anchorRepository>SvnRepository</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchor>
                    <fileName>diff2-iteration1.patch</fileName>
                    <id>50</id>
                    <uploadDate>2014-12-04T10:57:08.458+01:00</uploadDate>
                    <url>crucible/cru/CR-1/downloadpatch/50/diff2-iteration1.patch</url>
                </patch>
                <patch>
                    <anchor>
                        <anchorPath>/</anchorPath>
                        <anchorRepository>SvnRepository</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchor>
                    <fileName>diff2-iteration2.patch</fileName>
                    <id>51</id>
                    <uploadDate>2014-12-04T10:57:08.458+01:00</uploadDate>
                    <url>crucible/cru/CR-1/downloadpatch/51/diff2-iteration2.patch</url>
                </patch>
                <patch>
                    <anchor>
                        <anchorPath>/</anchorPath>
                        <anchorRepository>SvnRepository</anchorRepository>
                        <stripCount>0</stripCount>
                    </anchor>
                    <fileName>diff2-iteration3.patch</fileName>
                    <id>52</id>
                    <uploadDate>2014-12-04T10:57:08.458+01:00</uploadDate>
                    <url>crucible/cru/CR-1/downloadpatch/52/diff2-iteration3.patch</url>
                </patch>
            </patches>
            <sourceName>PATCH:50</sourceName>
        </patchGroup>
    </patchGroups>
    

  • 200 - application/json (patchGroups) [expand]

    Example
    {
      "patchGroup" : [ {
        "patches" : [ {
          "id" : 5,
          "fileName" : "diff1.patch",
          "uploadDate" : 1417687028451,
          "url" : "crucible/cru/CR-1/downloadpatch/5/diff1.patch"
        } ],
        "sourceName" : "PATCH:5",
        "displayName" : "diff1.patch (6 minutes ago)"
      }, {
        "patches" : [ {
          "id" : 50,
          "fileName" : "diff2-iteration1.patch",
          "uploadDate" : 1417687028458,
          "anchor" : {
            "anchorPath" : "/",
            "anchorRepository" : "SvnRepository",
            "stripCount" : 0
          },
          "url" : "crucible/cru/CR-1/downloadpatch/50/diff2-iteration1.patch"
        }, {
          "id" : 51,
          "fileName" : "diff2-iteration2.patch",
          "uploadDate" : 1417687028458,
          "anchor" : {
            "anchorPath" : "/",
            "anchorRepository" : "SvnRepository",
            "stripCount" : 0
          },
          "url" : "crucible/cru/CR-1/downloadpatch/51/diff2-iteration2.patch"
        }, {
          "id" : 52,
          "fileName" : "diff2-iteration3.patch",
          "uploadDate" : 1417687028458,
          "anchor" : {
            "anchorPath" : "/",
            "anchorRepository" : "SvnRepository",
            "stripCount" : 0
          },
          "url" : "crucible/cru/CR-1/downloadpatch/52/diff2-iteration3.patch"
        } ],
        "sourceName" : "PATCH:50",
        "displayName" : "diff2-iteration1.patch (46 minutes ago) - 3 iterations"
      } ]
    }

/rest-service/reviews-v1/{id}/addPatch

resource-wide template parameters
parameter value description

id

string

Methods

POST

Old, non-restful name. Kept for backwards compatibility. Exactly the same as POSTing to /{id}/patch

acceptable request representations:

  • application/xml [expand]

    Deprecated

  • application/json [expand]

    Deprecated

available response representations:

  • 200 [expand]

    Deprecated

  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

/rest-service/reviews-v1/{id}/reviewers

resource-wide template parameters
parameter value description

id

string

the id of the review to add to

Methods

GET

Get a list of reviewers in the review given by the permaid id.

available response representations:

  • 200 - application/xml (reviewers) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewers>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/2</avatarUrl>
            <displayName>display name of user2</displayName>
            <userName>user2</userName>
            <completed>true</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/1</avatarUrl>
            <displayName>display name of user1</displayName>
            <userName>user1</userName>
            <completed>false</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/4</avatarUrl>
            <displayName>display name of user4</displayName>
            <userName>user4</userName>
            <completed>true</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/3</avatarUrl>
            <displayName>display name of user3</displayName>
            <userName>user3</userName>
            <completed>false</completed>
        </reviewer>
    </reviewers>
    

    A list of reviewers and whether they've completed the review or now.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>
  • 200 - application/json (reviewers) [expand]

    Example
    {
      "reviewer" : [ {
        "userName" : "user2",
        "displayName" : "display name of user2",
        "avatarUrl" : "http://gravatar.com/url/2",
        "completed" : true
      }, {
        "userName" : "user1",
        "displayName" : "display name of user1",
        "avatarUrl" : "http://gravatar.com/url/1",
        "completed" : false
      }, {
        "userName" : "user4",
        "displayName" : "display name of user4",
        "avatarUrl" : "http://gravatar.com/url/4",
        "completed" : true
      }, {
        "userName" : "user3",
        "displayName" : "display name of user3",
        "avatarUrl" : "http://gravatar.com/url/3",
        "completed" : false
      } ]
    }

    A list of reviewers and whether they've completed the review or now.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>

POST

Adds the given list of reviewers to the review.

acceptable request representations:

  • application/xml (reviewers) [expand]

    a list of comma separated reviewers

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>
  • application/json (reviewers) [expand]

    a list of comma separated reviewers

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>

/rest-service/reviews-v1/{id}/reviewers/completed

resource-wide template parameters
parameter value description

id

string

the review perma id to retrieve reviewers

Methods

GET

Gets a list of completed reviewers.

available response representations:

  • 200 - application/xml (reviewers) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewers>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/2</avatarUrl>
            <displayName>display name of user2</displayName>
            <userName>user2</userName>
            <completed>true</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/1</avatarUrl>
            <displayName>display name of user1</displayName>
            <userName>user1</userName>
            <completed>true</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/4</avatarUrl>
            <displayName>display name of user4</displayName>
            <userName>user4</userName>
            <completed>true</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/3</avatarUrl>
            <displayName>display name of user3</displayName>
            <userName>user3</userName>
            <completed>true</completed>
        </reviewer>
    </reviewers>
    

    A list of reviewers that have completed the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>
  • 200 - application/json (reviewers) [expand]

    Example
    {
      "reviewer" : [ {
        "userName" : "user2",
        "displayName" : "display name of user2",
        "avatarUrl" : "http://gravatar.com/url/2",
        "completed" : true
      }, {
        "userName" : "user1",
        "displayName" : "display name of user1",
        "avatarUrl" : "http://gravatar.com/url/1",
        "completed" : true
      }, {
        "userName" : "user4",
        "displayName" : "display name of user4",
        "avatarUrl" : "http://gravatar.com/url/4",
        "completed" : true
      }, {
        "userName" : "user3",
        "displayName" : "display name of user3",
        "avatarUrl" : "http://gravatar.com/url/3",
        "completed" : true
      } ]
    }

    A list of reviewers that have completed the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>

/rest-service/reviews-v1/{id}/reviewers/uncompleted

resource-wide template parameters
parameter value description

id

string

the review perma id to retrieve reviewers

Methods

GET

Gets a list of reviewers that have not completed the review.

available response representations:

  • 200 - application/xml (reviewers) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewers>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/2</avatarUrl>
            <displayName>display name of user2</displayName>
            <userName>user2</userName>
            <completed>false</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/1</avatarUrl>
            <displayName>display name of user1</displayName>
            <userName>user1</userName>
            <completed>false</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/4</avatarUrl>
            <displayName>display name of user4</displayName>
            <userName>user4</userName>
            <completed>false</completed>
        </reviewer>
        <reviewer>
            <avatarUrl>http://gravatar.com/url/3</avatarUrl>
            <displayName>display name of user3</displayName>
            <userName>user3</userName>
            <completed>false</completed>
        </reviewer>
    </reviewers>
    

    A list of reviewers that have not completed the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>
  • 200 - application/json (reviewers) [expand]

    Example
    {
      "reviewer" : [ {
        "userName" : "user2",
        "displayName" : "display name of user2",
        "avatarUrl" : "http://gravatar.com/url/2",
        "completed" : false
      }, {
        "userName" : "user1",
        "displayName" : "display name of user1",
        "avatarUrl" : "http://gravatar.com/url/1",
        "completed" : false
      }, {
        "userName" : "user4",
        "displayName" : "display name of user4",
        "avatarUrl" : "http://gravatar.com/url/4",
        "completed" : false
      }, {
        "userName" : "user3",
        "displayName" : "display name of user3",
        "avatarUrl" : "http://gravatar.com/url/3",
        "completed" : false
      } ]
    }

    A list of reviewers that have not completed the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewers" type="reviewers"/>

/rest-service/reviews-v1/{id}/reviewers/{username}

resource-wide template parameters
parameter value description

id

string

the perma id of the review

username

string

the name of the reviewer.

Methods

DELETE

Removes the reviewer from the review.

/rest-service/reviews-v1/{id}/reviewitems

resource-wide template parameters
parameter value description

id

string

the id of the review (e.g. "CR-362").

Methods

GET

Returns a list of all the items in a review.

available response representations:

  • 200 - application/xml (reviewItems) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItems>
        <reviewItem>
            <participants>
                <participant>
                    <user>
                        <avatarUrl>http://foo.com/avatar</avatarUrl>
                        <displayName>Fred Eaglesmith</displayName>
                        <userName>fred</userName>
                    </user>
                    <completed>false</completed>
                </participant>
                <participant>
                    <user>
                        <avatarUrl>http://foo.com/avatar</avatarUrl>
                        <displayName>Corb Lund</displayName>
                        <userName>clund</userName>
                    </user>
                    <completed>false</completed>
                </participant>
            </participants>
            <permId>
                <id>CFR-7453</id>
            </permId>
            <authorName>evzijst</authorName>
            <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
            <commitType>Modified</commitType>
            <fileType>File</fileType>
            <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
            <fromPath>/project/trunk/pom.xml</fromPath>
            <fromRevision>688</fromRevision>
            <repositoryName>REPO</repositoryName>
            <showAsDiff>true</showAsDiff>
            <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
            <toPath>/project/trunk/pom.xml</toPath>
            <toRevision>6881</toRevision>
        </reviewItem>
    </reviewItems>
    

    A list of all the items in the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItems" type="reviewItems"/>
  • 200 - application/json (reviewItems) [expand]

    Example
    {
      "reviewItem" : [ {
        "permId" : {
          "id" : "CFR-7453"
        },
        "participants" : [ {
          "user" : {
            "userName" : "fred",
            "displayName" : "Fred Eaglesmith",
            "avatarUrl" : "http://foo.com/avatar"
          },
          "completed" : false
        }, {
          "user" : {
            "userName" : "clund",
            "displayName" : "Corb Lund",
            "avatarUrl" : "http://foo.com/avatar"
          },
          "completed" : false
        } ],
        "repositoryName" : "REPO",
        "fromPath" : "/project/trunk/pom.xml",
        "fromRevision" : "688",
        "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
        "toPath" : "/project/trunk/pom.xml",
        "toRevision" : "6881",
        "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
        "fileType" : "File",
        "commitType" : "Modified",
        "authorName" : "evzijst",
        "showAsDiff" : true,
        "commitDate" : 1417687028439
      } ]
    }

    A list of all the items in the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItems" type="reviewItems"/>

POST

Add the changes between two files in a fisheye repository to the review.

This call includes the Location repsonse header that contains the URL of the newly created entity.

acceptable request representations:

  • application/xml (reviewItem) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants/>
        <permId/>
        <revisions size="0"/>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>689</toRevision>
    </reviewItem>
    

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • application/json (reviewItem) [expand]

    Example
    {
      "permId" : {
      },
      "participants" : [ ],
      "revisions" : {
        "size" : 0
      },
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "689"
    }

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>

available response representations:

  • 200 - application/xml (reviewItem) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    A reviewItem element containing details of the diff added to the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • 200 - application/json (reviewItem) [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    A reviewItem element containing details of the diff added to the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first.

/rest-service/reviews-v1/{id}/reviewitems/revisions

resource-wide template parameters
parameter value description

id

string

the id of the review (e.g. "CR-362").

Methods

POST

Adds a review item for each of the supplied crucibleRevisionData elements.

Provide a list of crucibleRevisionData elements, each one containing the desired shape of the review item. If a crucibleRevisionData element contains a path that already exists (i.e., an existing review item with the same path is in the review), then the crucibleRevisionData element given here will merge the revisions with the existing review item revisions instead of creating a new review item.

acceptable request representations:

  • application/xml (revisions) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <revisions>
        <revisionData>
            <rev>688</rev>
            <rev>689</rev>
            <source>REPO</source>
            <path>/project/trunk/pom.xml</path>
        </revisionData>
    </revisions>
    

  • application/json (revisions) [expand]

    Example
    {
      "revisionData" : [ {
        "source" : "REPO",
        "path" : "/project/trunk/pom.xml",
        "rev" : [ "688", "689" ]
      } ]
    }

available response representations:

  • 200 - application/xml (detailedReviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
        <actions>
            <actionData>
                <displayName>Abandon</displayName>
                <name>action:abandonReview</name>
            </actionData>
            <actionData>
                <displayName>Approve</displayName>
                <name>action:approveReview</name>
            </actionData>
            <actionData>
                <displayName>Comment</displayName>
                <name>action:commentOnReview</name>
            </actionData>
            <actionData>
                <displayName>Complete</displayName>
                <name>action:completeReview</name>
            </actionData>
            <actionData>
                <displayName>Edit Review Details</displayName>
                <name>action:modifyReviewFiles</name>
            </actionData>
        </actions>
        <generalComments>
            <generalCommentData>
                <createDate>2014-12-04T10:57:08.419+0100</createDate>
                <defectApproved>false</defectApproved>
                <defectRaised>false</defectRaised>
                <deleted>false</deleted>
                <draft>false</draft>
                <message>I thought you said you were going to *remove* this line?</message>
                <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                <metrics/>
                <parentCommentId/>
                <readStatus>UNREAD</readStatus>
                <replies/>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Joe Bloggs</displayName>
                    <userName>joe</userName>
                </user>
                <permId>
                    <id>CR:1</id>
                </permId>
                <permaId>
                    <id>CR:1</id>
                </permaId>
            </generalCommentData>
        </generalComments>
        <reviewItems>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-239</id>
                </permId>
                <anchorData>
                    <anchorPath>trunk</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                <fromPath>dir238/a.txt</fromPath>
                <fromRevision>239</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                <toPath>dir238/a.txt</toPath>
                <toRevision>2391</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-240</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                <fromPath>dir239/d.txt</fromPath>
                <fromRevision>240</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                <toPath>dir239/d.txt</toPath>
                <toRevision>2401</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-241</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                <fromPath>dir240/c.txt</fromPath>
                <fromRevision>241</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                <toPath>dir240/c.txt</toPath>
                <toRevision>2411</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-242</id>
                </permId>
                <anchorData>
                    <anchorPath>tags/tag1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                <fromPath>dir241/b.txt</fromPath>
                <fromRevision>242</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                <toPath>dir241/b.txt</toPath>
                <toRevision>2421</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-243</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                <fromPath>dir242/d.txt</fromPath>
                <fromRevision>243</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                <toPath>dir242/d.txt</toPath>
                <toRevision>2431</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-244</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                <fromPath>dir243/e.txt</fromPath>
                <fromRevision>244</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                <toPath>dir243/e.txt</toPath>
                <toRevision>2441</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-245</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                <fromPath>dir244/f.txt</fromPath>
                <fromRevision>245</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                <toPath>dir244/f.txt</toPath>
                <toRevision>2451</toRevision>
            </reviewItem>
        </reviewItems>
        <transitions>
            <transitionData>
                <displayName>Summarize</displayName>
                <name>action:summarizeReview</name>
            </transitionData>
        </transitions>
    </detailedReviewData>
    

    A detailedReviewData element object with the added crucibleRevisionData elements.

    XML Schema

    Source: crucible.xsd

    <xs:element name="detailedReviewData" type="detailedReviewData"/>
  • 200 - application/json (detailedReviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754",
      "reviewItems" : {
        "reviewItem" : [ {
          "permId" : {
            "id" : "CFR-239"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir238/a.txt",
          "fromRevision" : "239",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
          "toPath" : "dir238/a.txt",
          "toRevision" : "2391",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "anchorData" : {
            "anchorPath" : "trunk",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-240"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir239/d.txt",
          "fromRevision" : "240",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
          "toPath" : "dir239/d.txt",
          "toRevision" : "2401",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-241"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir240/c.txt",
          "fromRevision" : "241",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
          "toPath" : "dir240/c.txt",
          "toRevision" : "2411",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-242"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir241/b.txt",
          "fromRevision" : "242",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
          "toPath" : "dir241/b.txt",
          "toRevision" : "2421",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "tags/tag1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-243"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir242/d.txt",
          "fromRevision" : "243",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
          "toPath" : "dir242/d.txt",
          "toRevision" : "2431",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-244"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir243/e.txt",
          "fromRevision" : "244",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
          "toPath" : "dir243/e.txt",
          "toRevision" : "2441",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-245"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir244/f.txt",
          "fromRevision" : "245",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
          "toPath" : "dir244/f.txt",
          "toRevision" : "2451",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        } ]
      },
      "generalComments" : {
        "comments" : [ {
          "metrics" : {
          },
          "message" : "I thought you said you were going to *remove* this line?",
          "draft" : false,
          "deleted" : false,
          "defectRaised" : false,
          "defectApproved" : false,
          "readStatus" : "UNREAD",
          "user" : {
            "userName" : "joe",
            "displayName" : "Joe Bloggs",
            "avatarUrl" : "http://foo.com/avatar"
          },
          "createDate" : "2014-12-04T10:57:08.419+0100",
          "permaId" : {
            "id" : "CR:1"
          },
          "replies" : [ ],
          "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
          "permId" : {
            "id" : "CR:1"
          },
          "parentCommentId" : {
          }
        } ]
      },
      "transitions" : {
        "transitionData" : [ {
          "name" : "action:summarizeReview",
          "displayName" : "Summarize"
        } ]
      },
      "actions" : {
        "actionData" : [ {
          "name" : "action:abandonReview",
          "displayName" : "Abandon"
        }, {
          "name" : "action:approveReview",
          "displayName" : "Approve"
        }, {
          "name" : "action:commentOnReview",
          "displayName" : "Comment"
        }, {
          "name" : "action:completeReview",
          "displayName" : "Complete"
        }, {
          "name" : "action:modifyReviewFiles",
          "displayName" : "Edit Review Details"
        } ]
      }
    }

    A detailedReviewData element object with the added crucibleRevisionData elements.

    XML Schema

    Source: crucible.xsd

    <xs:element name="detailedReviewData" type="detailedReviewData"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>IllegalArgument</code>
        <message>Invalid input.</message>
        <stacktrace>java.lang.IllegalArgumentException: Invalid input.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:39)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the repository does not exist for one or more of the given crucibleRevisionData elements, or if one or more of the paths does not exist in the repository specified in the crucibleRevisionData elements, or if a revision specified in the crucibleRevisionData elements does not exist.

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "IllegalArgument",
      "message" : "Invalid input.",
      "stacktrace" : "java.lang.IllegalArgumentException: Invalid input.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:39)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the repository does not exist for one or more of the given crucibleRevisionData elements, or if one or more of the paths does not exist in the repository specified in the crucibleRevisionData elements, or if a revision specified in the crucibleRevisionData elements does not exist.

  • 401 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the caller does not have permission to modify the review.

  • 401 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the caller does not have permission to modify the review.

  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

/rest-service/reviews-v1/{id}/reviewitems/details

resource-wide template parameters
parameter value description

id

string

the id of the review (e.g. "CR-362").

Methods

POST

Adds the given review item to the review. This will always create a new review item, even if there is an existing one with the same data in the review (in which case the existing item will be replaced).

The response includes the Location HTTP header.

acceptable request representations:

  • application/xml (reviewItem) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • application/json (reviewItem) [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>

available response representations:

  • 200 - application/xml (reviewItem) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    The added review item with the permId set.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • 200 - application/json (reviewItem) [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    The added review item with the permId set.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewItem" type="fisheyeReviewItemData"/>
  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

/rest-service/reviews-v1/{id}/reviewitems/{riId}/details

resource-wide template parameters
parameter value description

id

string

a valid review id (e.g. "CR-345").

riId

string

a valid review item id (e.g. "CFR-5622").

Methods

PUT

Sets the review item specified by itemId with the given reviewItem. The old review item is discarded. Can only perform this operation if the old review item specified by itemId can be deleted. The old review item's permId is not changed.

acceptable request representations:

  • application/xml (fisheyeReviewItemData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    XML Schema

    Source: crucible.xsd

    <xs:complexType name="fisheyeReviewItemData">
        <xs:complexContent>
          <xs:extension base="reviewItemData">
            <xs:sequence>
              <xs:element name="anchorData" type="anchorData" minOccurs="0"/>
              <xs:element name="authorName" type="xs:string" minOccurs="0"/>
              <xs:element name="commitDate" type="xs:dateTime" minOccurs="0"/>
              <xs:element name="commitType" type="commitType" minOccurs="0"/>
              <xs:element name="expandedRevisions" type="reviewItemRevisionData" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
              <xs:element name="fileType" type="fileType" minOccurs="0"/>
              <xs:element name="fromContentUrl" type="xs:string" minOccurs="0"/>
              <xs:element name="fromPath" type="xs:string" minOccurs="0"/>
              <xs:element name="fromRevision" type="xs:string" minOccurs="0"/>
              <xs:element name="patchUrl" type="xs:string" minOccurs="0"/>
              <xs:element name="repositoryName" type="xs:string" minOccurs="0"/>
              <xs:element name="showAsDiff" type="xs:boolean" minOccurs="0"/>
              <xs:element name="toContentUrl" type="xs:string" minOccurs="0"/>
              <xs:element name="toPath" type="xs:string" minOccurs="0"/>
              <xs:element name="toRevision" type="xs:string" minOccurs="0"/>
            </xs:sequence>
          </xs:extension>
        </xs:complexContent>
      </xs:complexType>
  • application/json (fisheyeReviewItemData) [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    XML Schema

    Source: crucible.xsd

    <xs:complexType name="fisheyeReviewItemData">
        <xs:complexContent>
          <xs:extension base="reviewItemData">
            <xs:sequence>
              <xs:element name="anchorData" type="anchorData" minOccurs="0"/>
              <xs:element name="authorName" type="xs:string" minOccurs="0"/>
              <xs:element name="commitDate" type="xs:dateTime" minOccurs="0"/>
              <xs:element name="commitType" type="commitType" minOccurs="0"/>
              <xs:element name="expandedRevisions" type="reviewItemRevisionData" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
              <xs:element name="fileType" type="fileType" minOccurs="0"/>
              <xs:element name="fromContentUrl" type="xs:string" minOccurs="0"/>
              <xs:element name="fromPath" type="xs:string" minOccurs="0"/>
              <xs:element name="fromRevision" type="xs:string" minOccurs="0"/>
              <xs:element name="patchUrl" type="xs:string" minOccurs="0"/>
              <xs:element name="repositoryName" type="xs:string" minOccurs="0"/>
              <xs:element name="showAsDiff" type="xs:boolean" minOccurs="0"/>
              <xs:element name="toContentUrl" type="xs:string" minOccurs="0"/>
              <xs:element name="toPath" type="xs:string" minOccurs="0"/>
              <xs:element name="toRevision" type="xs:string" minOccurs="0"/>
            </xs:sequence>
          </xs:extension>
        </xs:complexContent>
      </xs:complexType>

available response representations:

  • 200 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    The newly created review item, with its itemId set to the new ID.

  • 200 - application/json [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    The newly created review item, with its itemId set to the new ID.

  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first. Also if the given patch is too large (contains too many files) for a single review.

/rest-service/reviews-v1/{id}/reviewitems/{riId}/revisions

resource-wide template parameters
parameter value description

id

string

the PermId of the review to remove the item from (e.g. "CR-345").

riId

string

the id of the review item from which to remove the list of revisions (e.g. "CFR-5622").

Methods

POST

Adds the given list of revisions to the supplied review item, merging if required. For example, if the review item for a.txt contains revisions 3 to 6, and if:

  • revisions to add is 4 and 5, then a.txt will have revisions 3--4--5--6
  • revisions to add is 2 and 7, then a.txt will have revisions 2--3--6--7
  • revisions to add is just 2, then a.txt will have revisions 2--3--6
  • revisions to add is just 7, then a.txt will have revisions 3--6--7
  • revisions to add is 2 and 4, then a.txt will have revisions 2--3--4--6
  • revisions to add is 4 and 7, then a.txt will have revisions 3--4--6--7

available response representations:

  • 200 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    The review item with the added list of revisions.

  • 200 - application/json [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    The review item with the added list of revisions.

  • 409 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>ReviewContentTooLarge</code>
        <message>Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.</message>
        <stacktrace>com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.
    	at com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.&lt;clinit&gt;(ReviewExampleDocuments.java:126)
    	at com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.&lt;clinit&gt;(ServerExampleDocuments.java:10)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first.

  • 409 - application/json (error) [expand]

    Example
    {
      "code" : "ReviewContentTooLarge",
      "message" : "Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.",
      "stacktrace" : "com.atlassian.crucible.spi.services.ReviewContentTooLargeException: Attempt to add too many revisions to a review - no more than 800 file revisions are allowed.\n\tat com.atlassian.crucible.spi.rpc.ReviewExampleDocuments.<clinit>(ReviewExampleDocuments.java:126)\n\tat com.atlassian.fisheye.spi.rpc.ServerExampleDocuments.<clinit>(ServerExampleDocuments.java:10)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    If the review is at or over allowed content size limit so new changes cannot be added until some other content is removed from review first.

DELETE

Removes the revisions given from the review item in the review specified by the id. If the review item has no more revisions left, it is automatically deleted.

/rest-service/reviews-v1/{id}/reviewitems/{riId}

resource-wide template parameters
parameter value description

id

string

review id (e.g. "CR-345").

riId

string

review item id (e.g. "CFR-6312").

Methods

DELETE

Removes an item from a review.

GET

Returns detailed information for a specific review item.

available response representations:

  • 200 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewItem>
        <participants>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Fred Eaglesmith</displayName>
                    <userName>fred</userName>
                </user>
                <completed>false</completed>
            </participant>
            <participant>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Corb Lund</displayName>
                    <userName>clund</userName>
                </user>
                <completed>false</completed>
            </participant>
        </participants>
        <permId>
            <id>CFR-7453</id>
        </permId>
        <authorName>evzijst</authorName>
        <commitDate>2014-12-04T10:57:08.439+01:00</commitDate>
        <commitType>Modified</commitType>
        <fileType>File</fileType>
        <fromContentUrl>/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml</fromContentUrl>
        <fromPath>/project/trunk/pom.xml</fromPath>
        <fromRevision>688</fromRevision>
        <repositoryName>REPO</repositoryName>
        <showAsDiff>true</showAsDiff>
        <toContentUrl>/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml</toContentUrl>
        <toPath>/project/trunk/pom.xml</toPath>
        <toRevision>6881</toRevision>
    </reviewItem>
    

    A single item from a review.

  • 200 - application/json [expand]

    Example
    {
      "permId" : {
        "id" : "CFR-7453"
      },
      "participants" : [ {
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Eaglesmith",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      }, {
        "user" : {
          "userName" : "clund",
          "displayName" : "Corb Lund",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "completed" : false
      } ],
      "repositoryName" : "REPO",
      "fromPath" : "/project/trunk/pom.xml",
      "fromRevision" : "688",
      "fromContentUrl" : "/context/cru/CR-123/rawcontent/5622//project/trunk/pom.xml",
      "toPath" : "/project/trunk/pom.xml",
      "toRevision" : "6881",
      "toContentUrl" : "/context/cru/CR-123/rawcontent/5913//project/trunk/pom.xml",
      "fileType" : "File",
      "commitType" : "Modified",
      "authorName" : "evzijst",
      "showAsDiff" : true,
      "commitDate" : 1417687028439
    }

    A single item from a review.

/rest-service/reviews-v1/{id}/comments?render=<value>

resource-wide template parameters
parameter value description

id

string

the review perma-id

Methods

GET

Return all the comments visible to the requesting user for the review.

request query parameters
parameter value description

render

boolean

Default: false

indicate whether to render the wiki text in the returned comments. If set to "true", the comments will contain a <messageAsHtml> element containing the wiki rendered html.

available response representations:

  • 200 - application/xml (comments) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <comments>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <versionedLineCommentData>
            <createDate>2014-12-04T10:57:08.447+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>*bold* message</message>
            <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
            <parentCommentId/>
            <readStatus>READ</readStatus>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Fred Veiligheidspet</displayName>
                <userName>fred</userName>
            </user>
            <permaId/>
            <reviewItemId>
                <id>CRFX-1234</id>
            </reviewItemId>
            <fromLineRange>10</fromLineRange>
            <toLineRange>20</toLineRange>
        </versionedLineCommentData>
        <versionedLineCommentData>
            <createDate>2014-12-04T10:57:08.447+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>*bold* message</message>
            <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
            <parentCommentId/>
            <readStatus>READ</readStatus>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Fred Veiligheidspet</displayName>
                <userName>fred</userName>
            </user>
            <permaId/>
            <reviewItemId>
                <id>CRFX-1234</id>
            </reviewItemId>
            <fromLineRange>10</fromLineRange>
            <toLineRange>20</toLineRange>
        </versionedLineCommentData>
    </comments>
    

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 200 - application/json (comments) [expand]

    Example
    {
      "comments" : [ {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "message" : "*bold* message",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "READ",
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Veiligheidspet",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : 1417687028447,
        "messageAsHtml" : "<p><b>bold</b> message</p>",
        "reviewItemId" : {
          "id" : "CRFX-1234"
        },
        "fromLineRange" : "10",
        "toLineRange" : "20"
      }, {
        "message" : "*bold* message",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "READ",
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Veiligheidspet",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : 1417687028447,
        "messageAsHtml" : "<p><b>bold</b> message</p>",
        "reviewItemId" : {
          "id" : "CRFX-1234"
        },
        "fromLineRange" : "10",
        "toLineRange" : "20"
      } ]
    }

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>PermaIdFormat</code>
        <message>Malformed PermId.</message>
        <stacktrace>com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:33)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review perma-id is not well-formed

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "PermaIdFormat",
      "message" : "Malformed PermId.",
      "stacktrace" : "com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:33)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review perma-id is not well-formed

  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

POST

Add a general comment to the review.

acceptable request representations:

  • application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>true</draft>
        <message>I thought you said you were going to remove this line?</message>
        <parentCommentId/>
        <permId/>
        <permaId/>
    </generalCommentData>
    

  • application/json [expand]

    Example
    {
      "message" : "I thought you said you were going to remove this line?",
      "draft" : true,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "permaId" : {
      },
      "permId" : {
      },
      "parentCommentId" : {
      }
    }

available response representations:

  • 201 - application/xml (generalCommentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <createDate>2014-12-04T10:57:08.419+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>I thought you said you were going to *remove* this line?</message>
        <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
        <metrics/>
        <parentCommentId/>
        <readStatus>UNREAD</readStatus>
        <replies/>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Bloggs</displayName>
            <userName>joe</userName>
        </user>
        <permId>
            <id>CR:1</id>
        </permId>
        <permaId>
            <id>CR:1</id>
        </permaId>
    </generalCommentData>
    

    the newly created comment, with its URI in the Location header

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>
  • 201 - application/json (generalCommentData) [expand]

    Example
    {
      "metrics" : {
      },
      "message" : "I thought you said you were going to *remove* this line?",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "UNREAD",
      "user" : {
        "userName" : "joe",
        "displayName" : "Joe Bloggs",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : "2014-12-04T10:57:08.419+0100",
      "permaId" : {
        "id" : "CR:1"
      },
      "replies" : [ ],
      "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
      "permId" : {
        "id" : "CR:1"
      },
      "parentCommentId" : {
      }
    }

    the newly created comment, with its URI in the Location header

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>IllegalState</code>
        <message>The review must be open to perform the requested action.</message>
        <stacktrace>java.lang.IllegalStateException: The review must be open to perform the requested action.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:45)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    • if the reviewId is not a well-formed review perma-id, or
    • if the review is not open for commenting
  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "IllegalState",
      "message" : "The review must be open to perform the requested action.",
      "stacktrace" : "java.lang.IllegalStateException: The review must be open to perform the requested action.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:45)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    • if the reviewId is not a well-formed review perma-id, or
    • if the review is not open for commenting
  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to comment on the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to comment on the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

/rest-service/reviews-v1/{id}/comments/general?render=<value>

resource-wide template parameters
parameter value description

id

string

review perma-id

Methods

GET

request query parameters
parameter value description

render

boolean

Default: false

indicate whether to render the wiki text in the returned comments. If set to "true", the comments will contain a <messageAsHtml> element containing the wiki rendered html.

available response representations:

  • 200 - application/xml (comments) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <comments>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
    </comments>
    

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 200 - application/json (comments) [expand]

    Example
    {
      "comments" : [ {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      } ]
    }

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>PermaIdFormat</code>
        <message>Malformed PermId.</message>
        <stacktrace>com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:33)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review perma-id is not well-formed

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "PermaIdFormat",
      "message" : "Malformed PermId.",
      "stacktrace" : "com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:33)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review perma-id is not well-formed

  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

/rest-service/reviews-v1/{id}/comments/versioned?render=<value>

resource-wide template parameters
parameter value description

id

string

review perma-id

Methods

GET

request query parameters
parameter value description

render

boolean

Default: false

indicate whether to render the wiki text in the returned comments. If set to "true", the comments will contain a <messageAsHtml> element containing the wiki rendered html.

available response representations:

  • 200 - application/xml (comments) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <comments>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
    </comments>
    

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 200 - application/json (comments) [expand]

    Example
    {
      "comments" : [ {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      } ]
    }

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>PermaIdFormat</code>
        <message>Malformed PermId.</message>
        <stacktrace>com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:33)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review perma-id is not well-formed

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "PermaIdFormat",
      "message" : "Malformed PermId.",
      "stacktrace" : "com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:33)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review perma-id is not well-formed

  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

/rest-service/reviews-v1/{id}/reviewitems/{riId}/comments?render=<value>

resource-wide template parameters
parameter value description

id

string

the review perma id

riId

string

the review item id.

Methods

GET

request query parameters
parameter value description

render

boolean

Default: false

indicate whether to render the wiki text in the returned comments. If set to "true", the comments will contain a <messageAsHtml> element containing the wiki rendered html.

available response representations:

  • 200 - application/xml (comments) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <comments>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <versionedLineCommentData>
            <createDate>2014-12-04T10:57:08.447+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>*bold* message</message>
            <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
            <parentCommentId/>
            <readStatus>READ</readStatus>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Fred Veiligheidspet</displayName>
                <userName>fred</userName>
            </user>
            <permaId/>
            <reviewItemId>
                <id>CRFX-1234</id>
            </reviewItemId>
            <fromLineRange>10</fromLineRange>
            <toLineRange>20</toLineRange>
        </versionedLineCommentData>
        <versionedLineCommentData>
            <createDate>2014-12-04T10:57:08.447+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>*bold* message</message>
            <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
            <parentCommentId/>
            <readStatus>READ</readStatus>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Fred Veiligheidspet</displayName>
                <userName>fred</userName>
            </user>
            <permaId/>
            <reviewItemId>
                <id>CRFX-1234</id>
            </reviewItemId>
            <fromLineRange>10</fromLineRange>
            <toLineRange>20</toLineRange>
        </versionedLineCommentData>
    </comments>
    

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 200 - application/json (comments) [expand]

    Example
    {
      "comments" : [ {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "message" : "*bold* message",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "READ",
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Veiligheidspet",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : 1417687028447,
        "messageAsHtml" : "<p><b>bold</b> message</p>",
        "reviewItemId" : {
          "id" : "CRFX-1234"
        },
        "fromLineRange" : "10",
        "toLineRange" : "20"
      }, {
        "message" : "*bold* message",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "READ",
        "user" : {
          "userName" : "fred",
          "displayName" : "Fred Veiligheidspet",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : 1417687028447,
        "messageAsHtml" : "<p><b>bold</b> message</p>",
        "reviewItemId" : {
          "id" : "CRFX-1234"
        },
        "fromLineRange" : "10",
        "toLineRange" : "20"
      } ]
    }

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>PermaIdFormat</code>
        <message>Malformed PermId.</message>
        <stacktrace>com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:33)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review perma-id is not well-formed

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "PermaIdFormat",
      "message" : "Malformed PermId.",
      "stacktrace" : "com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:33)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review perma-id is not well-formed

  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

POST

This call includes the Location repsonse header that contains the URL of the newly created entity.

acceptable request representations:

  • application/xml (versionedLineCommentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <versionedLineCommentData>
        <createDate>2014-12-04T10:57:08.447+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>*bold* message</message>
        <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
        <parentCommentId/>
        <readStatus>READ</readStatus>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Fred Veiligheidspet</displayName>
            <userName>fred</userName>
        </user>
        <permaId/>
        <reviewItemId>
            <id>CRFX-1234</id>
        </reviewItemId>
        <fromLineRange>10</fromLineRange>
        <toLineRange>20</toLineRange>
    </versionedLineCommentData>
    

    XML Schema

    Source: crucible.xsd

    <xs:element name="versionedLineCommentData" type="versionedLineCommentData"/>
  • application/json (versionedLineCommentData) [expand]

    Example
    {
      "message" : "*bold* message",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "READ",
      "user" : {
        "userName" : "fred",
        "displayName" : "Fred Veiligheidspet",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : 1417687028447,
      "messageAsHtml" : "<p><b>bold</b> message</p>",
      "reviewItemId" : {
        "id" : "CRFX-1234"
      },
      "fromLineRange" : "10",
      "toLineRange" : "20"
    }

    XML Schema

    Source: crucible.xsd

    <xs:element name="versionedLineCommentData" type="versionedLineCommentData"/>

available response representations:

  • 200 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <versionedLineCommentData>
        <createDate>2014-12-04T10:57:08.447+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>*bold* message</message>
        <messageAsHtml>&lt;p&gt;&lt;b&gt;bold&lt;/b&gt; message&lt;/p&gt;</messageAsHtml>
        <parentCommentId/>
        <readStatus>READ</readStatus>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Fred Veiligheidspet</displayName>
            <userName>fred</userName>
        </user>
        <permaId/>
        <reviewItemId>
            <id>CRFX-1234</id>
        </reviewItemId>
        <fromLineRange>10</fromLineRange>
        <toLineRange>20</toLineRange>
    </versionedLineCommentData>
    

    the returned comment

  • 200 - application/json [expand]

    Example
    {
      "message" : "*bold* message",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "READ",
      "user" : {
        "userName" : "fred",
        "displayName" : "Fred Veiligheidspet",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : 1417687028447,
      "messageAsHtml" : "<p><b>bold</b> message</p>",
      "reviewItemId" : {
        "id" : "CRFX-1234"
      },
      "fromLineRange" : "10",
      "toLineRange" : "20"
    }

    the returned comment

/rest-service/reviews-v1/{id}/comments/{cId}/replies?render=<value>

resource-wide template parameters
parameter value description

id

string

the review perma-id (e.g. "CR-45").

cId

string

the comment to reply to

Methods

GET

Gets the replies to the given comment.

request query parameters
parameter value description

render

boolean

Default: false

true if the comments should also be rendered into html, into the element <messageAsHtml>

available response representations:

  • 200 - application/xml (comments) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <comments>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
        <generalCommentData>
            <createDate>2014-12-04T10:57:08.419+0100</createDate>
            <defectApproved>false</defectApproved>
            <defectRaised>false</defectRaised>
            <deleted>false</deleted>
            <draft>false</draft>
            <message>I thought you said you were going to *remove* this line?</message>
            <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
            <metrics/>
            <parentCommentId/>
            <readStatus>UNREAD</readStatus>
            <replies/>
            <user>
                <avatarUrl>http://foo.com/avatar</avatarUrl>
                <displayName>Joe Bloggs</displayName>
                <userName>joe</userName>
            </user>
            <permId>
                <id>CR:1</id>
            </permId>
            <permaId>
                <id>CR:1</id>
            </permaId>
        </generalCommentData>
    </comments>
    

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 200 - application/json (comments) [expand]

    Example
    {
      "comments" : [ {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      }, {
        "metrics" : {
        },
        "message" : "I thought you said you were going to *remove* this line?",
        "draft" : false,
        "deleted" : false,
        "defectRaised" : false,
        "defectApproved" : false,
        "readStatus" : "UNREAD",
        "user" : {
          "userName" : "joe",
          "displayName" : "Joe Bloggs",
          "avatarUrl" : "http://foo.com/avatar"
        },
        "createDate" : "2014-12-04T10:57:08.419+0100",
        "permaId" : {
          "id" : "CR:1"
        },
        "replies" : [ ],
        "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
        "permId" : {
          "id" : "CR:1"
        },
        "parentCommentId" : {
        }
      } ]
    }

    the comments visible to the requesting user

    XML Schema

    Source: crucible.xsd

    <xs:element name="comments" type="comments"/>
  • 400 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>PermaIdFormat</code>
        <message>Malformed PermId.</message>
        <stacktrace>com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:33)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review perma-id is not well-formed

  • 400 - application/json (error) [expand]

    Example
    {
      "code" : "PermaIdFormat",
      "message" : "Malformed PermId.",
      "stacktrace" : "com.cenqua.crucible.model.PermaIdFormatException: Malformed PermId.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:33)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review perma-id is not well-formed

  • 403 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not permitted to view the review

  • 403 - application/json (error) [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not permitted to view the review

  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if the review does not exist

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if the review does not exist

POST

Adds a reply to the given comment. This call includes the Location repsonse header that contains the URL of the newly created entity.

acceptable request representations:

  • application/xml (generalCommentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>true</draft>
        <message>I thought you said you were going to remove this line?</message>
        <parentCommentId/>
        <permId/>
        <permaId/>
    </generalCommentData>
    

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>
  • application/json (generalCommentData) [expand]

    Example
    {
      "message" : "I thought you said you were going to remove this line?",
      "draft" : true,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "permaId" : {
      },
      "permId" : {
      },
      "parentCommentId" : {
      }
    }

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>

available response representations:

  • 201 - application/xml (generalCommentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <createDate>2014-12-04T10:57:08.419+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>I thought you said you were going to *remove* this line?</message>
        <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
        <metrics/>
        <parentCommentId/>
        <readStatus>UNREAD</readStatus>
        <replies/>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Bloggs</displayName>
            <userName>joe</userName>
        </user>
        <permId>
            <id>CR:1</id>
        </permId>
        <permaId>
            <id>CR:1</id>
        </permaId>
    </generalCommentData>
    

    the newly created comment, with its URI in the Location header

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>
  • 201 - application/json (generalCommentData) [expand]

    Example
    {
      "metrics" : {
      },
      "message" : "I thought you said you were going to *remove* this line?",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "UNREAD",
      "user" : {
        "userName" : "joe",
        "displayName" : "Joe Bloggs",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : "2014-12-04T10:57:08.419+0100",
      "permaId" : {
        "id" : "CR:1"
      },
      "replies" : [ ],
      "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
      "permId" : {
        "id" : "CR:1"
      },
      "parentCommentId" : {
      }
    }

    the newly created comment, with its URI in the Location header

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>

/rest-service/reviews-v1/{id}/comments/markAllAsRead

resource-wide template parameters
parameter value description

id

string

the review perma-id (e.g. "CR-45").

Methods

POST

For the effective user, mark all comments in a review as read (except those marked as leave unread).

available response representations:

  • 200 - application/xml (detailedReviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <detailedReviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
        <actions>
            <actionData>
                <displayName>Abandon</displayName>
                <name>action:abandonReview</name>
            </actionData>
            <actionData>
                <displayName>Approve</displayName>
                <name>action:approveReview</name>
            </actionData>
            <actionData>
                <displayName>Comment</displayName>
                <name>action:commentOnReview</name>
            </actionData>
            <actionData>
                <displayName>Complete</displayName>
                <name>action:completeReview</name>
            </actionData>
            <actionData>
                <displayName>Edit Review Details</displayName>
                <name>action:modifyReviewFiles</name>
            </actionData>
        </actions>
        <generalComments>
            <generalCommentData>
                <createDate>2014-12-04T10:57:08.419+0100</createDate>
                <defectApproved>false</defectApproved>
                <defectRaised>false</defectRaised>
                <deleted>false</deleted>
                <draft>false</draft>
                <message>I thought you said you were going to *remove* this line?</message>
                <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
                <metrics/>
                <parentCommentId/>
                <readStatus>UNREAD</readStatus>
                <replies/>
                <user>
                    <avatarUrl>http://foo.com/avatar</avatarUrl>
                    <displayName>Joe Bloggs</displayName>
                    <userName>joe</userName>
                </user>
                <permId>
                    <id>CR:1</id>
                </permId>
                <permaId>
                    <id>CR:1</id>
                </permaId>
            </generalCommentData>
        </generalComments>
        <reviewItems>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-239</id>
                </permId>
                <anchorData>
                    <anchorPath>trunk</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt</fromContentUrl>
                <fromPath>dir238/a.txt</fromPath>
                <fromRevision>239</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt</toContentUrl>
                <toPath>dir238/a.txt</toPath>
                <toRevision>2391</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-240</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt</fromContentUrl>
                <fromPath>dir239/d.txt</fromPath>
                <fromRevision>240</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt</toContentUrl>
                <toPath>dir239/d.txt</toPath>
                <toRevision>2401</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-241</id>
                </permId>
                <anchorData>
                    <anchorPath>branches/branch1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt</fromContentUrl>
                <fromPath>dir240/c.txt</fromPath>
                <fromRevision>241</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt</toContentUrl>
                <toPath>dir240/c.txt</toPath>
                <toRevision>2411</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-242</id>
                </permId>
                <anchorData>
                    <anchorPath>tags/tag1</anchorPath>
                    <anchorRepository>REPO</anchorRepository>
                    <stripCount>0</stripCount>
                </anchorData>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt</fromContentUrl>
                <fromPath>dir241/b.txt</fromPath>
                <fromRevision>242</fromRevision>
                <patchUrl>/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch</patchUrl>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt</toContentUrl>
                <toPath>dir241/b.txt</toPath>
                <toRevision>2421</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-243</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.444+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt</fromContentUrl>
                <fromPath>dir242/d.txt</fromPath>
                <fromRevision>243</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>true</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt</toContentUrl>
                <toPath>dir242/d.txt</toPath>
                <toRevision>2431</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-244</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt</fromContentUrl>
                <fromPath>dir243/e.txt</fromPath>
                <fromRevision>244</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt</toContentUrl>
                <toPath>dir243/e.txt</toPath>
                <toRevision>2441</toRevision>
            </reviewItem>
            <reviewItem>
                <participants>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Fred Eaglesmith</displayName>
                            <userName>fred</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                    <participant>
                        <user>
                            <avatarUrl>http://foo.com/avatar</avatarUrl>
                            <displayName>Corb Lund</displayName>
                            <userName>clund</userName>
                        </user>
                        <completed>false</completed>
                    </participant>
                </participants>
                <permId>
                    <id>CFR-245</id>
                </permId>
                <authorName>evzijst</authorName>
                <commitDate>2014-12-04T10:57:08.445+01:00</commitDate>
                <commitType>Modified</commitType>
                <fileType>File</fileType>
                <fromContentUrl>/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt</fromContentUrl>
                <fromPath>dir244/f.txt</fromPath>
                <fromRevision>245</fromRevision>
                <repositoryName>REPO</repositoryName>
                <showAsDiff>false</showAsDiff>
                <toContentUrl>/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt</toContentUrl>
                <toPath>dir244/f.txt</toPath>
                <toRevision>2451</toRevision>
            </reviewItem>
        </reviewItems>
        <transitions>
            <transitionData>
                <displayName>Summarize</displayName>
                <name>action:summarizeReview</name>
            </transitionData>
        </transitions>
    </detailedReviewData>
    

    The full, detailed review, reflecting the changes.

    XML Schema

    Source: crucible.xsd

    <xs:element name="detailedReviewData" type="detailedReviewData"/>
  • 200 - application/json (detailedReviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754",
      "reviewItems" : {
        "reviewItem" : [ {
          "permId" : {
            "id" : "CFR-239"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir238/a.txt",
          "fromRevision" : "239",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5861/dir238/a.txt",
          "toPath" : "dir238/a.txt",
          "toRevision" : "2391",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6445/dir238/a.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6371/patch-83.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "anchorData" : {
            "anchorPath" : "trunk",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-240"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir239/d.txt",
          "fromRevision" : "240",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5864/dir239/d.txt",
          "toPath" : "dir239/d.txt",
          "toRevision" : "2401",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5869/dir239/d.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6049/patch-2584.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-241"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir240/c.txt",
          "fromRevision" : "241",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5867/dir240/c.txt",
          "toPath" : "dir240/c.txt",
          "toRevision" : "2411",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6675/dir240/c.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6076/patch-3588.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "branches/branch1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-242"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir241/b.txt",
          "fromRevision" : "242",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5870/dir241/b.txt",
          "toPath" : "dir241/b.txt",
          "toRevision" : "2421",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6777/dir241/b.txt",
          "patchUrl" : "/contextcru/CR-FOO-21/downloadpatch/6014/patch-2894.patch",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "anchorData" : {
            "anchorPath" : "tags/tag1",
            "anchorRepository" : "REPO",
            "stripCount" : 0
          },
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-243"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir242/d.txt",
          "fromRevision" : "243",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5872/dir242/d.txt",
          "toPath" : "dir242/d.txt",
          "toRevision" : "2431",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6714/dir242/d.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : true,
          "commitDate" : 1417687028444,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-244"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir243/e.txt",
          "fromRevision" : "244",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5874/dir243/e.txt",
          "toPath" : "dir243/e.txt",
          "toRevision" : "2441",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6662/dir243/e.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        }, {
          "permId" : {
            "id" : "CFR-245"
          },
          "participants" : [ {
            "user" : {
              "userName" : "fred",
              "displayName" : "Fred Eaglesmith",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          }, {
            "user" : {
              "userName" : "clund",
              "displayName" : "Corb Lund",
              "avatarUrl" : "http://foo.com/avatar"
            },
            "completed" : false
          } ],
          "repositoryName" : "REPO",
          "fromPath" : "dir244/f.txt",
          "fromRevision" : "245",
          "fromContentUrl" : "/context/cru/CR-FOO-21/rawcontent/5876/dir244/f.txt",
          "toPath" : "dir244/f.txt",
          "toRevision" : "2451",
          "toContentUrl" : "/context/cru/CR-FOO-21/rawcontent/6556/dir244/f.txt",
          "fileType" : "File",
          "commitType" : "Modified",
          "authorName" : "evzijst",
          "showAsDiff" : false,
          "commitDate" : 1417687028445,
          "expandedRevisions" : [ ]
        } ]
      },
      "generalComments" : {
        "comments" : [ {
          "metrics" : {
          },
          "message" : "I thought you said you were going to *remove* this line?",
          "draft" : false,
          "deleted" : false,
          "defectRaised" : false,
          "defectApproved" : false,
          "readStatus" : "UNREAD",
          "user" : {
            "userName" : "joe",
            "displayName" : "Joe Bloggs",
            "avatarUrl" : "http://foo.com/avatar"
          },
          "createDate" : "2014-12-04T10:57:08.419+0100",
          "permaId" : {
            "id" : "CR:1"
          },
          "replies" : [ ],
          "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
          "permId" : {
            "id" : "CR:1"
          },
          "parentCommentId" : {
          }
        } ]
      },
      "transitions" : {
        "transitionData" : [ {
          "name" : "action:summarizeReview",
          "displayName" : "Summarize"
        } ]
      },
      "actions" : {
        "actionData" : [ {
          "name" : "action:abandonReview",
          "displayName" : "Abandon"
        }, {
          "name" : "action:approveReview",
          "displayName" : "Approve"
        }, {
          "name" : "action:commentOnReview",
          "displayName" : "Comment"
        }, {
          "name" : "action:completeReview",
          "displayName" : "Complete"
        }, {
          "name" : "action:modifyReviewFiles",
          "displayName" : "Edit Review Details"
        } ]
      }
    }

    The full, detailed review, reflecting the changes.

    XML Schema

    Source: crucible.xsd

    <xs:element name="detailedReviewData" type="detailedReviewData"/>

/rest-service/reviews-v1/{id}/comments/{cId}/markAsRead

resource-wide template parameters
parameter value description

id

string

the review perma id

cId

string

the comment perma id.

Methods

POST

Mark the given comment as read for the user used to make this POST.

available response representations:

  • 200 - application/xml (commentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <createDate>2014-12-04T10:57:08.419+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>I thought you said you were going to *remove* this line?</message>
        <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
        <metrics/>
        <parentCommentId/>
        <readStatus>READ</readStatus>
        <replies/>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Bloggs</displayName>
            <userName>joe</userName>
        </user>
        <permId>
            <id>CR:1</id>
        </permId>
        <permaId>
            <id>CR:1</id>
        </permaId>
    </generalCommentData>
    

  • 200 - application/json (commentData) [expand]

    Example
    {
      "metrics" : {
      },
      "message" : "I thought you said you were going to *remove* this line?",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "READ",
      "user" : {
        "userName" : "joe",
        "displayName" : "Joe Bloggs",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : "2014-12-04T10:57:08.419+0100",
      "permaId" : {
        "id" : "CR:1"
      },
      "replies" : [ ],
      "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
      "permId" : {
        "id" : "CR:1"
      },
      "parentCommentId" : {
      }
    }

/rest-service/reviews-v1/{id}/comments/{cId}/markAsLeaveUnread

resource-wide template parameters
parameter value description

id

string

the review perma id for the comment

cId

string

the comment perma id

Methods

POST

Marks the comment as leave unread to the current user - it will not automatically be marked as read by crucible.

available response representations:

  • 200 - application/xml (commentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <createDate>2014-12-04T10:57:08.419+0100</createDate>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>false</draft>
        <message>I thought you said you were going to *remove* this line?</message>
        <messageAsHtml>I thought you said you were going to &lt;b&gt;remove&lt;/b&gt; this line?</messageAsHtml>
        <metrics/>
        <parentCommentId/>
        <readStatus>UNREAD</readStatus>
        <replies/>
        <user>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Bloggs</displayName>
            <userName>joe</userName>
        </user>
        <permId>
            <id>CR:1</id>
        </permId>
        <permaId>
            <id>CR:1</id>
        </permaId>
    </generalCommentData>
    

  • 200 - application/json (commentData) [expand]

    Example
    {
      "metrics" : {
      },
      "message" : "I thought you said you were going to *remove* this line?",
      "draft" : false,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "readStatus" : "UNREAD",
      "user" : {
        "userName" : "joe",
        "displayName" : "Joe Bloggs",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "createDate" : "2014-12-04T10:57:08.419+0100",
      "permaId" : {
        "id" : "CR:1"
      },
      "replies" : [ ],
      "messageAsHtml" : "I thought you said you were going to <b>remove</b> this line?",
      "permId" : {
        "id" : "CR:1"
      },
      "parentCommentId" : {
      }
    }

/rest-service/reviews-v1/{id}/comments/{cId}/replies/{rId}

resource-wide template parameters
parameter value description

id

string

The review perma id

cId

string

the reply's parent comment perma id

rId

string

the perma id of the reply to delete

Methods

POST

Updates a reply with the given newComment.

acceptable request representations:

  • application/xml (generalCommentData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <generalCommentData>
        <defectApproved>false</defectApproved>
        <defectRaised>false</defectRaised>
        <deleted>false</deleted>
        <draft>true</draft>
        <message>I thought you said you were going to remove this line?</message>
        <parentCommentId/>
        <permId/>
        <permaId/>
    </generalCommentData>
    

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>
  • application/json (generalCommentData) [expand]

    Example
    {
      "message" : "I thought you said you were going to remove this line?",
      "draft" : true,
      "deleted" : false,
      "defectRaised" : false,
      "defectApproved" : false,
      "permaId" : {
      },
      "permId" : {
      },
      "parentCommentId" : {
      }
    }

    XML Schema

    Source: crucible.xsd

    <xs:element name="generalCommentData" type="generalCommentData"/>

DELETE

Deletes the reply.

/rest-service/reviews-v1/{id}/publish

resource-wide template parameters
parameter value description

id

string

the review perma id to look for draft comments

Methods

POST

Publishes all the draft comments of the current user.

/rest-service/reviews-v1/{id}/publish/{cId}

resource-wide template parameters
parameter value description

id

string

the review perma id

cId

string

the comment perma id

Methods

POST

publishes the given draft comment.

/rest-service/reviews-v1/{id}/complete

resource-wide template parameters
parameter value description

id

string

the review perma id

Methods

POST

Completes the review for the current user

/rest-service/reviews-v1/{id}/uncomplete

resource-wide template parameters
parameter value description

id

string

the review perma id

Methods

POST

Uncompletes the review for the current user.

/rest-service/reviews-v1/{id}/transition?action=<value>

resource-wide template parameters
parameter value description

id

string

the review perma-id (e.g. "CR-45").

Methods

POST

Change the state of a review by performing an action on it.

request query parameters
parameter value description

action

string

the string representation of the action to perform. Valid actions are:

  • action:abandonReview -- abandon (i.e. cancel) a review
  • action:deleteReview -- permanently delete a review
  • action:submitReview -- submit a review to the moderator for approval
  • action:approveReview -- approve a review (i.e. issue it to the reviewers)
  • action:rejectReview -- reject a review submitted for approval
  • action:summarizeReview -- summarize a review
  • action:closeReview -- close a review once it has been summarized
  • action:reopenReview -- re-open a closed review
  • action:recoverReview -- recover an abandoned review
  • action:completeReview -- indicate you have completed a review
  • action:uncompleteReview -- indicate you have not completed a review, after indicating you have completed a review

available response representations:

  • 200 - application/xml (reviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewData>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <author>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </author>
        <createDate>2014-12-04T10:57:08.409+0100</createDate>
        <creator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Joe Krustofski</displayName>
            <userName>joe</userName>
        </creator>
        <description>Description or statement of objectives for this example review.</description>
        <dueDate>2014-12-05T10:57:08.409+0100</dueDate>
        <jiraIssueKey>FOO-6754</jiraIssueKey>
        <metricsVersion>4</metricsVersion>
        <moderator>
            <avatarUrl>http://foo.com/avatar</avatarUrl>
            <displayName>Scott the Moderator</displayName>
            <userName>scott</userName>
        </moderator>
        <name>Example review.</name>
        <permaId>
            <id>CR-FOO-21</id>
        </permaId>
        <permaIdHistory>CR-FOO-21</permaIdHistory>
        <projectKey>CR-FOO</projectKey>
        <type>REVIEW</type>
    </reviewData>
    

    The review object containing the details of the review, including its new state.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 200 - application/json (reviewData) [expand]

    Example
    {
      "projectKey" : "CR-FOO",
      "name" : "Example review.",
      "description" : "Description or statement of objectives for this example review.",
      "author" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "moderator" : {
        "userName" : "scott",
        "displayName" : "Scott the Moderator",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "creator" : {
        "userName" : "joe",
        "displayName" : "Joe Krustofski",
        "avatarUrl" : "http://foo.com/avatar"
      },
      "permaId" : {
        "id" : "CR-FOO-21"
      },
      "permaIdHistory" : [ "CR-FOO-21" ],
      "type" : "REVIEW",
      "allowReviewersToJoin" : true,
      "metricsVersion" : 4,
      "createDate" : "2014-12-04T10:57:08.409+0100",
      "dueDate" : "2014-12-05T10:57:08.409+0100",
      "jiraIssueKey" : "FOO-6754"
    }

    The review object containing the details of the review, including its new state.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>

/rest-service/reviews-v1/{id}/close

resource-wide template parameters
parameter value description

id

string

the review perma id to close. it should be in the open state.

Methods

POST

Closes the given review with the summary given.

acceptable request representations:

  • application/xml (closeReviewSummary) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <closeReviewSummary>
        <summary>summary of the review.</summary>
    </closeReviewSummary>
    

  • application/json (closeReviewSummary) [expand]

    Example
    {
      "summary" : "summary of the review."
    }

available response representations:

  • 200 - application/xml (reviewData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <reviewData>
        <metricsVersion>0</metricsVersion>
        <permaId>
            <id>CR-1234</id>
        </permaId>
        <summary>summary of the review.</summary>
    </reviewData>
    

    A summary of the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>
  • 200 - application/json (reviewData) [expand]

    Example
    {
      "permaId" : {
        "id" : "CR-1234"
      },
      "summary" : "summary of the review.",
      "metricsVersion" : 0
    }

    A summary of the review.

    XML Schema

    Source: crucible.xsd

    <xs:element name="reviewData" type="reviewData"/>

/rest-service/reviews-v1/{id}/remind

resource-wide template parameters
parameter value description

id

string

the review perma id to remind about. it should be in the open state.

Methods

POST

Immediately send a reminder to incomplete reviewers about the given review.

acceptable request representations:

available response representations:

/rest-service/projects-v1?excludeAllowedReviewers=<value>

Provides an API for working with Projects.

Methods

GET

Deprecated since FishEye 3.5.0 for removal in 4.0. Use GET /rest-service-fecru/admin/projects instead.

Get the list of projects that the authenticated user is entitled to access.
request query parameters
parameter value description

excludeAllowedReviewers

boolean

Default: false

if set to true, user data (e.g. {@link ProjectData#allowedReviewers}) which is expensive to compute, will not be included in the response data. Defaults to false so allowedReviewers are included in the response.

available response representations:

  • 200 - application/xml (projects) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <projects>
        <projectData>
            <allowedReviewers size="2"/>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <defaultDuration>5</defaultDuration>
            <defaultModerator>joe</defaultModerator>
            <defaultObjectives>default objectives</defaultObjectives>
            <defaultRepositoryName>FOOREPO</defaultRepositoryName>
            <defaultReviewers>
                <userName>joe</userName>
                <userName>fred</userName>
            </defaultReviewers>
            <id>5</id>
            <key>CR-FOO</key>
            <moderatorEnabled>true</moderatorEnabled>
            <name>Foo Project</name>
            <permissionSchemeId>32</permissionSchemeId>
        </projectData>
        <projectData>
            <allowedReviewers size="2"/>
            <allowReviewersToJoin>true</allowReviewersToJoin>
            <defaultDuration>5</defaultDuration>
            <defaultModerator>joe</defaultModerator>
            <defaultObjectives>default objectives</defaultObjectives>
            <defaultRepositoryName>FOOREPO</defaultRepositoryName>
            <defaultReviewers>
                <userName>joe</userName>
                <userName>fred</userName>
            </defaultReviewers>
            <id>5</id>
            <key>CR-FOO</key>
            <moderatorEnabled>true</moderatorEnabled>
            <name>Foo Project</name>
            <permissionSchemeId>32</permissionSchemeId>
        </projectData>
    </projects>
    

    A list of all Crucible projects that the caller is entitled to access.

  • 200 - application/json (projects) [expand]

    Example
    {
      "projectData" : [ {
        "allowedReviewers" : {
          "size" : 2
        },
        "id" : 5,
        "name" : "Foo Project",
        "key" : "CR-FOO",
        "defaultRepositoryName" : "FOOREPO",
        "permissionSchemeId" : 32,
        "defaultDuration" : 5,
        "defaultModerator" : "joe",
        "moderatorEnabled" : true,
        "defaultObjectives" : "default objectives",
        "allowReviewersToJoin" : true,
        "defaultReviewers" : [ "joe", "fred" ]
      }, {
        "allowedReviewers" : {
          "size" : 2
        },
        "id" : 5,
        "name" : "Foo Project",
        "key" : "CR-FOO",
        "defaultRepositoryName" : "FOOREPO",
        "permissionSchemeId" : 32,
        "defaultDuration" : 5,
        "defaultModerator" : "joe",
        "moderatorEnabled" : true,
        "defaultObjectives" : "default objectives",
        "allowReviewersToJoin" : true,
        "defaultReviewers" : [ "joe", "fred" ]
      } ]
    }

    A list of all Crucible projects that the caller is entitled to access.

/rest-service/projects-v1/{key}?excludeAllowedReviewers=<value>

resource-wide template parameters
parameter value description

key

string

the key of a Crucible project.

Methods

GET

Deprecated since FishEye 3.5.0 for removal in 4.0. Use GET /rest-service-fecru/admin/projects/[key] instead.

Returns a project description.

If the specified project does not exist, or the caller does not have permission to access the project, 404 is returned.

request query parameters
parameter value description

excludeAllowedReviewers

boolean

Default: false

available response representations:

  • 200 - application/xml (projectData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <projectData>
        <allowedReviewers size="2"/>
        <allowReviewersToJoin>true</allowReviewersToJoin>
        <defaultDuration>5</defaultDuration>
        <defaultModerator>joe</defaultModerator>
        <defaultObjectives>default objectives</defaultObjectives>
        <defaultRepositoryName>FOOREPO</defaultRepositoryName>
        <defaultReviewers>
            <userName>joe</userName>
            <userName>fred</userName>
        </defaultReviewers>
        <id>5</id>
        <key>CR-FOO</key>
        <moderatorEnabled>true</moderatorEnabled>
        <name>Foo Project</name>
        <permissionSchemeId>32</permissionSchemeId>
    </projectData>
    

    A detailed description of a Crucible project.

    XML Schema

    Source: crucible.xsd

    <xs:complexType name="projectData">
        <xs:sequence>
          <xs:element name="allowReviewersToJoin" type="xs:boolean"/>
          <xs:element name="allowedReviewerGroups" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="allowedReviewerUsers" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="allowedReviewers" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="defaultDuration" type="xs:int" minOccurs="0"/>
          <xs:element name="defaultModerator" type="xs:string" minOccurs="0"/>
          <xs:element name="defaultObjectives" type="xs:string" minOccurs="0"/>
          <xs:element name="defaultRepositoryName" type="xs:string" minOccurs="0"/>
          <xs:element name="defaultReviewerGroups" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="defaultReviewerUsers" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="id" type="xs:int"/>
          <xs:element name="key" type="xs:string" minOccurs="0"/>
          <xs:element name="moderatorEnabled" type="xs:boolean"/>
          <xs:element name="name" type="xs:string" minOccurs="0"/>
          <xs:element name="permissionSchemeId" type="xs:int"/>
          <xs:element name="permissionSchemeName" type="xs:string" minOccurs="0"/>
          <xs:element name="storeRevisions" type="xs:boolean" minOccurs="0"/>
        </xs:sequence>
      </xs:complexType>
  • 200 - application/json (projectData) [expand]

    Example
    {
      "allowedReviewers" : {
        "size" : 2
      },
      "id" : 5,
      "name" : "Foo Project",
      "key" : "CR-FOO",
      "defaultRepositoryName" : "FOOREPO",
      "permissionSchemeId" : 32,
      "defaultDuration" : 5,
      "defaultModerator" : "joe",
      "moderatorEnabled" : true,
      "defaultObjectives" : "default objectives",
      "allowReviewersToJoin" : true,
      "defaultReviewers" : [ "joe", "fred" ]
    }

    A detailed description of a Crucible project.

    XML Schema

    Source: crucible.xsd

    <xs:complexType name="projectData">
        <xs:sequence>
          <xs:element name="allowReviewersToJoin" type="xs:boolean"/>
          <xs:element name="allowedReviewerGroups" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="allowedReviewerUsers" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="allowedReviewers" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="defaultDuration" type="xs:int" minOccurs="0"/>
          <xs:element name="defaultModerator" type="xs:string" minOccurs="0"/>
          <xs:element name="defaultObjectives" type="xs:string" minOccurs="0"/>
          <xs:element name="defaultRepositoryName" type="xs:string" minOccurs="0"/>
          <xs:element name="defaultReviewerGroups" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="defaultReviewerUsers" type="xs:string" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
          <xs:element name="id" type="xs:int"/>
          <xs:element name="key" type="xs:string" minOccurs="0"/>
          <xs:element name="moderatorEnabled" type="xs:boolean"/>
          <xs:element name="name" type="xs:string" minOccurs="0"/>
          <xs:element name="permissionSchemeId" type="xs:int"/>
          <xs:element name="permissionSchemeName" type="xs:string" minOccurs="0"/>
          <xs:element name="storeRevisions" type="xs:boolean" minOccurs="0"/>
        </xs:sequence>
      </xs:complexType>
  • 404 - application/xml (error) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotFound</code>
        <message>Requested resource not found.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:27)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    Response when the requested Crucible project does not exist.

  • 404 - application/json (error) [expand]

    Example
    {
      "code" : "NotFound",
      "message" : "Requested resource not found.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotFoundException: Requested resource not found.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:27)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    Response when the requested Crucible project does not exist.

/rest-service/auth-v1

This resource offers the ability for client applications to authenticate with Crucible and use the returned session identifier to make further calls without the need to send the caller's username and password every time.

The received token should be used as a FEAUTH query parameter for subsequent REST requests.

Usage of this resource is not required, as Crucible's REST API also supports basic HTTP authentication whereby the caller embeds the username and password in the HTTP request headers of every call, making the process completely stateless.

See https://developer.atlassian.com/display/FECRUDEV/Authenticating+REST+Requests for more details.
Methods

/rest-service/auth-v1/login

Methods

POST

Deprecated since FishEye 3.5.0 for removal in 4.0. Use POST /rest-service-fecru/auth/login instead.

Get the user authentication token.

acceptable request representations:

request form value parameters
parameter value description

userName

string

the username of the user to get the token for

password

string

the password for the user to get the token for

  • application/x-www-form-urlencoded [expand]

available response representations:

  • 200 - application/xml (loginResult) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <loginResult>
        <token>evzijst:3319:bb51658323e4927ca7669e9b439bfe21</token>
    </loginResult>
    

    Result of a successful login.

    XML Schema

    Source: crucible.xsd

    <xs:element name="loginResult" type="loginResult"/>
  • 200 - application/json (loginResult) [expand]

    Example
    {
      "token" : "evzijst:3319:bb51658323e4927ca7669e9b439bfe21"
    }

    Result of a successful login.

    XML Schema

    Source: crucible.xsd

    <xs:element name="loginResult" type="loginResult"/>
  • 403 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <loginResult>
        <error>authentication failed</error>
    </loginResult>
    

    Result of an unsuccessful login.

  • 403 - application/json [expand]

    Example
    {
      "error" : "authentication failed"
    }

    Result of an unsuccessful login.

GET

Deprecated since FishEye 3.5.0 for removal in 4.0. Use POST /rest-service-fecru/auth/login instead.

Get the user authentication token.
This is a legacy version of the login request. Using GET is deprecated as your password is likely to appear in logs which record request URLs. Use the POST version instead.
request query parameters
parameter value description

userName

string

the username of the user to get the token for

password

string

the password for the user to get the token for

available response representations:

  • 200 - application/xml (loginResult) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <loginResult>
        <token>evzijst:3319:bb51658323e4927ca7669e9b439bfe21</token>
    </loginResult>
    

    Result of a successful login.

    XML Schema

    Source: crucible.xsd

    <xs:element name="loginResult" type="loginResult"/>
  • 200 - application/json (loginResult) [expand]

    Example
    {
      "token" : "evzijst:3319:bb51658323e4927ca7669e9b439bfe21"
    }

    Result of a successful login.

    XML Schema

    Source: crucible.xsd

    <xs:element name="loginResult" type="loginResult"/>
  • 403 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <loginResult>
        <error>authentication failed</error>
    </loginResult>
    

    Result of an unsuccessful login.

  • 403 - application/json [expand]

    Example
    {
      "error" : "authentication failed"
    }

    Result of an unsuccessful login.

/rest-service/repositories-v1?name=<value>&enabled=<value>&available=<value>&type=<value>&limit=<value>

Methods

GET

Returns a list of all repositories. This includes plugin provided repositories

request query parameters
parameter value description

name

string

filter repositories by name, only repositories of names containing this value would be returned if value was provided. Case insensitive.

enabled

boolean

filter repositories by enabled flag. Only enabled/disabled repositories would be returned accordingly if value was provided.

available

boolean

filter repositories by its availability. Only available/unavailable repositories would be returned accordingly if value was provided.

type

string

filter repositories by type. Allowed values: cvs, svn, p4, git, hg, plugin (for light SCM repositories). Parameter can be specified more than once.

limit

int

Default: 10000

maximum number of repositories to be returned.

available response representations:

  • 200 - application/xml (repositories) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <repositories>
        <repoData xsi:type="svnRepositoryData" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <available>true</available>
            <enabled>true</enabled>
            <name>Foo Repository</name>
            <type>svn</type>
            <path>/foo</path>
            <url>http://localhost/svn</url>
        </repoData>
        <repoData xsi:type="pluginRepositoryData" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <available>true</available>
            <enabled>true</enabled>
            <name>CSLite</name>
            <type>plugin</type>
            <description>Crucible SCM plugin repository for the CS repository.</description>
            <hasChangelogBrowser>true</hasChangelogBrowser>
            <hasDirectoryBrowser>true</hasDirectoryBrowser>
            <pluginKey>CSL</pluginKey>
            <stateDescription>available</stateDescription>
        </repoData>
    </repositories>
    

    Listing of all FishEye and Crucible SCM repositories that are accessible to the caller of this resource.

  • 200 - application/json (repositories) [expand]

    Example
    {
      "repoData" : [ {
        "name" : "Foo Repository",
        "type" : "svn",
        "enabled" : true,
        "available" : true,
        "url" : "http://localhost/svn",
        "path" : "/foo"
      }, {
        "name" : "CSLite",
        "type" : "plugin",
        "enabled" : true,
        "available" : true,
        "description" : "Crucible SCM plugin repository for the CS repository.",
        "stateDescription" : "available",
        "pluginKey" : "CSL",
        "hasDirectoryBrowser" : true,
        "hasChangelogBrowser" : true
      } ]
    }

    Listing of all FishEye and Crucible SCM repositories that are accessible to the caller of this resource.

/rest-service/repositories-v1/content/{repo}/{revision}/{path:.*$}

resource-wide template parameters
parameter value description

revision

string

the SCM revision string.

repo

string

name of the Crucible SCM plugin repository.

path

string

the path of a file.

Methods

GET

Returns the raw content of the specified file revision as a binary stream. No attempt is made to identify the content type and no mime type is provided.

available response representations:

  • 200 [expand]

    The raw content of the specified file revision. Crucible currently does not provide a mime type.

/rest-service/repositories-v1/change/{repo}/{revision}

resource-wide template parameters
parameter value description

revision

string

the SCM revision string.

repo

string

name of the Crucible SCM plugin repository.

Methods

GET

Represents a particular changeset.

available response representations:

  • 200 - application/xml (change) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <change author="joe" date="2014-12-04T10:57:11.514+01:00" csid="345">
        <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/change/REPO/345"/>
        <comment>Commit message</comment>
        <revision revision="345" path="trunk/pom.xml">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/345/trunk/pom.xml"/>
            <details/>
            <diffRevision/>
            <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml"/>
        </revision>
        <revision revision="345" path="trunk/pom.xml">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/345/trunk/pom.xml"/>
            <details/>
            <diffRevision/>
            <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml"/>
        </revision>
    </change>
    

    A single change set.

    A change set describes the contents of a single commit on a Crucible SCM repository and includes changes to one or more files and or directories. Note that versioned directories are not supported by all SCM systems. For that reason the response does not distinguish between files and directories but instead, every record is a <revision>.

    Use title expansion if you want to force Crucible to populate each revision record with full meta data (expensive, as this is a 1-plus-n operation).

    Since the expandable <details> and <diffRevision> elements are burried more deeply in the xml hierarchy, use: ?expand=revision.*.

  • 200 - application/json (change) [expand]

    Example
    {
      "csid" : "345",
      "date" : 1417687031514,
      "author" : "joe",
      "comment" : "Commit message",
      "link" : {
        "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/change/REPO/345",
        "rel" : "self"
      },
      "revision" : [ {
        "path" : "trunk/pom.xml",
        "revision" : "345",
        "details" : {
        },
        "diffRevision" : {
        },
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml",
          "rel" : "history"
        }
      }, {
        "path" : "trunk/pom.xml",
        "revision" : "345",
        "details" : {
        },
        "diffRevision" : {
        },
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml",
          "rel" : "history"
        }
      } ]
    }

    A single change set.

    A change set describes the contents of a single commit on a Crucible SCM repository and includes changes to one or more files and or directories. Note that versioned directories are not supported by all SCM systems. For that reason the response does not distinguish between files and directories but instead, every record is a <revision>.

    Use title expansion if you want to force Crucible to populate each revision record with full meta data (expensive, as this is a 1-plus-n operation).

    Since the expandable <details> and <diffRevision> elements are burried more deeply in the xml hierarchy, use: ?expand=revision.*.

/rest-service/repositories-v1/changes/{repo}/{path:.*$}?oldestCsid=<value>&includeOldest=<value>&newestCsid=<value>&includeNewest=<value>&max=<value>

resource-wide template parameters
parameter value description

repo

string

name of the Crucible SCM plugin repository.

path

string

only show change sets which contain at least one revision with a path under this path. Changesets with some revisions outside this path still include all revisions. i.e. Revisions outside the path are *not* excluded from the change set.

Methods

GET

Represents a sorted list of changesets, newest first.

Note that when providing a path, use a trailing slash in the request url to indicate that it is a directory (use a "/" for the root directory of the repository). This may be necessary for some SCM plugins (including svn-light).

request query parameters
parameter value description

oldestCsid

string

only return change sets after this change set. If omitted there is no restriction.

includeOldest

boolean

include the change set with id "from" in the change sets returned.

newestCsid

string

only return change sets before this change set. If omitted there is no restriction.

includeNewest

boolean

include the change set with id "to" in the change sets returned.

max

int

return only the newest change sets, to a maximum of maxChangesets.

available response representations:

  • 200 - application/xml (changes) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <changes olderChangeSetsExist="false" newerChangeSetsExist="true">
        <change author="joe" date="2014-12-04T10:57:11.514+01:00" csid="345">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/change/REPO/345"/>
            <comment>Commit message</comment>
            <revision revision="345" path="trunk/pom.xml">
                <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/345/trunk/pom.xml"/>
                <details/>
                <diffRevision/>
                <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml"/>
            </revision>
            <revision revision="345" path="trunk/pom.xml">
                <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/345/trunk/pom.xml"/>
                <details/>
                <diffRevision/>
                <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml"/>
            </revision>
        </change>
        <change author="joe" date="2014-12-04T10:57:11.514+01:00" csid="234">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/change/REPO/234"/>
            <comment>Commit message</comment>
            <revision revision="234" path="trunk/pom.xml">
                <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/234/trunk/pom.xml"/>
                <details/>
                <diffRevision/>
                <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/234/trunk/pom.xml"/>
            </revision>
            <revision revision="234" path="trunk/pom.xml">
                <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/234/trunk/pom.xml"/>
                <details/>
                <diffRevision/>
                <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/234/trunk/pom.xml"/>
            </revision>
        </change>
    </changes>
    

    A collection of change sets. To expand both <details> and <diffRevision> of the revision elements inside the individual changesets, use: ?expand=change.revision.*

  • 200 - application/json (changes) [expand]

    Example
    {
      "newerChangeSetsExist" : true,
      "olderChangeSetsExist" : false,
      "change" : [ {
        "csid" : "345",
        "date" : 1417687031514,
        "author" : "joe",
        "comment" : "Commit message",
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/change/REPO/345",
          "rel" : "self"
        },
        "revision" : [ {
          "path" : "trunk/pom.xml",
          "revision" : "345",
          "details" : {
          },
          "diffRevision" : {
          },
          "link" : {
            "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml",
            "rel" : "history"
          }
        }, {
          "path" : "trunk/pom.xml",
          "revision" : "345",
          "details" : {
          },
          "diffRevision" : {
          },
          "link" : {
            "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/345/trunk/pom.xml",
            "rel" : "history"
          }
        } ]
      }, {
        "csid" : "234",
        "date" : 1417687031514,
        "author" : "joe",
        "comment" : "Commit message",
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/change/REPO/234",
          "rel" : "self"
        },
        "revision" : [ {
          "path" : "trunk/pom.xml",
          "revision" : "234",
          "details" : {
          },
          "diffRevision" : {
          },
          "link" : {
            "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/234/trunk/pom.xml",
            "rel" : "history"
          }
        }, {
          "path" : "trunk/pom.xml",
          "revision" : "234",
          "details" : {
          },
          "diffRevision" : {
          },
          "link" : {
            "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/234/trunk/pom.xml",
            "rel" : "history"
          }
        } ]
      } ]
    }

    A collection of change sets. To expand both <details> and <diffRevision> of the revision elements inside the individual changesets, use: ?expand=change.revision.*

/rest-service/repositories-v1/{name}/svn

resource-wide template parameters
parameter value description

name

string

name of a FishEye or Crucible SCM plugin repository.

Methods

GET

For backward compatibility we provide this method, but repositories should be referred to just by their name.

available response representations:

  • 200 - application/xml (svnRepositoryData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <svnRepositoryData>
        <available>true</available>
        <enabled>true</enabled>
        <name>Foo Repository</name>
        <type>svn</type>
        <path>/foo</path>
        <url>http://localhost/svn</url>
    </svnRepositoryData>
    

    Description of a Subversion repository provided by FishEye.

    XML Schema

    Source: crucible.xsd

    <xs:element name="svnRepositoryData" type="svnRepositoryData"/>
  • 200 - application/json (svnRepositoryData) [expand]

    Example
    {
      "name" : "Foo Repository",
      "type" : "svn",
      "enabled" : true,
      "available" : true,
      "url" : "http://localhost/svn",
      "path" : "/foo"
    }

    Description of a Subversion repository provided by FishEye.

    XML Schema

    Source: crucible.xsd

    <xs:element name="svnRepositoryData" type="svnRepositoryData"/>

/rest-service/repositories-v1/{name}

resource-wide template parameters
parameter value description

name

string

name of the Crucible SCM plugin repository.

Methods

GET

Returns the details of the repository with the specified name. When the repository exists, but the user has no access to it (possibly because the user is not authenticated), a 401 is returned.

The supplied repository name can be either a Crucible SCM plugin repository, or a FishEye repository.

available response representations:

  • 200 - application/xml (repositoryData) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <svnRepositoryData>
        <available>true</available>
        <enabled>true</enabled>
        <name>Foo Repository</name>
        <type>svn</type>
        <path>/foo</path>
        <url>http://localhost/svn</url>
    </svnRepositoryData>
    

    Example of a repository element. Possible return documents include:

    • SvnRepositoryData
    • CvsRepositoryData
    • P4RepositoryData
    • GitRepositoryData
    • PluginRepositoryData - represents Crucible SCM repositories provided by SCM plugins.

    XML Schema

    Source: crucible.xsd

    <xs:complexType name="repositoryData">
        <xs:sequence>
          <xs:element name="available" type="xs:boolean"/>
          <xs:element name="enabled" type="xs:boolean"/>
          <xs:element name="name" type="xs:string" minOccurs="0"/>
          <xs:element name="type" type="xs:string" minOccurs="0"/>
        </xs:sequence>
      </xs:complexType>
  • 200 - application/json (repositoryData) [expand]

    Example
    {
      "name" : "Foo Repository",
      "type" : "svn",
      "enabled" : true,
      "available" : true,
      "url" : "http://localhost/svn",
      "path" : "/foo"
    }

    Example of a repository element. Possible return documents include:

    • SvnRepositoryData
    • CvsRepositoryData
    • P4RepositoryData
    • GitRepositoryData
    • PluginRepositoryData - represents Crucible SCM repositories provided by SCM plugins.

    XML Schema

    Source: crucible.xsd

    <xs:complexType name="repositoryData">
        <xs:sequence>
          <xs:element name="available" type="xs:boolean"/>
          <xs:element name="enabled" type="xs:boolean"/>
          <xs:element name="name" type="xs:string" minOccurs="0"/>
          <xs:element name="type" type="xs:string" minOccurs="0"/>
        </xs:sequence>
      </xs:complexType>

/rest-service/repositories-v1/browse/{repo}/{path:.*$}

resource-wide template parameters
parameter value description

repo

string

name of the Crucible SCM plugin repository.

path

string

path to a directory. When path represents a file name, the result is unspecified.

Methods

GET

Lists the contents of the specified directory.

available response representations:

  • 200 - application/xml (listing) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <listing path="trunk">
        <dir path="trunk/src">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/browse/REPO/trunk/src"/>
        </dir>
        <dir path="trunk/test">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/browse/REPO/trunk/test"/>
        </dir>
        <file revision="1234" path="trunk/pom.xml">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/1234//trunk/pom.xml"/>
            <details/>
            <diffRevision/>
            <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/1234/trunk/pom.xml"/>
            <link rel="content" href="http://localhost:8060/crucible/rest-service/repositories-v1/content/REPO/1234/trunk/pom.xml"/>
        </file>
    </listing>
    

    Repository directory listing result containing files and directories.

    Every item contains a <link self=""/> perma link. Following this for a file it will give you the details for that file (containing the same information as the <file/> element in this result document). Following the link on a directory will give you a new dir listing.

    Other links:

    • <content/> on a file will return a raw MediaType.APPLICATION_OCTET_STREAM.
    • <history/> gives the full versioned history of the file.

  • 200 - application/json (listing) [expand]

    Example
    {
      "path" : "trunk",
      "dir" : [ {
        "path" : "trunk/src",
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/browse/REPO/trunk/src",
          "rel" : "self"
        }
      }, {
        "path" : "trunk/test",
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/browse/REPO/trunk/test",
          "rel" : "self"
        }
      } ],
      "file" : [ {
        "path" : "trunk/pom.xml",
        "revision" : "1234",
        "details" : {
        },
        "diffRevision" : {
        },
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/content/REPO/1234/trunk/pom.xml",
          "rel" : "content"
        }
      } ]
    }

    Repository directory listing result containing files and directories.

    Every item contains a <link self=""/> perma link. Following this for a file it will give you the details for that file (containing the same information as the <file/> element in this result document). Following the link on a directory will give you a new dir listing.

    Other links:

    • <content/> on a file will return a raw MediaType.APPLICATION_OCTET_STREAM.
    • <history/> gives the full versioned history of the file.

/rest-service/repositories-v1/{repo}/{revision}/{path:.*$}

resource-wide template parameters
parameter value description

revision

string

the SCM revision string.

repo

string

name of the Crucible SCM plugin repository.

path

string

the path of a file or versioned directory (note that versioned directories are not supported by all SCM plugins).

Methods

GET

Represents the details of a versioned entity (file or directory). This resource can be reached by following the file's self-link from a browse result.

Note that most responses support title expansion to minimize the costs of accessing the resources. Since file meta data is not always provided by SCM plugins, it is not expanded by default in the rest responses. Use title expansion to explicitly make Crucible include it.

The xml root element declares which elements are expandable (in this response: details and diffRevision). To expand both, use: ?expand=details,diffRevision

available response representations:

  • 200 - application/xml (scmVersionedEntity) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <file revision="1234" path="trunk/pom.xml">
        <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/1234//trunk/pom.xml"/>
        <details/>
        <diffRevision/>
        <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/1234/trunk/pom.xml"/>
        <link rel="content" href="http://localhost:8060/crucible/rest-service/repositories-v1/content/REPO/1234/trunk/pom.xml"/>
    </file>
    

    a versioned file.

  • 200 - application/json (scmVersionedEntity) [expand]

    Example
    {
      "path" : "trunk/pom.xml",
      "revision" : "1234",
      "details" : {
      },
      "diffRevision" : {
      },
      "link" : {
        "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/content/REPO/1234/trunk/pom.xml",
        "rel" : "content"
      }
    }

    a versioned file.

  • 401 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    when the caller does not have permission to access this resource.

  • 401 - application/json [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    when the caller does not have permission to access this resource.

/rest-service/repositories-v1/history/{repo}/{revision}/{path:.*$}

resource-wide template parameters
parameter value description

revision

string

the SCM revision string.

repo

string

name of the Crucible SCM plugin repository.

path

string

the path of a file or versioned directory (note that versioned directories are not supported by all SCM plugins).

Methods

GET

Represents the history of a versioned entity.

available response representations:

  • 200 - application/xml (history) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <history path="trunk/pom.xml">
        <revision revision="7" path="trunk/pom.xml">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/7/trunk/pom.xml"/>
            <details/>
            <diffRevision/>
            <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/7/trunk/pom.xml"/>
        </revision>
        <revision revision="4" path="trunk/pom.xml">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/4/trunk/pom.xml"/>
            <details/>
            <diffRevision/>
            <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/4/trunk/pom.xml"/>
        </revision>
        <revision revision="3" path="trunk/pom.xml">
            <link rel="self" href="http://localhost:8060/crucible/rest-service/repositories-v1/REPO/3/trunk/pom.xml"/>
            <details/>
            <diffRevision/>
            <link rel="history" href="http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/3/trunk/pom.xml"/>
        </revision>
    </history>
    

    Revision history for a versioned SCM entity.

    Use title expansion if you want to force Crucible to populate each revision record with full meta data (expensive, as this is a 1-plus-n operation).

    Since the expandable <details> and <diffRevision> elements are burried more deeply in the xml hierarchy, use: ?expand=revision.details.

    Note that a history response does not distinguish between files and directories. Instead, every record is a <revision>. This is because the Crucible SCM api does not provide enough information to tell the difference. Only when full meta data is provided (which a plugin is not required to include in most operations) you can infer the type by looking for the filetype property.

  • 200 - application/json (history) [expand]

    Example
    {
      "path" : "trunk/pom.xml",
      "revision" : [ {
        "path" : "trunk/pom.xml",
        "revision" : "7",
        "details" : {
        },
        "diffRevision" : {
        },
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/7/trunk/pom.xml",
          "rel" : "history"
        }
      }, {
        "path" : "trunk/pom.xml",
        "revision" : "4",
        "details" : {
        },
        "diffRevision" : {
        },
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/4/trunk/pom.xml",
          "rel" : "history"
        }
      }, {
        "path" : "trunk/pom.xml",
        "revision" : "3",
        "details" : {
        },
        "diffRevision" : {
        },
        "link" : {
          "href" : "http://localhost:8060/crucible/rest-service/repositories-v1/history/REPO/3/trunk/pom.xml",
          "rel" : "history"
        }
      } ]
    }

    Revision history for a versioned SCM entity.

    Use title expansion if you want to force Crucible to populate each revision record with full meta data (expensive, as this is a 1-plus-n operation).

    Since the expandable <details> and <diffRevision> elements are burried more deeply in the xml hierarchy, use: ?expand=revision.details.

    Note that a history response does not distinguish between files and directories. Instead, every record is a <revision>. This is because the Crucible SCM api does not provide enough information to tell the difference. Only when full meta data is provided (which a plugin is not required to include in most operations) you can infer the type by looking for the filetype property.

/rest-service/groups-v1

Methods

GET

Get a list of all the groups.

available response representations:

  • 200 - application/xml (groups) [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <groups>
        <groupData>
            <name>group1</name>
        </groupData>
        <groupData>
            <name>group2</name>
        </groupData>
        <groupData>
            <externalSource>crowd</externalSource>
            <name>crowd-group1</name>
        </groupData>
    </groups>
    

    a list of groups

  • 200 - application/json (groups) [expand]

    Example
    {
      "groupData" : [ {
        "name" : "group1"
      }, {
        "name" : "group2"
      }, {
        "name" : "crowd-group1",
        "externalSource" : "crowd"
      } ]
    }

    a list of groups

  • 403 - application/xml [expand]

    Example
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <error>
        <code>NotPermitted</code>
        <message>Access denied.</message>
        <stacktrace>com.atlassian.crucible.spi.services.NotPermittedException: Access denied.
    	at com.atlassian.crucible.spi.rpc.ExampleDocuments.&lt;clinit&gt;(ExampleDocuments.java:21)
    	at sun.misc.Unsafe.ensureClassInitialized(Native Method)
    	at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)
    	at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)
    	at java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)
    	at java.lang.reflect.Field.getFieldAccessor(Field.java:1038)
    	at java.lang.reflect.Field.get(Field.java:379)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)
    	at com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:606)
    	at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)
    	at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)
    	at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)
    	at com.sun.tools.javadoc.Start.begin(Start.java:167)
    	at com.sun.tools.javadoc.Main.execute(Main.java:59)
    	at com.sun.tools.javadoc.Main.main(Main.java:49)
    </stacktrace>
    </error>
    

    if you are not logged in or anonymous access is not allowed

  • 403 - application/json [expand]

    Example
    {
      "code" : "NotPermitted",
      "message" : "Access denied.",
      "stacktrace" : "com.atlassian.crucible.spi.services.NotPermittedException: Access denied.\n\tat com.atlassian.crucible.spi.rpc.ExampleDocuments.<clinit>(ExampleDocuments.java:21)\n\tat sun.misc.Unsafe.ensureClassInitialized(Native Method)\n\tat sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:43)\n\tat sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:140)\n\tat java.lang.reflect.Field.acquireFieldAccessor(Field.java:1057)\n\tat java.lang.reflect.Field.getFieldAccessor(Field.java:1038)\n\tat java.lang.reflect.Field.get(Field.java:379)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedLinkFromTag(ResourceDocletJsonXml.java:649)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.getSerializedExample(ResourceDocletJsonXml.java:542)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.createRepresentationDocTypes(ResourceDocletJsonXml.java:453)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.addResponseDoc(ResourceDocletJsonXml.java:428)\n\tat com.sun.jersey.wadl.resourcedoc.ResourceDocletJsonXml.start(ResourceDocletJsonXml.java:196)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:606)\n\tat com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:280)\n\tat com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:160)\n\tat com.sun.tools.javadoc.Start.parseAndExecute(Start.java:397)\n\tat com.sun.tools.javadoc.Start.begin(Start.java:167)\n\tat com.sun.tools.javadoc.Main.execute(Main.java:59)\n\tat com.sun.tools.javadoc.Main.main(Main.java:49)\n"
    }

    if you are not logged in or anonymous access is not allowed