This module enables you to integrate your App with social networking sites such as Facebook, Twitter and LinkedIn allows App users to update the status on such social networking sites.
In order to use various functions available in a specific API, a developer has to create an instance of ServiceAPI by passing the apiKey and secretKey which will be created after the app creation from AppHQ dashboard.
Required Parameters
apiKey - The Application key given when the application was created.
secretKey - The secret key corresponding to the application key given when the application was created.
ServiceAPI api = new ServiceAPI("API_KEY","SECRET_KEY");ServiceAPI api = new ServiceAPI("API_KEY","SECRET_KEY");ServiceAPI *api = [[ServiceAPI alloc]init]; api.apiKey = @"<API_KEY>"; api.secretKey = @"<SECRET_KEY>";ServiceAPI api = new ServiceAPI("API_KEY","SECRET_KEY");ServiceAPI api = new ServiceAPI("API_KEY","SECRET_KEY");ServiceAPI api = new ServiceAPI("API_KEY","SECRET_KEY");App42.initialize("API_KEY","SECRET_KEY");ServiceAPI api = new ServiceAPI("API_KEY","SECRET_KEY");$api = new ServiceAPI("API_KEY","SECRET_KEY");Coming Soonapi = App42::ServiceAPI.new("<API_KEY>","<SECRET_KEY>")Coming SoonComing Soon
After initialization, developer needs to call the buildXXXService method on ServiceAPI instance to get the instance of the particular API that you wish to build. For example, To build an instance of SocialService, buildSocialService() method needs to be called.
SocialService socialService = api.buildSocialService();SocialService socialService = api.BuildSocialService();SocialService *socialService = [api buildSocialService];SocialService socialService = api.buildSocialService();SocialService socialService = api.buildSocialService();SocialService socialService = api.BuildSocialService();var socialService = new App42Social();SocialService socialService = api.BuildSocialService();$socialService = $api->buildSocialService();Coming Soonsocial_service = api.build_social_service()Coming SoonComing Soon
import com.shephertz.app42.paas.sdk.android.ServiceAPI; import com.shephertz.app42.paas.sdk.android.App42Response; import com.shephertz.app42.paas.sdk.android.App42Exception; import com.shephertz.app42.paas.sdk.android.App42BadParameterException; import com.shephertz.app42.paas.sdk.android.App42NotFoundException; import com.shephertz.app42.paas.sdk.android.social.Social; import com.shephertz.app42.paas.sdk.android.social.SocialService;using com.shephertz.app42.paas.sdk.windows; using com.shephertz.app42.paas.sdk.windows.social;#import "Shephertz_App42_iOS_API/Shephertz_App42_iOS_API.h"import com.shephertz.app42.paas.sdk.jme.ServiceAPI; import com.shephertz.app42.paas.sdk.jme.App42Response; import com.shephertz.app42.paas.sdk.jme.App42Exception; import com.shephertz.app42.paas.sdk.jme.App42BadParameterException; import com.shephertz.app42.paas.sdk.jme.App42NotFoundException; import com.shephertz.app42.paas.sdk.jme.social.Social; import com.shephertz.app42.paas.sdk.jme.social.SocialService;import com.shephertz.app42.paas.sdk.java.ServiceAPI; import com.shephertz.app42.paas.sdk.java.App42Response; import com.shephertz.app42.paas.sdk.java.App42Exception; import com.shephertz.app42.paas.sdk.java.App42BadParameterException; import com.shephertz.app42.paas.sdk.java.App42NotFoundException; import com.shephertz.app42.paas.sdk.java.social.Social; import com.shephertz.app42.paas.sdk.java.social.SocialService;using com.shephertz.app42.paas.sdk.csharp; using com.shephertz.app42.paas.sdk.csharp.social;<script type="text/javascript" src="App42-all-x.x.x.min.js"></script>using com.shephertz.app42.paas.sdk.csharp; using com.shephertz.app42.paas.sdk.csharp.social;use com\shephertz\app42\paas\sdk\php\ServiceAPI; use com\shephertz\app42\paas\sdk\php\App42Response; use com\shephertz\app42\paas\sdk\php\App42Exception; use com\shephertz\app42\paas\sdk\php\App42BadParameterException; use com\shephertz\app42\paas\sdk\php\App42NotFoundException; use com\shephertz\app42\paas\sdk\php\social\SocialService; include_once '../ServiceAPI.php'; include_once '../App42Response.php'; include_once '../App42Exception.php'; include_once '../App42BadParameterException.php'; include_once '../App42NotFoundException.php'; include_once '../SocialService.php';Coming Soonrequire 'App42_Ruby_API'Coming SoonComing Soon
Links the User Facebook access credentials to the App User account.
Required Parameters
userName - Name of the user whose Facebook account to be linked.
accessToken - Facebook Access Token that has been received after authorization.
String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.linkUserFacebookAccount(userName, accessToken); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getFacebookAccessToken()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; socialService.LinkUserFacebookAccount(userName, accessToken, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("fb Access Token is" + social.GetFacebookAccessToken()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *accessToken = @"FACEBOOK ACCESS TOKEN"; Social *social = [socialService linkUserFacebookAccount:userName accessToken:accessToken); NSLog(@"Username is %@",social.userName); NSLog(@"FacebookAccessToken is %@",social.facebookAccessToken); NSString *jsonResponse = [social toString];String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.linkUserFacebookAccount(userName, accessToken); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getFacebookAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.linkUserFacebookAccount(userName, accessToken); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getFacebookAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; socialService.LinkUserFacebookAccount(userName, accessToken, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", accessToken = "FACEBOOK ACCESS TOKEN", social ; socialService.linkUserFacebookAccount(userName, accessToken,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("fb Access Token is " + social.facebookAccessToken) }, error: function(error) { } });String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.LinkUserFacebookAccount(userName, accessToken); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("fb Access Token is" + social.GetFacebookAccessToken()); String jsonResponse = social.ToString();$userName = "Nick"; $accessToken = "FACEBOOK ACCESS TOKEN"; $social = $socialService->linkUserFacebookAccount($userName, $accessToken); Print_r("userName is" . $social->getUserName()); Print_r("fb Access Token is" . $social->getFacebookAccessToken()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; facebook_access_token = "SD23435FF-m67CV2QqqizC6tKwS88R8K7YxTts54HPmUv4EfJC"; social = social_service.link_user_facebook_account(user_name, facebook_access_token); puts "userName is #{social.user_name}"; puts "facebookAccessToken is #{social.facebook_access_token}"; json_response = social.to_s();Coming SoonComing Soon
Links the User Facebook access credentials to the App User account.
Required Parameters
userName - Name of the user whose Facebook account to be linked.
accessToken - Facebook Access Token that has been received after authorization.
appId - Facebook App Id.
appSecret - Facebook App Secret.
String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; String appId = "FACEBOOK APP ID"; String appSecret = "FACEBOOK APP SECRET"; Social social = socialService.linkUserFacebookAccount(userName, accessToken,appId,appSecret); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getFacebookAccessToken()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; String appId = "FACEBOOK APP ID"; String appSecret = "FACEBOOK APP SECRET"; socialService.LinkUserFacebookAccount(userName, accessToken,appId,appSecret, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("fb Access Token is" + social.GetFacebookAccessToken()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *accessToken = @"FACEBOOK ACCESS TOKEN"; NSString *appId = @"FACEBOOK APP ID"; NSString *appSecret = @"FACEBOOK APP SECRET"; Social *social = [socialService linkUserFacebookAccount:userName appId:appId appSecret:appSecret accessToken:accessToken); NSLog(@"Username is %@",social.userName); NSLog(@"FacebookAccessToken is %@",social.facebookAccessToken); NSString *jsonResponse = [social toString];String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; String appId = "FACEBOOK APP ID"; String appSecret = "FACEBOOK APP SECRET"; Social social = socialService.linkUserFacebookAccount(userName, accessToken,appId,appSecret); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getFacebookAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; String appId = "FACEBOOK APP ID"; String appSecret = "FACEBOOK APP SECRET"; Social social = socialService.linkUserFacebookAccount(userName, accessToken,appId,appSecret); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getFacebookAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; String appId = "FACEBOOK APP ID"; String appSecret = "FACEBOOK APP SECRET"; socialService.LinkUserFacebookAccount(userName, accessToken, appId, appSecret, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", accessToken = "FACEBOOK ACCESS TOKEN", appId = "FACEBOOK APP ID", appSecret = "FACEBOOK APP SECRET", social ; socialService.linkUserFacebookAccountWithCredentials(userName, accessToken,appId,appSecret,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("fb Access Token is " + social.facebookAccessToken) }, error: function(error) { } });String userName = "Nick"; String accessToken = "FACEBOOK ACCESS TOKEN"; String appId = "FACEBOOK APP ID"; String appSecret = "FACEBOOK APP SECRET"; Social social = socialService.LinkUserFacebookAccount(userName, accessToken,appId,appSecret); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("fb Access Token is" + social.GetFacebookAccessToken()); String jsonResponse = social.ToString();$userName = "Nick"; $accessToken = "FACEBOOK ACCESS TOKEN" ; $appId = "FACEBOOK APP ID"; $appSecret = "FACEBOOK APP SECRET"; $social = $socialService->linkUserFacebookAccount($userName, $accessToken,$appId,$appSecret); Print_r("userName is" . $social->getUserName()); Print_r("fb Access Token is" . $social->getFacebookAccessToken()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; facebook_access_token = "SD23435FF-m67CV2QqqizC6tKwS88R8K7YxTts54HPmUv4EfJC"; facebook_app_id = "7lFvyAd515aKrFWrtYU"; facebook_app_secret = "uFQ4QBr1fxcTthcB7bE5yvnaqDF567UJddRk8vNs"; social = social_service.link_user_facebook_account_with_token(user_name, facebook_access_token, facebook_app_id, facebook_app_secret); puts "userName is #{social.user_name}"; puts "facebookAccessToken is #{social.facebook_access_token}"; puts "facebookAppId is #{social.facebook_app_id}"; puts "facebookAppSecret is #{social.facebook_app_secret}"; json_response = social.to_s();Coming SoonComing Soon
Updates the Facebook status of the specified user.
Required Parameters
userName - Name of the user for whom the status needs to be updated
status - Status that has to be updated.
String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateFacebookStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateFacebookStatus(userName, status, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *status = @"Nick is using the App42 API"; Social *social = [socialService updateFacebookStatus:userName status:status); NSLog(@"Username is %@",social.userName); NSLog(@"status is %@",social.status); NSString *jsonResponse = [social toString];String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateFacebookStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateFacebookStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateFacebookStatus(userName, status, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", status = "Nick is using the App42 API", social ; socialService.updateFacebookStatus(userName, status,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("status is " + social.status) }, error: function(error) { } });String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.UpdateFacebookStatus(userName, status); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString();$userName = "Nick"; $status = "Nick is using the App42 API"; $social = $socialService->updateFacebookStatus($userName, $status); Print_r("userName is" . $social->getUserName()); Print_r("status is" . $social->getStatus()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; status = "Reviewing Twitter APIs By Nick"; social = social_service.update_facebook_status(user_name, status); puts "userName is #{social.user_name}"; puts "facebookAppId is #{social.facebook_app_id}"; puts "facebookAppSecret is #{social.facebook_app_secret}"; puts "facebookAccessToken is #{social.facebook_access_token}"; json_response = social.to_s();Coming SoonComing Soon
This function returns a list of facebook friends of the specified user by accessing the facebook account.
Required Parameters
userName - Name of the user whose Facebook friends account has to be retrieve.
String userName = "Nick"; Social social = socialService.getFacebookFriendsFromLinkUser(userName); System.out.println("userName is " + social.getUserName()); for(int i =0; i < social.getFriendList().size();i++) { System.out.println(social.getFriendList().get(i).getInstalled()); System.out.println(social.getFriendList().get(i).getId()); System.out.println(social.getFriendList().get(i).getName()); }public class Callback : App42Callback { String userName = "Nick"; socialService.GetFacebookFriendsFromLinkUser(userName, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); for(int i =0; i < social.GetFriendList().Count;i++) { Console.WriteLine(social.GetFriendList()[i].GetInstalled()); Console.WriteLine(social.GetFriendList()[i].GetId()); Console.WriteLine(social.GetFriendList()[i].GetName()); } } }Coming SoonString userName = "Nick"; Social social = socialService.getFacebookFriendsFromLinkUser(userName); System.out.println("userName is " + social.getUserName()); Vector friendList = social.getFriendList(); for(int i=0;i < friendList.size();i++) { Social.Friends friend = (Social.Friends)friendList.elementAt(i); System.out.println(friend.getInstalled()); System.out.println(friend.getId()); System.out.println(friend.getName()); }String userName = "Nick"; Social social = socialService.getFacebookFriendsFromLinkUser(userName); System.out.println("userName is " + social.getUserName()); for(int i =0; i < social.getFriendList().size();i++) { System.out.println(social.getFriendList().get(i).getInstalled()); System.out.println(social.getFriendList().get(i).getId()); System.out.println(social.getFriendList().get(i).getName()); }String userName = "Nick"; socialService.GetFacebookFriendsFromLinkUser(userName, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { Social social = (Social) response; App42Log.Console("userName is" + social.GetUserName()); for(int i =0; i < social.GetFriendList().Count;i++) { App42Log.Console(social.GetFriendList()[i].GetInstalled()); App42Log.Console(social.GetFriendList()[i].GetId()); App42Log.Console(social.GetFriendList()[i].GetName()); } } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", social ; socialService.getFacebookFriendsFromLinkUser(userName,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) }, error: function(error) { } });String userName = "Nick"; Social social = socialService.GetFacebookFriendsFromLinkUser(userName); Console.WriteLine("userName is" + social.GetUserName()); for(int i =0; i < social.GetFriendList().Count;i++) { Console.WriteLine(social.GetFriendList()[i].GetInstalled()); Console.WriteLine(social.GetFriendList()[i].GetId()); Console.WriteLine(social.GetFriendList()[i].GetName()); }$userName = "Nick"; $social = $socialService->getFacebookFriendsFromLinkUser($userName); Print_r("userName is" . $social->getUserName()); Print_r("friendName is" . $social->getFriendList()[0]->getName()); $jsonResponse = $social->toString();Coming SoonComing SoonComing SoonComing Soon
This function returns a list of facebook friends of the specified user using a given authorization token. To get the friend list here, user needs not to log into the facebook account.
Required Parameters
accessToken - Facebook Access Token that has been received after authorization.
String accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.getFacebookFriendsFromAccessToken(accessToken); System.out.println("accessToken is " + social.getFacebookAccessToken()); for(int i =0; i < social.getFriendList().size();i++) { System.out.println(social.getFriendList().get(i).getInstalled()); System.out.println(social.getFriendList().get(i).getId()); System.out.println(social.getFriendList().get(i).getName()); }public class Callback : App42Callback { String accessToken = "FACEBOOK ACCESS TOKEN"; socialService.GetFacebookFriendsFromAccessToken(accessToken, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("accessToken is" + social.GetFacebookAccessToken()); Console.WriteLine("userName is" + social.GetUserName()); for(int i =0; i < social.GetFriendList().Count;i++) { Console.WriteLine(social.GetFriendList()[i].GetInstalled()); Console.WriteLine(social.GetFriendList()[i].GetId()); Console.WriteLine(social.GetFriendList()[i].GetName()); } } }Coming SoonString accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.getFacebookFriendsFromAccessToken(accessToken); System.out.println("accessToken is " + social.getFacebookAccessToken()); Vector friendList = social.getFriendList(); for(int i=0;i < friendList.size();i++) { Social.Friends friend = (Social.Friends)friendList.elementAt(i); System.out.println(friend.getInstalled()); System.out.println(friend.getId()); System.out.println(friend.getName()); }String userName = "Nick"; Social social = socialService.getFacebookFriendsFromAccessToken(accessToken); System.out.println("accessToken is " + social.getFacebookAccessToken()); for(int i =0; i < social.getFriendList().size();i++) { System.out.println(social.getFriendList().get(i).getInstalled()); System.out.println(social.getFriendList().get(i).getId()); System.out.println(social.getFriendList().get(i).getName()); }String accessToken = "FACEBOOK ACCESS TOKEN"; socialService.GetFacebookFriendsFromAccessToken(accessToken, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { Social social = (Social) response; App42Log.Console("accessToken is" + social.GetFacebookAccessToken()); for(int i =0; i < social.GetFriendList().Count;i++) { App42Log.Console(social.GetFriendList()[i].GetInstalled()); App42Log.Console(social.GetFriendList()[i].GetId()); App42Log.Console(social.GetFriendList()[i].GetName()); } } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var accessToken = "FACEBOOK ACCESS TOKEN, social ; socialService.getFacebookFriendsFromAccessToken(accessToken,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("accessToken is " + social.getFacebookAccessToken) }, error: function(error) { } });String accessToken = "FACEBOOK ACCESS TOKEN"; Social social = socialService.GetFacebookFriendsFromAccessToken(accessToken); Console.WriteLine("accessToken is" + social.GetFacebookAccessToken()); for(int i =0; i < social.GetFriendList().Count;i++) { Console.WriteLine(social.GetFriendList()[i].GetInstalled()); Console.WriteLine(social.GetFriendList()[i].GetId()); Console.WriteLine(social.GetFriendList()[i].GetName()); }$accessToken = "FACEBOOK ACCESS TOKEN"; $social = $socialService->getFacebookFriendsFromAccessToken($accessToken); Print_r("accessToken is" . $social->getFacebookAccessToken()); Print_r("friendName is" . $social->getFriendList()[0]->getName()); $jsonResponse = $social->toString();Coming SoonComing SoonComing SoonComing Soon
Links the User Twitter access credentials to the App User account.
Required Parameters
userName - Name of the user whose Twitter account to be linked.
accessToken - Twitter Access Token that has been received after authorization.
accessTokenSecret - Twitter Access Token Secret that has been received after authorization.
String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is " + social.getTwitterAccessToken()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("twitter Access Token is" + social.GetTwitterAccessToken()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *accessToken = @"TWITTER ACCESS TOKEN"; NSString *accessTokenSecret = @"TWITTER ACCESS TOKEN SECRET"; Social *social = [socialService linkUserTwitterAccount:userName accessToken:accessToken accessTokenSecret:accessTokenSecret); NSLog(@"Username is %@",social.userName); NSLog(@"twitter Access Token is %@",social.twitterAccessToken); NSString *jsonResponse = [social toString];String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is " + social.getTwitterAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is" + social.getTwitterAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", accessToken = "TWITTER ACCESS TOKEN", accessTokenSecret = "TWITTER ACCESS TOKEN SECRET", social ; socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("twitter Access Token is " + social.twitterAccessToken) }, error: function(error) { } });String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; Social social = socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("twitter Access Token is" + social.GetTwitterAccessToken()); String jsonResponse = social.ToString();$userName = "Nick"; $accessToken = "TWITTER ACCESS TOKEN"; $accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; $social = $socialService->linkUserTwitterAccount($userName, $accessToken,$accessTokenSecret); Print_r("userName is" . $social->getUserName()); Print_r("twitter Access Token is" . $social->getTwitterAccessToken()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; twitter_access_token = "SD23435FF-m67CV2QqqizC6tKwS88R8K7YxTts54HPmUv4EfJC"; twitter_access_token_secret = "DEFThh67kJdQAOS3zSBqn8SqjkRpgw8oJJZKV9vg"; social = socialService.link_user_twitter_account(user_name, twitter_access_token, twitter_access_token_secret); puts "userName is #{social.user_name}"; puts "twitterAccessToken is #{social.twitter_access_token}"; puts "twitterAccessTokenSecret is #{social.twitter_access_token_secret}"; json_response = social.to_s();Coming SoonComing Soon
Links the User Twitter access credentials to the App User account.
Required Parameters
userName - Name of the user whose Twitter account to be linked.
accessToken - Twitter Access Token that has been received after authorization.
accessTokenSecret - Twitter Access Token Secret that has been received after authorization.
consumerKey - Twitter App Consumer Key.
consumerSecret - Twitter App Consumer Secret.
String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessToken = "TWITTER ACCESS TOKEN"; String consumerKey = "TWITTER CONSUMER KEY"; String consumerSecret = "TWITTER CONSUMER SECRET"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,consumerKey,consumerSecret); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is " + social.getTwitterAccessToken()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; String consumerKey = "TWITTER CONSUMER KEY"; String consumerSecret = "TWITTER CONSUMER SECRET"; socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret,consumerKey,consumerSecret, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("twitter Access Token is" + social.GetTwitterAccessToken()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *accessToken = @"TWITTER ACCESS TOKEN"; NSString *accessTokenSecret = @"TWITTER ACCESS TOKEN SECRET"; NSString *consumerKey = @"TWITTER CONSUMER KEY"; NSString *consumerSecret = @"TWITTER CONSUMER SECRET"; Social *social = [socialService linkUserTwitterAccount:userName accessToken:accessToken accessTokenSecret:accessTokenSecret consumerKey:consumerKey consumerSecret:consumerSecret); NSLog(@"Username is %@",social.userName); NSLog(@"twitter Access Token is %@",social.twitterAccessToken); NSString *jsonResponse = [social toString];String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; String consumerKey = "TWITTER CONSUMER KEY"; String consumerSecret = "TWITTER CONSUMER SECRET"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,consumerKey,consumerSecret); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is " + social.getTwitterAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; String consumerKey = "TWITTER CONSUMER KEY"; String consumerSecret = "TWITTER CONSUMER SECRET"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,consumerKey,consumerSecret); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is" + social.getTwitterAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; String consumerKey = "TWITTER CONSUMER KEY"; String consumerSecret = "TWITTER CONSUMER SECRET"; socialService.LinkUserTwitterAccount(userName, accessToken, accessTokenSecret, consumerKey, consumerSecret, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", accessToken = "TWITTER ACCESS TOKEN", accessTokenSecret = "TWITTER ACCESS TOKEN SECRET", consumerKey = "TWITTER CONSUMER KEY", consumerSecret = "TWITTER CONSUMER SECRET", social ; socialService.linkUserTwitterAccountWithCredentials(userName, accessToken,accessTokenSecret,consumerKey,consumerSecret,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("twitter Access Token is " + social.twitterAccessToken) }, error: function(error) { } });String userName = "Nick"; String accessToken = "TWITTER ACCESS TOKEN"; String accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; String consumerKey = "TWITTER CONSUMER KEY"; String consumerSecret = "TWITTER CONSUMER SECRET"; Social social = socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret,consumerKey,consumerSecret); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("twitter Access Token is" + social.GetTwitterAccessToken()); String jsonResponse = social.ToString();$userName = "Nick"; $accessToken = "TWITTER ACCESS TOKEN"; $accessTokenSecret = "TWITTER ACCESS TOKEN SECRET"; $consumerKey = "TWITTER CONSUMER KEY"; $consumerSecret = "TWITTER CONSUMER SECRET"; $social = $socialService->linkUserTwitterAccount($userName, $accessToken,$accessTokenSecret,$consumerKey,$consumerSecret); Print_r("userName is" . $social->getUserName()); Print_r("twitter Access Token is" . $social->getTwitterAccessToken()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; twitter_access_token = "SD23435FF-m67CV2QqqizC6tKwS88R8K7YxTts54HPmUv4EfJC"; twitter_access__token_secret = "DEFThh67kJdQAOS3zSBqn8SqjkRpgw8oJJZKV9vg"; twitter_consumer_key = "7lFvyAd515aKrFWrtYU"; twitter_consumer_secret = "uFQ4QBr1fxcTthcB7bE5yvnaqDF567UJddRk8vNs"; social = social_service.link_user_twitter_account_with_token(user_name, twitter_access_token, twitter_access__token_secret, twitter_consumer_key, twitter_consumer_secret); puts "userName is #{social.user_name}"; puts "twitterAccessToken is #{social.twitter_access_token}"; puts "twitterAccessTokenSecret is #{social.twitter_access__token_secret}"; puts "twitterConsumerKey is #{social.twitter_consumer_key}"; puts "twitterConsumerSecret is #{social.twitter_consumer_secret}"; json_response = social.to_s();Coming SoonComing Soon
Updates the Twitter status of the specified user.
Required Parameters
userName - Name of the user for whom the status needs to be updated
status - Status that has to be updated.
String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateTwitterStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateTwitterStatus(userName, status, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *status = @"Nick is using the App42 API"; Social *social = [socialService updateTwitterStatus:userName status:status); NSLog(@"Username is %@",social.userName); NSLog(@"status is %@",social.status); NSString *jsonResponse = [social toString];String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateTwitterStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateTwitterStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateTwitterStatus(userName, status, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", status = "Nick is using the App42 API", social ; socialService.updateTwitterStatus(userName, status,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("status is " + social.status) }, error: function(error) { } });String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.UpdateTwitterStatus(userName, status); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString();$userName = "Nick"; $status = "Nick is using the App42 API"; $social = $socialService->updateTwitterStatus($userName, $status); Print_r("userName is" . $social->getUserName()); Print_r("status is" . $social->getStatus()); $jsonResponse = $social->toString();Coming Soonsocial = social_service.update_twitter_status(user_name, status); puts "userName is #{social.user_name}"; puts "status is #{social.status}"; puts "twitterConsumerKey is #{social.twitter_consumer_key}"; puts "twitterConsumerSecret is #{social.twitter_consumer_secret}"; puts "twitterAccessToken is #{social.twitter_access_token}"; puts "twitterAccessToken is #{social.twitter_access_token_secret}"; json_response = social.to_s();Coming SoonComing Soon
Links the User LinkedIn access credentials to the App User account.
Required Parameters
userName - Name of the user whose LinkedIn account to be linked.
accessToken - LinkedIn Access Token that has been received after authorization.
accessTokenSecret - LinkedIn Access Token Secret that has been received after authorization.
String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; Social social = socialService.linkUserLinkedInAccount(userName, accessToken,accessTokenSecret); System.out.println("userName is " + social.getUserName()); System.out.println("linkedIn Access Token is " + social.getLinkedinAccessToken()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; socialService.LinkUserLinkedInAccount(userName, accessToken,accessTokenSecret, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("linkedIn Access Token is" + social.GetLinkedinAccessToken()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *accessToken = @"LINKEDIN ACCESS TOKEN"; NSString *accessTokenSecret = @"LINKEDIN ACCESS TOKEN SECRET"; Social *social = [socialService linkUserLinkedInAccount:userName accessToken:accessToken accessTokenSecret:accessTokenSecret); NSLog(@"Username is %@",social.userName); NSLog(@"linkedIn Access Token is %@",social.linkedinAccessToken); NSString *jsonResponse = [social toString];String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; Social social = socialService.linkUserLinkedInAccount(userName, accessToken,accessTokenSecret); System.out.println("userName is " + social.getUserName()); System.out.println("linkedIn Access Token is " + social.getLinkedinAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; Social social = socialService.linkUserLinkedInAccount(userName, accessToken,accessTokenSecret); System.out.println("userName is " + social.getUserName()); System.out.println("linkedIn Access Token is" + social.getLinkedinAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; socialService.LinkUserLinkedInAccount(userName, accessToken,accessTokenSecret, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", accessToken = "LINKEDIN ACCESS TOKEN", accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET", social ; socialService.linkUserLinkedInAccount(userName, accessToken,accessTokenSecret,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("linkedIn Access Token is " + social.linkedinAccessToken) }, error: function(error) { } });String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; Social social = socialService.LinkUserLinkedInAccount(userName, accessToken,accessTokenSecret); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("linkedIn Access Token is" + social.GetLinkedinAccessToken()); String jsonResponse = social.ToString();$userName = "Nick"; $accessToken = "LINKEDIN ACCESS TOKEN"; $accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; $social = $socialService->linkUserLinkedInAccount($userName, $accessToken,$accessTokenSecret); Print_r("userName is" . $social->getUserName()); Print_r("linkedIn Access Token is" . $social->getLinkedinAccessToken()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; access_token = "7a7493f4-e3dd-4ab3-8014-efea40518d3d"; access_token_secret = "35c0745f-40d9-4889-9f37-6af7571e4249"; social = social_service.link_user_linkedIn_account(user_name, access_token, access_token_secret); puts "userName is #{social.user_name}"; puts "linkedinAccessToken is #{social.linkedin_access_token}"; puts "linkedinAccessTokenSecret is #{social.linkedin_access_token_secret}"; response = social.response(); json_response = social.to_s();Coming SoonComing Soon
Links the User LinkedIn access credentials to the App User account.
Required Parameters
userName - Name of the user whose LinkedIn account to be linked.
accessToken - LinkedIn Access Token that has been received after authorization.
accessTokenSecret - LinkedIn Access Token Secret that has been received after authorization.
apiKey - LinkedIn App API Key.
secretKey - LinkedIn App Secret Key.
String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessToken = "LINKEDIN ACCESS TOKEN"; String apiKey = "LINKEDIN API KEY"; String secretKey = "LINKEDIN SECRET KEY"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,apiKey,secretKey); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is " + social.getTwitterAccessToken()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; String apiKey = "LINKEDIN API KEY"; String secretKey = "LINKEDIN SECRET KEY"; socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret,apiKey,secretKey, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("twitter Access Token is" + social.GetTwitterAccessToken()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *accessToken = @"LINKEDIN ACCESS TOKEN"; NSString *accessTokenSecret = @"LINKEDIN ACCESS TOKEN SECRET"; NSString *apiKey = @"LINKEDIN API KEY"; NSString *secretKey = @"LINKEDIN SECRET KEY"; Social *social = [socialService linkUserTwitterAccount:userName accessToken:accessToken accessTokenSecret:accessTokenSecret apiKey:apiKey secretKey:secretKey); NSLog(@"Username is %@",social.userName); NSLog(@"twitter Access Token is %@",social.twitterAccessToken); NSString *jsonResponse = [social toString];String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; String apiKey = "LINKEDIN API KEY"; String secretKey = "LINKEDIN SECRET KEY"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,apiKey,secretKey); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is " + social.getTwitterAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; String apiKey = "LINKEDIN API KEY"; String secretKey = "LINKEDIN SECRET KEY"; Social social = socialService.linkUserTwitterAccount(userName, accessToken,accessTokenSecret,apiKey,secretKey); System.out.println("userName is " + social.getUserName()); System.out.println("twitter Access Token is" + social.getTwitterAccessToken()); String jsonResponse = social.toString();String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; String apiKey = "LINKEDIN API KEY"; String secretKey = "LINKEDIN SECRET KEY"; socialService.LinkUserTwitterAccount(userName, accessToken, accessTokenSecret, apiKey, secretKey, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", accessToken = "LINKEDIN ACCESS TOKEN", accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET", apiKey = "LINKEDIN API KEY", secretKey = "LINKEDIN SECRET KEY", social ; socialService.linkUserLinkedInAccountWithCredentials(userName, accessToken,accessTokenSecret,apiKey,secretKey,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("twitter Access Token is " + social.twitterAccessToken) }, error: function(error) { } });String userName = "Nick"; String accessToken = "LINKEDIN ACCESS TOKEN"; String accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; String apiKey = "LINKEDIN API KEY"; String secretKey = "LINKEDIN SECRET KEY"; Social social = socialService.LinkUserTwitterAccount(userName, accessToken,accessTokenSecret,apiKey,secretKey); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("twitter Access Token is" + social.GetTwitterAccessToken()); String jsonResponse = social.ToString();$userName = "Nick"; $accessToken = "LINKEDIN ACCESS TOKEN"; $accessTokenSecret = "LINKEDIN ACCESS TOKEN SECRET"; $apiKey = "LINKEDIN API KEY"; $secretKey = "LINKEDIN SECRET KEY"; $social = $socialService->linkUserTwitterAccount($userName, $accessToken,$accessTokenSecret,$apiKey,$secretKey); Print_r("userName is" . $social->getUserName()); Print_r("twitter Access Token is" . $social->getTwitterAccessToken()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; access_token = "7a7493f4-e3dd-4ab3-8014-efea40518d3d"; access_token_secret = "35c0745f-40d9-4889-9f37-6af7571e4249"; api_key = "bua6eo3pq5g3"; secret_key = "zBhKq5q7ruHcgH6l"; social = social_service.link_user_linkedIn_account_with_token(user_name, access_token, access_token_secret, api_key, secret_key); puts "userName is #{social.user_name}"; puts "linkedinAccessToken is #{social.linkedin_access_token}"; puts "linkedinAccessTokenSecret is #{social.linkedin_access_token_secret}"; puts "linkedinApiKey is #{social.linkedin_api_key}"; puts "linkedinSecretKey is #{social.linkedin_secret_key}"; response = social.response(); json_response = social.to_s();Coming SoonComing Soon
Updates the LinkedIn status of the specified user.
Required Parameters
userName - Name of the user for whom the status needs to be updated
status - Status that has to be updated.
String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateLinkedInStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateLinkedInStatus(userName, status, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *status = @"Nick is using the App42 API"; Social *social = [socialService updateLinkedInStatus:userName status:status); NSLog(@"Username is %@",social.userName); NSLog(@"status is %@",social.status); NSString *jsonResponse = [social toString];String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateLinkedInStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateLinkedInStatus(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateLinkedInStatus(userName, status, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", status = "Nick is using the App42 API", social ; socialService.updateLinkedInStatus(userName, status,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("status is " + social.status) }, error: function(error) { } });String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.UpdateLinkedInStatus(userName, status); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString();$userName = "Nick"; $status = "Nick is using the App42 API"; $social = $socialService->updateLinkedInStatus($userName, $status); Print_r("userName is" . $social->getUserName()); Print_r("status is" . $social->getStatus()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; status = "Reviewing Twitter APIs By Nick"; social = social_service.update_linkedIn_status(user_name, api_key, secret_key, access_token, access_token_secret); puts"userName is #{social.user_name}"; puts "linkedinApiKey is #{social.linkedin_api_key}"; puts "linkedinSecretKey is #{social.linkedin_secret_key}"; puts "linkedinAccessToken is #{social.linkedin_access_token}"; puts "linkedinAccessTokenSecret is #{social.linkedin_access_token_secret}"; response = social.response(); json_response = social.to_s();Coming SoonComing Soon
Updates the status for all linked social accounts of the specified user.
Required Parameters
userName - Name of the user for whom the status needs to be updated
status - Status that has to be updated.
String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateSocialStatusForAll(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();public class Callback : App42Callback { String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateSocialStatusForAll(userName, status, this); void App42Callback.OnException(App42Exception exception) { Console.WriteLine("Exception Message"); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *status = @"Nick is using the App42 API"; Social *social = [socialService updateSocialStatusForAll:userName status:status); NSLog(@"Username is %@",social.userName); NSLog(@"status is %@",social.status); NSString *jsonResponse = [social toString];String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateSocialStatusForAll(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("fb Access Token is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateSocialStatusForAll(userName, status); System.out.println("userName is " + social.getUserName()); System.out.println("status is " + social.getStatus()); String jsonResponse = social.toString();String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.updateSocialStatusForAll(userName, status, new UnityCallBack()); public class UnityCallBack : App42CallBack { public void OnSuccess(object response) { App42Log.Console("Success : " + response); } public void OnException(Exception e) { App42Log.Console("Exception : " + e); } }var userName = "Nick", status = "Nick is using the App42 API", social ; socialService.updateSocialStatusForAll(userName, status,{ success: function(object) { var response = JSON.parse(object); social = response.app42.response.social; console.log("userName is " + social.userName) console.log("status is " + social.status) }, error: function(error) { } });String userName = "Nick"; String status = "Nick is using the App42 API"; Social social = socialService.updateSocialStatusForAll(userName, status); Console.WriteLine("userName is" + social.GetUserName()); Console.WriteLine("status is" + social.GetStatus()); String jsonResponse = social.ToString();$userName = "Nick"; $status = "Nick is using the App42 API"; $social = $socialService->updateSocialStatusForAll($userName, $status); Print_r("userName is" . $social->getUserName()); Print_r("status is" . $social->getStatus()); $jsonResponse = $social->toString();Coming Soonuser_name = "Nick"; status = "Reviewing Twitter APIs By Nick"; social = social_service.update_social_status_for_all(user_name, status); puts "userName is #{social.user_name}"; puts "twitterConsumerKey is #{social.twitter_consumer_key}"; puts "twitterConsumerSecret is #{social.twitter_consumer_secret}"; puts "twitterAccessToken is #{social.twitter_access_token}"; puts "twitterAccessToken is #{social.twitter_access_token_secret}"; puts "userName is #{social.user_name}"; puts "facebookAppId is #{social.facebook_app_id}"; puts "facebookAppSecret is #{social.facebook_app_secret}"; puts "facebookAccessToken is #{social.facebook_access_token}"; puts "userName is #{social.user_name}"; puts "linkedinApiKey is #{social.linkedin_api_key}"; puts "linkedinSecretKey is #{social.linkedin_secret_key}"; puts "linkedinAccessToken is #{social.linkedin_access_token}"; puts "linkedinAccessTokenSecret is #{social.linkedin_access_token_secret}"; response = social.response(); json_response = social.to_s();Coming SoonComing Soon
The functions available under Social API can throw some exceptions in abnormal conditions. Example of the same has been given below. E.g. If App developer is linking the User Twitter account name who has not authorized the app to use his account, the function will throw the App42Exception (as shown below) with message as “Not Found” and the appErrorCode as “3800” and the details as “Twitter App Credentials (ConsumerKey / ConsumerSecret) does not exist”.
String userName = "Nick"; String status = "Nick is using the App42 API"; try { Social social = socialService.updateTwitterStatus(userName, status); } catch(App42Exception ex) { int appErrorCode = ex.getAppErrorCode(); int httpErrorCode = ex.getHttpErrorCode(); if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } String jsonText = ex.getMessage(); }public class Callback : App42Callback { String userName = "Nick"; String status = "Nick is using the App42 API"; socialService.UpdateTwitterStatus(userName, status, this); void App42Callback.OnException(App42Exception exception) { int appErrorCode = exception.GetAppErrorCode(); int httpErrorCode = exception.GetHttpErrorCode(); if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } String jsonText = exception.GetMessage(); } void App42Callback.OnSuccess(Object response) { Social social = (Social) response; String jsonResponse = social.ToString(); } }NSString *userName = @"Nick"; NSString *status = @"Nick is using the App42 API"; @try { Social *social = [socialService updateTwitterStatus:userName status:status]; } @catch(App42Exception *ex) { int appErrorCode = ex.appErrorCode; int httpErrorCode = ex.httpErrorCode; if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } NSString *jsonText = ex.reason; }String userName = "Nick"; String status = "Nick is using the App42 API"; try { Social social = socialService.updateTwitterStatus(userName, status); } catch(App42Exception ex) { int appErrorCode = ex.getAppErrorCode(); int httpErrorCode = ex.getHttpErrorCode(); if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } String jsonText = ex.getMessage(); }String userName = "Nick"; String status = "Nick is using the App42 API"; try { Social social = socialService.updateTwitterStatus(userName, status); } catch(App42Exception ex) { int appErrorCode = ex.getAppErrorCode(); int httpErrorCode = ex.getHttpErrorCode(); if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } String jsonText = ex.getMessage(); }Coming Soonvar userName = "Nick", appErrorCode , status = "Nick is using the App42 API"; socialService.updateTwitterStatus(userName, status,{ success: function(object) { }, error: function(error) { var socialObj = JSON.parse(error); appErrorCode = socialObj.app42Fault.appErrorCode; if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } } });String userName = "Nick"; String status = "Nick is using the App42 API"; try { Social social = socialService.UpdateTwitterStatus(userName, status); } catch(App42Exception ex) { int appErrorCode = ex.GetAppErrorCode(); int httpErrorCode = ex.GetHttpErrorCode(); if(appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if(appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if(appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if(appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if(appErrorCode == 1401) { // handle here for Client is not authorized } else if(appErrorCode == 1500) { // handle here for Internal Server Error } String jsonText = ex.GetMessage(); }$userName = "Nick"; $status = "Nick is using the App42 API"; try { $social = $socialService->updateTwitterStatus($userName, $status); } catch(App42Exception $ex) { $appErrorCode = $ex->getAppErrorCode(); $httpErrorCode = $ex->getHttpErrorCode(); if($appErrorCode == 3800) { // Handle here for Not Found (Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.) } else if($appErrorCode == 3801) { // Handle here for Bad Request (The request is Unauthorized with the provided credentials.) } else if($appErrorCode == 3802) { // Handle here for Not Found (Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.) } else if($appErrorCode == 3803) { // Handle here for Bad Request (The Twitter Access Credentials are invalid.) } else if($appErrorCode == 1401) { // handle here for Client is not authorized } else if($appErrorCode == 1500) { // handle here for Internal Server Error } $jsonText = $ex->getMessage(); }Coming SoonComing SoonComing SoonComing Soon
Functions in Session API might throw exceptions with following HTTP and Application Error Codes (along with their descriptions):
1400 - BAD REQUEST - The Request parameters are invalid
1401 - UNAUTHORIZED - Client is not authorized
1500 - INTERNAL SERVER ERROR - Internal Server Error. Please try again
3800 - NOT FOUND - Twitter App Credentials(ConsumerKey / ConsumerSecret) does not exist.
3801 - BAD REQUEST - The request is Unauthorized with the provided credentials.
3802 - NOT FOUND - Twitter User Access Credentials does not exist. Please use linkUserTwitterAccount API to link the User Twitter account.
3803 - BAD REQUEST - The Twitter Access Credentials are invalid." + <Exception Message>.
3804 - NOT FOUND - Facebook App Credentials(ConsumerKey / ConsumerSecret) does not exist.
3805 - BAD REQUEST - The Facebook Access Credentials are invalid.
3806 - NOT FOUND - Facebook User Access Credentials does not exist. Please use linkUserFacebookAccount API to link the User facebook account.
3807 - NOT FOUND - LinkedIn App Credentials(ApiKey / SecretKey) does not exist.
3808 - BAD REQUEST - The Access Credentials are invalid.
3809 - NOT FOUND - LinkedIn User Access Credentials does not exist. Please use linkUserLinkedInAccount API to link the User LinkedIn account.
3810 - NOT FOUND - Social App Credentials do not exist.
3811 - NOT FOUND - User Social Access Credentials do not exist. Please use linkUserXXXXXAccount API to link the User Social account.