Generate access tokens with custom permissions with no frontend

I have set the connection to password and set the directory to username-password-connection.