Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(Player): Add support for Proof of Origin tokens #708

Merged
merged 8 commits into from
Aug 8, 2024

Conversation

unixfox
Copy link
Contributor

@unixfox unixfox commented Jul 27, 2024

This PR adds the ability to configure po_token.

Fixes #674
Fixes #696

@unixfox
Copy link
Contributor Author

unixfox commented Jul 27, 2024

Maybe I should provide some instructions on how to generate that famous potoken? Like linking to https://github.com/iv-org/youtube-trusted-session-generator

But I have no idea where you would want that? The "option" section already contains a lot of things: https://github.com/LuanRT/YouTube.js?tab=readme-ov-file#options

@LuanRT
Copy link
Owner

LuanRT commented Jul 28, 2024

Usually, we add docs for things like this here. Just a link to invidious' po token generator in the readme would be more than enough.

@unixfox
Copy link
Contributor Author

unixfox commented Aug 1, 2024

@LuanRT I have added a link to invidious youtube-trusted-session-generator in the same "options" section in the README

Code is ready for review.

@MaksymPylypenko
Copy link

MaksymPylypenko commented Aug 6, 2024

Tried copying them from the browser:

po_token:"MnTFOHrx2ZbFMcUAqVR2f_PRzEIP5qfkbb-Kk6c5jcMbYqeGVSsbpkoEkfUlKN_NGbWnkUEFi-f3EFtq9mozm_mE_ZQLq2ljjVH3OjP2FZDBVEmheqvHTrDnN2ZmK6O9sdCeGi8BAixnidGaZTn0H_Do4K7N-g==",
visitor_data:"Cgs0T1RXZU11WVRDNCjmncq1BjIKCgJDQRIEGgAgJg%3D%3D"

Playback requests are still failing with 403

@LuanRT
Copy link
Owner

LuanRT commented Aug 6, 2024

@MaksymPylypenko
You'll have to add it to the videoplayback requests as well (pot query param), it won't work properly otherwise.

@LuanRT LuanRT changed the title Add ability to configure po_token feat(Player): Add support for Proof of Identity Tokens Aug 8, 2024
@LuanRT LuanRT changed the title feat(Player): Add support for Proof of Identity Tokens feat(Player): Add support for Proof of Identity tokens Aug 8, 2024
@LuanRT
Copy link
Owner

LuanRT commented Aug 8, 2024

Looks good and works like a charm. Merging.
@unixfox Thank you!

@LuanRT LuanRT merged commit c9f0ddd into LuanRT:main Aug 8, 2024
4 checks passed
@LuanRT LuanRT changed the title feat(Player): Add support for Proof of Identity tokens feat(Player): Add support for Proof of Origin tokens Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

<10.1.0> <LOGIN_REQUIRED> Allow passing poToken for unblock YouTube restrictions
3 participants