Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Updated README

  • Loading branch information...
commit d7a908522718e1773d358873ec03bb4bed77cd81 1 parent 60734a2
@gsf gsf authored
Showing with 25 additions and 27 deletions.
  1. +25 −27 README.md
View
52 README.md
@@ -1,48 +1,46 @@
node-elasticsearch
-============
+==================
-This is a module around the REST API for [Elastic Search](http://www.elasticsearch.org/) built for NodeJS.
+This is a Node.js module for the [elasticsearch](http://www.elasticsearch.org/) REST API.
-Details
-=============
+Usage
+=====
-This works with node 0.4.x and with 0.2.x. I needed it for both and so wrote an [http compatability layer](http://github.com/ncb000gt/node-http_compat).
+```js
+var elasticsearch = require('elasticsearch');
+var es = elasticsearch({index: 'kitteh'});
+es.query({query: {field: {field1: 'hai'}}}, function(err, results) {
+ console.log(results);
+});
+```
-Usage
-=============
- var lib = require('elasticsearch'), sys = require('sys'); //replace sys with util if you're on node 0.4.x
- lib.createClient(function(client) {
- client.query({query: {field: {field1: 'hai'}}}, function(err, results) {
- console.log(sys.inspect(results, true, 10));
- });
- });
+API
+===
+TBD
-API
-==============
-*Will go here when I'm ready to post it.*
+Testing
+=======
+
+```
+npm install
+npm test
+```
Requirements
-=============
+============
-* NodeJS
-* Elastic Search
-* nodeunit (for testing)
+* Node.js
+* elasticsearch
* The need for search
License
-=============
+=======
MIT
-
-
-Trademarks?
-============
-
-Node.js™ is an official trademark of Joyent. This module is not formally related to or endorsed by the official Joyent Node.js open source or commercial project
Please sign in to comment.
Something went wrong with that request. Please try again.