Which token from firebase to use to authenticate?

I need to use http request to create a record in firebase because I need to make the document id the uid of the user. Which token is used to authenticate rest api calls on behalf of the user? I know I need to add a header Bearer (someToken) but I am unsure which token returned from a firebase auth request or from a firebase login to use? Does anyone know?

Some time ago I ran into this question as well.

Here is the documentation how I do it now: Firestore; security rules : if request.auth != null; - #21 by stayfoolish