Intercepting requests to Published Rest Service

Hello, We are  publishing a Rest Service in our application. Our intention is to intercept incoming request to our Rest Service. I created a Java Action to add a custom request handler to capture the requests.  When I pass “abc/” as path argument and hit the URL, request handler works as expected.  But when I pass the path of endpoint for our Published Rest Service which is “rest/” (fullpath is rest/myendpoint) request handler is not invoked. ( I also tried with path as “myendpoint/” and all other variations ) My question: Is adding requesthandler only for http requests? Is there a way to intercept incoming requests to published Rest Service?  
1 answers

From what you describe, it seems like you want to use a custom request handler to intercept calls to a published REST service. That’s not possible. Custom request handlers handle requests by returning a response. They don’t intercept and change requests for other handlers or published services.

Either your custom request handler can handle requests to /rest/, by reding the request and returning a response, or the published REST service handles the requests and returns a response.