Get request headers from received request in fetch event.

I am trying to get the headers of received requests, but end up getting null for the following code:
export default {
    async fetch(request, env, ctx) {
        console.log(JSON.stringify(request.headers));
    }
}
Was this page helpful?