Last post Jun 28, 2018 03:08 AM by Brando ZWZ
Jun 27, 2018 04:50 AM|Ojusvee06|LINK
I am using the MobileServiceClient (Microsoft.Azure.Mobile.Client version 4.0.1) with the InvokeApiAsync method to do the call but always fails with a null exception. If I call an API that does not have authorization, it works fine.
So my question is if I can use the MobileServiceClient or this doesn't want to work with .NET Core. I don't want to call my APIs with HttpClient.
Jun 28, 2018 03:08 AM|Brando ZWZ|LINK
As far as I know, the MobileServiceClient couldn't add the authorization token by default to ask for asp.net core web api.
So you will find you couldn't get the response from the asp.net core web api.
I suggest you could create a custom HttpMessageHandler to add the token to the request and use MobileServiceClient send the request.
More details, you could refer to below article.