Passing your own accessToken

Please tell me if it is possible to somehow transfer a custom accesstoken to the server so that when a player enters, check the accesstoken on the server with the database and decide whether to grant access or not. If this is not possible, is it possible to implement player authentication when entering the server through uuid?