Whitelisting by user agent

I want to add the Layer0 user-agent to my whitelist. Does layer 0 send a specific user-agent? Where I can find it or override?

Whitelisting by user agents is not secure - anybody can fake a user agent. Instead you should whitelist our IPs (Layer0 Documentation - Custom Domains & SSL). As an additional measure, some developers include a secret value that is injected into a (secret) request header and then verified by their own backend upstream.

Regarding user-agent header, Layer0 platform does not modify it in any way, but rather passes it through to your code as it was received. If you want to set it yourself through our router you can do something like this:

router
  .match('/:splat*', ({ setRequestHeader }) => {
    setRequestHeader('user-agent', '<new value>')
  })

If you just want to update the header, to say add a suffix to it, you can use updateRequestHeader instead.

router
  .match('/:splat*', ({ updateRequestHeader }) => {
    updateRequestHeader('user-agent', /^(.*)$/, '$1, <suffix>')
  })