# Tiktok Obsidian

> Turn a TikTok URL into a markdown note in an Obsidian vault using the TikToker whisper-scripts (local Whisper + yt-dlp). Use when the user pastes a TikTok link in Claude Code and wants transcription saved to Obsidian, or to batch-ingest TikToks without using the Obsidian UI.

- Skill: `martin-pv/tiktok-obsidian` (Agent Skill)
- Install (CLI): `npx skillmds@latest add martin-pv/tiktok-obsidian`
- Raw SKILL.md: https://api.skillmd.com/api/skills/martin-pv/tiktok-obsidian/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Docs & Writing
- Author: martin-pv (https://skillmd.com/u/martin-pv)
- Updated: 2026-09-22
- Page: https://skillmd.com/skills/martin-pv/tiktok-obsidian

---


# TikTok → Obsidian (Claude Code)

The Obsidian **TikToker plugin** only runs inside Obsidian. This skill uses the **same scripts** the plugin ships with (`whisper-scripts/`) so Claude Code can produce notes on disk that Obsidian will show as soon as the vault refreshes.

## What you cannot do from Claude Code

- Call Obsidian plugin APIs, modals, or “Save via TikToker” inside the app.
- Get the exact same rich metadata/embed as the plugin unless you duplicate its oEmbed + template logic.

## What this skill does

1. Run local transcription (audio via `yt-dlp`, text via `faster-whisper` in the plugin venv).
2. Write a `.md` file into the vault with YAML frontmatter + `## Transcription`.

## Configuration (edit if your paths differ)

| Variable | Default |
|----------|---------|
| Vault root | `/Users/martinp/clawd/SecondBrain` |
| Notes folder | `Tiktoks` (matches common TikToker `outputFolder`) |
| Script | `$VAULT/.obsidian/plugins/tiktoker/whisper-scripts/tiktok2text.sh` |
| Browser for cookies | `safari` (use `-b chrome` if TikTok login is only in Chrome) |

## Procedure (run in terminal)

1. **Transcribe** (stdout is the transcript; stderr has `Saved: …txt`):

```bash
WHISPER="/Users/martinp/clawd/SecondBrain/.obsidian/plugins/tiktoker/whisper-scripts/tiktok2text.sh"
URL="PASTE_TIKTOK_URL_HERE"
"$WHISPER" -o /tmp "$URL"
```
(Default is Safari cookies; same as `tiktok2text.sh`. For Chrome: add `-b chrome`.)

Use `-o /tmp` so the `.txt` lands in `/tmp` and is easy to find, or omit `-o` and read the path from stderr (`Saved: …`).

2. **Video id** from the URL: the numeric segment after `/video/` (e.g. `7591638352298855694`).

3. **Build the note** at  
   `$VAULT/Tiktoks/YYYY-MM-DD tiktok <video_id>.md`  
   (or any naming the user prefers) with:

```markdown
---
url: "CANONICAL_TIKTOK_URL"
date: YYYY-MM-DD
---

## Transcription

PASTE_TRANSCRIPT_FROM_STDOUT_OR_TXT_FILE
```

4. Strip tracking junk from `url` in frontmatter if you want cleaner links (optional): keep up to `/video/<id>`.

## Reliability

- **Cookies:** Default is Safari. If download fails, try `-b chrome` or ensure the user is logged into TikTok in that browser (Terminal may need Full Disk Access to read Safari cookies).
- **PATH:** If `python3` / `yt-dlp` fail when not in Obsidian, run from a normal Terminal (or use the same PATH fix as in `tiktok2text.sh` — Homebrew + `~/.pyenv/shims`).
- **Timeouts:** Long videos take longer; Whisper model is controlled with `-m tiny|base|small|…` (default in script is `base`).

## Optional: match TikToker embed

To mirror the plugin’s iframe note body, fetch oEmbed (`https://www.tiktok.com/oembed?url=...`) and add the returned `html` in a `## Video` section above `## Transcription`. The plugin does more (author, hashtags); oEmbed gives title/author/thumbnail/embed HTML only.

