GET /like
Get list of members who liked the item
Example URI
Code Block | ||||
---|---|---|---|---|
| ||||
http://example.com/restful_api/like?type_id=app&item_id=8&app_id=PHPfox_Videos&parent_module=pages |
Parameters
Parameter | Type | Require ? | Description |
---|---|---|---|
type_id | string | yes | Type id of the item |
item_id | number | yes | Item id |
app_id | string | no | Require if item type is app |
parent_module | string | no | Require for getting likes on app item on pages/groups |
Response
Code Block | ||||
---|---|---|---|---|
| ||||
{ "status": "success", "data": [ { "user_id": "1", "profile_page_id": "0", "user_server_id": "0", "user_name": "admin", "full_name": "Admin", "gender": "0", "user_image": "2016/12/07140d52d833bb6c304ee1f48bbe623f%s.png", "is_invisible": "0", "user_group_id": "1", "language_id": "en", "birthday": "05091988", "country_iso": "US" }, { "user_id": "3", "profile_page_id": "0", "user_server_id": "0", "user_name": "profile-3", "full_name": "Neil", "gender": "0", "user_image": null, "is_invisible": "0", "user_group_id": "2", "language_id": null, "birthday": null, "country_iso": null } ], "messages": [] } |
POST /like
Like an item
Example URI
Code Block | ||||
---|---|---|---|---|
| ||||
http://example.com/restful_api/like |
Parameters
Parameter | Type | Require ? | Description |
---|---|---|---|
type_id | string | yes | Type id of the item |
item_id | number | yes | Id of the item |
app_id | string | no | Required if item type is app |
parent_module | string | no | Require for adding like on app item on pages/groups |
Response
Code Block | ||||
---|---|---|---|---|
| ||||
{ "status": "success", "data": [], "messages": [ "Like successfully added." ] } |
DELETE /like
Unlike an item
Example URI
Code Block | ||||
---|---|---|---|---|
| ||||
http://example.com/restful_api/like |
Parameters
Parameter | Type | Require ? | Description |
---|---|---|---|
type_id | string | yes | Type id of the item |
item_id | number | yes | Id of the item |
app_id | string | no | Required if item type is app |
parent_module | string | no | Require for adding like on app item on pages/groups |
Response
Code Block | ||||
---|---|---|---|---|
| ||||
{ "status": "success", "data": [], "messages": [ "Like successfully deleted." ] } |