Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Package name & Class Name of facebook app

Just a small confusion I want to ask while making a facebook app to implement share feature in my android appenter image description here

Unique app Identifier used to open your app

  1. Package Name: Is it that unique identifier that I have written while creating the new facebook app at their developer console ? or Is it the package name of my android app ?

The Main Activity you want Facebook to launch

  1. Class Name: I have added a facebook share button in every fragment(class), so which class is the Main Activity that it want facebook to launch ? Or is it the main activity of my android app?
like image 964
Vivek Warde Avatar asked Jul 19 '14 08:07

Vivek Warde


3 Answers

See this screenshot from Facebook's getting started documentation.

like image 143
Horatio Avatar answered Sep 18 '22 13:09

Horatio


add Package name of your application in Package Name Field add Activity Name in Class Name Field. Like You have com.example.facebook as your package name . In that package you have many Activity but you want to use Facebook Code in FbExampleActivity then FbExampleActivity is your Class Name.

like image 42
Mr X Avatar answered Sep 20 '22 13:09

Mr X


I haven't tried yet, but it seems that these fields for deep link only. It is useful when you want Facebook to show ads linking to your app. In case users click on an ad:

  • if your app was installed on user's device (based on the package name you defined here), it will send an intent to your activity (base on class name you defined here). This activity will handle the intent.

  • Otherwise, it will go to your application on google play (again, base on the package name you define here)

deep link: https://developers.facebook.com/docs/app-ads/deep-linking

App Links on Android: https://developers.facebook.com/docs/applinks/android

In conclusion, if you are not going to integrate app links, just put your package and main activity here.

like image 26
thanhbinh84 Avatar answered Sep 18 '22 13:09

thanhbinh84