https://github.com/jgravois/koop-walmart
fetch walmart georss and display it in ArcGIS Online
https://github.com/jgravois/koop-walmart
koop-provider koopjs
Last synced: 2 months ago
JSON representation
fetch walmart georss and display it in ArcGIS Online
- Host: GitHub
- URL: https://github.com/jgravois/koop-walmart
- Owner: jgravois
- License: other
- Created: 2017-08-31T23:02:54.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2017-09-01T17:38:33.000Z (almost 8 years ago)
- Last Synced: 2025-03-25T10:03:27.212Z (3 months ago)
- Topics: koop-provider, koopjs
- Language: JavaScript
- Size: 79.1 KB
- Stars: 2
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://travis-ci.org/koopjs/koop-provider-sample) [](https://greenkeeper.io/)
# Koop Walmart Provider
This provider was created to support the Hurricane Harvey relief effort by helping folks identify Walmart stores that have been closed. The data source for this provider is Walmart's [GeoRSS feed](https://walmart.alertlink.com/rss/stores.rss).
> View it [live](https://h8w2a8ip0c.execute-api.us-east-1.amazonaws.com/latest/walmart/FeatureServer/0/query?where=status=%27Closed%27).
If you want to write your own provider, simply fork this repository or copy the contents. Full documentation is provided [here](https://koopjs.github.io/docs/specs/provider/).
## Files
| File | | Description |
| --- | --- | --- |
| `index.js` | Mandatory | Configures provider for usage by Koop |
| `model.js` | Mandatory | Translates remote API to GeoJSON |
| `routes.js` | Optional | Specifies additional routes to be handled by this provider |
| `controller.js` | Optional | Handles additional routes specified in `routes.js` |
| `server.js` | Optional | Reference implementation for the provider |
| `test/model-test.js` | Optional | tests the `getData` function on the model |
| `test/fixtures/input.json` | Optional | a sample of the raw input from the 3rd party API |
| `config/default.json` | Optional | used for advanced configuration, usually API keys. |## Test it out
Run server:
- `npm install`
- `DEPLOY=dev npm start`Example API Query:
- `curl localhost:8080/sample/FeatureServer/0/query?returnCountOnly=true`Tests:
- `npm test`## With Docker
- `docker build -t koop-walmart .`
- `docker run -it -p 8080:8080 koop-walmart`## Publish to npm
- run `npm init` and update the fields
- Choose a name like `koop-provider-foo`
- run `npm publish`