Reputation: 1397
I've seen other topics like this: launch facebook app from other app and tried some of the URIs listed there, but I can't figure out how to start the facebook chat with a specific friend.
Is there an official page that describes the IntentUriHandler and all the allowed URIs with their params?
Thanks, Lorenzo
Upvotes: 5
Views: 7375
Reputation: 10342
found it here: https://developers.facebook.com/docs/messenger-platform/discovery/m-me-links#format
http://m.me/{#user_id}
you can use this URI to open messaging with a friend with known id.
You can start the intent like below
startActivity(new Intent(android.action.VIEW, "http://m.me/{#user_id}"));
Upvotes: 10
Reputation: 12512
startActivity(new Intent(Intent.ACTION_VIEW,
Uri.parse("fb://messaging/" + userId)));
Upvotes: 7