# Cesium Ion reporting 401 Unauthorized

**URL:** <https://community.cesium.com/t/cesium-ion-reporting-401-unauthorized/35264>\
**Category:** Cesium ion\
**Created:** [September 18, 2024, 5:23pm UTC](https://community.cesium.com/t/cesium-ion-reporting-401-unauthorized/35264 "2024-09-18T17:23:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ngaray](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/ngaray/32/14000_2.png) [@ngaray](https://community.cesium.com/u/ngaray)\
**Post date:** [September 18, 2024, 5:23pm UTC](https://community.cesium.com/t/cesium-ion-reporting-401-unauthorized/35264/1 "2024-09-18T17:23:05Z")

</div>

I am getting a 401 error every time I use a token from my Ion account.

I am on the following versions, and at present the project requires me to stay on 1.117.0  
@cesium/engine: 9.1.0  
@cesium/widgets: 6.1.0  
cesium: 1.117.0

---

<div class="post-metadata">

**Author:** ![ngaray](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/ngaray/32/14000_2.png) [@ngaray](https://community.cesium.com/u/ngaray)\
**Post date:** [September 18, 2024, 5:33pm UTC](https://community.cesium.com/t/cesium-ion-reporting-401-unauthorized/35264/2 "2024-09-18T17:33:49Z")

</div>

Curiously, I am seeing this at the bottom of the screen **This application is using Cesium’s default ion access token. Please assign _Cesium.Ion.defaultAccessToken_ with an access token from your ion account before making any Cesium API calls. You can sign up for a free ion account at [https://cesium.com](https://cesium.com/).**

But, ironically, I am not using Cesium’s default ion access token, I have specified one I generated.

Update: I am actually seeing 2 requests for access and I don’t know why, the first is successful and uses the token I provided, the second is failing and using maybe the _defaultAccessToken_ for the current version of Cesium.

 ![image](https://global.discourse-cdn.com/cesium/original/3X/e/f/efcbcd7f93721785225ba739129318f00c70f3fd.png)

---

<div class="post-metadata">

**Author:** ![Gabby\_Getz](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/gabby_getz/32/7838_2.png) [@Gabby\_Getz](https://community.cesium.com/u/Gabby_Getz)\
**Post date:** [September 19, 2024, 1:27pm UTC](https://community.cesium.com/t/cesium-ion-reporting-401-unauthorized/35264/4 "2024-09-19T13:27:37Z")

</div>

Hello there,

Thanks for reaching out about this. We want to confirm what the issue may be, and get it fixed if appropriate.

I am not able to replicate this behavior in an environment like [Sandcastle](https://sandcastle.cesium.com/). It may have to do with your specific build configuration. Would you be able to provide a minimal code example which replicates the issue?

Thank you!  
Gabby

---

<div class="post-metadata">

**Author:** ![ngaray](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/ngaray/32/14000_2.png) [@ngaray](https://community.cesium.com/u/ngaray)\
**Post date:** [September 25, 2024, 1:08pm UTC](https://community.cesium.com/t/cesium-ion-reporting-401-unauthorized/35264/5 "2024-09-25T13:08:30Z")

</div>

Hi Gabby, unfortunately I am unable to provide a sample. This integration is part of a larger project framework for which I do not own the source. I did reach out over email to see if we could coordinate something.

Thanks,  
Nick
