Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Facebook Open Graph without a browser

For a middleware system with internet (which works inside a set-top box) I want to develop a primitive Facebook interface where users can type their user-names and password, showing their latest notification, messages and other casual stuff on the TV screen by using the recent Facebook Graph API.

This middleware program uses Java ME to run programs (such as this simple facebook app) and it can connect to internet however it doesn't have a real web browser. Without browser it can connect to any url to retrieve the JSON response however I am not sure how to achieve authentication without a real browser.

Under this circumstances, is it possible Facebook authentication? If you think so, what approach would you suggest ?

Thanks

like image 790
Hellnar Avatar asked May 03 '10 19:05

Hellnar


People also ask

How do I use Open Graph on Facebook?

What does Open Graph protocol do? Through the Open Graph protocol, you can tell Facebook how your shared content should be displayed on Facebook. This protocol tells Facebook which title, URL, image, and description of your blog post/page should be used when your content is shared on Facebook.

Why OG image is not working?

Right-click on your page and click on View Page Source. Then check if you're able to find the og:image tag added in the source code. If the og:image tag is not found, that means Rank Math is either disabled or not able to print your social tags.

Is og URL necessary?

You do not ever need og:url . Instead, use the existing rel=canonical standard to link to your canonical page URL. Facebook's own documentation states they support this [1].


1 Answers

Facebook provides trusted partners with a private Authorization API to get an OAuth 2 token from a username / password.

A more complicated approach would be doing something similar to how Netflix enrolls a device:

  1. device calls server to obtain a Code
  2. device shows code on screen and directs user to go to URL on server and enter Code
  3. server redirects user to Facebook and obtains OAuth token, user told to go back to device
  4. device calls server with Code and obtains OAuth token
  5. device can now make calls directly on behalf of user
like image 138
Dick Hardt Avatar answered Sep 17 '22 15:09

Dick Hardt