Skip to content

Commit e1f2204

Browse files
committed
bump npm version and update README
1 parent e66193e commit e1f2204

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

README.md

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
node-red-node-cf-cloudant
22
=========================
3-
A [Node-RED](http://nodered.org) node to `insert`, `update` and `delete` documents
3+
A pair of [Node-RED](http://nodered.org) nodes to work with documents
44
in a [Cloudant](http://cloudant.com) database that is integrated with
55
[IBM Bluemix](http://bluemix.net).
66

@@ -13,13 +13,20 @@ npm install node-red-node-cf-cloudant
1313

1414
Usage
1515
-----
16-
Allows basic access to a [Cloudant](http://cloudant.com) database. Currently
17-
it only have one node that supports `insert`, `update` and `delete`
18-
operations.
16+
Allows basic access to a [Cloudant](http://cloudant.com) database to
17+
`insert`, `update`, `delete` and `search` for documents.
1918

2019
To **insert** a new document into the database you have the option to store
2120
the entire `msg` object or just the `msg.payload`. If the input value is not
2221
in JSON format, it will be transformed before being stored.
2322

2423
For **update** and **delete**, you must pass the `_id` and the `_rev`as part
2524
of the input `msg` object.
25+
26+
To **search** for a document you have two options: get a document directly by
27+
its `_id` or use an existing [search index](https://cloudant.com/for-developers/search/)
28+
from the database. For both cases, the query should be passed in the
29+
`msg.payload` input object as a string.
30+
31+
When getting documents by id, the `payload` will be the desired `_id` value.
32+
For `search indexes`, the query should follow the format `indexName:value`.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name" : "node-red-node-cf-cloudant",
3-
"version" : "0.2.0",
3+
"version" : "0.2.1",
44
"description" : "A Node-RED node to write to a Cloudant database on Bluemix",
55
"dependencies" : {
66
"nano" : "5.10.0"

0 commit comments

Comments
 (0)