mirror of
https://framagit.org/veretcle/tootube.git
synced 2025-07-20 12:31:19 +02:00
06e5c5a5ba6158bbe1e35cc7ae80b4075d1ccde1
Obtain Authorization Token from Google
That the complicated part:
- create an OAuth2.0 application with authorization for Youtube DATA Api v3 Upload
- create a OAuth2.0 client with Desktop client
You’ll need:
- the
client_id
from your OAuth2.0 client - the
client_secret
from you OAuth2.0 client
Then enter in:
https://accounts.google.com/o/oauth2/v2/auth?client_id=XXX.apps.googleusercontent.com&redirect_uri=urn:ietf:wg:oauth:2.0:oob&scope=https://www.googleapis.com/auth/youtube.upload&response_type=code
And accept that your YouTube account might be modified. You’ll get a code then; enter this curl
post:
curl -s \
--request POST \
--data "code=[THE_CODE]&client_id=XXX.apps.googleusercontent.com&client_secret=[THE_CLIENT_SECRET]&redirect_uri=urn:ietf:wg:oauth:2.0:oob&grant_type=authorization_code" \
https://accounts.google.com/o/oauth2/token
You’ll get a Token. The only important part is the refresh_token
In your tootube.toml
config file, put the refresh_token
.
Languages
Rust
100%