Posts and Reviews
Posts and reviews API allows to support social functions in your App, like writing reviews for recipes , add Posts (with different types attached content), leave replies.
General information
Reviews and Posts entities
Reviews and Posts are technically separated entities on Whisk from UX perspective but there are connected in the back-end side.
Review in UX - special content which user could leave for a certain recipe. Review should include binary rate mandatory, and text, image, tags as optiional parameters.
Post in UX - special type of content which could be created by user and contain text, image, recipe or review.
On back-end side when we are getting request for creating a review for some recipe from a user we automatically create post in our system and put created review in it. So from this moment client will get post id every time when requestion review. So it is possible to call operations on Post if user want to do something with review. For example, to report review client should call post reporting endpoint.
Client could create reviews via reviews api or post api but it is recommended to create and edit reviews via reviews api cause reviews have more lightweighted structure.
Review object
Review object is a group of objects and attributes
Attributes description
Attribute | Type | Description |
---|---|---|
Mandatory. Recipe id to which review relates | ||
Optional. Text which will be attached to review | ||
| Mandatory. Rate attached to review. | |
| Optional. Array of tags attached to review | |
| Optional. Image object |
After review creation and automatic attaching to Post on BE side review attributes text
and image
copy to post attributes.
Post object
Post object is a group of objects and attributes
Attributes description
Attribute | Type | Description |
---|---|---|
Mandatory. Post id (unique) | ||
Optional. Deprecated. Title for conversation Post. | ||
| Optional. Text attached to post. | |
| Optional. Information for displaying post on HomeFeed or in profile | |
| Mandatory. Data for displaying information about author | |
| Mandatory. Data on post was added | |
| Mandatory. Information about time since the post was added | |
| Optional. Identify type of attachment for post | |
| Optional. Represents image attachments to regular post | |
| Optional. Shows if recipe was added as attachment to post. Can't use with | |
| Optional.Shows if recipe review was added as attachment to post. Can't use with other types such as | |
| Optional. Shows if communities were added to posts. Can't be used with other attachment types. | |
| Optional. Shows replies to post | |
| Optional. Shows reactions to post |
Reply object
Reply object is a group of objects and attributes
Attributes description
Attribute | Type | Description |
---|---|---|
Mandatory. Reply id (unique) | ||
| Optional. Text attached to reply. | |
| Mandatory. Data for displaying information about author | |
| Mandatory. Information about time since the reply was added | |
| Optional. Identify type of attachment for reply. Could be either image or recipe. If there is no attachment it could be skipped | |
| Optional. Represents images attachments to reply. | |
| Optional. Shows if recipe was added as attachment to rely. | |
| Optional. Shows reactions to post | |
| Mandatory. Total number of replies | |
| Standard pagination object |
Last updated