getPage function only throws video data - rfacebook

I have been using the getPage function from the Rfacebook package for a long time to retrieve the post ids from facebook pages, but lately, it only throws the data for videos. Anyone knows why this is happening?

Related

How to convert '\x1F�\b\x00\x00\x00\x00\x00\x02�U��j�0\x10E��\n' data gotten from google userinfo api to an object using nodejs

I am implementing google OAuth and i am recieving the access_token and and id_token quite alright.
After sending a request to google's userinfo endpoint as shown in this image enter image description here
I am recieving a success from goole with this data type on the response data
enter image description here
A few months ago when i implemented this on a seperat project i got back an object and not i am getting this, whatevery it is.
Can anyone point me where i can research or convert this to an object using javascript?
I am expecting an Object and i have tried using the global Buffer method available on Nodejs and i keep getting enter image description here

Subscription API Error 400 Unable to reach callback URL

I've made subscriptions with Instagram before with their public API and it has worked fine, as of recently I stopped getting calls from them at my callback for the subscription. As of now I deleted all of my subscriptions and tried to make a new one, but keep getting an Error 400 Unable to reach callback URL my.url.com. My callback URL is public and I've tried other sites that are public and I keep getting the same error. I've submitted an error report to Instagram, but have not heard back in a couple days. Any ideas on what to do next or is anyone else experiencing this issue?

Twitter API get Parameters after Oauth

I'm using Allauth for Twitter, works like a charm.
I have never worked with Scopes, so my question is, is there any support to get for example the twitter user stream?
Or anyone got any ideas how to get the request working?
I'm struggeling with the twitter api, it seems way more complicated then facebook or foursquare or any other api i have come across.
with facebook it's like this
return requests.get("https://graph.facebook.com/v2.3/%s&access_token=%s" % (path, access_token)).json()
Now if i send
requests.get('https://api.twitter.com/1.1/statuses/home_timeline.json&oauth_consumer_key=' +oauth_con+ 'oauth_signature_method="HMAC-SHA1"&oauth_nonce="'+now+'"&oauth_token="'+twitter+'"&oauth_timestamp="'+now+'"&oauth_version=1.1"')
I get a either a 400 error or a 404 error depending on .json? or json&.
According to the doc you have to have "" around every parameter. Didn't help.

Scraping youtube mix playlist id for a video

So here is what I am trying to do:
The app in question that this problem is regarding is here: https://github.com/viperfx/ng-juketube, to give everyone some context. So I am loading a youtube video in the background using the youtube Iframe API giving it a youtube video id. That works well. Next, I want to find out the playlist ID of the youtube mix's that appear sometimes on the sidebar.
Current solution:
I am using nodejs in the backend to scrape the youtube video page, and then look in the sidebar for the string 'Youtube Mix'. When I am running my server locally this works well. However when I am running the app from heroku I do not get the same results (as in a mix does not show up) because I am assuming the youtube server and the IP address I have are affecting youtube mix from showing up.
So my question is how can I obtain the youtube mix playlist id using the client (browser) rather than the server?
I have tried things like trying to load the youtube page as an iframe - does not work. iframes only allowed for /embed*
So here is how I solved this issue.
Using a service called http://www.corsproxy.com/ I was able to scrape youtube and get the playlist id using client side code. Here is a snippet from my code showing the solution:
$.get('http://www.corsproxy.com/www.youtube.com/watch?v='+newVal.videoId,function(response) {
var doc = new DOMParser().parseFromString(response, 'text/html');
$scope.mixId = doc.querySelector('.related-playlist').getAttribute('href').split('list=')[1];
$scope.$apply();
});

How to provide information in the html link for Facebook open graph api call of "property name" when posting trying to post an action

I am trying to create an html object dynamically with the necessary header information depending on the query string in the link I provide to Facebook. I am hoping that Facebook open graph will call this html link as I provided. However it seems that query string info are not getting passed to my server. Do anyone know how to make this work or what is the more appropriate way to do this. BTW, I am writing my code in Node.js.
To get more info about Facebook open graph api, look here, https://developers.facebook.com/docs/beta/opengraph/actions/.
For example, the link I am trying to pass to Facebook is, "http://xxx-url.com/getFacebookObject?objectId=&description=first dynamic post", so I sent a request with the link as, "https://graph.facebook.com/me/app-name:action-name?object=http://xxx-url.com/getFacebookObject?objectId=&description=first dynamic post". However, when I check the log on the server, I don't see anything in the query string.
Instead of using the query string, you can embed the data in the URL:
http://some-domain.com/getFacebookObject/id/description
Then, depending on what node.js packages you're using, extract the data from the request:
// expess.js style
app.get("/getFacebookObject/:id/:description", function(req, res) {
var id = req.params.id,
desc = req.params.description;
// your code...
});
(See http://expressjs.com/guide.html.)
Sorry, Facebook will strip off all query string information from the URL when they launch your site in the iframe. If it was a page tab app, then you could add it to the app_data query string parameters which in turn gets passed to your iframe's page tab app via the app_data part of the signed_request parameter.

Resources