-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat(poToken_generator.py): Added a script to generate poToken and updated requirements.txt. * fix(application.yml): Added poToken configuration option. * docs(README.md): Added poToken generation tutorial and Pterodactyl egg setup instructions. * refactor(poToken_generator.py): resolve check * docs(Readme.md): A more detailed description of the tutorial on generating poToken and added Support group invite link. * Update(player.png, player-en.png): new UI
- Loading branch information
1 parent
6e46dfa
commit 2107681
Showing
6 changed files
with
129 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,74 +1,65 @@ | ||
server: # REST and WS server | ||
port: 2333 | ||
address: 0.0.0.0 | ||
lavalink: | ||
server: | ||
password: "youshallnotpass" | ||
sources: | ||
youtube: false | ||
bandcamp: true | ||
soundcloud: true | ||
twitch: true | ||
vimeo: true | ||
http: true | ||
local: false | ||
filters: | ||
volume: true | ||
equalizer: true | ||
karaoke: true | ||
timescale: true | ||
tremolo: true | ||
vibrato: true | ||
distortion: true | ||
rotation: true | ||
channelMix: true | ||
lowPass: true | ||
bufferDurationMs: 400 | ||
frameBufferDurationMs: 5000 | ||
opusEncodingQuality: 10 | ||
resamplingQuality: HIGH | ||
trackStuckThresholdMs: 10000 | ||
useSeekGhosting: true | ||
youtubePlaylistLoadLimit: 6 | ||
playerUpdateInterval: 5 | ||
youtubeSearchEnabled: true | ||
soundcloudSearchEnabled: true | ||
gc-warnings: true | ||
plugins: | ||
- dependency: "dev.lavalink.youtube:youtube-plugin:1.5.2" | ||
snapshot: false | ||
|
||
plugins: | ||
youtube: | ||
enabled: true | ||
allowSearch: true | ||
allowDirectVideoIds: true | ||
allowDirectPlaylistIds: true | ||
clients: [ "MUSIC", "ANDROID", "WEB" ] | ||
|
||
metrics: | ||
prometheus: | ||
enabled: false | ||
endpoint: /metrics | ||
|
||
plugins: | ||
- dependency: dev.lavalink.youtube:youtube-plugin:1.7.2 | ||
snapshot: false | ||
server: | ||
bufferDurationMs: 400 | ||
filters: | ||
channelMix: true | ||
distortion: true | ||
equalizer: true | ||
karaoke: true | ||
lowPass: true | ||
rotation: true | ||
timescale: true | ||
tremolo: true | ||
vibrato: true | ||
volume: true | ||
frameBufferDurationMs: 5000 | ||
gc-warnings: true | ||
opusEncodingQuality: 10 | ||
password: youshallnotpass | ||
playerUpdateInterval: 5 | ||
resamplingQuality: HIGH | ||
soundcloudSearchEnabled: true | ||
sources: | ||
bandcamp: true | ||
http: true | ||
local: false | ||
soundcloud: true | ||
twitch: true | ||
vimeo: true | ||
youtube: false | ||
trackStuckThresholdMs: 10000 | ||
useSeekGhosting: true | ||
youtubePlaylistLoadLimit: 6 | ||
youtubeSearchEnabled: true | ||
logging: | ||
file: | ||
path: ./logs/ | ||
|
||
level: | ||
root: INFO | ||
lavalink: INFO | ||
|
||
request: | ||
enabled: true | ||
includeClientInfo: true | ||
includeHeaders: false | ||
includeQueryString: true | ||
includePayload: true | ||
maxPayloadLength: 10000 | ||
|
||
|
||
logback: | ||
rollingpolicy: | ||
max-file-size: 1GB | ||
max-history: 30 | ||
file: | ||
path: ./logs/ | ||
level: | ||
lavalink: INFO | ||
root: INFO | ||
logback: | ||
rollingpolicy: | ||
max-file-size: 1GB | ||
max-history: 30 | ||
request: | ||
enabled: true | ||
includeClientInfo: true | ||
includeHeaders: false | ||
includePayload: true | ||
includeQueryString: true | ||
maxPayloadLength: 10000 | ||
metrics: | ||
prometheus: | ||
enabled: false | ||
endpoint: /metrics | ||
plugins: | ||
youtube: | ||
pot: | ||
token: "Paste your po_token here" | ||
visitorData: "paste your visitor_data here" | ||
server: | ||
address: 0.0.0.0 | ||
port: 2333 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
from nodriver import start, cdp, loop | ||
import json | ||
import sys | ||
|
||
|
||
async def main(): # pylint: disable=W0613 | ||
browser = await start(headless=False) | ||
print("[INFO] launching browser.") | ||
tab = browser.main_tab | ||
tab.add_handler(cdp.network.RequestWillBeSent, send_handler) | ||
await browser.get('https://www.youtube.com/embed/jNQXAC9IVRw') | ||
await tab.wait(cdp.network.RequestWillBeSent) | ||
button_play = await tab.select("#movie_player") | ||
await button_play.click() | ||
await tab.wait(cdp.network.RequestWillBeSent) | ||
print("[INFO] waiting additional 30 seconds for slower connections.") | ||
await tab.sleep(30) | ||
|
||
|
||
async def send_handler(event: cdp.network.RequestWillBeSent): # pylint: disable=W0613 | ||
if "/youtubei/v1/player" in event.request.url: | ||
post_data = event.request.post_data | ||
post_data_json = json.loads(post_data) | ||
print("visitor_data: " + post_data_json["context"]["client"]["visitorData"]) | ||
print("po_token: " + post_data_json["serviceIntegrityDimensions"]["poToken"]) | ||
sys.exit(0) | ||
return | ||
|
||
|
||
if __name__ == '__main__': | ||
loop().run_until_complete(main()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters