Added http API and first pass at a query language