mirror of
https://github.com/iv-org/invidious.git
synced 2024-09-07 10:02:50 +00:00
Move the default API key to a constant for clarity
This commit is contained in:
parent
f353589a53
commit
9e7c2dcdbb
@ -5,6 +5,8 @@
|
|||||||
module YoutubeAPI
|
module YoutubeAPI
|
||||||
extend self
|
extend self
|
||||||
|
|
||||||
|
private DEFAULT_API_KEY = "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8"
|
||||||
|
|
||||||
private ANDROID_APP_VERSION = "17.29.35"
|
private ANDROID_APP_VERSION = "17.29.35"
|
||||||
|
|
||||||
# Enumerate used to select one of the clients supported by the API
|
# Enumerate used to select one of the clients supported by the API
|
||||||
@ -24,25 +26,25 @@ module YoutubeAPI
|
|||||||
ClientType::Web => {
|
ClientType::Web => {
|
||||||
name: "WEB",
|
name: "WEB",
|
||||||
version: "2.20220804.07.00",
|
version: "2.20220804.07.00",
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "WATCH_FULL_SCREEN",
|
screen: "WATCH_FULL_SCREEN",
|
||||||
},
|
},
|
||||||
ClientType::WebEmbeddedPlayer => {
|
ClientType::WebEmbeddedPlayer => {
|
||||||
name: "WEB_EMBEDDED_PLAYER", # 56
|
name: "WEB_EMBEDDED_PLAYER", # 56
|
||||||
version: "1.20220803.01.00",
|
version: "1.20220803.01.00",
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "EMBED",
|
screen: "EMBED",
|
||||||
},
|
},
|
||||||
ClientType::WebMobile => {
|
ClientType::WebMobile => {
|
||||||
name: "MWEB",
|
name: "MWEB",
|
||||||
version: "2.20220805.01.00",
|
version: "2.20220805.01.00",
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "", # None
|
screen: "", # None
|
||||||
},
|
},
|
||||||
ClientType::WebScreenEmbed => {
|
ClientType::WebScreenEmbed => {
|
||||||
name: "WEB",
|
name: "WEB",
|
||||||
version: "2.20220804.00.00",
|
version: "2.20220804.00.00",
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "EMBED",
|
screen: "EMBED",
|
||||||
},
|
},
|
||||||
ClientType::Android => {
|
ClientType::Android => {
|
||||||
@ -54,19 +56,19 @@ module YoutubeAPI
|
|||||||
ClientType::AndroidEmbeddedPlayer => {
|
ClientType::AndroidEmbeddedPlayer => {
|
||||||
name: "ANDROID_EMBEDDED_PLAYER", # 55
|
name: "ANDROID_EMBEDDED_PLAYER", # 55
|
||||||
version: ANDROID_APP_VERSION,
|
version: ANDROID_APP_VERSION,
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "", # None?
|
screen: "", # None?
|
||||||
},
|
},
|
||||||
ClientType::AndroidScreenEmbed => {
|
ClientType::AndroidScreenEmbed => {
|
||||||
name: "ANDROID", # 3
|
name: "ANDROID", # 3
|
||||||
version: ANDROID_APP_VERSION,
|
version: ANDROID_APP_VERSION,
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "EMBED",
|
screen: "EMBED",
|
||||||
},
|
},
|
||||||
ClientType::TvHtml5ScreenEmbed => {
|
ClientType::TvHtml5ScreenEmbed => {
|
||||||
name: "TVHTML5_SIMPLY_EMBEDDED_PLAYER",
|
name: "TVHTML5_SIMPLY_EMBEDDED_PLAYER",
|
||||||
version: "2.0",
|
version: "2.0",
|
||||||
api_key: "AIzaSyAO_FJ2SlqU8Q4STEHLGCilw_Y9_11qcW8",
|
api_key: DEFAULT_API_KEY,
|
||||||
screen: "EMBED",
|
screen: "EMBED",
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user