fixing REST API support.