Facebook Instant Games - Playing Games with a Group of Players - facebook

Some questions for sharing and playing together with friends:
1) How can I play a game with a Facebook group?
2) Can I post an update or an invite to a group?
3) I want to have a button in the game to share the game. Where I then can select to share on timeline, friends timeline, group, ... (like the normale share dialog).
But when I use shareAsync() I don't get the option to select where to share to.
How can I share the game to other people's timeline, chats and groups?
4) Can I directly create a context with multiple players?
Is there a way to call createAsync() with more then one playerId?
From an existing chat with multiple users I can already get a context with multiple players. But is it possible to create a multiplayer session from inside the game?
Thank you!

1) If you share a post to a Facebook group you will be able to play there. The context type will be POST. We are working on bringing custom updates to Facebook posts. (I assume you mean Facebook group rather than Messenger group chat here).
2) We are working on bringing updateAsync updates to Facebook posts, although the updates will be posted to posts rather than the entire group. (Again, I assume you mean Facebook group rather than Messenger group chat here).
3) shareAsync is implemented differently depending on which surface you're playing on. If you're playing on Facebook.com, shareAsync will give you a regular Facebook share dialog. If you're playing in Messenger shareAsync is more targeted to the Messenger experience.
4) Instant Games does not currently support creating a context with multiple participants using createAsync. You can use chooseAsync along with the minSize and maxSize parameters to encourage players to choose an existing Messenger thread.

Related

How to implement content Geo-fencing in facebook messenger bot?

I want to share videos via subscription messages with my messenger bot. However the content I am willing to share is restrictive to certain countries only.
When posting a video, geo-fencing is straight forward and facebook allows you to select the countries the post will be visible at.
However when sharing content via messenger this gets tricky. Any workaround besides asking from the user to share their location?
You could restrict countries of Facebook Apps in the developer console, Settings -> Advanced tab.

Use Facebook Messenger bot to interact with Shared Days

I have just started looking into Facebook Messenger's bots and am thinking of making one.
Recently, Facebook Messenger has introduced the idea of Shared Days, which are basically Snapchat-like stories that people can post to and share for their friends to see.
Does Facebook's APIs allow one to use a bot to create stories (post pictures to shared days)?
I am looking at the APIs and cannot find anyway to do this. I want to create a bot that can post stories on Facebook Messenger's Shared Days. I want the bot to post stories periodically on its own story that only its subscribers can see, if that's possible.
Any reference to some documentation, and perhaps a simple toy example would be helpful.
Currently, you cannot post to a user's or page's "My Day" using the Send API or any other apis.
That doesn't cut you off entirely from using them in your bot, however. Facebook is making it easier to share content from bots to your friends or my day with each iteration of messenger.
When your bot puts an image file into chat as an upload, your user can click the share arrow next to the image, or at the bottom left when fullscreened, and share it to their day, their friends, group chats, etc.
IMO, This is a very powerful viral tool that no one is using yet.

Using bots on Facebook groups

I am new to Facebook messengers bots. I want to know how can I add a bot to a group (more than 1 people in the conversation). I read about the API in here
and I tried some bots like Mealou and getbirdiebot on my messanger. But in order to access them, I had to click on their link, which trigers an event for oppening a private conversation between me and the bot. How can I add a bot to a group then?
Is it even possible?
P.S: In this link facebook uses A.I to read the text and process it in the groups. I want to do something like that.

When I click a facebook share button, I should share multiple links with multiple images as one post on facebook timeline

Is there a possibility of sharing on facebook timeline, multiple links with multiple images which are nicely formatted as one post at the click of a share button?
The idea is that, I currently maintain an e-commerce site and I want any customer to be able to share all the products in an order unto their timeline as a single post with links back to the site.
Currently, using the facebook open-graph api I can only share a link and an image on the click of a facebook share which means I would need to have seperate share button for each products but from the user experience perspective this would not be efficient as it would be better to only have one button to carry out the post and all the products in the order are all shared as one post on the customer facebook timeline.
Unfortunately it's not possible. The whole idea behind open graph is interacting with objects one by one. You can combine whole list of products into one object and share it, but it will still have only one link and image representing that object.

Securely reward a Facebook wall post

We're developing a social game on Facebook from which players can share posts on their wall. Now we want to reward them for that with in-game currency.
Of course, this should not provide an opening for hackers to generate infinite funds, but since the posting happens entirely client side, they could so by repeatedly telling our server "I have posted", though they haven't. Unless we add countermeasures.
Can our server check with Facebook whether a post was really made?
Can we attach data to a wallpost, like a cryptographic signature generated by our server?
If not, we need to limit the currency a hacker can acquire with some kind of flood control. Tips there?
We're developing a social game on Facebook from which players can share posts on their wall. Now we want to reward them for that with in-game currency.
I think that’d be a violoation of Facebook Platform Policies:
IV. Application Integration Points
You must not incentivize users to use (or gate content behind the use of) Facebook social channels, or imply that an incentive is directly tied to the use of our channels.
The callback you get after using the Feed Dialog will return to you a post_id. You can store that post_id in your database along with a flag indicating that you have already rewarded the user for that specific post. This way you can "reward" users once per post by testing the existence of that post_id + flag in your database.