Http response headers in cloud function response

Hey!
I am trying to set http response headers on cloud functions’s responses, but I can’t find any way to do this.

The end-goal is that I’d like to run a cloud function that logs the user in and then sets a cookie in the response which will be stored in the browser. I already have the logging-in part of the solution working, so all that’s left is to set the response cookie.

In order to manage the responde header, you will have to create a custom express.js endpoint instead of using the cloud code function.