<?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: Accessing webmap from enterprise in ArcGIS API for Java Script in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031936#M71901</link>
    <description>&lt;P&gt;To add on to KenBuja answer we have found that when we publish things, portal will automatically assign tokens.&amp;nbsp; Check if any of layers, mapping application, etc. used in the map are using tokens in the data source.&amp;nbsp; I cannot find my notes on it, if I remember correctly we took out the token portion of the url, or changed the token portion of the URL to manager.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="portal.jpg" style="width: 913px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/7277iEBAED97334FA8D2D/image-size/large?v=v2&amp;amp;px=999" role="button" title="portal.jpg" alt="portal.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 02 Mar 2021 15:13:27 GMT</pubDate>
    <dc:creator>MatthewDriscoll</dc:creator>
    <dc:date>2021-03-02T15:13:27Z</dc:date>
    <item>
      <title>Accessing webmap from enterprise in ArcGIS API for Java Script</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031707#M71896</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am trying to access the web map (Shared to the organisation) published in the enterprise portal using the ArcGIS API for javascript.&lt;/P&gt;&lt;P&gt;We have used SAML to access the portal (below settings)&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="himalaya_GIS_0-1614636544332.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/7229iF9A9630323083F08/image-size/medium?v=v2&amp;amp;px=400" role="button" title="himalaya_GIS_0-1614636544332.png" alt="himalaya_GIS_0-1614636544332.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Code I am using&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="himalaya_GIS_1-1614636648222.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/7230iF6C5C2ED708B9E39/image-size/medium?v=v2&amp;amp;px=400" role="button" title="himalaya_GIS_1-1614636648222.png" alt="himalaya_GIS_1-1614636648222.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Getting the below login screen - tried with my organisation login credentials, it says incorrect username and password? I was expecting to see my portal login screen instead of this? Any help will be appreciated.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="himalaya_GIS_2-1614636719884.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/7231iA141361883BDB19A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="himalaya_GIS_2-1614636719884.png" alt="himalaya_GIS_2-1614636719884.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 01 Mar 2021 22:15:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031707#M71896</guid>
      <dc:creator>himalaya_GIS</dc:creator>
      <dc:date>2021-03-01T22:15:27Z</dc:date>
    </item>
    <item>
      <title>Re: Accessing webmap from enterprise in ArcGIS API for Java Script</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031731#M71897</link>
      <description>&lt;P&gt;When I have to add in a service that requires signing in with my organization creditentials, I have to use OAuthInfo as well as IdentityManager, like this&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;    require([...,
      "esri/identity/OAuthInfo",
      "esri/identity/IdentityManager",
      ...
    ], function (..., OAuthInfo, identityManager, ...) {

      const portalUrl = 'your portal url';
      const info = new OAuthInfo({
        appId: "xxxxxxxxxxxxxxxx", //*** Your Client ID value goes here ***//
        popup: false // inline redirects don't require any additional app configuration
      });
      identityManager.registerOAuthInfos([info]);
      // send users to arcgis.com to login
      identityManager.getCredential(portalUrl);
      identityManager.checkSignInStatus(portalUrl).then(function () {
        layer = new FeatureLayer({
          portalItem: {
            id: "your item"
          },
          outFields: ["*"]
        });
      .
      .
      .
      });&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 01 Mar 2021 23:19:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031731#M71897</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2021-03-01T23:19:29Z</dc:date>
    </item>
    <item>
      <title>Re: Accessing webmap from enterprise in ArcGIS API for Java Script</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031936#M71901</link>
      <description>&lt;P&gt;To add on to KenBuja answer we have found that when we publish things, portal will automatically assign tokens.&amp;nbsp; Check if any of layers, mapping application, etc. used in the map are using tokens in the data source.&amp;nbsp; I cannot find my notes on it, if I remember correctly we took out the token portion of the url, or changed the token portion of the URL to manager.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="portal.jpg" style="width: 913px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/7277iEBAED97334FA8D2D/image-size/large?v=v2&amp;amp;px=999" role="button" title="portal.jpg" alt="portal.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 02 Mar 2021 15:13:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/accessing-webmap-from-enterprise-in-arcgis-api-for/m-p/1031936#M71901</guid>
      <dc:creator>MatthewDriscoll</dc:creator>
      <dc:date>2021-03-02T15:13:27Z</dc:date>
    </item>
  </channel>
</rss>

