Node -Webkit Facebook integration

I am creating a desktop news reader using node -webkit

https://github.com/rogerwang/node-webkit

which is basically a server and a client at the same time. My problem with the facebook API is this: I want the user of my application to log in and present to them their current posts on the wall and more. In addition, I have some news from other sources that should be similar to him / share with this user.

The whole application is a one-page JS (more precisely: coffeescript) thing with several components, hard forwarding is not possible.

Every API login feature shown in the API does not seem to be suitable for my type of application. What is the best way to connect to facebook without hard redirects and without your own redirect URI?

+4
source share
1 answer

If you are developing a standalone client application, and not a website, I would not use my Javascript API, because it assumes that it runs on some website.

You might be lucky with the unofficial Node.js API , since node -webkit allows you to make calls to any Node.js library from the DOM.

If you still do not succeed, try logging in to the user by submitting the login page to the <iframe> . You can then make HTTP calls through AJAX or through Node.js HTTP APIs to directly access Facebook’s internal APIs.

+3
source

Source: https://habr.com/ru/post/1469364/


All Articles