I'm trying to understand actions and objects on facebook and im completely blown away by how spotify publishes actions with that format. How the heck do you customize the layout of a user's action like that?
As far as im concern, with facebook's lovely documentation, all you can do is publish actions on a single line : (user A) -- (action) -- on -- (object) followed by a title and description.
How do you design html/css layout of a user's actions? Link? Attachment? I'm guessing you have to do some sort of "magic" on the description? Thanks!
Facebook's open Graph Tutorial does a decent job of explaining this but with the various options you have to scroll for a while to make it to the grouping part. In short, the individual actions you're familiar with combine together via "aggregations" which can be set to show a number of formats from lists to grids.
To set one of these up you must configure your Actions and Objects via the open graph settings first and then manually create an aggregation and a few defaults to fill in for preview purposes.
This will show up when a user authenticates your app for open graph and becomes customized to them as they start actually using said actions.
Now as for the play button option, that's something I assume is unique to their integration.
Documents at https://developers.facebook.com/docs/beta/opengraph/tutorial/
Related
Is it possible to set starting options in facebook messenger for pages like example bellow:
example of expected result
I figured that similar could be achieved by using messenger BOT with 'start button', multiple BOT replies with 'quick reply' buttons and passing conversation to live chat in required cases.
The problem with this is that after user clicks 'get started' button BOT publish text replay 'Get started' which is not desired.
I wonder if there is an build-in setting to achieve this? If not, how would one solve it?
EDIT: It seems to me, it is not possible to build something like that neither with facebook quick reply neither with templates/buttons
EDIT 2: I also tried doing this in Facebook's page settings with no result. It seems it doesn't have anything to do with Facebook's 'quick replies'
First of all there is no way to set those options from facebook platform itself. Those questions are generated by facebook to give user a head start to a conversation and those are generated based on the type of page you are created. To see the option go to
Your Page's Settings-> Messaging -> General Settings
It is ideal that you will configure the 'Get Started' to initiate conversation with your bot and then show users a bunch of options using various templates like quick replies, carousel, list etc. By this way you have full control over your templates and expected answers.
But then again if you want to use those generated options from facebook then you can look for those option's text in the delivered json to your configured web hook. Here is a sample json:
{"object":"page","entry":[{"id":"","time":1519980744192,"messaging":[{"sender":{"id":""},"recipient":{"id":""},"timestamp":1519980743903,"message":{"mid":"","seq":1,"text":"Could you give me a call? I'd like to speak to someone."}}]}]}
Look at the 'text' attribute. The text is from after clicking one of those options. But again this is not ideal as the options can get changed anytime by facebook's algorithm.
My suggestion is to use 'Get Started' button and then send a list to the user.
The screenshot you posted shows a features that is currently being tested for Pages, so it is not available to every Page. There is no built-in way to do this, other than sending quick replies in response to the get started postback, messaging_optins or messaging_referrals events.
You can create a persistent menu to achieve this.
Here are few video tutorials I created to help you with Facebook integration and sending rich messages in facebook messenger through Dialogflow.
https://www.youtube.com/watch?v=fJ4HoYxoKl8
https://www.youtube.com/watch?v=JC9Y-AmcL6A
I am looking to generate a list of URLS or FB ID's for a set of existing Facebook Pages. Ultimately the initial query I am looking to run is simple: Find all NEW facebook pages created in City XYZ.
The term NEW, is open to interpretation. It could mean "Created this month" Or newer relative others in a set (these details are not important at the moment) . Also, "Pages" refers to fan pages (not user profiles).
I have identified 3 possible approaches. Both of which I am hoping to get some input on. Regarding feasibility and process.
Option 1) Somehow leverage Facebook's Graph API and develop some time of web application to generate a list of all Pages, then filter by city, then filter by date created.
Option 2 (Best Case)) Write or generate a custom Graph Search URL with embedded search criteria and leverage FBs existing search feature to get results. A great example of this approach is used by the tool searchisback.com. Only this tool is used to do advanced searches on People, but I need advanced searches on Pages.
Option 3) Locate a tool that already does this that I can use.
I again hoping to get some input and possible some direction/recommendations.
I should also mention that I actually know very little about Facebook APIs and Facebook Development. My position right now is of some who knows what they want to do, but no idea how to do it.
Option 1: Not possible, you can only search for Pages by name, the Graph Search is not available with the API. Those are all the options: https://developers.facebook.com/docs/graph-api/using-graph-api#search
Option 2: See answer to option 1.
Option 3: There are tools that list Pages, but they all have to add them manually. So there is not really a tool that does what you want to achieve.
In short: What you want to do is not possible.
Our app uses the Google Analytics Rest API. We'd like to get the number of page views generated by different links to the site.
For example, one link to our site might be:
http://oursite.com?linknum=12345
and another might be:
http://oursite.com?linknum=23456
We'd like to track the number of page views by all visitors who click on each link, so we need a way to filter by parameter.
So far, we just get the number of page views for all visitors without any filters:
curl 'https://www.googleapis.com/analytics/v3/data/ga?ids=ga:(our id) &metrics=ga:pageviews&start-date=2014-4-26&end-date=2011-12-08&access_token=(our access token)'
The best way to learn the API is to use the query explorer at
http://ga-dev-tools.appspot.com/explorer/
For your analysis, add dimension=ga:pagePath and sort=ga:pageviews.
In addition, you could ask for pages which match a filter expression.
For example filter=ga:pagePath=#linknum to only include pages with linknum.
Okay, I'm not sure if I'm doing something wrong in Open Graph, but here goes. I've got 3 stories in my Open Graph, which are three different actions linked to one object type.
Make A Pledge To -> Cause
Create -> Cause
Log Expense For -> Cause
Here is what the three look like in the sample section (I'm pretty sure they look like that in the actual timeline as well).
Make a pledge to a cause:
Create a cause:
Log an expense for a cause:
Is there a reason why the "make a pledge" layout is different? Both objects are actual objects on my website, parsed via providing the url to Facebook's sample data tool. I've set the caption in the "make a pledge" story to the same as the "create" story, but the description and cause target that appears in the "create" story doesn't appear in the "make a pledge" story.
Could someone help me on this? Is there a way I can make the "make a pledge" story look like the "create" story? Or is this something Facebook decides?
Facebook uses both formats – and which gets chosen is not up to you or any settings you make/picture formats you use, but Facebook themselves decides that. It might even be one or the other for different users viewing one and the same story.
They do that to test out the formats, and see which one is more “successful”, meaning which one generates more user interaction.
(Can’t point you to a source for that, but is has been confirmed by Facebook employees in the Facebook Developers Group.)
Facebook checks if an image is available on the referenced site/link. If it finds it, it shows a slightly different format. Your second two actions didn't have an image in the reference.
I have an app with blog records per each user. I have add share button to my app, to give ability to post interesting blog records to users time line or to send to other user. But in default it takes image and text for share as it wants and not always correctly. So I find out that it can be dirven by meta tags (using for example "image" property to set image for share dialog). That's work ok on main page (where I'd like to make ability share with whole application), but on pages of blog records I cann`t customize it. meta tag should be in , but all info (short text and image of blog post) I get later in body, so I can insert it. How can I manage with this? Or may be there is another way to share content with?
What blog engine are you using? If it is a wordpress - try this plugin http://wordpress.org/extend/plugins/facebook-share-new/ from offician facebook docs http://developers.facebook.com/docs/. Otherwise I'd suggest to find a facebook plugin for your blog engine using google and install it.