Astra
Schedule call
← Back to Work
Agent· 2025· Open source
linkedin-video-dl

Download videos from LinkedIn posts

Built from client requests originating in OpenClaw. A fast, zero-dependency Go CLI that downloads videos embedded in public LinkedIn posts. Paste the URL, it gives you the .mp4. No auth, no API keys, no session cookies — just the post URL and the LinkedIn CDN.

Stack
Gostdlib
dependencies
0
The Problem

LinkedIn doesn't expose a download button on video posts, and most third-party tools either require a login, ship a heavy Electron shell, or charge for what amounts to one HTTP request. None of that is what you want when you're saving a video for a deck, archiving a talk, or pulling a batch of clips offline.

The Approach

A tiny Go binary that fetches the public post HTML with browser-like headers, then extracts video URLs from LinkedIn's CDN (`dms.licdn.com`) using multiple patterns — direct MP4 URLs, URL-encoded and unicode-escaped variants, `contentUrl` fields in JSON-LD, and `src` attributes inside embedded JSON. It picks the best quality available and downloads to a temp file (renaming on completion) so an interrupted run never leaves a corrupted partial.

Highlights
  1. 01
    Zero dependencies
    Go standard library only. `go install` and you're done — no module tree to audit, no surprise transitive deps.
  2. 02
    No auth
    Only works on public posts — by design. If a video is gated behind a login, this tool won't fetch it. The constraint keeps the surface area honest.
  3. 03
    Multi-strategy extraction
    Parses direct MP4 URLs, URL-encoded and unicode-escaped variants, JSON-LD `contentUrl`, and `src` attributes in embedded JSON. Picks the best quality available.
  4. 04
    Safe downloads
    Writes to a temp file and renames on completion. An interrupted download never leaves a half-written .mp4 in your working directory.
  5. 05
    Live progress bar
    Real-time progress with percentage and bytes transferred — built with stdlib formatting, no external TUI library.
  6. 06
    Auto-named files
    Filenames are derived from the post slug, so a batch of downloads stays sorted and traceable without manual renaming.
Links