I corrected it, but the response is still the same.
Well, you didn't even mention what the actual result was so I don't know.
Without actual URL we can't even test this ourselves.
So there you are on your own.
My only advice is to use the Developer tools and look if there is something else passed on when doing this in the browser.
You need to mimicks this exactly.
It's also possible the cookie is only valid 1 time.
In that case you would need to create the cookie yourself with exactly the same code (converted to FPC).