added support for path and query parameters