<?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: Get Basemaps without exposing API Key in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608507#M87008</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/901163"&gt;@LightmobieLDA&lt;/a&gt;,&amp;nbsp;thanks for posting your question here. While we recommend using an API Key with basemaps in our tutorials, API Keys are not required for every basemap.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Legacy basemaps still work without an API Key, like `gray` or `gray-vector` as seen in this example:&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/sample-code/sandbox/?sample=query-attribute-bins" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/sample-code/sandbox/?sample=query-attribute-bins&lt;/A&gt;&lt;/P&gt;&lt;P&gt;And documented here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html#basemap:~:text=The%20legacy%20basemaps%20can%20be%20accessed%20using%20the%20basemap%20id%20in%20the%20table%20below" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html#basemap:~:text=The%20legacy%20basemaps%20can%20be%20accessed%20using%20the%20basemap%20id%20in%20the%20table%20below&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 23 Apr 2025 14:44:52 GMT</pubDate>
    <dc:creator>Noah-Sager</dc:creator>
    <dc:date>2025-04-23T14:44:52Z</dc:date>
    <item>
      <title>Get Basemaps without exposing API Key</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608480#M87006</link>
      <description>&lt;P&gt;I'm building an aplication using leaflet JS&amp;nbsp;for a company and i want to use the esri basemaps URL to get the tiles for the map. By following the tutorials I got a solution where I created an API key that I use to get this information, but it exposes the API Key in the js. I did not like this approach so I built an API endpoint that act as a middleware and joins the esri basemaps URL with the API key token. However this approach proves enificient since some HTTP get request take several seconds to return.&amp;nbsp;&lt;BR /&gt;I am using plain HTML and js with the library Leaflet, I may use the Esri-leaflet integration library but the problem persist.&lt;/P&gt;&lt;P&gt;Am I missing something, or is there another approach to solve this problem?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Apr 2025 14:18:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608480#M87006</guid>
      <dc:creator>LightmobieLDA</dc:creator>
      <dc:date>2025-04-23T14:18:55Z</dc:date>
    </item>
    <item>
      <title>Re: Get Basemaps without exposing API Key</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608507#M87008</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/901163"&gt;@LightmobieLDA&lt;/a&gt;,&amp;nbsp;thanks for posting your question here. While we recommend using an API Key with basemaps in our tutorials, API Keys are not required for every basemap.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Legacy basemaps still work without an API Key, like `gray` or `gray-vector` as seen in this example:&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/sample-code/sandbox/?sample=query-attribute-bins" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/sample-code/sandbox/?sample=query-attribute-bins&lt;/A&gt;&lt;/P&gt;&lt;P&gt;And documented here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html#basemap:~:text=The%20legacy%20basemaps%20can%20be%20accessed%20using%20the%20basemap%20id%20in%20the%20table%20below" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html#basemap:~:text=The%20legacy%20basemaps%20can%20be%20accessed%20using%20the%20basemap%20id%20in%20the%20table%20below&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Apr 2025 14:44:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608507#M87008</guid>
      <dc:creator>Noah-Sager</dc:creator>
      <dc:date>2025-04-23T14:44:52Z</dc:date>
    </item>
    <item>
      <title>Re: Get Basemaps without exposing API Key</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608836#M87021</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/169842"&gt;@Noah-Sager&lt;/a&gt;, thanks for the rapid response. The company will use the application that I'm building as a commercial product, and it was my understanding that the API key was necessary to keep track of the credits that are being used. I was able to translate the code that you provided to our use case (thank you very much), but my biggest concern is the legal aspect. How do you know that is my account that is requesting the an API Request without the token?&lt;/P&gt;</description>
      <pubDate>Thu, 24 Apr 2025 09:37:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1608836#M87021</guid>
      <dc:creator>LightmobieLDA</dc:creator>
      <dc:date>2025-04-24T09:37:35Z</dc:date>
    </item>
    <item>
      <title>Re: Get Basemaps without exposing API Key</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1609173#M87033</link>
      <description>&lt;P&gt;If a service does not require any kind of authentication (like a log-in or an API key), that means it doesn't use your credits and it doesn't know who is sending requests. Weather or not you can use these free-of-charge services in a commercial product depends on the license. My guess is that it would be ok to use esri default basemaps. You should contact Esri support to make sure.&lt;/P&gt;</description>
      <pubDate>Fri, 25 Apr 2025 08:42:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1609173#M87033</guid>
      <dc:creator>Edvinas_S</dc:creator>
      <dc:date>2025-04-25T08:42:09Z</dc:date>
    </item>
    <item>
      <title>Re: Get Basemaps without exposing API Key</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1609283#M87046</link>
      <description>&lt;P&gt;Unfortunately, I don't know much about the legal aspects. I would take&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/413145"&gt;@Edvinas_S&lt;/a&gt;'s recommendation and account your account manager with Esri. We do have this page on licensing and attribution for the JS SDK:&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/licensing/" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/licensing/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Apr 2025 16:50:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1609283#M87046</guid>
      <dc:creator>Noah-Sager</dc:creator>
      <dc:date>2025-04-25T16:50:40Z</dc:date>
    </item>
    <item>
      <title>Re: Get Basemaps without exposing API Key</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1609890#M87059</link>
      <description>&lt;P&gt;Thank you very much for your feedback and help&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/413145"&gt;@Edvinas_S&lt;/a&gt;&amp;nbsp; and&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/169842"&gt;@Noah-Sager&lt;/a&gt;. I will follow your advise.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Apr 2025 09:23:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/get-basemaps-without-exposing-api-key/m-p/1609890#M87059</guid>
      <dc:creator>LightmobieLDA</dc:creator>
      <dc:date>2025-04-29T09:23:29Z</dc:date>
    </item>
  </channel>
</rss>

