Regular Expressions 101

Spon⁠sors

Community Library

Community Library Entry

0

Regular ExpressionOpen Workspace

r'''
(?:http(?:s)?:\/\/)?(?:(?:www)\.(?:tiktok\.com)(?:\/)(?!foryou)(@[a-zA-z0-9]+)(?:\/)(?:video)(?:\/)([\d]+)|(?:m)\.(?:tiktok\.com)(?:\/)(?!foryou)(?:v)(?:\/)?(?=([\d]+)\.html))
'''
gm

Description
Created·2022-06-17 02:26
Type·Match
Flavor·Python

Extract the id only from the necessary and supported links oembed tool provided by tiktok to embed these videos

Submitted by Oscar David Garces Gomez - FB@soyvillareal
Open Workspace