REST API interface for Conservation Hack ElasticSearch Server
See: http://conservationhackathon.org/
This API is built using Hapi.js (Node.js)
and ElasticSearch (with esta).
If you are new to either of these we have beginner tutorials to get you started:
- What is an API? https://github.com/docdis/learn-api-design
- Hapi.js: https://github.com/nelsonic/learn-hapi
- ElasticSearch: https://github.com/docdis/learn-elasticsearch
- esta: https://github.com/dwyl/esta (ultra-simple ElasticSearch node.js driver)
If you have any ideas, suggestions, feature requests or spot an issue/bug that needs to be fixed, please submit an issue: https://github.com/ConsHack/conshack-api/issues
- People - the people who are using the application
- Sessions - all session information for the person using the plugin (when they logged in, what browser, if they logged out etc.)
- Articles - Journal Articles and their meta data
- Searches - list of searches that were performed and where they were run
-
API access to Predicts to get list of articles which have already been reviewed (with data entered);
-
Auto-complete Search Article Titles
-
Dashboard of all articles which have been reviewed & recent searches
-
Realtime interaction between all people using the plugin to enable (google-docs style) collaboration and eliminate duplicated effort!
The API server uses requires ElasticSearch
You will need to have a running instance of ElasticSearch on your localhost to run the API locally.
There a couple of ways to get ElasticSearch running on your machine, please see: https://github.com/docdis/learn-elasticsearch
we have included a Vagrantfile to simplify booting ElasticSearch on any Operating System.
Read more about how Vagrant will change your life (as a developer...): https://github.com/docdis/learn-vagrant
Alternatively you can simply add an environment variable and connect to our ElasticSearch instance on Heroku:
export SEARCHBOX_SSL_URL=AskUsForTheElasticSearchURI--WeCantPublish
ElasticSearch Index (export these environment variables)
export ES_INDEX=conshack
Once you have ElasticSearch up and running, boot the hapi.js (node.js) API Server with the following terminal command:
npm install && npm run dev
The API is hosted on Heroku: https://conshack-api.herokuapp.com/
If you want to build on the API you will need to:
git remote add heroku [email protected]:conshack-api.git
Ask us for heroku access to the app so you can push changes!