There is a WSO2 EI backend running with Basic Auth
mechanism.
Postman - WSO2 EI URL Hit:
OAuth
401 unauthorized ERROR
as per below postman hit.Postman - APIM URL Hit:
WSO2 APIM Publisher:
WSO2 APIM Dev Portal:
TryitTool in DEV Portal:
Scenario:
Endpoint Security Configurations
of Publisher portal.Note: Basic Auth credentials (admin:admin
) is passed in each api hit
Am I missing anything? How can we achieve this?
The API Gateway drops the authentication header and that’s why you get 401. You can set the EI credentials at the endpoint credentials so that authentication header is passed to the backend. Go to the endpoint section at the APIM and provide the same credentials as the endpoint credentials.
Although your EI endpoint is secured with basic authentication, you don’t need to expose the API at the gateway with basic authentication. You can use OAuth or API keys.