Cookies showing up in Insomnia , not in Google Chrome cookie tab
Answered
American Bobtail posted this in #help-forum
American BobtailOP
Hi everyone,
I'm running a Next.js 14 project with app router. When testing the sign-in endpoint, I'm getting the auth cookies, as shown in Insomnia, but no cookie shows up in the Google Chrome cookie tab. When I try to expose the cookie, I also get null.
Any ideas of what might be causing the issue?
Thanks in advance!
I'm running a Next.js 14 project with app router. When testing the sign-in endpoint, I'm getting the auth cookies, as shown in Insomnia, but no cookie shows up in the Google Chrome cookie tab. When I try to expose the cookie, I also get null.
Any ideas of what might be causing the issue?
Thanks in advance!
Answered by Ray
you have to make the request on browser in order to store the cookies to it
17 Replies
American BobtailOP
Anyone? I'm stuck here. Tried eveything, from setting samesite to lax , to inserting secure, to deleting browsing data, cookies included. Nothing.
Insomnia still shows the cookies. For Chrome, they do not exist
Insomnia still shows the cookies. For Chrome, they do not exist
American BobtailOP
Yes,
@American Bobtail Yes,
could you show a screenshot of it?
American BobtailOP
Absolutely. Just give me a sec, pelase
@American Bobtail Click to see attachment
how do you make the request on browser?
American BobtailOP
I haven't implemented the sign in page, I have the endpoint written, and that's what I'm testing with Insomina.
Maybe I got this terribly wrong, but once I hit thta endpoint those cookies should from then on included in every request, right?
Maybe I got this terribly wrong, but once I hit thta endpoint those cookies should from then on included in every request, right?
@American Bobtail I haven't implemented the sign in page, I have the endpoint written, and that's what I'm testing with Insomina.
Maybe I got this terribly wrong, but once I hit thta endpoint those cookies should from then on included in every request, right?
you have to make the request on browser in order to store the cookies to it
Answer
if you make the request on Insomina, it only store on Insomina
American BobtailOP
I say this because that 's what was happening on Wednsday the cookie was being stored, even though I hadn't teh sign in page
*showing in Chrome cookie panel, thta is
@American Bobtail I say this because that 's what was happening on Wednsday the cookie was being stored, even though I hadn't teh sign in page
maybe you were working on other project?
and logined with next-auth?
American BobtailOP
No, this is the only project. In fcat I had quickly mocked up a sign in page and I noticed the cookie was missing, whereas before it was showing. Earlier this week I manually deleted that cookie, but that shouldn't have changed anything. I have also since cleared all cookies and nothign seems to work.
I will try hitting that endpoint with a quick sign in and see if I get the cookie
I will try hitting that endpoint with a quick sign in and see if I get the cookie
American BobtailOP
@Ray, I am happy to report the cookie is in!
Gosh, I could have sworn it was there even when I was hitting the endpoint just with Insomnia, but I have to eat crow 😄
Thank you very much for your guidance and time. Have a wonderful day!
Gosh, I could have sworn it was there even when I was hitting the endpoint just with Insomnia, but I have to eat crow 😄
Thank you very much for your guidance and time. Have a wonderful day!