Links
😛

Facebook

Facebook Analytics is the data and tools you need to track your brand's performance on the world's most popular social network. Tracking Facebook analytics helps you understand your past performance and tweak your future strategy.
To configure your app to work with Facebook, you need to do the following steps:
  1. 1.
    Create a Facebook account (If you didn't have it before)
  2. 2.
    ​Create a Facebook app.
  3. 3.
    ​Set up the iOS app.
  4. 4.
    ​Set up the Android app.

How to create a Facebook app?

Go to My Apps page, and click "Create App" button (top right corner)
Select app type as "None"
Fill out the app name and contact email
The first part is done, now we need to setup iOS and/or Android app(s)

How to set up iOS?

Go to "Settings -> Basic" page
Scroll down and click "Add platform", select "iOS" and click "Next"
Enter Bundle ID. It can be found on the Natively platform: Publish -> iOS Build -> Bundle Identifier
Enter iPhone/iPad Store ID. It can be found on the Natively platform: Publish -> iOS Build -> App Store App Id (This value is the same for iPhone and iPad apps if you have iPad support enabled)
Click "Save changes"
At the next step, we need to go to the Advanced settings, copy "Client token" and App ID
Paste this value to the Natively platform. Also, do not forget to fill Permission description for iOS.
Click Save, and rebuild your iOS app after all changes!
Important, the App ID and Client Token are the same for iOS and Android. if you have both platforms you can enter it once. But you need to rebuild each app separately.
​

How to set up Android?

Go to "Settings -> Basic" page
Scroll down and click "Add platform", select "Android" and click "Next"
Select Google Play in a list of stores (Natively officially supports only Google Play, you can select other options on your own risk)
At that point, you need to enter a key hash. We will explain in next step how to get it.
To get a key hash value you need:
  1. 1.
    Make sure you've already uploaded a first build to Google Play developer console.
  2. 2.
    Go to Google Play console and navigate to App Page -> Setup -> App Integrity
  3. 3.
    Scroll down and copy SHA-1 certificate fingerprint value
  1. 5.
    Enter your SHA-1 value and click "Convert Hex to Base64"
  2. 6.
    Copy Base64 value
Paste it in the "Key hashes" field
After that, on the same page, you need to enter your Package Name and Class Name
  1. 1.
    Package Name: Publish -> iOS Build -> Bundle Identifier
  2. 2.
    Class Name: "com.base.app.Core.JasonViewActivity"
  3. 3.
    Click "Save changes"
At the next step, we need to go to the Advanced settings, copy "Client token" and App ID
Paste this value to the Natively platform.
Important, the App ID and Client Token are the same for iOS and Android. if you have both platforms you can enter it once. But you need to rebuild each app separately.
Click Save, and rebuild your Android app after all changes!