tobilg / facebook-events-by-location-core Goto Github PK
View Code? Open in Web Editor NEW[DEPRECATED] Search Facebook events by location and proximity.
License: MIT License
[DEPRECATED] Search Facebook events by location and proximity.
License: MIT License
Everything is fine, i changed anything and start getting this error
Request failed with status code 400
at createError (.../node_modules/axios/lib/core/createError.js:16:15)
at settle (.../node_modules/axios/lib/core/settle.js:18:12)
at IncomingMessage.handleStreamEnd (.../node_modules/axios/lib/adapters/http.js:192:11)
at emitNone (events.js:111:20)
at IncomingMessage.emit (events.js:208:7)
at endReadableNT (_stream_readable.js:1055:12)
at _combinedTickCallback (internal/process/next_tick.js:138:11)
at process._tickCallback (internal/process/next_tick.js:180:9)
i think could be some return that has changed in the graph api
Since a few days ago, no events is being found in any coordinate. As you can see, in this request:
{ data:
{ events: [],
metadata: { venues: 168, venuesWithEvents: 0, events: 0 }
}
}
I'm not sure if this lib needs an update or if the Facebook politics has changed. There is no error, no exceptions. Only empty results.
Has anyone noticed?
This should be a queryOptions key.
Hi,
I need to fetch some events containing a keyword (eg. cars) inside a radius.
(i'd get events all over the world)
Google discover can do this quite smartly, but i still haven't seen another solution.
Is this - api heavy - hack the ONLY way to accomplish this still?
I'm guessing this is exactly as i need.
Hi.
I was checking the following venue: ProgresjaMusicZone?fields=events
When you look at the returned output you can see:
"paging": { "cursors": { "before": "OTM4NzAzMjI2MjY1NTM2", "after": "MTI0ODM3NzE0NTI1NjY0MwZDZD" }, "next": "https://graph.facebook.com/v2.9/142450042462794/events?access_token=XXX&pretty=0&limit=25&after=MTI0ODM3NzE0NTI1NjY0MwZDZD"
I think the current version of the script doesn't support paging of the events (it does support paging of the venues thou). I think it can be handled in two ways - by adding paging support to update the events section of the venue in case it is pages or more simple way (yet less elegant) -> add a .limit(500) while querying for the events.
Best regards,
DP.
Would be cool to stop rate limiting by caching the requests to /event/id in an SQLite db.
Hey, first of all thanks for keeping this awesome piece of software updated!!
I upgraded to the newest version today (0.3.0), but it's throwing some errors when I try to do a request
Warning: a promise was rejected with a non-error: [object Object] W20170413-18:18:15.252(2)? (STDERR) at /Users/projects/Projects/Personal/node_modules/facebook-events-by-location-core/lib/eventSearch.js:325:17 W20170413-18:18:15.252(2)? (STDERR) at processImmediate [as _immediateCallback] (timers.js:396:17) W20170413-18:18:15.253(2)? (STDERR) From previous event: W20170413-18:18:15.253(2)? (STDERR) at [object Object].EventSearch.search (/Users/projects/Projects/Personal/node_modules/facebook-events-by-location-core/lib/eventSearch.js:131:12) W20170413-18:18:15.253(2)? (STDERR) at [object Object]._handler (imports/server/publish.js:30:8) W20170413-18:18:15.253(2)? (STDERR) at maybeAuditArgumentChecks (packages/ddp-server/livedata_server.js:1737:12) W20170413-18:18:15.253(2)? (STDERR) at [object Object]._.extend._runHandler (packages/ddp-server/livedata_server.js:1035:17) W20170413-18:18:15.262(2)? (STDERR) at [object Object]._.extend._startSubscription (packages/ddp-server/livedata_server.js:853:9) W20170413-18:18:15.263(2)? (STDERR) at [object Object]._.extend.protocol_handlers.sub (packages/ddp-server/livedata_server.js:625:12) W20170413-18:18:15.263(2)? (STDERR) at packages/ddp-server/livedata_server.js:559:43 W20170413-18:18:15.380(2)? (STDERR) {"message":{"name":"StatusCodeError","statusCode":400,"message":"400 - \"{\\\"error\\\":{\\\"message\\\":\\\"The action attempted has been deemed abusive or is otherwise disallow ed\\\",\\\"type\\\":\\\"OAuthException\\\",\\\"code\\\":368,\\\"error_subcode\\\":1489009,\\\"is_transient\\\":false,\\\"error_user_title\\\":\\\"Too many place searches\\\",\\\"error_user_msg\\\":\\\"You searched for too many places in a short amount of time. You will be allowed to search for more places after some time has passed.\\\",\\\"fbtrace_id\\\":\\\"FIj9mmbDdYI\\\"}}\"","error":"{\"error\":{\"message\":\"The action attempted has been deemed abusive or is otherwise disallowed\",\"type\":\"OAuthException\",\"code\":368,\"error_subcode\":1489009,\"is_transient\":false,\"error_user_title\":\"Too many place searches\",\"error_use r_msg\":\"You searched for too many places in a short amount of time. You will be allowed to search for more places after some time has passed.\",\"fbtrace_id\":\"FIj9mmbDdYI\"}}","options":{"uri":"https://graph.fa cebook.com/v2.7/search?type=place&q=¢er=52.370987900020594,4.897470250725746&distance=1000&limit=100&fields=id&access_token=EAAZAEZC5u8GuoBAJR2kevJwwWIXw2ZBY1lTdoK7XIqE4BLm61w6PUvoF5fhCzu35ZAZBQoogtN0QmBNjXdxQG oUZBpsv5kKNhLyvvlknaYQira3fpJGDpyfibOmHxTU32ScVJGtmJqZBsfgnnpOJ7Q63r29zZCkjsgZCCjyrTgNdgEAZDZD&after=NDk5","method":"GET","simple":true,"resolveWithFullResponse":false,"transform2xxOnly":false},"response":{"statusC ode":400,"body":"{\"error\":{\"message\":\"The action attempted has been deemed abusive or is otherwise disallowed\",\"type\":\"OAuthException\",\"code\":368,\"error_subcode\":1489009,\"is_transient\":false,\"error _user_title\":\"Too many place searches\",\"error_user_msg\":\"You searched for too many places in a short amount of time. You will be allowed to search for more places after some time has passed.\",\"fbtrace_id\": \"FIj9mmbDdYI\"}}","headers":{"www-authenticate":"OAuth \"Facebook Platform\" \"invalid_request\" \"The action attempted has been deemed abusive or is otherwise disallowed\"","access-control-allow-origin":"*","prag ma":"no-cache","cache-control":"no-store","x-fb-rev":"2955911","content-type":"text/javascript; charset=UTF-8","x-fb-trace-id":"FIj9mmbDdYI","facebook-api-version":"v2.7","expires":"Sat, 01 Jan 2000 00:00:00 GMT"," vary":"Accept-Encoding","x-fb-debug":"KG8CEACPNSrtXex5Bj5wG37UAGfLD2bJJQw1Oyn0/pPD6t0JpL7iNVi6JnYyWa82PKPejDA1hikGahGUHweBXw==","date":"Thu, 13 Apr 2017 16:18:14 GMT","connection":"close"},"request":{"uri":{"protoc ol":"https:","slashes":true,"auth":null,"host":"graph.facebook.com","port":443,"hostname":"graph.facebook.com","hash":null,"search":"?type=place&q=¢er=52.370987900020594,4.897470250725746&distance=1000&limit=10 0&fields=id&access_token=EAAZAEZC5u8GuoBAJR2kevJwwWIXw2ZBY1lTdoK7XIqE4BLm61w6PUvoF5fhCzu35ZAZBQoogtN0QmBNjXdxQGoUZBpsv5kKNhLyvvlknaYQira3fpJGDpyfibOmHxTU32ScVJGtmJqZBsfgnnpOJ7Q63r29zZCkjsgZCCjyrTgNdgEAZDZD&after=ND k5","query":"type=place&q=¢er=52.370987900020594,4.897470250725746&distance=1000&limit=100&fields=id&access_token=EAAZAEZC5u8GuoBAJR2kevJwwWIXw2ZBY1lTdoK7XIqE4BLm61w6PUvoF5fhCzu35ZAZBQoogtN0QmBNjXdxQGoUZBpsv5kK NhLyvvlknaYQira3fpJGDpyfibOmHxTU32ScVJGtmJqZBsfgnnpOJ7Q63r29zZCkjsgZCCjyrTgNdgEAZDZD&after=NDk5","pathname":"/v2.7/search","path":"/v2.7/search?type=place&q=¢er=52.370987900020594,4.897470250725746&distance=100 0&limit=100&fields=id&access_token=EAAZAEZC5u8GuoBAJR2kevJwwWIXw2ZBY1lTdoK7XIqE4BLm61w6PUvoF5fhCzu35ZAZBQoogtN0QmBNjXdxQGoUZBpsv5kKNhLyvvlknaYQira3fpJGDpyfibOmHxTU32ScVJGtmJqZBsfgnnpOJ7Q63r29zZCkjsgZCCjyrTgNdgEAZDZ D&after=NDk5","href":"https://graph.facebook.com/v2.7/search?type=place&q=¢er=52.370987900020594,4.897470250725746&distance=1000&limit=100&fields=id&access_token=EAAZAEZC5u8GuoBAJR2kevJwwWIXw2ZBY1lTdoK7XIqE4BLm 61w6PUvoF5fhCzu35ZAZBQoogtN0QmBNjXdxQGoUZBpsv5kKNhLyvvlknaYQira3fpJGDpyfibOmHxTU32ScVJGtmJqZBsfgnnpOJ7Q63r29zZCkjsgZCCjyrTgNdgEAZDZD&after=NDk5"},"method":"GET","headers":{}}}},"code":-1}
"You searched
for too many places in a short amount of time. You will be allowed to search for more places after some time has passed."
The wierd thing is that I get this after making one single request.
I'm having an issue with events that have been canceled. I'm unable to reliably detect which events are canceled and would appreciate if you would add the is_canceled to the fields that are retrieved for an event (such a field is documented in https://developers.facebook.com/docs/graph-api/reference/event/).
I am currently only getting 100 places, no matter what my radius is. Is facebook limiting the number of results?
I have updated to the latest version.
I am running my service on Heroku:
I'd love the ability to specify a limit of the amount of events that I get back from the search. Is this something I could propose as a pull request?
Hi !
Concerning the last version of the API Graph v2.12, is_draft
will require an admin token :https://developers.facebook.com/docs/graph-api/changelog/version2.12#gapi-90
Consequently, the is_draft
variable should be removed otherwise it will provoke the following error :
(#200) Permissions error
I'm getting this error with the following syntax. Anyone know if I've messed something up?
es.search({
lat: 59.831834,
lng: 17.635795,
accessToken: //accessToken
})
.then((events) => {
console.log(JSON.stringify(events));
})
.catch((err) => {
console.error(JSON.stringify(err));
});
UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 2): TypeError: Converting circular structure to JSON
I find two issues when trying to run
In the self.allowedSorts array there is no wrongSortOption
so below condition is throwing error
if (queryOptions.sort && self.allowedSorts.indexOf(queryOptions.sort) === -1) {
1)"error{"message":"An invalid sort option was passed: 'wrongSortOption'","code":3}"
and also queryOptions.longitude I am getting a null value for longitude.
2)The error is {"message":"Please specify the lat and lng parameters!","code":1}
This api works just fine for me when testing on my local machine, however it fails when I run it on a remote heroku server
Error msg from logs: {"message":{"name":"StatusCodeError","statusCode":500,"message":"500 - \"{\\\"error\\\":{\\\"message\\\":\\\"An unknown error has occurred.\\\",\\\"type\\\":\\\"OAuthException\\\",\\\"code\\\":1,\\\"fbtrace_id\\\":\\\"BHzu820eh4d\\\"}}
I checked my app access token here https://developers.facebook.com/tools/debug/accesstoken/ and it's valid. Appreciate any insight
I can't get this module to return events and I can't get Facebook's graph API to return either. As I see Facebook has closed events listing down or limited it severely.
Is there anybody that can confirm this?
I wanted to make a simple event listing page where you could see local events in your city on a map without having to use Facebook directly.
'www-authenticate': 'OAuth "Facebook Platform" "invalid_request" "Syntax error \\"Expected \\")\\", got end of string\\" at character 493: id,name,about,emails,cover.fields(id,source),picture.type(large),category,category_list.fields(name),location{city,country,latitude,longitude,state,street,zip},events.fields(id,type,name,cover.fields(id,source),picture.type(large),description,start_time,end_time,category,ticket_uri,ticketing_privacy_uri,ticketing_terms_uri,place.fields(id,name,location{city,country,latitude,longitude,state,street,zip}),is_canceled,timezone,updated_time).since(2018-04-06T18:00:00).until(2018-05-06T07:00:00"'
Hi there
I,m very intersted on this code, can you explain how to integrate it in a php file and how to retrieve the json output ? Or can I hire you for to do that? Thank's.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.