OData query string parser for node.js based on pegjs.
Installation
npm install odata-parser
Usage
var parser = ; var ast = parser util
will result in:
'$top': 10 '$skip': 5 '$select': 'foo'
Filters like:
parser
results in:
$filter: type: 'and' left: type: 'eq' left: type: 'property' name: 'Name' right: type: 'literal' value: 'John' right: type: 'lt' left: type: 'property' name: 'LastName' right: type: 'literal' value: 'Doe'
Using functions in filters
parser
restuls in:
$filter: type: 'functioncall' func: 'substringof' args: type: 'literal' value: 'nginx' type: 'property' name: 'Servers'
Issue Reporting
If you have found a bug or if you have a feature request, please report them at this repository issues section. Please do not report security vulnerabilities on the public GitHub issue tracker. The Responsible Disclosure Program details the procedure for disclosing security issues.
Author
License
This project is licensed under the MIT license. See the LICENSE file for more info.