Hi,
When I try to set a basic authentication ( user/pass), or api key (via Authorization) - when Gateway try to reach the API, it changes the parameters to Bearer instead to keep in Basic. Anyone has any idea hwo to force to run Basic instead of Bearer ?
Thanks,
Solved! Go to Solution.
Hi @ewermix ,
Could you please share a bit more about your Rest API you used within your custom connector?
Does your Rest API support Basic Authentication (Username + Password)?
Based on the issue that you mentioned, I think you have some misunderstanding on the authentication in custom connector of PowerApps.
Actually, your custom connector use Access_Token to access your Rest API/ call corresponding server instead of the actual Username & Password , or API Key.
When you create a connection to your custom connector within the "Test" step along with your Username & Pasweord, or API Key, it would send an HTTP Reuqest along with your Username & Pasweord, or API Key to your Rest API/corresponding server, your Rest API/corresponding server would authenticate the credentials you passed, if pass, the corresponding server would return a Access_Token to you, and save it within the created connection.
When you test the actions you specified in your custom conector, the connection would call the corresponding server along with the stored Access_Token.
Within PowerApps, regardless of which authentication way (OAuth2.0, Basic Auth, API Key) you used within the custom connector, when you create a connection to the custom connector, the corresponding server would return a Access_Token to you if the credentials you provided is correct. When you call the action you specified in your custom connector later, it would send an HTTP request to the corresponding server along with the stored Access_Token rather than the actual Username & Password , or API Key.
Based on the error message within the screenshot you provided, it seems to tell that there is something wrong with the connection you created to your custom conector. Please check if you have used a proper Username and Password to create a connection to your custom conector.
Also please consider specify the API Key as authentication way in your custom connector, and configure it as below:
Set Parameter location property to Header.
Please take a try with above solution, then check if the issue is solved.
In additon, there is no way to force the custom connector to use Basic credential (Username & Password) rather than Bearer (Access_Token) in PowerApps currently.
Best regards,
Hi @ewermix
Hi @yashag2255 ,
Its already configured to use basic authentication.. however the request keeping using Bearer 😞
Follow below:
Hi @ewermix ,
Could you please share a bit more about your Rest API you used within your custom connector?
Does your Rest API support Basic Authentication (Username + Password)?
Based on the issue that you mentioned, I think you have some misunderstanding on the authentication in custom connector of PowerApps.
Actually, your custom connector use Access_Token to access your Rest API/ call corresponding server instead of the actual Username & Password , or API Key.
When you create a connection to your custom connector within the "Test" step along with your Username & Pasweord, or API Key, it would send an HTTP Reuqest along with your Username & Pasweord, or API Key to your Rest API/corresponding server, your Rest API/corresponding server would authenticate the credentials you passed, if pass, the corresponding server would return a Access_Token to you, and save it within the created connection.
When you test the actions you specified in your custom conector, the connection would call the corresponding server along with the stored Access_Token.
Within PowerApps, regardless of which authentication way (OAuth2.0, Basic Auth, API Key) you used within the custom connector, when you create a connection to the custom connector, the corresponding server would return a Access_Token to you if the credentials you provided is correct. When you call the action you specified in your custom connector later, it would send an HTTP request to the corresponding server along with the stored Access_Token rather than the actual Username & Password , or API Key.
Based on the error message within the screenshot you provided, it seems to tell that there is something wrong with the connection you created to your custom conector. Please check if you have used a proper Username and Password to create a connection to your custom conector.
Also please consider specify the API Key as authentication way in your custom connector, and configure it as below:
Set Parameter location property to Header.
Please take a try with above solution, then check if the issue is solved.
In additon, there is no way to force the custom connector to use Basic credential (Username & Password) rather than Bearer (Access_Token) in PowerApps currently.
Best regards,
Hi @v-xida-msft ,I have re-created the whole connector and worked like a charm ! Thanks for clarifying 😉