https://github.com/citygram/citygram-services
Web content transformation proxies for open data API's
https://github.com/citygram/citygram-services
Last synced: 4 months ago
JSON representation
Web content transformation proxies for open data API's
- Host: GitHub
- URL: https://github.com/citygram/citygram-services
- Owner: citygram
- Created: 2014-07-26T19:00:29.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2022-12-14T02:12:23.000Z (about 2 years ago)
- Last Synced: 2024-08-02T14:12:31.797Z (7 months ago)
- Language: Ruby
- Homepage: https://citygram-services.herokuapp.com/
- Size: 290 KB
- Stars: 16
- Watchers: 4
- Forks: 37
- Open Issues: 31
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# spy-glass (aka Citygram connector)
__Spyglass__ is a [Code for America](https://github.com/codeforamerica) project by the [Charlotte Team](http://team-charlotte.tumblr.com/) for the [2014 fellowship](http://www.codeforamerica.org/geeks/our-geeks/2014-fellows/).
### Why are we doing this?
### What does this do now?
This is a registry of micro ETL endpoints. What does that even mean? Good question. Citygram has good [overview documentation](https://github.com/codeforamerica/citygram/wiki/Getting-Started-with-Citygram).
But here's a specific example of the information flow:
[CKAN code enforcement](http://www.civicdata.com/dataset/lexington-code-enforcement-complaints) -> [Citygram connector](https://github.com/citygram/citygram-services/blob/master/lib/spy_glass/registry/lexington-code-enforcement-complaints.rb) -> [Citygram](https://www.citygram.org/lexington)
This particular Citygram connector pulls the [last seven days worth](https://github.com/citygram/citygram-services/blob/master/lib/spy_glass/registry/lexington-code-enforcement-complaints.rb#L7) of code complaints and [formats them as geojson](https://citygram-services.herokuapp.com/) that Citygram polls many times a day.
It creates a unique key that [is a composite](https://github.com/citygram/citygram-services/blob/master/lib/spy_glass/registry/lexington-code-enforcement-complaints.rb#L25) of the CaseNo and Status columns. When this key changes, Citygram will create a new event that will be sent to subscribers. Since the key is a composite, an event is created whenever a status changes for a given case.
### What will this do in the future?
TODO
### Who is this made by?
- [Danny Whalen](https://github.com/invisiblefunnel)
- [Erik Schwartz](https://github.com/eeeschwartz)
- [Jim Van Fleet](https://github.com/bigfleet)### Setup
* [Install Ruby](https://github.com/codeforamerica/howto/blob/master/Ruby.md)
```
git clone https://github.com/citygram/citygram-services.git
cd citygram-services
cp .env.sample .env
gem install bundler
bundle install
bundle exec rackup
```