I have several services in my app that point to different API URLs. Now I need to set different headers to each of these services. My question is now regarding the new interceptors in Angular 4. Is there a possibility to set one interceptor for a specific service? So each service has its specific interceptor?
Hopefully, you guys get my question.
Once a request/response is fired with the new HttpClient, all interceptors will be called. One thing you can do, is marking your request, so you set the right header in the interceptor that is designed to handle that request.