Can we use n1ql query in Couchbase-Lite-PhoneGap-Plugin

I don’t think that from a security perspective you would want your mobile clients in the Internet have direct access to the couchbase server bucket. The typical pattern is to have a simple web service (Python, node, java, c, go , .net …) that interfaces with Couchbase service using one of our many SDKs. This web service would then support a simple REST APIs that your mobile app can query into .

On a related note, In 2.0 version of Couchbase Lite (now in Developer Build), we do have support for N1QL like queries that can be made directly against the CB lite data store. We don’t have a phone gap plugin for it as yet (CC @jens)