I was wondering if it would be possible to call my API from the getServerSideProps like:
await axios.post('/api/auth/refresh-token');
and use previously set user cookies on the server-side.
Right now, whenever I do that, the server thinks it's a different session and cookies are not available.
I use next-iron-session and if I call the API on the client-side everything is fine and session is available.