How to properly set esriConfig.portalUrl ?

755
1
04-14-2020 09:28 AM
EkremCanli2
New Contributor III

Hi,

started with ArcGIS API for JS only today and am having issues loading scenes from a public portal already. If I use an ID from a public AGOL portal item, my scene shows as intended. If I change to an on-premises portal url with esriConfi.portalURL, nothing appears at all.

<script>
require([
"esri/config"
"esri/WebScene",
"esri/views/SceneView"
], function(esriConfig, WebScene, SceneView) {

// Set the hostname to the on-premises portal
esriConfig.portalUrl = "https://arcgisportal.mysynergis.com/portal/";

var webscene = new WebScene({
portalItem: {
id: "2694728cac174fcb8622f5c472f689fe"
}
});

var view = new SceneView({
container: "viewDiv",
map: webscene
});

});
</script>

Any idea what's missing? Also what platform would you suggest for debugging? The ArcGIS API for JavaScript Sandbox doesn't show anything... (also is here on the community forum a proper way to post code like on stackoverflow?)

Thanks!

1 Reply
RyanDickinson1
New Contributor III

Have you checked your browser's developer tools to capture the traffic when you try to load the scene?

0 Kudos