ShareShortcuts
„DTikTok“ forken

Hast du auf Basis dieses Kurzbefehls etwas Neues erstellt? Teile ihn als Fork: Er wird zu deinem eigenen Kurzbefehl, den du selbst verwaltest, und beide Seiten verlinken aufeinander, damit aabbccddeeffgg2000 die Anerkennung erhält.

  1. 1Lade den Kurzbefehl und ändere ihn in der Kurzbefehle-App. Gib ihm einen eigenen Namen.
  2. 2Teile ihn in der Kurzbefehle-App und kopiere den iCloud-Link.
  3. 3Komm hierher zurück, füge den Link ein und beschreibe, was sich geändert hat, z. B. „Einen Schritt hinzugefügt, der Apple Intelligence nutzt, um den Text zu personalisieren.“
Downloads
60K
Gesichert
0
Aktionen
55
Kategorie
API
Version
1.0
Sprache
EN

Vorschau

Neue Funktionen

Version 1.0

First release

Versionsverlauf
1.0 7. Dez 2022

First release

Was er macht

55 Aktionen
  1. Comment
    DTikTok made by user/heismauri on RoutineHub
  2. Dictionary
  3. Get Contents of URL
    https://routinehub.co/api/v1/shortcuts/…/versions/latest
  4. Get Dictionary Value
  5. If
  6. Text
  7. Choose from Menu
    …
  8. Choose from Menu
    Update now
  9. URL
    https://routinehub.co/download/…
  10. Open URLs
  11. Choose from Menu
    Update later
  12. If
  13. Set Variable
    url
  14. If
  15. Get Clipboard
  16. Set Variable
    url
  17. Expand URL
  18. Match Text
  19. URL
    ……
  20. Get Contents of URL
    …
  21. Make HTML from Rich Text
  22. Match Text
  23. Get Dictionary from Input
  24. Choose from Menu
    What would you like to download?
  25. Choose from Menu
    Original video
  26. Set Variable
    original
  27. Choose from Menu
    Unwatermarked video
  28. Set Variable
    unwatermarked
  29. Choose from Menu
    Audio
  30. Set Variable
    music
  31. Choose from Menu
  32. Show Notification
    Downloading "…" by …
  33. Get Contents of URL
    …
  34. Get Type
  35. If
  36. Set Variable
    video
  37. If
  38. Get Contents of URL
    …
  39. Get Type
  40. If
  41. Set Variable
    video
  42. If
  43. Get Contents of URL
    …
  44. Get Type
  45. If
  46. Set Variable
    video
  47. If
  48. Show Notification
    Error - This TikTok cannot be downloaded
  49. Stop This Shortcut
  50. Set Name
  51. Quick Look
  52. If
  53. Save File
  54. If
  55. Save to Photo Album

Als Code ansehen
Beta

Jede Aktion dieses Kurzbefehls als Cherri ausgeschrieben, eine Programmiersprache für Kurzbefehle. Ideal, um zu lernen, wie er funktioniert.

#include 'actions/web'
#define color red
#define glyph filmstrip

/*
DTikTok
made by user/heismauri on RoutineHub
*/
const Dictionary = {
	"DTikTok": {
		"api": "https://godownloader.com/api/download",
		"dictionary": "(?\u003c=\u003cscript id=\"__NEXT_DATA__\" type=\"application\\/json\"\u003e)(.*?)(?=\u003c\\/script\u003e)",
		"id": "(?\u003c=(v\\/|video\\/))\\d+",
		"main": "https://godownloader.com/tiktok/"
	},
	"ID": 5870,
	"Name": "DTikTok",
	"Version": "2.1.1"
}
const ContentsOfURL = downloadURL("https://routinehub.co/api/v1/shortcuts/{Dictionary['ID']}/versions/latest")
const LatestVersion = getValue(ContentsOfURL, "Version")

if LatestVersion != Dictionary['Version'] {
	const UpdatePrompt = "An update is available for \\"{Dictionary['Name']}\\"\n\nRelease notes: \n{ContentsOfURL['Notes']}\n\n{Dictionary['Version']} → {ContentsOfURL['Version']}"
	menu UpdatePrompt {
	item "Update now":
		const URL = url("https://routinehub.co/download/{ContentsOfURL['id']}")
		openURL(URL)
	item "Update later":
	}
}

if ShortcutInput {
	@url = ShortcutInput
} else {
	getClipboard()
}
@url
expandURL(@url)
const id = containsText(, Dictionary['DTikTok.id'])
url("{Dictionary['DTikTok.main']}{id}")
const ContentsOfURL1 = downloadURL()
makeHTML(ContentsOfURL1, true)
const Matches = containsText(, Dictionary['DTikTok.dictionary'])

menu "What would you like to download?" {
item "Original video":
	@original = getDictionary(Matches)
item "Unwatermarked video":
	@unwatermarked = DTikTok['props.pageProps.token.nwm']
item "Audio":
	@music = DTikTok['props.pageProps.token.music']
item :
}
showNotification("Downloading \"{DTikTok['props.pageProps.data.title']}\" by {DTikTok['props.pageProps.data.author']}", Dictionary['Name'])
const ContentsOfURL2 = formRequest(Dictionary['DTikTok.api'], "POST", {
	"t": "{token}"
})
const Type = typeOf(ContentsOfURL2)

if Type contains "Media" {
	@video = ContentsOfURL2
} else {
	const ContentsOfURL3 = formRequest(Dictionary['DTikTok.api'], "POST", {
		"t": "{DTikTok['props.pageProps.token.hevc']}"
	})
	const Type1 = typeOf(ContentsOfURL3)
	if Type1 contains "Media" {
		@video = ContentsOfURL3
	} else {
		const ContentsOfURL4 = formRequest(Dictionary['DTikTok.api'], "POST", {
			"t": "{DTikTok['props.pageProps.token.wm']}"
		}, {})
		const Type2 = typeOf(ContentsOfURL4)
		if Type2 contains "Media" {
			@video = ContentsOfURL4
		} else {
			showNotification("Error - This TikTok cannot be downloaded", Dictionary['Name'])
			stop()
		}
	}
}
const RenamedItem = setName(@video, id)
quicklook(RenamedItem)

if RenamedItem['File Extension'] contains "mp3" {
	saveFilePrompt(RenamedItem)
} else {
	savePhoto(RenamedItem)
}
In Cherri Playground öffnen Mit cherri 2.3.0 (GPL-2.0) dekompiliert. Eventuell sind kleine Korrekturen nötig, bevor es kompiliert wird.

Bewertungen und Rezensionen

Rezension schreiben
–
von 5
★★★★★
★★★★
★★★
★★
★
0 ratings

No reviews yet. Be the first to share what you think!

Werbung

Das gefällt dir vielleicht auch

Alle anzeigen
Werbung