Similar to foursquarevenues, except it uses koa-request instead of request to access foursquares venue API.
Install using npm:
npm install koa-foursquare --save
Basic usage:
'use strict';
var koa = require('koa');
var config = require('./config');
var foursquare = require('koa-foursquare')(config.fs.clientID, config.fs.clientSecret);
var app = koa();
require('koa-qs')(app, 'first');
app.use(function *(next) {
let ll = (this.query.ll !== undefined) ? this.query : '39.3968238,-74.5447961';
let params = {
ll: ll,
limit: 15,
venuePhotos: 1,
categoryId: '4d4b7105d754a06374d81259',
};
this.type = 'json';
this.body = yield foursquare.exploreVenues(params);
});
app.listen(3000);
Returns a hierarchical list of categories applied to venues.
No parameters.
Returns a list of venues near the current location, optionally matching a search term.
Param | Type | Description |
---|---|---|
params | Object |
url parameters |
Parameter options found here under Parameters section.
Returns a list of recommended venues near the current location.
Param | Type | Description |
---|---|---|
params | Object |
url parameters |
Parameter options found here under Parameters section.
Gives details about a venue, including location, mayorship, tags, tips, specials, and category.
Param | Type | Description |
---|---|---|
params | Object |
url parameters |
Parameter options found here under Parameters section.
Please submit all issues and pull requests to the koa-foursquare repository!
If you have any problem or suggestion please open an issue here.