# Unable to access Cumulocity API via Postman

**URL:** <https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873>\
**Category:** Forum\
**Tags:** cumulocity\
**Created:** [February 1, 2022, 6:31am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873 "2022-02-01T06:31:58Z")\
**Posts on this page:** 6\
**Page:** 2

<div class="post-metadata">

**Author:** ![m.stange](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/m.stange/32/21703_2.png) [@m.stange](https://community.cumulocity.com/u/m.stange)\
**Post date:** [March 21, 2022, 9:27am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873/22 "2022-03-21T09:27:43Z")

</div>

username:password

try to make a new user with a username without “@”. we had also trouble before when using a email address.

make a user named “api”  
password: “api12345”  
and use the token “Basic YXBpOmFwaTEyMzQ1”

if that one works, you are on the right way

Best regards

Mirko

---

<div class="post-metadata">

**Author:** ![yousef.okasha](https://avatars.discourse-cdn.com/v4/letter/y/71c47a/32.png) [@yousef.okasha](https://community.cumulocity.com/u/yousef.okasha)\
**Post date:** [March 21, 2022, 10:00am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873/23 "2022-03-21T10:00:08Z")

</div>

I can’t change the username this option isn’t available. is there another solution?

---

<div class="post-metadata">

**Author:** ![Christian\_Guether1](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/christian_guether1/32/14848_2.png) [@Christian\_Guether1](https://community.cumulocity.com/u/Christian_Guether1)\
**Post date:** [March 21, 2022, 10:43am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873/24 "2022-03-21T10:43:52Z")

</div>

Hi Yousef,

often this error occurs because of some typo in the username or the password, when creating the base64 encoded. Did you use a specific tool or page to generate the base64 encoded string? Have you used Postman to set the Authorization using the _Authorization_ tab:

 ![image](https://europe1.discourse-cdn.com/flex005/uploads/cumulocity/original/3X/8/f/8f0d60204822fe097e20d8d5cb4d8055c11639fb.png)

You could also double check your base64 token with the one used in Cumulocity using the Developer Tools of your browser. The Developer Tools should provide a Network tab, which displays all the traffic for a specific browser tab. Navigate in Cumulocity to any application or page to execute a couple of requests. Pick an HTTP request to Cumulocity and check the request headers for the Authorization token and compare it to the one you are using in Postman:

 ![image](https://europe1.discourse-cdn.com/flex005/uploads/cumulocity/original/3X/9/6/960f5195cf81780b5bfccaee6c78bc545aaeac5c.png)

Best regards  
Christian

---

<div class="post-metadata">

**Author:** ![yousef.okasha](https://avatars.discourse-cdn.com/v4/letter/y/71c47a/32.png) [@yousef.okasha](https://community.cumulocity.com/u/yousef.okasha)\
**Post date:** [March 21, 2022, 11:26am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873/25 "2022-03-21T11:26:14Z")

</div>

Hi, Christain

I’ve used this tool to encode the base64 encoded [https://www.base64encode.org/](https://www.base64encode.org/) but previously I’ve used the base64 provided by the ubuntu terminal but both of them generated the same string. I encoded this one: env641673/yousef.okasha@techsa.io:“, I’ve also used the authorization tab that you used in the attached picture but also got a response with 401 status code.PASSWORD”

 ![Screenshot (17)](https://europe1.discourse-cdn.com/flex005/uploads/cumulocity/original/3X/b/7/b76ed405f9b0b329ca5711ecd5a808fae9c57eda.png)  
As you can see there is no Authorization header in the request headers, there are only cookies.

Thank you

---

<div class="post-metadata">

**Author:** ![Christian\_Guether1](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/christian_guether1/32/14848_2.png) [@Christian\_Guether1](https://community.cumulocity.com/u/Christian_Guether1)\
**Post date:** [March 29, 2022, 8:55am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873/26 "2022-03-29T08:55:50Z")

</div>

Hi Yousef,

you are using a Cumulocity instance within softwareag.cloud, which uses SSO for authentication. Therefore, you don’t see the authorization header as authorization is handled via a token in the Cookie. That’s also the reason why Basic authentication doesn’t work for your current user, because the user is configured to sign in and authenticate via SSO.

The easiest solution for your issue is to create a new local user within your Cumulocity tenant, which then will use Basic authentication. How to managed and add a new user is described [here](https://cumulocity.com/guides/users-guide/administration/#to-add-a-user). I suggest to create a user with a preconfigured password, who has the role `admin` assigned:

 ![image](https://europe1.discourse-cdn.com/flex005/uploads/cumulocity/original/3X/d/9/d9cb7bacf09f4c7a800f4119b5d16a98053b14a1.png)

The role `admin` allows the user to access all available APIs. Once you have created this user you can his credentials (username and password) to generate the Basic auth header (or simply copy it from the Dev Tools, when you sign in with the newly created user).

Best regards  
Christian

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/system/32/31990_2.png) [@system](https://community.cumulocity.com/u/system)\
**Post date:** [June 27, 2022, 8:55am UTC](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873/27 "2022-06-27T08:55:57Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.

[Previous page](https://community.cumulocity.com/t/unable-to-access-cumulocity-api-via-postman/3873.md?page=1)
