<?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: 498 Invalid Token error with esriConfig.apiKey in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1510582#M85116</link>
    <description>&lt;P&gt;I believe it was created with an Esri Location Platform account. I did finally get the base map working by adding updating the referers I set on the key, but I still could not get the feature layers to load.&lt;/P&gt;&lt;P&gt;I finally tried adding&amp;nbsp;`?f=pjson` to the feature layer URL, and then it worked. I then tried it again without the extra parameter, and it loaded. So I'm not sure why it required it to work or why it then worked when I removed the parameter.&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":thinking_face:"&gt;🤔&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But I have a functioning map now. Thank you for reaching out anyways!&lt;/P&gt;&lt;P&gt;Molly&lt;/P&gt;</description>
    <pubDate>Fri, 26 Jul 2024 13:21:42 GMT</pubDate>
    <dc:creator>WebDevelopers</dc:creator>
    <dc:date>2024-07-26T13:21:42Z</dc:date>
    <item>
      <title>498 Invalid Token error with esriConfig.apiKey</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1509461#M85104</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to change my TypeScript app that uses the JS SDK version 4.24 to use one of the new API keys, since its previous API Key is now legacy. I haven't changed anything except the API key, and now I get `498 Invalid Token` on every request.&lt;/P&gt;&lt;P&gt;I also tried the advice from &lt;A href="https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/td-p/1351515" target="_self"&gt;this post&lt;/A&gt; and used my new API key in the suggested tutorial in the &lt;A href="https://developers.arcgis.com/javascript/latest/tutorials/display-a-map/" target="_self"&gt;documentation&lt;/A&gt;. It doesn't work there either, but my old legacy API key does.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any ideas? Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jul 2024 17:47:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1509461#M85104</guid>
      <dc:creator>WebDevelopers</dc:creator>
      <dc:date>2024-07-24T17:47:42Z</dc:date>
    </item>
    <item>
      <title>Re: 498 Invalid Token error with esriConfig.apiKey</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1509474#M85105</link>
      <description>&lt;P&gt;oops forgot to show part of my code&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;import esriConfig from '@arcgis/core/config';
import Map                          from '@arcgis/core/Map';
import MapView                      from '@arcgis/core/views/MapView';

esriConfig.apiKey = "xyzxy";
//creates the map
const map = new Map({
  basemap: "arcgis-light-gray", // Basemap layer service
});

//creates the MapView
const view = new MapView({
  map: map,
  center: [-98.0932, 38.232], // Longitude, latitude
  zoom: 4, // Zoom level
  container: 'viewDiv', // Div element
  popup: {
      autoOpenEnabled: false
  }
});

&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Jul 2024 18:06:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1509474#M85105</guid>
      <dc:creator>WebDevelopers</dc:creator>
      <dc:date>2024-07-24T18:06:50Z</dc:date>
    </item>
    <item>
      <title>Re: 498 Invalid Token error with esriConfig.apiKey</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1510389#M85112</link>
      <description>&lt;P&gt;Can you just confirm what you used to create the legacy and the new API key?&lt;BR /&gt;&lt;BR /&gt;There's still a bit of confusion about the API keys - was the new one generated from a Esri Location Platform account?&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jul 2024 03:31:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1510389#M85112</guid>
      <dc:creator>JamesIng</dc:creator>
      <dc:date>2024-07-26T03:31:57Z</dc:date>
    </item>
    <item>
      <title>Re: 498 Invalid Token error with esriConfig.apiKey</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1510582#M85116</link>
      <description>&lt;P&gt;I believe it was created with an Esri Location Platform account. I did finally get the base map working by adding updating the referers I set on the key, but I still could not get the feature layers to load.&lt;/P&gt;&lt;P&gt;I finally tried adding&amp;nbsp;`?f=pjson` to the feature layer URL, and then it worked. I then tried it again without the extra parameter, and it loaded. So I'm not sure why it required it to work or why it then worked when I removed the parameter.&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":thinking_face:"&gt;🤔&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But I have a functioning map now. Thank you for reaching out anyways!&lt;/P&gt;&lt;P&gt;Molly&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jul 2024 13:21:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/498-invalid-token-error-with-esriconfig-apikey/m-p/1510582#M85116</guid>
      <dc:creator>WebDevelopers</dc:creator>
      <dc:date>2024-07-26T13:21:42Z</dc:date>
    </item>
  </channel>
</rss>

