I'm using the fetch API for making requests and fetch sadly forbids the Cookie header from getting passed. Will be looking into how I can bypass this.
Scratch that. I wasn't thinking clearly. I ran the call from restfox.dev, and it's another domain, of course. You'd need to write your own http client to get around it.