Install
openclaw skills install @robj1925/yt-timestamp-autoposterGenerate SEO-optimized YouTube timestamps from a YouTube URL or a raw transcript string, then optionally append them to the description of that specific video or your latest upload. Use when you need to create chapters for a YouTube video. Also use when the user asks to generate timestamps, append timestamps to YouTube, or process transcript text.
openclaw skills install @robj1925/yt-timestamp-autoposterTransforms a YouTube URL or a raw transcript string into SEO-optimized timestamps (chapters) powered by Gemini. Optionally appends the result directly to the description of a specific YouTube video or your latest upload via the YouTube Data API.
Before using this skill, ensure you have:
pip install youtube-transcript-api google-generativeai google-auth-oauthlib google-api-python-clientcredentials.json placed in scripts/ (only required for --post — download from Google Cloud Console as an OAuth 2.0 Desktop App client)--latest mode checks for existing timestamps before attempting to generate new onesFetches the transcript from the video, generates SEO timestamps, and optionally appends them to the description of that specific video.
# Generate only (view output)
python scripts/youtube_desc_generator.py --url "<youtube_url>" "<gemini_api_key>"
# Generate and post to that video
python scripts/youtube_desc_generator.py --url "<youtube_url>" "<gemini_api_key>" --post
Reads a raw transcript string, generates SEO timestamps, and optionally appends them to the description of your latest YouTube upload.
# Generate only (view output)
python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "<gemini_api_key>"
# Generate and post to latest video
python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "<gemini_api_key>" --post
Automatically fetches your most recent video, checks if timestamps already exist (to prevent duplicates), downloads the transcript, generates SEO timestamps, and optionally appends them to the description.
# Generate and post timestamps for your latest video (if they don't already exist)
python scripts/youtube_desc_generator.py --latest "<gemini_api_key>" --post
Examples:
python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY"
python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY" --post
python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "$GEMINI_API_KEY" --post
When using --transcript, the transcript must be a string with timestamps in MM:SS format, separated by newlines:
0:00 Welcome to this video about AI agents.
0:12 Today we're going to cover what an AI agent actually is.
1:00 Let me show you a live demo of an agent booking a flight.
...
When the user speaks naturally, map their intent to the correct command using the table below. Always extract the YouTube URL or transcript text from their message and substitute it into the command.
| What the user says | Command to run |
|---|---|
| "Create timestamps for my latest video" | python scripts/youtube_desc_generator.py --latest "$GEMINI_API_KEY" --post |
| "Generate timestamps for this video: https://youtu.be/abc123" | python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY" |
| "Create SEO chapters from this YouTube link: https://youtu.be/abc123" | python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY" |
| "Give me the timestamps for this video: https://youtu.be/abc123" | python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY" |
| "Generate timestamps for this video and post it: https://youtu.be/abc123" | python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY" --post |
| "Generate SEO timestamps and post them back to this video: https://youtu.be/abc123" | python scripts/youtube_desc_generator.py --url "https://youtu.be/abc123" "$GEMINI_API_KEY" --post |
| "Process this transcript text: 0:00 Welcome..." | python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "$GEMINI_API_KEY" |
| "Generate timestamps from my transcript text: 0:00 Welcome..." | python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "$GEMINI_API_KEY" |
| "Process my transcript text and post it to my latest video: 0:00 Welcome..." | python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "$GEMINI_API_KEY" --post |
| "Generate timestamps from my transcript and upload to YouTube: 0:00 Welcome..." | python scripts/youtube_desc_generator.py --transcript "0:00 Welcome..." "$GEMINI_API_KEY" --post |
Use these rules to determine which command to run when the intent is ambiguous:
--latest mode--url mode--transcript mode--post flag (Note: commands like "create timestamps for my latest video" imply updating it, so --post is added)--post → generate and print only, do not touch YouTube--transcript --post and --latest --post → always targets the latest upload on the channel--url --post → always targets that specific videoThe script returns a single clean block — no labels or extra text:
0:00 with keyword-rich labels and SEO suffix tags (e.g. (Tutorial), (Overview), (2026))Important: Output only the final timestamps. Do not include any introductory sentences, headings, labels, preamble, or commentary before or after the output.
URL mode:
youtube-transcript-apiMM:SS timestamps--post) Authenticates via OAuth2 and appends the new timestamps to that specific video's descriptionTranscript mode:
--post) Authenticates via OAuth2, finds your latest upload, and appends the new timestamps to its description--post only)credentials.json and place it in scripts/--post, a browser window will open for you to authorize accesstoken.pickle file will be saved automatically for future runsNo transcript available (URL mode):
--transcript mode with a manually prepared transcript stringTranscript text not loading (transcript mode):
MM:SS text formatGemini API errors:
gemini-3.1-flash-lite-preview--post not updating the video:
credentials.json is in the scripts/ directorytoken.pickle and re-authenticate if credentials have expiredWrong video appended to in transcript mode:
--url mode instead⚠️ Important: The --post flag will append timestamps to a video's description automatically without manual confirmation in the CLI.
token.pickle — keep this file secure