Allow the authentication key to be customisable defaults to uid

The use case is perhaps to change the auth key to `email` when in
preview because the uid's are different from production to preview.