Saltar al contenido principal

Reviews

The Reviews API allows you to create, retrieve, update, and delete reviews for event occurrences. Reviews provide feedback from users about their experience.

Authentication​

All requests to the Reviews API must be authenticated using the ONLIVE.SITE authentication scheme. Please refer to the Authentication Guide for detailed instructions.

Base URL​

https://openapi.onlive.site/api/v1/reviews

Endpoints​


Create Review​

Creates a new review for an event occurrence.

HTTP Request​

POST /api/v1/reviews

Request Body​

FieldTypeRequiredDescription
occurrenceIdstring (uuid)YesThe ID of the event occurrence being reviewed
userIdstring (uuid)YesThe ID of the user who is creating the review
ratingnumberYesThe rating given in the review (1-5 scale)
commentstringNoThe comment text for the review

Example Request Body​

{
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 5,
"comment": "Great event, very informative!"
}

Response​

201 Created

Returns the created Review object.

Example Response​

{
"id": "123e4567-e89b-12d3-a456-426614174000",
"organizationId": "550e8400-e29b-41d4-a716-446655440003",
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 5,
"comment": "Great event, very informative!",
"organization": {
"id": "550e8400-e29b-41d4-a716-446655440003",
"name": "Tech Events Inc"
},
"createdAt": "2025-10-21T12:00:00.000Z",
"updatedAt": "2025-10-21T12:00:00.000Z"
}

Get Review​

Retrieves a specific review by its ID.

HTTP Request​

GET /api/v1/reviews/{id}

Path Parameters​

ParameterTypeRequiredDescription
idstring (uuid)YesThe unique identifier of the review

Query Parameters​

ParameterTypeRequiredDescription
withTrashedbooleanNoInclude trashed reviews

Response​

200 OK

Returns the Review object.

Example Response​

{
"id": "123e4567-e89b-12d3-a456-426614174000",
"organizationId": "550e8400-e29b-41d4-a716-446655440003",
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 5,
"comment": "Great event, very informative!",
"organization": {
"id": "550e8400-e29b-41d4-a716-446655440003",
"name": "Tech Events Inc"
},
"createdAt": "2025-10-21T12:00:00.000Z",
"updatedAt": "2025-10-21T12:00:00.000Z"
}

Update Review​

Updates an existing review.

HTTP Request​

PUT /api/v1/reviews/{id}

Path Parameters​

ParameterTypeRequiredDescription
idstring (uuid)YesThe unique identifier of the review to update

Request Body​

All fields are optional. Only the fields you want to update need to be included.

FieldTypeRequiredDescription
ratingnumberNoThe rating given in the review (1-5 scale)
commentstringNoThe comment text for the review

Example Request Body​

{
"rating": 4,
"comment": "Updated comment about the event"
}

Response​

200 OK

Returns the updated Review object.

Example Response​

{
"id": "123e4567-e89b-12d3-a456-426614174000",
"organizationId": "550e8400-e29b-41d4-a716-446655440003",
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 4,
"comment": "Updated comment about the event",
"organization": {
"id": "550e8400-e29b-41d4-a716-446655440003",
"name": "Tech Events Inc"
},
"createdAt": "2025-10-21T12:00:00.000Z",
"updatedAt": "2025-10-21T14:00:00.000Z"
}

Search Reviews​

Returns a paginated list of reviews with optional filtering and sorting.

HTTP Request​

GET /api/v1/reviews

Query Parameters​

ParameterTypeRequiredDescription
limitnumberNoMaximum number of items to return (default: 10, min: 1)
pagenumberNoPage number (starts at 1, default: 1, min: 1)
sortstringNoField name and direction to sort results by (default: "createdAt DESC", example: "createdAt DESC")
organizationIdstring (uuid)NoFilter reviews by organization ID
occurrenceIdstring (uuid)NoFilter by event occurrence ID
userIdstring (uuid)NoFilter by user ID
eventIdstring (uuid)NoFilter reviews by event ID
searchstringNoSearch term to filter reviews by comment text
withTrashedbooleanNoInclude soft-deleted reviews in the results
userGroupIdstring (uuid)NoFilter reviews by user group ID
templateIdstring (uuid)NoFilter reviews by template ID

Example Request​

GET /api/v1/reviews?organizationId=550e8400-e29b-41d4-a716-446655440003&occurrenceId=550e8400-e29b-41d4-a716-446655440000&eventId=123e4567-e89b-12d3-a456-426614174000&userId=550e8400-e29b-41d4-a716-446655440002&search=informative&page=1&limit=20&sort=rating DESC

Response​

200 OK

Returns a paginated list of reviews using the EventReviewsResponseDto structure.

Example Response​

{
"count": 1,
"total": 1,
"currentPage": 1,
"totalPages": 1,
"items": [],
"data": [
{
"organizationId": "550e8400-e29b-41d4-a716-446655440003",
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 5,
"comment": "Great event, very informative!",
"createdAt": "2025-10-21T12:00:00.000Z",
"updatedAt": "2025-10-21T12:00:00.000Z"
}
]
}

Delete Review​

Deletes a review.

HTTP Request​

DELETE /api/v1/reviews/{id}

Path Parameters​

ParameterTypeRequiredDescription
idstring (uuid)YesThe unique identifier of the review to delete

Query Parameters​

ParameterTypeRequiredDescription
withTrashedbooleanNoInclude trashed reviews

Response​

200 OK

Returns the deleted Review object.

Example Response​

{
"id": "123e4567-e89b-12d3-a456-426614174000",
"organizationId": "550e8400-e29b-41d4-a716-446655440003",
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 5,
"comment": "Great event, very informative!",
"organization": {
"id": "550e8400-e29b-41d4-a716-446655440003",
"name": "Tech Events Inc"
},
"createdAt": "2025-10-21T12:00:00.000Z",
"updatedAt": "2025-10-21T12:00:00.000Z"
}

Review Object​

The Review object represents a user review for an event occurrence.

Properties​

PropertyTypeDescription
idstring (uuid)The unique identifier of the review
organizationIdstring (uuid)The ID of the organization the review belongs to
occurrenceIdstring (uuid)The ID of the event occurrence being reviewed
userIdstring (uuid)The ID of the user who created the review
ratingnumberThe rating given in the review (1-5 scale)
commentstring | nullThe comment text for the review
organizationobjectThe organization associated with the review
createdAtstring (date-time)The date and time when the review was created
updatedAtstring (date-time)The date and time when the review was last updated
deletedAtstring (date-time)The deletion date of the review (if deleted)

Example​

{
"id": "123e4567-e89b-12d3-a456-426614174000",
"organizationId": "550e8400-e29b-41d4-a716-446655440003",
"occurrenceId": "550e8400-e29b-41d4-a716-446655440000",
"userId": "550e8400-e29b-41d4-a716-446655440002",
"rating": 5,
"comment": "Great event, very informative!",
"organization": {
"id": "550e8400-e29b-41d4-a716-446655440003",
"name": "Tech Events Inc"
},
"createdAt": "2025-10-21T12:00:00.000Z",
"updatedAt": "2025-10-21T12:00:00.000Z"
}