API Documentation


JSON Store


JSON store APIs



Miscellaneous


Describe all the JSON store related APIs



Information
Returns some basic information on the database server

This service is like a 'ping' service, checking of the database instance is properly running

Input
Method URI Description
GET /$darwino-jstore
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

User
Returns information on the current user.
Input
Method URI Description
GET /$darwino-jstore/user
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Database


Database related APIs



Database Collection
Returns the list of the available databases
Input
Method URI Description
GET /$darwino-jstore/databases
Name Type Optional Description
details
boolean Yes When true, it returns some database details (label, instances...), else it only returns the database names
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Database Meta Data
Returns the meta data for a specific database
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}
Name Type Optional Description
database_id
string No Database Id
Name Type Optional Description
sessiondata
boolean Yes Returns extra information relative to the current database and user session (ftsearch, user...)
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Documents Count
Return the number of documents in a database
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/documentscount
Name Type Optional Description
database_id
string No Database ID
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Delete All Documents
Delete all the documents in a database
Input
Method URI Description
DELETE /$darwino-jstore/databases/{database_id}/documents
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
options
int Yes Delete options. See constants in Database.java
before
number Yes Only delete the document before the date encoded as a long
Output
Code Description
200
OK. Indicates that the request was received successfully.

Read Document By Id
Read a document using its internal id
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/documents/{id}
Name Type Optional Description
database_id
string No Database ID
id
int No Document ID as an integer value
Output
Content Type: application/jsonData Schema...

Document Exists By Id
Check is a document exists using its internal id
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/documentexists/{id}
Name Type Optional Description
database_id
string No Database ID
id
int No Document ID as an integer value
Output
Content Type: application/jsonData Schema...

Update Full Text Index
Update the database full text index on demand
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/updateftindex
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
async
boolean Yes Indicates if the update should be done synchronously
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

List Instances
Get a list of the available instances for a database
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/instances
Name Type Optional Description
database_id
string No Database ID
Output

Reset Database
Remove all the documents from the current database instance
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/reset
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
instance
string Yes Instance to reset, else will reset the current instance
Output

Deploy a Database
Deploy a database to the server - Replace the existing one, if any
Input
Method URI Description
POST /$darwino-jstore/database/{database_id}/deploy
Content Type: application/jsonData Schema...
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
force
boolean Yes Force the deployment to this version number
Output
Content Type: application/jsonData Schema...

Undeploy a Database
Undeploy a database from the server
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}
Name Type Optional Description
database_id
string No Database ID
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Store


Store related APIs



Documents Count
Return the count of documents in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documentscount
Name Type Optional Description
database_id
string No
store_id
string No
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Document IDs
Return the list of all the documents ID in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documentsids
Name Type Optional Description
database_id
string No
store_id
string No
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Read Tags
Get the tags list for the store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/tags
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
maxtags
number Yes Maximum number of tags to be returned
sortbyname
boolean Yes Sort the tags by name
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Store Collection1.0.1
Returns the list of the available stores in a database
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
details
boolean Yes When true, it returns some database details (label, instances...), else it only returns the database names
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Index Collection1.0.1
Returns the list of the available index in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
details
boolean Yes When true, it returns some database details (label, instances...), else it only returns the database names
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Document


CRUD operations on documents accessed by UNID



Check Document Exists
Check if a document exists by UNID
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documentexists/{unid}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Check Document Deleted
Check if a document is deleted by UNID.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documentdeleted/{unid}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Children Count
Return the count of the children of a document by UNID.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/childrencount/{unid}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Children List
Return the list of the children of a document by UNID.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/children/{unid}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Slave List
Return the list of the slaves of a document by UNID.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/syncslaves/{unid}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Read Social Data
Access the social data of a document by UNID
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/social
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Name Type Optional Description
user
string Yes User ID for the social data. An empty ID means the current user.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Set Social Data
Set the document social data by UNID
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/social
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Name Type Optional Description
user
string Yes User ID for the social data. An empty ID means the current user.
rate
number Yes Rate value for the document
share
boolean Yes Share (true) or unshare (false) the document
read
boolean Yes Mark the document as read (true) or unread (false)
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Document CRUD


Crud operations on documents



Init Document
Initialize a new document after calling the proper event handler (onPostNewDocument) on the server. The document is *not* saved in the database, it is just initialized
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/newdocument
Content Type: application/jsonData Schema...
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Create Document
Create a new document and save it The UNID can be passed or will be automatically generated.
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid} The content should be passed in a field named 'json', while the meta-data and attachments can also be passed this way.
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/content The content only contains the JSON document, without the meta-data or the attachment
Content Type: application/jsonData Schema...
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No The UNID of the document. If empty, then a default one will be generated.
Name Type Optional Description
jsonfields
int Yes Options on the fields to return
Output
Content Type: application/jsonData Schema...
Name Type Optional Description
x-dwo-jstore-id
string No The new document id, when created from the content only API
x-dwo-jstore-unid
string No The new document unid, when created from the content only API
Code Description
200
OK. Indicates that the request was received successfully.

Read Document
Read a document from a store.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid} The content should be passed in a field named 'json', while the meta-data and attachments can also be passed this way.
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/content The content only contains the JSON document, without the meta-data or the attachment
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Name Type Optional Description
jsonfields
int Yes Options on the fields to return
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Update Document
Update an existing document.
Input
Method URI Description
PUT /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid} The content should be passed in a field named 'json', while the meta-data and attachments can also be passed this way.
PUT /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/content The content only contains the JSON document, without the meta-data or the attachment
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Delete Document
Delete an existing document, and return an empty response.
Input
Method URI Description
DELETE /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}
DELETE /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/content The trailing '/content' has no impact with this method. It is provided for consistency with the other methods.
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Document Attachments


Access the document attachments



Read Design Element Content
Read a design element attachment. This is equivalent of reading the attachment 'content' from the store '_design'
Input
Method URI Description
GET /$darwino-jstore/design/{database_id}/{design_name}
Name Type Optional Description
database_id
string No Database ID
design_name
string No Name of the design element
Output
Code Description
200
OK. Indicates that the request was received successfully.

Get Attachments List1.0.1
Get the list of attachments of a document
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/attachments
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
Output

Access Attachments
Access the attachments of a document by UNID and attachment name
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/attachments/{attachment_name} Read a document attachment content
HEAD /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/attachments/{attachment_name} Check if the attachment exists
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/attachments/{attachment_name} Create a new attachment, if it does not exist in the document
PUT /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/attachments/{attachment_name} Update an existing attachment in the document
DELETE /$darwino-jstore/databases/{database_id}/stores/{store_id}/documents/{unid}/attachments/{attachment_name} Delete an existing attachment in the document
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
unid
string No Document UNID or ID if prefixed by id:
attachment_name
string No Attachment name
Name Type Optional Description
encode
string Yes Used to encode the result as base 64 if the parameter value is 'base64'. Else, the attachment will be returned as binary
Output

Indexes





Check Key Exists
Check if a document exists in an index
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/documentexists/{key}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
key
string No Key of the entry as a JSON value (can be an array...)
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Read Document By Key
Read a document from a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}documents/{key}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index name
key
string No Key of the entry as a JSON value
Name Type Optional Description
jsonfields
int Yes Options on the fields to return
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Update Document By Key
Update an existing document
Input
Method URI Description
PUT /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/documents/{key}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index name
key
string No Document key as a JSON value
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Delete Document By Key
Delete an existing document by key, and return an empty response
Input
Method URI Description
DELETE /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}documents/{key}
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index name
key
string No Document key as a JSON value
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Database


Query the database



Query Count - Database
Return the count of documents from a query, cross stores.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/count
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query One Entry - Database
Returns a single entry from a query. This is cross stores.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/entry
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Entries - Database
Return the list of entries from a database. This is cross stores.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/entries
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Document Entries - Database
Return the list of documents from a database. This is cross stores.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/docentries
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Document IDs - Database
Returns a list of document IDs from a database. This is cross stores.
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/ids
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Mark as Read/Unread - Database
Marks all the documents as read/unread.
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/markallread
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Delete Documents - Database
Delete all documents from a query. This is cross store
Input
Method URI Description
DELETE /$darwino-jstore/databases/{database_id}/deleteall
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Store





Query Count - Store
Return the count of documents from a query
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/count
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query One Entry - Store
Returns a single entry from a query
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/entry
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Entries - Store
Return the list of entries in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/entries
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Document Entries - Store
Return the list of document from a store

 

Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/docentries
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Document IDs - Store
Returns a list of document IDs in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/ids
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Mark as Read/Unread - Store
Marks all the documents as read/unread
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/markallread Mark all the documents in the collection as read or unread
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Delete Documents - Store
Delete all documents from a query
Input
Method URI Description
DELETE /$darwino-jstore/databases/{database_id}/stores/{store_id}/deleteall
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Indexes





Query Count - Index
Get the number of entries in the index
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/count
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query One Entry - Index
Returns a single entry from a query
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/entry
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Entries - Index
Return the list of entries in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/entries
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Document Entries - Index
Return the list of document from a store

 

Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/docentries
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Document IDs - Index
Returns a list of document IDs in a store
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/ids
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Query Mark as Read/Unread - Index
Marks all the documents as read/unread
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/markallread Mark all the documents in the collection as read or unread
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Query Delete Documents - Index
Delete all documents from a query
Input
Method URI Description
DELETE /$darwino-jstore/databases/{database_id}/stores/{store_id}/indexes/{index_id}/deleteall
Name Type Optional Description
database_id
string No Database ID
store_id
string No Store ID
index_id
string No Index ID
Name Type Optional Description
orderby
string Yes Order by fields, separated by a coma
descending
boolean Yes Sort using descending order
categorycount
number Yes Category count
categorystart
number Yes Category start
ftsearch
string Yes Full text search query
id
string Yes Filter the entries by id
unid
string Yes Filter the entries by unid
parentid
string Yes Filter the entries by parentid
key
string Yes Filter the entries by key
partialkey
string Yes Filter the entries by a partial key
tags
string Yes Filter the entries by tags
startkey
string Yes Filter the entries starting from a key
excludestart
boolean Yes Exclude the entries exactly matching the start key
endkey
string Yes Filter the entries up to key
excludeend
string Yes Exclude the entries matching exactly the end key
skip
number Yes Ignore 'the first 'skip' entries
limit
number Yes Limits the number of entries returned
hierarchical
number Yes Indicates that the entries should be returned hierarchically up to a certain level
options
string Yes Defines the options used when executing the query: 1: Insert the category #1 2: Insert the category #2 4: Insert the category #3 8: Insert the category #4 32: Makes the entry value the document content 256: returns the read marks as part of the entries 4096: Calculate the hierarchy manually (not advised) 8192: Sort the collection by the Full Text rank 16384: Do not use SQL to filter the entries (not advised)
query
string Yes JSON query
extract
string Yes Cursor entry transformation
transformer
string Yes Transformation of the resulting JSON document
jsontree
boolean Yes Return the response entries as a children property in the JSON resultset.
Output

Synchronization


Manage data synchronization between databases



Check Service
Check if the synchronization service is available
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/replication/check
Name Type Optional Description
database_id
string No
Name Type Optional Description
sourceId
string No Source ID for the synchronization
profile
string Yes Name of the synchronization profile
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Get Synchronization Date
Get the last synchronization date
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/replication/date
Name Type Optional Description
database_id
string No
Name Type Optional Description
sourceId
string No Source ID for the synchronization
profile
string Yes Name of the synchronization profile
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Get Synchronization Changes
Get the list of changes
Input
Method URI Description
GET /$darwino-jstore/databases/{database_id}/replication/listchanges
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
startdate
number Yes Minimum timestamp for the replication changes, as a Java encoded time. 0 or none means all changes.
enddate
string Yes Maximum timestamp for the replication changes, as a Java encoded time. 0 or none means all changes.
profilejson
string Yes Replication profile as a JSON object
repid
string Yes Replication id of the client. All the document with this repid will be skipped, to avoid an unnecessary roundtrip
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Send Replication Updates
Push the list of replication changes
Input
Method URI Description
POST /$darwino-jstore/databases/{database_id}/replication/update
Name Type Optional Description
database_id
string No Database ID
Name Type Optional Description
sourceid
string No Synchronization source ID
committhreshold
int Yes Number of documents to save before committing the transaction and starting a new one
profilejson
string No Replication profile as a JSON object
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.

Mobile


This set of services are dedicated to the mobile clients


 


Validate User
Validates the current user and returns some application information

This services validate that the user is valid and returns the list of application properties pushed by the server

Input
Method URI Description
GET /$darwino-mobile/validate
Output
Content Type: application/jsonData Schema...
Code Description
200
OK. Indicates that the request was received successfully.
401
Unauthorized. Returned when no authenticated user or no userid, email, or key parameter are provided on the request.

Users


Access to users from the current directory



Service Information
Get information on the user service
Input
Method URI Description
GET /$darwino-social/users
Output
Content Type: application/jsonData Schema...

Stock Images
Return stock images used by consumers, like the anonymous photo
Input
Method URI Description
GET /$darwino-social/users/images/{resource}
Name Type Optional Description
resource
enumerated No Name of the resource, like the anonymous photo
Authorized values:
  • anonymous-photo.png
Output

Retrieve Current User
Return information on the current user
Input
Method URI Description
GET /$darwino-social/users/user
Name Type Optional Description
providers
string Yes List of providers to use, separated by a coma. A empty value means no provider, while the absence of the parameter means all available providers (default)
Output
Content Type: application/jsonData Schema...

Retrieve User
Return the information a user based on its DN
Input
Method URI Description
GET /$darwino-social/users/users/{userdn}
Name Type Optional Description
userdn
string No User distinguished name, @me also meaning the current user
Name Type Optional Description
loginid
boolean Yes Assume that the userdn is actually a login id, that depends on the directory (email, short name...)
providers
string Yes List of providers to use, separated by a coma. A empty value means no provider, while the absence of the parameter means all available providers (default)
Output
Content Type: application/jsonData Schema...

Retrieve User Content
Return some specific user content, beyond its JSON attribute. It can be, for example, the user picture, or the payload from a provider
Input
Method URI Description
GET /$darwino-social/users/users/{userdn}/content/{type} Return the typed content for the user
Name Type Optional Description
userdn
string No User distinguished name, @me also meaning the current user
type
string No The name of the content to retrieve for this user, like "photo" or "payload"
Name Type Optional Description
loginid
boolean Yes Assume that the userdn is actually a login id, that depends on the directory (email, short name...)
provider
string Yes Name of the provider to retrieve the content from. An empty value means the main directory
Output
Content Type: application/jsonData Schema...

Retrieve Multiple Users
Return information on multiple users at once. The users must be identified by DN, not login id
Input
Method URI Description
GET /$darwino-social/users/users
POST /$darwino-social/users/users Same than get, except that the ids are passed in the POST body to support large arrays
Content Type: application/jsonData Schema...
Name Type Optional Description
providers
string Yes List of providers to use, separated by a coma. A empty value means no provider, while the absence of the parameter means all available providers (default)
ids
string Yes Array of ids as a JSON array. It cannot be a simple string with a separator as the ids can contain separators themselves
Output
Content Type: application/jsonData Schema...

Type Ahead
Search users based on name selection, for type ahead functions
Input
Method URI Description
GET /$darwino-social/users/typeahead
Name Type Optional Description
provider
string Yes The name of the provider to delegate the research to. If not available, then it will search the main directory
query
string Yes The typeahead query, expressed as a simple search string
skip
int Yes The number of entries to skip in the result
limit
int Yes The maximum number of entries to return
attributes
string Yes A list of attribute names, separated by a coma, to return for each entry. Empty means the default attribute list
options
string Yes Specific options for the search, expressed as a JSON object. The available options depend on the directory/provider
Output
Content Type: application/jsonData Schema...

Search Users
Search users in the directory based on selection formula
Input
Method URI Description
GET /$darwino-social/users/query
Name Type Optional Description
provider
string Yes The name of the provider to delegate the research to. If not available, then it will search the main directory
query
string Yes The selection query, expressed in a LDAP like query language
skip
int Yes The number of entries to skip in the result
limit
int Yes The maximum number of entries to return
attributes
string Yes A list of attribute names, separated by a coma, to return for each entry. Empty means the default attribute list
options
string Yes Specific options for the search, expressed as a JSON object. The available options depend on the directory/provider
Output
Content Type: application/jsonData Schema...

Preferences


Access the user preferences



Access current user preferences
Input
Method URI Description
GET /$darwino-social/preferences/{prefid} Read preferences of the current user
POST /$darwino-social/preferences/{prefid} Change the current user preferences
DELETE /$darwino-social/preferences/{prefid} Delete the current user preferences
Use the table bellow that represents the expected fields:
Name Type Optional Description
Name Type Optional Description
prefid
string No The preference Id
Output

Access user preferences
Input
Method URI Description
GET /$darwino-social/preferences/users/{userid}/preferences/{prefid} Read preferences for a specific user
POST /$darwino-social/preferences/users/{userid}/preferences/{prefid} Change the user preferences
DELETE /$darwino-social/preferences/users/{userid}/preferences/{prefid} Delete the user preferences
Use the table bellow that represents the expected fields:
Name Type Optional Description
Name Type Optional Description
userid
string No The id of the user. The service implementation might prevent the access to a user that is not the current authenticated user.
prefid
string No The preference Id
Output

Debug


Set of debug/development related services



Profiler Commands
Sends a command to control the profiler
Input
Method URI Description
GET /$darwino-debug/profiler
Name Type Optional Description
start
string Yes As first parameter, starts the profiler. The value can be empty.
stop
string Yes As first parameter, stops the profiler. The value can be empty.
reset
string Yes As first parameter, reset the profiler in memory data. The value can be empty.
Output
Content Type: application/jsonData Schema...