# How to set auth token cookie fetched from browser?

**URL:** <https://community.postman.com/t/how-to-set-auth-token-cookie-fetched-from-browser/61639>\
**Category:** Help Hub\
**Tags:** authentication\
**Created:** [May 29, 2024, 9:16pm UTC](https://community.postman.com/t/how-to-set-auth-token-cookie-fetched-from-browser/61639 "2024-05-29T21:16:35Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![amogh-daryapurkar](https://avatars.discourse-cdn.com/v4/letter/a/7cd45c/32.png) [@amogh-daryapurkar](https://community.postman.com/u/amogh-daryapurkar)\
**Post date:** [May 29, 2024, 9:16pm UTC](https://community.postman.com/t/how-to-set-auth-token-cookie-fetched-from-browser/61639/1 "2024-05-29T21:16:35Z")

</div>

Hello,

I am trying to create a request that requires an auth-token in the header for authentication. The auth-token is stored as a cookie, which can be obtained by accessing [Redirecting](https://admin.hlx.page/auth/microsoft) . After redirection to [https://admin.hlx.page/profile](https://admin.hlx.page/profile), you can find the cookie in the response. I need to use this cookie value in the header for my request. I’m not very experienced with Postman, so any guidance would be greatly appreciated.

Note: The [Redirecting](https://admin.hlx.page/auth/microsoft) is behind oauth and works fine when you are already logged in browser.

---

<div class="post-metadata">

**Author:** ![gbadebo-bello](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/gbadebo-bello/32/12175_2.png) [@gbadebo-bello](https://community.postman.com/u/gbadebo-bello)\
**Post date:** [May 30, 2024, 10:19am UTC](https://community.postman.com/t/how-to-set-auth-token-cookie-fetched-from-browser/61639/2 "2024-05-30T10:19:38Z")

</div>

Hi @amogh-daryapurkar. Welcome to the Postman Community.

Since this uses OAuth, Postman has OAuth authorization helpers that helps you manage the redirection automatically. But you have to set the redirect URL to a URL Postman provides or autofills for you, this enables Postman easily get the authorization grant after redirection.

You can learn how to use this authorization helper [here](https://learning.postman.com/docs/sending-requests/authorization/oauth-20/)

---

<div class="post-metadata">

**Author:** ![amogh-daryapurkar](https://avatars.discourse-cdn.com/v4/letter/a/7cd45c/32.png) [@amogh-daryapurkar](https://community.postman.com/u/amogh-daryapurkar)\
**Post date:** [June 25, 2024, 4:06pm UTC](https://community.postman.com/t/how-to-set-auth-token-cookie-fetched-from-browser/61639/3 "2024-06-25T16:06:12Z")

</div>

Thank you for your reply @gbadebo-bello !

But this is little different than OAuth so that document is not helping here much.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/system/32/29796_2.png) [@system](https://community.postman.com/u/system)\
**Post date:** [July 25, 2024, 4:07pm UTC](https://community.postman.com/t/how-to-set-auth-token-cookie-fetched-from-browser/61639/4 "2024-07-25T16:07:07Z")

</div>

Closed on July 25, 2024, 4:07pm UTC

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