Reviews Resource

Endpoints under /reviews allow access to user reviews including deleting specific reviews.

POST /v2/reviews

A POST request to the /review endpoint creates a user review.

Request Body
media type data type description
application/json UserReview (JSON) A UserReview object including the review content, the object to which the review applies and the user to whom the review is attributed.
Response Body
media type data type description
application/json UserReview (JSON) The new UserReview object including the unique key assigned to it.

Example

Request
POST /v2/reviews
Content-Type: application/json
Accept: application/json

                
{
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
}
                
              
Response
HTTP/1.1 201 Created
Content-Type: application/json

                
{
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
}
                
              

PUT /v2/reviews

A PUT request to the /review endpoint updates a user review.

Request Body
media type data type description
application/json UserReview (JSON) A UserReview object including the updated properties of the review. Only properties provided are updated.
Response Body
media type data type description
application/json UserReview (JSON) The updated UserReview object.

Example

Request
PUT /v2/reviews
Content-Type: application/json
Accept: application/json

                
{
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
}
                
              
Response
HTTP/1.1 204 No Content
Content-Type: application/json

                
{
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
}
                
              

DELETE /v2/reviews/{key}

A DELETE request to the /review endpoint deletes a user review identified by key.

Request Parameters
name type description
key path The unique identifier for a user review.
Response Body
media type data type description
application/json object (JSON)

Example

Request
DELETE /v2/reviews/{key}
Content-Type: application/json
Accept: application/json

                
...
                
              
Response
HTTP/1.1 204 No Content
Content-Type: application/json

                
...
                
              

GET /v2/reviews/entity/{entityKey}

A GET request to the /review/entity/{entityKey} endpoint returns reviews on a particular entity identified by the entityKey.

Request Parameters
name type description
entityKey path The unique identifier for the entity.
Response Body
media type data type description
application/json array of UserReview (JSON) An array of UserReview objects in JSON format.

Example

Request
GET /v2/reviews/entity/{entityKey}
Content-Type: application/json
Accept: application/json

                
...
                
              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
[ {
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
} ]
                
              

GET /v2/reviews/user/{user}

A GET request to the /review/user/{user} endpoint returns reviews generated by a particular user.

Request Parameters
name type description
user path The name of the user profile.
Response Body
media type data type description
application/json array of UserReview (JSON) An array of UserReview objects in JSON format.

Example

Request
GET /v2/reviews/user/{user}
Content-Type: application/json
Accept: application/json

                
...
                
              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
[ {
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
} ]
                
              

POST /v2/reviews/users/{user}

Request Parameters
name type description
user path
Request Body
media type data type
application/json UserReview (JSON)
Response Body
media type data type description
application/json UserReview (JSON)

Example

Request
POST /v2/reviews/users/{user}
Content-Type: application/json
Accept: application/json

                
{
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
}
                
              
Response
HTTP/1.1 201 Created
Content-Type: application/json

                
{
  "user" : "...",
  "entityKey" : "...",
  "rating" : 12345,
  "title" : "...",
  "source" : "...",
  "key" : "...",
  "type" : "...",
  "description" : "...",
  "timeOfLastChange" : 12345,
  "timeOfCreation" : 12345,
  "restricted" : [ "...", "..." ],
  "updateable" : [ "...", "..." ],
  "viewAble" : [ "...", "..." ],
  "customProperties" : [ {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  }, {
    "displayName" : "...",
    "value" : { },
    "description" : "...",
    "facetAble" : true,
    "name" : "...",
    "type" : "..."
  } ]
}