Spotify ➤ MP3
• Run from Spotify 'Share Sheet' or copy the Spotify track URL and run this Shortcut
polaОтсканируй на iPhone, чтобы установить
• Run from Spotify 'Share Sheet' or copy the Spotify track URL and run this Shortcut. •This Shortcut can also be used on Apple Watch.
Что нового
Версия 1.0
First release
Что делает
Действий: 36-
CommentCreated by: @Pola219 Get More Useful Shortcuts in: https://routinehub.co/user/Pola219
-
CommentVersion 1.4
-
Dictionary
-
Get Contents of URLhttps://updatekit.mikebeas.com/v1
-
Get Dictionary Value
-
If
-
Choose from MenuNew version available. What's new: … Press UPDATE to download latest version. This is an important update. Do not skip!
-
Choose from MenuUPDATE
-
Open URLs
-
Stop This Shortcut
-
Choose from MenuSKIP
-
Nothing
-
Comment• Run from Spotify 'Share Sheet' or copy the Spotify track URL and run this Shortcut. •This Shortcut can also be used on Apple Watch.
-
If
-
URL
-
Expand URL
-
Set VariableiniLink
-
Split Text
-
Get Item from List
-
Set VariableResponse
-
List
-
Get Contents of URLhttps://spotifymate.com
-
Make HTML from Rich Text
-
Match Text
-
Split Text
-
Get Item from List
-
Get Item from List
-
Get Contents of URLhttps://spotifymate.com/action
-
Make HTML from Rich Text
-
Match Text
-
Get Item from List
-
URL…
-
Get Contents of URL…
-
If
-
Replace Text
-
Save File
Посмотреть как код
Все действия этой команды, записанные на Cherri — языке программирования для приложения «Быстрые команды». Отлично подходит, чтобы разобраться, как она работает.
#include 'actions/web'
#define color green
#define glyph musicNote
/*
Created by: @Pola219
Get More Useful Shortcuts in:
https://routinehub.co/user/Pola219
*/
// Version 1.4
const UPDATE = jsonRequest("https://updatekit.mikebeas.com/v1", "POST", {
"shortcut": {
"id": "17349",
"module": "routinehub",
"version": "1.4"
}
})
const Response = getValue(UPDATE, "update")
if Response == {
menu "New version available. \nWhat's new: \n{UPDATE['payload.notes']}\nPress UPDATE to download latest version. This is an important update. Do not skip!" {
item "UPDATE":
openURL(UPDATE['payload.download'])
stop()
item "SKIP":
}
}
/*
• Run from Spotify 'Share Sheet' or copy the Spotify track URL and run this Shortcut.
•This Shortcut can also be used on Apple Watch.
*/
if ShortcutInput {
const InputURL = url(ShortcutInput)
@iniLink = expandURL(InputURL)
const SplitText = splitText(@iniLink, ".")
getListItem(SplitText, 2)
@Response
list("spotify")
const ContentsOfURL = downloadURL("https://spotifymate.com")
makeHTML(ContentsOfURL)
const Matches = containsText(, "(?<=<input name=\")(.*?)(?=\" type=\"hidden\" value=\")(.*?)(?=\" \/>)")
const SplitText1 = splitText(Matches, """)
const Value = getListItem(SplitText1, 0)
const Key = getListItem(SplitText1, 0)
const ContentsOfURL1 = formRequest("https://spotifymate.com/action", "POST", {
"url": "{@iniLink}",
"{Key}": "{Value}"
})
makeHTML(ContentsOfURL1)
const Matches1 = containsText(, "(?<= href=\")[^\"]+(?=\" class=\"abutton is-success is-fullwidth\"><span><span>Download Mp3)")
getRandomItem(Matches1)
url()
const Filename = downloadURL()
if @Response contains "spotify" {
const Audioname = replaceText("SpotifyMate.com - ", "", Filename)
saveFile("{Audioname}.mp3", Filename)
}
}
Открыть в Cherri Playground
Декомпилировано с помощью cherri 2.3.0 (GPL-2.0). Перед компиляцией могут понадобиться небольшие исправления.
Оценки и отзывы
Написать отзыв–
из 5
★★★★★
★★★★
★★★
★★
★
0 ratings
Пока нет отзывов. Поделись мнением первым!
Реклама
Ещё от pola
Вам также может понравиться
Реклама