Social sharing options

Social sharing options
0.0 0


In my game, I implemented a icon for invite facebook friends. I used sdkbox, with the method: sdkbox::PluginFacebook::inviteFriends(app_link_url, link_image). Works perfect, the problem is that Facebook team has announced that the AppLinks ( is deprecated and it will be supported until February 5, 2018. So, I should to re-evaluate what method of social sharing I should to use in my App.

Talking with @yinjimmy , he propused me integrate Facebook Invites manually: but It sounds like hard, I was very happy to use sdkbox::PluginFacebook::inviteFriends because it was very easy to implement.

I read that sdkbox has a special plugin for social sharing: but it includes only Facebook, Twitter and SMS.

I’m not interested sharing with Twitter and SMS. And If I wanted to use Facebook Share, I implemented sdkbox facebook in my App.

What’s about Whatsapp? SDKBox is thinking to include it? Anyone has implemented it manually? It’s possible? And what’s about Facebook Invites? SDKBox will update for it?

  1. get token from

  2. create link host

curl \
-F access_token="APP_ACCESS_TOKEN" \
-F name="iOS App Link Object Example" \
-F ios=' [
      "url" : "sharesample://story/1234",
      "app_store_id" : 12345,
      "app_name" : "ShareSample",
  ]' \
-F web=' {
    "should_fallback" : false,

and u will get a link, such as:

  1. queary link
curl -G \
-d access_token="APP_ACCESS_TOKEN" \
-d fields=canonical_url \
-d pretty=true
   "canonical_url": "",
   "id": "611591085677879"


curl -G \
-d access_token="APP_ACCESS_TOKEN" \
-d fields=app_links \
-d ids= \
-d pretty=true
  1. update link host
curl \
-F access_token="APP_ACCESS_TOKEN" \
-F name="FB App Link Object Example" \
-F ios=' [
      "url" : "sharesample://story/1234",
      "app_store_id" : 12345,
      "app_name" : "ShareSample",
  ]' \
-F web=' {
    "should_fallback" : false,


But if App Links Hosting is deprecated. Is convenient to use it?
Facebook will provides other method for invite friends, without app_link?
sdkbox provides facebook invites but it requiere app link.


Someone tried to generate App Link URL manually with cURL?
I downloaded it from: but I’ve some errors when I try to create link host.

Tried too, host my own file, but I can’t.
I created app_link.html and put this code:

    <meta property="al:ios:url" content="couchinapp://invite_from_fb?referral=123456789" />
    <meta property="al:ios:app_store_id" content="123456789" />
    <meta property="al:ios:app_name" content="Couchin'" />
    <meta property="al:android:url" content="couchinapp://invite_from_fb?referral=123456789" />
    <meta property="al:android:app_name" content="Couchin" />
    <meta property="al:android:package" content="com.mycompany.couchin" />
    <meta property="al:web:url" content="" />
Couchin App Link

As Facebook mentioned here:

And I changed the data.
I upload the html in my hosting and I called the URL in sdkbox::PluginFacebook::inviteFriends
But when I try to invite some people, this is the msg:


Missing App Link URL.

All this would be easier if Facebook had not put your URL generator offline:


what errors ?



C:\Tranthor\curl-7.56.1\I386>curl \ -F access_token="APP_TOKEN" \ -F name="APP_NAME" \ -F ios=' [{ "url" : "APP_NAME://", "app_name" : "APP_NAME", }, ]' \ -F web=' { "should_fallback" : false, }'
{"error":{"message":"(#100) Param ios must be a JSON-encoded string.","type":"OAuthException","code":100,"fbtrace_id":"Ea7+fQ7It2D"}}curl: (6) Could not resolve host: \
curl: (6) Could not resolve host: \
curl: (6) Could not resolve host: \
curl: (3) [globbing] bad range specification in column 2
curl: (6) Could not resolve host: url
curl: (3) Bad URL, colon is first character
curl: (1) Protocol "APP_NAME" not supported or disabled in libcurl
curl: (6) Could not resolve host: app_name
curl: (3) Bad URL, colon is first character
curl: (6) Could not resolve host: APP_NAME,
curl: (3) [globbing] unmatched close brace/bracket in column 1
curl: (3) [globbing] unmatched close brace/bracket in column 1
curl: (6) Could not resolve host: \
curl: (3) [globbing] unmatched brace in column 1
curl: (6) Could not resolve host: should_fallback
curl: (3) Bad URL, colon is first character
curl: (6) Could not resolve host: false,
curl: (3) [globbing] unmatched close brace/bracket in column 1


I replaced:
APP_TOKEN: With the app token from here:
APP_NAME: With the name of the app.

My OS is Windows10 (64).
I downloaded curl from:


command is invalid.
put it in bat file ? I cant try the command in windows system, cause I dont have a windows system.


Ok finally I solved the problem including native sharing in iOS and Android.
I think is better because I have options to share in SMS, Facebook, Whatsapp, Email, etc. Is very global.

How to include it in iOS:

How to include it in Android:
Put this in (or make a method) with this code:

Intent sharingIntent = new Intent(Intent.ACTION_SEND);
sharingIntent.putExtra(Intent.EXTRA_TEXT, "Share text");
Cocos2dxActivity.getContext().startActivity(Intent.createChooser(sharingIntent,"Share title"));

@yinjimmy evaluate it for sdkbox, would be fantastic if all this could be done in c++, without touching code in Java and Objetive-C.


Invite facebook friend not working

we also have a share plugin for system share.

sdkbox::SocialShareInfo info;
info.text = "#sdkbox( - the cure for sdk fatigue ";
info.title = "sdkbox";
//info.image = "path/to/image" = "";

// the follow property will be ignored in nativeShare
//info.showDialog = false;
//info.platform = sdkbox::SocialPlatform::Platform_Select;


But your issue here is about the fb app link.