<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Basemap not authorized using OAuth ESRI.ArcGISRunTime 200 in .NET Maps SDK Questions</title>
    <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1268170#M11744</link>
    <description>&lt;P&gt;Yes to use the arcgis location services you need to either:&lt;BR /&gt;1. Sign into ArcGIS.com before accessing the services&lt;BR /&gt;or&lt;BR /&gt;2. Set the ArcGISRuntimeEnvironment.APIKey property to an API Key you generate on the developer's website.&lt;BR /&gt;&lt;BR /&gt;This isn't a new 200 thing. This was also a requirement in 100.x, unless you were still using the deprecated map services (which have been removed from 200).&lt;/P&gt;</description>
    <pubDate>Wed, 15 Mar 2023 18:20:20 GMT</pubDate>
    <dc:creator>SomeGISGuy</dc:creator>
    <dc:date>2023-03-15T18:20:20Z</dc:date>
    <item>
      <title>Basemap not authorized using OAuth ESRI.ArcGISRunTime 200</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1265886#M11736</link>
      <description>&lt;P&gt;After updating nuget package of the ESRI.ArcGISRunTime to 200 our Basemap stopped working.&amp;nbsp;&lt;BR /&gt;I am able to load portal features, display them on the map etc.&amp;nbsp;&lt;BR /&gt;When the program is trying to load Basemap I am getting an endless loop of prompts asking me to log in again.&amp;nbsp;&lt;BR /&gt;After investigating it deeper I think in the Basemap API calls there is no Token being passed.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;// This will create an endless login loop
var map = new Map(BasemapStyle.ArcGISDarkGray);

// This work fine
var map = new Map();&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using the standard OAuth method with&amp;nbsp;TokenAuthenticationType.OAuthAuthorizationCode.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt;ServerInfo portalServerInfo = new ServerInfo(esriPortalUri)
{
OAuthClientInfo =
new OAuthClientInfo(clientId, redirectUri, clientSecret),
TokenAuthenticationType = TokenAuthenticationType.OAuthAuthorizationCode
};
// Register the server information with the AuthenticationManager.
AuthenticationManager.Current.RegisterServer(portalServerInfo);
var credential = await AuthenticationManager.Current.GenerateCredentialAsync(esriPortalUri);

AuthenticationManager.Current.AddCredential((OAuthTokenCredential) credential );&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Basemap prompt request without Token from SDK.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Coolodporny_0-1678350797840.png" style="width: 841px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/64786i5DD00F8AB7E5C0B3/image-dimensions/841x137?v=v2" width="841" height="137" role="button" title="Coolodporny_0-1678350797840.png" alt="Coolodporny_0-1678350797840.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Esri.ArcGISRuntime v200.0&lt;BR /&gt;Esri.ArcGISRuntime.WPF v200.0&lt;BR /&gt;&lt;SPAN&gt;Esri.ArcGISRuntime.Toolkit.WPF v200.0&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Mar 2023 08:46:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1265886#M11736</guid>
      <dc:creator>Coolodporny</dc:creator>
      <dc:date>2023-03-09T08:46:38Z</dc:date>
    </item>
    <item>
      <title>Re: Basemap not authorized using OAuth ESRI.ArcGISRunTime 200</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267360#M11737</link>
      <description>&lt;P&gt;You should either:&lt;BR /&gt;1. Set the APIKey property on the Esri.ArcGISRuntime.ArcGISRuntimeEnvironment&lt;BR /&gt;or&lt;BR /&gt;2. Require the user to sign into an ArcGIS Online portal prior to opening a basemap.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Mar 2023 23:06:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267360#M11737</guid>
      <dc:creator>dotMorten_esri</dc:creator>
      <dc:date>2023-03-13T23:06:14Z</dc:date>
    </item>
    <item>
      <title>Re: Basemap not authorized using OAuth ESRI.ArcGISRunTime 200</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267431#M11741</link>
      <description>&lt;P&gt;As mentioned in the ticket previous version of the nuget package (100+) was working fine. I am using the second option and asking the user the sign it by using the&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="csharp"&gt; // Use the OAuthAuthorize class (defined below) to show the login UI.
 AuthenticationManager.Current.OAuthAuthorizeHandler = new OAuthAuthorise();

 var credential = await 
 AuthenticationManager.Current.GenerateCredentialAsync(esriPortalUri);

 AuthenticationManager.Current.AddCredential((OAuthTokenCredential) credential 
 );&lt;/LI-CODE&gt;&lt;P&gt;I am popping up a login window where the user is inserting their email and password.&amp;nbsp;&lt;BR /&gt;The credentials are working fine to get the personal data from EsriPortal like a list of the groups, feature services etc. But when it comes to BaseMap is not allowed.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Maybe it has something to do with the Esri Portal version? Is there any limitation on which the Esri Portal version is supported by the newest Nuget version 200+?&lt;/P&gt;</description>
      <pubDate>Tue, 14 Mar 2023 08:35:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267431#M11741</guid>
      <dc:creator>Coolodporny</dc:creator>
      <dc:date>2023-03-14T08:35:17Z</dc:date>
    </item>
    <item>
      <title>Re: Basemap not authorized using OAuth ESRI.ArcGISRunTime 200</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267644#M11742</link>
      <description>&lt;P&gt;&amp;gt;&amp;nbsp;&lt;SPAN&gt;Maybe it has something to do with the Esri Portal version?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;Is this an on-premise portal? For basemaps to work, you'll need to sign into the arcgis.com / ArcGIS Online portal.&lt;/P&gt;</description>
      <pubDate>Tue, 14 Mar 2023 16:28:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267644#M11742</guid>
      <dc:creator>SomeGISGuy</dc:creator>
      <dc:date>2023-03-14T16:28:33Z</dc:date>
    </item>
    <item>
      <title>Re: Basemap not authorized using OAuth ESRI.ArcGISRunTime 200</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267903#M11743</link>
      <description>&lt;P&gt;That's maybe it. Indeed, I am using an on-premise portal. To make the base maps work from version 200+ will the user need to sign in to the on-premise portal and then to the official ArcGIS Online Portal?&lt;/P&gt;</description>
      <pubDate>Wed, 15 Mar 2023 08:00:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1267903#M11743</guid>
      <dc:creator>Coolodporny</dc:creator>
      <dc:date>2023-03-15T08:00:48Z</dc:date>
    </item>
    <item>
      <title>Re: Basemap not authorized using OAuth ESRI.ArcGISRunTime 200</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1268170#M11744</link>
      <description>&lt;P&gt;Yes to use the arcgis location services you need to either:&lt;BR /&gt;1. Sign into ArcGIS.com before accessing the services&lt;BR /&gt;or&lt;BR /&gt;2. Set the ArcGISRuntimeEnvironment.APIKey property to an API Key you generate on the developer's website.&lt;BR /&gt;&lt;BR /&gt;This isn't a new 200 thing. This was also a requirement in 100.x, unless you were still using the deprecated map services (which have been removed from 200).&lt;/P&gt;</description>
      <pubDate>Wed, 15 Mar 2023 18:20:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/basemap-not-authorized-using-oauth-esri/m-p/1268170#M11744</guid>
      <dc:creator>SomeGISGuy</dc:creator>
      <dc:date>2023-03-15T18:20:20Z</dc:date>
    </item>
  </channel>
</rss>

