Socialid.selfie.unlike
From Social ID Developers
Contents |
Description
Removes a like in a post from a particular user (decrements the likes count).
Usage
socialid.selfie.unlike(postId, handler, options)
Parameters
postId | required | numeric identifier for the post. | handler | optional | callback function to be called on the API response. | options | optional | object containing additional parameters. | user_id | optional | user identifier. Default: User IP. |
---|
API Response
data | Always "null". This API doesn't return any data. | status | API call status. Can be "success" in case of a successful unlike, "not_found" in case the post wasn't found, or "internal_server_error" in case an unknown error occurs. |
---|
Example
Makes the user with user_id = "32" unlike the post with post_id = "34":
var handler = function(response) { if (response.status == "success") { alert("Unlike successful."); } else { alert("Wasn't possible to unlike this post."); } } var appId = 1; socialid.selfie.init(appId); socialid.selfie.unlike(34, handler, {user_id: 32});