I have a lambda function (e.g. /getName). This will be hosted by one domain (e.g. A) and can be triggered by multiple domains (A, B, C, etc.). I need to set up CloudFront so that a request to /getName from Domain B gets re-routed or re-directed to Domain A without an explicit redirect (returning 301) to browser.
For example, when the browser makes an ajax call to www.B.com/getName, internally it should be a call to www.A.com/getName. The call to www.A.com/getName should not be visible to client/browser.
Is this possible in CloudFront? If so, what is the right way of setting this up?