Middleware for Custom RPC

Hi there! Is it possible to implement middleware for logging request/response or customizing error handling? Can I use RegisterBeforeRt and RegisterAfterRt for that? I’ve tried to implement it on my own, but it wasn’t successful. Is there someone who can resolve this task? Currently, I use a helper to customize my errors, but I have to add it for every RPC method.

Hello @vladislav-chunikhin, as you mention this would have to be done via RegisterBefore/AfterRt, can you elaborate on what is it that you would like to log, how you’d like to customize the errors, and what is it that you weren’t able to achieve with the hooks?