I want to use the data of http://data.seattle.gov/api/views/kzjm-xkqj/rows.json with SODA API.
In the API DOCS, i found it using a language ruby, python, coffeescript, cURL.
And it use require() function.
But I don't know how exactly the require() function is work.
I found about the require. Isn't it something like the loader of a jscript file???
I think first line is maybe... using this way
require 'https://soda.demo.socrata.com/resource/earthquakes.json?source=uw'
request = require 'request'
options = uri: 'https://soda.demo.socrata.com/resource/earthquakes.json?
$$app_token=APP_TOKEN&recall_id=94'
request options, (err, response, body) -> console.log body
I change the coffeescript into javascript, but i still don't know. var options, request;
request = require('request');
options = {uri: 'https://data.seattle.gov/Public-Safety/Seattle-Real-Time-Fire-911-
Calls/kzjm-xkqj/rows.json?$$app_token=APP_TOKEN&recall_id=94' };
request(options, function(err, response, body) { return console.log(body); } );
And.. Sorry for my poor English.