Using the Facebook Android sdk, is it possible to retrieve a listing of Events? - facebook

I took a look at the api and it appears that I can only pull the events associated with a user. What I would like to do is pull events that may or may not be associated with a user. Is this possible?

You can search for Events via the /search?type=event&q={your_query} endpoint. Have a look at the docs at https://developers.facebook.com/docs/graph-api/using-graph-api/v2.1#searchtypes

Related

Why Facebook Graph API doesn't list all public events for a page?

There're lots of events for this venue:
https://www.facebook.com/pg/ClubRoxyPrague/events/
However when requesting with Graph API we only get a few. Here's link to Graph API explorer:
https://developers.facebook.com/tools/explorer?method=GET&path=ClubRoxyPrague%2Fevents&version=v2.12
Until recently this worked well for us. Maybe it's data access restrictions Facebook announced few days ago: https://newsroom.fb.com/news/2018/04/restricting-data-access/
Why the API returns only some events? Is there any way to fetch all public events hosted by a certain page?
Due to the breaking data access changes you mentioned, it already wasn't possible to access events directly (also see: Unsupported get request in get Facebook event).
It seems like your specific issue is a logical consequence of that decision (although the /{page-id}/events was still available up to today, I personally already found it pretty strange that events were still accessible indirectly).

Facebook API 'Events Popular In Your Network'

I am trying to utilise the Facebook Graph API to access the section 'Events Popular In Your Network'. However, I cannot seem to find an endpoint that gives access to these. Is there a possible way to get hold of this information? The section is accessed by clicking 'Events' and scrolling down.
Unfortunately no, there is not an specific endpoint for that.
If you want, you might be able to build something similar using events (events docs). Getting friends events, checking attendees (attending endpoint) and ranking them (popular in this case means more friends attending to the event).
I hope it helps.

Legal ways to get all recent posts of multiple Facebook pages as soon as possible?

I want to get all the newest posts from 10 (or let's say 1xxxxx) Facebook pages (which I do not own) as soon as they there published without manual refreshing all 10 pages every second. What legal tools should I use?
Use the Facebook Graph API. It allows you to get your application notified via callback HTTP posts whenever certain updates occur. You'll find the API documentation for this feature here:
https://developers.facebook.com/docs/graph-api/real-time-updates/v2.2
Based on your usage, you may have to pay for that service.

Can you create an event using the Facebook API?

I would like to be able to use the Facebook APIs to create events for facebook pages. From this link it seems to not be allowed: https://developers.facebook.com/docs/graph-api/reference/v2.0/event
Am I missing something? It seems like this was available in the past and I have no idea why it would not be available now.
Creating events via the API was allowed in v1.0, but has been removed in the newer Graph API v2.0. Facebook has removed several permission permissions from various end-points, including events, to prevent abuse.

Using the Facebook Graph API why is it possible to read a list of videos posted to an event but not a list of photos?

As far as I can make out from reading the Facebook Graph API documentation for Events -
http://developers.facebook.com/docs/reference/api/event/
...it is possible to get a list (array) of videos that have been added to an event but NOT a list of photos. Why am I not able to get photos belonging to an event? Am I missing something here?
thanks
It's because the current implementation of the Graph API does not have the connection from Page Event to photos. The only "image" connection is the picture connection. This is probably because they haven't got around to expanding their API to handle all cases. The videoes connection is definitely out of the ordinary. It may have been placed in there early on in the development of the Graph API to hand one specific facebook partner's needs.
I can get a list of Photos by issuing a /{eventid}/photos request for an event that was created by my app, some event graph api calls are dependent on the fact that your app created the event. i.e. you can't edit an event that wasn't created with your app. I think for the photos request, you need read_stream, user_events, and maybe friend_events permission..