Let’s suppose I’ve two services:
- one for authentication purpose only -> This has /login endpoint
- second for other purpose -> This also has a /login endpoint, but I want to call service one’s /login endpoint under the hood.
Sample endpoints:
- Service # 1 POST http://service1.com/login (Request body has ‘email’ & ‘pass’)
- Service # 2 POST http://service2.com/login (should call service # 1’s /login by passing full request object, under the hood)
Ideally end user won’t be aware of service # 1 at all. This is the requirement.
Is this kind of structure possible?
If not what’s best I can do for this? Just simple redirection?
NOTE:- Both services are implemented using Slim Framework