How do I submit my Facebook graph api action for approval? - ruby-on-rails

I have a mobile phone app, supporting web site and a Facebook account
When certain actions are taken on my phone app I interact with my web server. My web server then posts some info to a page on MY Facebook account.
I chose to use the graph api to achieve the posts to my Facebook page but I can see no way of complying with Facebooks requirements for submission.
When I try to submit facebook states the following
No Aggregations created for this Action Type. Please create a
completed Aggregation populated with sample data before submitting for
review.
Firstly I have no idea what an aggregation is?
Then the docs state
Review your Action Type before submitting for approval. Make sure your
definition is complete and your app is testable end-to-end for
publishing actions of this Action Type
Which makes sense but how do I get my mobile app to Facebook staff so they can test?
I should add that all works fine in development mode

If you are trying to create an action via the Facebook Open Graph Beta, you should first look into the documentation here. There you will find all information on actions, objects and aggregations you can generate on the timeline.
Further you will have to go to the subsection Open Graph of your App Settings:
https://developers.facebook.com/apps/YOUR_APP_ID/opengraph and create your aggregations populated with sample data.
If you want to make a simple post though, then use the Graph API and POST a Post object to the feed connection of the User object. There are a lot of examples and tutorials on the web and a lot of questions on that matter here on stackoverflow.

Related

Facebook open graph run story with fitness.course

I am trying to use the Facebook iOS SDK (latest release at time of post) to post a run (fitness) Open Graph story. The Custom Stories tutorial explains how to setup basic story posts in my app (note: I am not using a custom story, I am using Facebook's run story); and I've made it that far.
The point where I'm stuck is with the fitness.course parameter. The course parameter documentation states the following:
A unique course URL is required for each run, bike, walk published for a user.
If I'm reading the documentation correctly, Facebook will not accept an array of location points. Instead, Facebook wants developers to upload course data to their own server and then pass in the URL of the associated course file on the server? Can someone confirm that's correct?
Is there a way to submit course information without hosting it on my own server (as this would be a lot more work than I planned)?

IOS twitter feed tutorial

I am currently building an app where they require all their users to be able to view their feeds only.
I looked at a lot of tutorials online which talk about the new api v1.1 of twitter and now authentication is required at all times.
I see a lot of examples and even successfully followed several of them like
http://www.appcoda.com/ios-programming-101-integrate-twitter-and-facebook-sharing-in-ios-6/
I even saw a tutorial posted on the twitter dev page.Following all of these focused on a few key elements
Using ACAccount to retrieve the account settings of the current user
Using the SLRequest to encapsulate the HTTP request made to the twitter api
Retrieving the data in JSON format, parsing it and presenting it to the user
Well my question is, I do not want user specific feeds. It's like a company updates their twitter regularly, users using the app should get feeds regarding the company. So I was wondering if there was a way, the app provides some default or hard coded authentication information ?
Is there some sort of tutorial, library or anything out there to help me move in the correct direction ?
Thank You for your time and help.
Your going to want to implement the following API call to get that information:
https://dev.twitter.com/docs/api/1.1/get/statuses/user_timeline
Once your application is authorized you can make a call to,
https://dev.twitter.com/docs/api/1.1/get/statuses/MorleyGaelsGAA.json
That should give you the information you're looking for.

Retrieve facebook data in backend service

I'm currently working on an app (iOS 6) where the user will be signing in using their facebook account.
In regards to this I have a few questions:
a) Since the app asks the user for permission to access cetain data (like: basic profile info, friend list, access to post to wall etc), I assume that the app based on it's app id will be somehow authenticated to access this information as long as the user doesn't restrict access through their facebook account.
b) will it be possible for example via a service application to authenticate with the same app id as the mobile app, and hence be able to collect data from the facebook users who authenticated with the app?
The purpose of my question is, that I would like do some analysis on the users using the iphone app, but I don't want the app to first download the information from facebook, and then pass it on to my service for analysis.
If the above is possible, could anyone please guide me in the direction of what it is that I need to do? Perhaps links to tutorials that describes this setup, og simply tell me the right facebook terminology that I'm looking for to achive this.
Thanks in advance!
It's a bit late and you may have already picked a service. I have been using Parse.com
(tutorial site). They're very good. They have SDKs and sample code for many platforms a RESTful service for others.
They have recently been acquired by FaceBook, and already have strong links to Facebook's SDK.

How to have a FB application create a personalized post to a user

I've read over some of the developer material and have not seen a way to have an application send facebook users personalized wall posts. For example, FB users who likes "Mustangs" could receive a post from my application when there is news specifcally about Mustangs. However, FB users who didn't select Mustangs would not receive the post. Is there a way to do this on the FB platform for applications?
FYI - The only success I have had is sending a post to a user which appears to have been sent from the user as if the user is posting to themselves. Only upon close inspection can one find the text "via application xyz" next to the post time.
Thanks for taking the time to read and respond.
Yes, you can do this with any of the frameworks. See https://developers.facebook.com/docs/sdks/ Also study up on the Graph API (pay attention to the from attribute of a feed item, testing it out using the graph API Exporer: https://developers.facebook.com/tools/explorer

Simple Facebook API usage in Rails 3

I want to connect my app to Facebook in order to post on the user's wall. I want the user to click to post a message on his Wall, the pop-up of the js SDK should appear, he would login and authorize and get redirected to the home page as the pop-up disappears.
I was trying the fb_graph gem but had some hard troubles and I want to know: Is there a simpler way to do it?
Note that I don't want to make the user able to login in my app with Facebook, just post to his wall.
As Facebook does not offer any Ruby API, you will have to choose between using the JS SDK or implementing a Facebook share link.
If you only want to post in the user's wall, I recommend the second option because of ease and nature. You can customize the content of the post this way.
If you decide to go the JS way, you will have to:
Create a FB app.
Include FB SDK into your page.
Initialize the SDK with your app settings.
Ask for permissions to the user in order to post into her wall.
Assign a button to a function where you check for login. If she's already logged, show a window to post into the wall (FB popup or your own form, as the iframe dialogs are only available inside Facebook pages).
There is another alternative to step 5 by using Graph API and an access token, but it's a little bit more complicated and I don't recommend it if you are new to FB development.
I think, essentially, it's all or nothing when it comes to Facebook authentication. You're asking for permission to take over the user's identity and post on their Facebook wall - there will definitely be some kind of authentication and user approval. It's not a totally trivial process.
I'm sure you've looked already, but if you are OK using any of the social plugins that Facebook offers (http://developers.facebook.com/docs/plugins/), that might be an easier option to achieve what you're looking for.
If not, you'll have to gain a user's permission and post on the wall the way Facebook describes on their site. There's another gem, called Koala (https://github.com/arsduo/koala) that is pretty easy to use as well, but you can also take a look through the fb_graph documentation and see which pieces of code are applicable to your needs and duplicate that functionality.
The best source of information is on Facebook's site (http://developers.facebook.com/docs/reference/api/), where they describe the process in detail:
You can publish to the Facebook graph by issuing HTTP POST requests to the appropriate connection URLs, using an user access token or an app access token (for Open Graph Pages).
and
Most write operations require extended permissions for the active user. See the authentication guide for details on how you can request extended permissions from the user during the authentication step.
The first time I looked at this stuff I was totally overwhelmed, but play around with it and it will make a lot more sense.
I just saw #manuelpedrera 's answer, and that's a good step-by-step guide. Short answer: there's no shortcut.
Koala is a Facebook library for Ruby, supporting the Graph API (including the batch requests and photo uploads), the REST API, realtime updates, test users, and OAuth validation.
Take a look at Koala gem: https://github.com/arsduo/koala

Resources