Agent skill

Import X History

by pc-style in pc-style/x-md

Imports an X (Twitter) account's post history in bulk through x.pcstyle.dev: hundreds to thousands of posts in one request, replies and reposts included, JSON or NDJSON, with per-account archiving…

MITAuto-check passedWriting & Content

Install Import X History

skills CLI
$ npx skills add pc-style/x-md --skill import-x-history -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install pc-style/x-md import-x-history --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/pc-style/x-md.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/import-x-history .claude/skills/import-x-history && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
import-x-history
GitHub stars
159
Token cost
~1.6k tokens
SKILL.md length
700 words
Files
1
Skills in repo
2
Repo updated
First seen
Licence
MIT

At a glance

Imports an X (Twitter) account's post history in bulk through x.pcstyle.dev: hundreds to thousands of posts in one request, replies and reposts included, JSON or NDJSON, with per-account archiving…

  • Onboarding a user from their X handle
  • SKILL.md covers the one call you need, parameters, the archive, and how to use it… and NDJSON output, plus 2 more sections
  • Calls curl; reaches x.pcstyle.dev and mdfromx.com; needs X_MD_API_KEY and X_MD_REQUIRE_API_KEY
  • Building a writing-style

What it does

Import X History is an agent skill from pc-style/x-md. Imports an X (Twitter) account's post history in bulk through x.pcstyle.dev: hundreds to thousands of posts in one request, replies and reposts included, JSON or NDJSON, with per-account archiving for repeat requests. Use when onboarding a user from their X handle, building a writing-style or memory profile from someone's posts, or when you need more than one page of an account's timeline. No key needed; a key raises the import allowance. Read-only.

Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Writing & Content, covering Brand voice and tone. It works with X (Twitter), Vercel and TypeScript. The repository describes itself as: Turn public X posts, profiles, and search into compact Markdown or JSON for agents. Hosted at x.pcstyle.dev. The licence is MIT.

When your agent uses it

  • Onboarding a user from their X handle
  • Building a writing-style
  • Memory profile from someones posts
  • You need more than one page of an accounts timeline

Example prompts

  • “s posts, or when you need more than one page of an account”
  • “Use the import-x-history skill to import an X (Twitter) account's post history in bulk through x.pcstyle.dev: hundreds to thousands of posts in one…”
  • “/import-x-history”

Requirements

  • A credential in X_MD_API_KEY
  • A credential in X_MD_REQUIRE_API_KEY
  • Pre-approved tools (allowed-tools): Bash(curl *x.pcstyle.dev*)

What it can do on your machine

Read from SKILL.md and the folder at commit 5e82627. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Bash(curl *x.pcstyle.dev*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • curl

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • x.pcstyle.dev
    • mdfromx.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • X_MD_API_KEY
    • X_MD_REQUIRE_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Import X History loads about 1.6k tokens when it runs. Until then it costs about 118 tokens; SKILL.md has 700 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~118
When it runs · the whole SKILL.md, loaded when a task matches
~1.6k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from pc-style/x-md at commit 5e82627, republished under its MIT licence (© pc-style). 700 words, ~1,602 tokens.

Download SKILL.mdSave it as .claude/skills/import-x-history/SKILL.md (or your agent's skills folder).
name
import-x-history
description
Imports an X (Twitter) account's post history in bulk through x.pcstyle.dev: hundreds to thousands of posts in one request, replies and reposts included, JSON or NDJSON, with per-account archiving for repeat requests. Use when onboarding a user from their X handle, building a writing-style or memory profile from someone's posts, or when you need more than one page of an account's timeline. No key needed; a key raises the import allowance. Read-only.
allowed-tools
Bash(curl *x.pcstyle.dev*)

import x history

one request, one handle, as much history as you ask for. base URL https://x.pcstyle.dev (https://mdfromx.com is the same service). no key is needed: anonymous imports are metered per address, 10 per 15 minutes. the default keyed allowance is 60 per 15 minutes per key, but issued keys can have an override; read RateLimit-Policy; send it as:

Authorization: Bearer $X_MD_API_KEY

if the key is in the environment as X_MD_API_KEY, use it and never print it. a self-hosted deployment in private mode (X_MD_REQUIRE_API_KEY) answers 401 unauthorized without one.

the one call you need

bash
curl -sS -H "Authorization: Bearer $X_MD_API_KEY" \
  "https://x.pcstyle.dev/api/v1/profiles/paulg/posts?since=2025-09-01&max_posts=2000"

response: { "profile": {...}, "posts": [...], "meta": {...} }

  • posts — newest first, raw upstream fields untouched: id, text, created_at, author, replying_to, quote, reposted_by, media, poll, likes, replies, retweets, quotes, views, bookmarks, url
  • meta.count, meta.oldest, meta.newest — what you got
  • meta.truncated — true when capped or incomplete; continue with until=<meta.next_until>, preserving since and deduplicating IDs. If meta.warnings is present, retry the same range before advancing
  • meta.floor_reached — true when accessible history was exhausted, including reaching account creation. This does not prove all published posts are available
  • meta.archive.served / .added — archive entries read versus entries fetched/written; added includes overlaps and updates, not just new unique IDs

parameters

paramdefaultuse
since—oldest post, 2025-01-01 / ISO datetime / unix seconds. omit for everything available
untilnownewest post, inclusive
max_posts500up to 5000, newest first
with_repliestruethe account's replies (tone, opinions, short-form style)
with_repoststruereposts come back as the original post with reposted_by set and the original's date
only_repliesfalsereplies only
formatjsonndjson emits the final sorted selection as {"post":…} lines, then one {"meta":…,"profile":…} line (or {"error":…})
concurrency16up to 32; honor Retry-After on busy or throttled responses
refreshfalsere-walk the range for fresh engagement counts instead of serving the archive
indexfalsetrue returns only what is archived for the handle. free, no walk

the archive, and how to use it well

the service stores what it walks per handle. the next import of that handle only fetches the gap (newer than the archive, or older when since moves back), then serves everything from the archive. that is why:

  • repeat requests can reuse archived posts; timing depends on the account, requested range, upstream health and missing coverage
  • for an onboarding slider (3 months → 1 year → everything), just call again with the wider since; only the extra months are walked
  • check ?index=true first when you only need to know whether history exists and how far back it goes:
bash
curl -sS -H "Authorization: Bearer $X_MD_API_KEY" \
  "https://x.pcstyle.dev/api/v1/profiles/paulg/posts?index=true"
# {"handle":"paulg","archive":{"count":1166,"oldest":"…","newest":"…","covered_since":"…","covered_until":"…","floor_reached":false,…},"persistent":true}

archived posts keep the engagement counts from when they were stored. pass refresh=true when likes/views must be current.

Show full SKILL.md (279 more words)Show less

NDJSON output

bash
curl -sN -H "Authorization: Bearer $X_MD_API_KEY" \
  "https://x.pcstyle.dev/api/v1/profiles/paulg/posts?since=2026-01-01&format=ndjson"

post lines are buffered until the final selection is known, newest first, matching JSON. Require the trailing meta line; an error line or missing metadata means failure. HTTP headers may already be 200, so inspect the stream error code and retry_after.

limits and errors

  • imports are metered on their own: 10 per 15 minutes per address without a key (import-ip in RateLimit-Policy), 60 per 15 minutes per key by default with one (issued-key overrides are advertised in headers) (import-key); one unit per import however many posts it returns. index=true is free
  • every response carries RateLimit / RateLimit-Policy; pace against them instead of discovering 429
  • errors are RFC 9457 problem JSON with a machine code:
    • 401 unauthorized / invalid_key — missing required key or invalid/disabled key
    • 400 invalid_option — bad date, since ≥ until, or a count out of range
    • 404 not_found — unknown, suspended or protected account
    • 429 rate_limited — wait Retry-After seconds
    • 503 import_busy — fresh-walk or per-handle capacity is occupied; import allowance is refunded, ordinary request quota still applies
    • 503 upstream_rate_limited / upstream_unavailable — wait at least Retry-After, add jitter, then retry the identical request at most twice
  • two fresh walks are admitted across the hosted service; queue demand. This is an admission limit, not a throughput guarantee
  • repost timestamps describe the original post, not the repost event; use profile cursor pagination when timeline position matters

what else is there

the same base URL (and key, if you have one) works on the rest of the read API — a single post or thread (/api/v1/posts?url=…), a profile page with limit up to 100 (/api/v1/profiles/{handle}?with_replies=true&limit=100&format=json), search with since/until (/api/v1/search?q=…), followers/following. full reference: https://x.pcstyle.dev/openapi.json, guide: https://x.pcstyle.dev/docs/bulk-import.

read-only: this never posts, follows, or reads protected accounts, DMs or Lists.

© pc-style, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/import-x-history of pc-style/x-md.

Open the folder on GitHubat commit 5e82627

Compare with similar skills

Import X History next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Import X History compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Import X History this skillpc-style/x-md159—~1.6kAutomated safety check: PassMIT
Voice Buildercharlie947/social-media-skills3.8k—~3.3kAutomated safety check: PassMIT
Content Writerchrispangg/deepagentsdk128—~3.3kAutomated safety check: PassMIT
Adk Style GuideBrainDAO/adk-ts119—~1.8kAutomated safety check: PassMIT
Write Like Meng On Xnirholas/three.ws2301 repos~2kAutomated safety check: PassApache-2.0
X Writerognjengt/founder-skills447—~3kAutomated safety check: PassMIT

Similar skills

  • Voice Builder

    charlie947/social-media-skills

    Build a personalised voice profile inside a Codex or Claude project from a short interview plus 3 to 5 sample pieces of writing.

    3.8k GitHub stars~3.3k tokensUpdated 26 days ago
    Writing & ContentAuto-check passed
  • Content Writer

    chrispangg/deepagentsdk

    Writing content across different platforms and styles. An agent skill from chrispangg/deepagentsdk.

    128 GitHub stars~3.3k tokensUpdated 7 mo ago
    Writing & ContentAuto-check passed
  • Adk Style Guide

    BrainDAO/adk-ts

    ADK-TS brand voice, terminology, and writing conventions. An agent skill from BrainDAO/adk-ts.

    119 GitHub stars~1.8k tokensUpdated 3 mo ago
    Writing & ContentAuto-check passed
  • Write Like Meng On X

    nirholas/three.ws

    Write, rewrite, review, or continuously refine X/Twitter posts in Meng To's current voice using his deduplicated authored-post corpus, personal and product context, shared resources, and Content…

    230 GitHub starsUsed in 1 repo~2k tokens
    Writing & ContentAuto-check passed
  • X Writer

    ognjengt/founder-skills

    Creates viral X (Twitter) posts using proven formats, post templates, and creator voice matching.

    447 GitHub stars~3k tokensUpdated 4 mo ago
    Writing & ContentAuto-check passed
  • Draft In Voice

    garrytan/gbrain

    Ghostwrite content in a specific person's voice from a VALIDATED voice profile — tweets, replies, short posts, launch copy, recruiting blurbs, emails.

    31k GitHub stars~3.7k tokensUpdated yesterday
    Writing & ContentAuto-check passed

More from pc-style/x-md

  • Browse X

    pc-style/x-md

    Reads public X (formerly Twitter) posts, threads, X Articles, profiles, followers, following, and search results as Markdown or JSON, with no X account and no API key.

    159 GitHub stars~733 tokensUpdated yesterday
    Auto-check passed

Questions about Import X History

What does Import X History do?

Imports an X (Twitter) account's post history in bulk through x.pcstyle.dev: hundreds to thousands of posts in one request, replies and reposts included, JSON or NDJSON, with per-account archiving…. Import X History is an agent skill from pc-style/x-md.dev: hundreds to thousands of posts in one request, replies and reposts included, JSON or NDJSON, with per-account archiving for repeat requests.

When should I use Import X History?

Import X History fits situations like: onboarding a user from their X handle; building a writing-style; memory profile from someones posts; you need more than one page of an accounts timeline.

How do I install Import X History in Claude Code?

Run `npx skills add pc-style/x-md --skill import-x-history -a claude-code`. Or copy the skill folder (skills/import-x-history in pc-style/x-md) into .claude/skills/import-x-history in your project. Claude Code loads it when a task matches its description.

How do I install Import X History in Codex?

Run `npx skills add pc-style/x-md --skill import-x-history -a codex`. Or copy the skill folder (skills/import-x-history in pc-style/x-md) into .agents/skills/import-x-history in your project. Codex loads it when a task matches its description.

Can I use Import X History in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add pc-style/x-md --skill import-x-history -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/import-x-history, .gemini/skills/import-x-history, .github/skills/import-x-history and .opencode/skills/import-x-history in your project.

What does Import X History need to run?

Going by SKILL.md and its folder, Import X History needs the command-line tools its instructions call (curl) and credentials named X_MD_API_KEY and X_MD_REQUIRE_API_KEY. Our summary lists: A credential in X_MD_API_KEY; A credential in X_MD_REQUIRE_API_KEY. Its frontmatter pre-approves these tools: Bash(curl *x.pcstyle.dev*).

Does Import X History access the network?

SKILL.md names 2 domains. In commands or code: x.pcstyle.dev and mdfromx.com; the agent is likely to contact these when it follows the instructions. This is read from the text; nothing was executed.

Is Import X History safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Import X History use?

Import X History is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Import X History use?

About 1.6k tokens (SKILL.md is roughly 6.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Import X History?

Skills that share tags, products or a category with Import X History: Voice Builder (charlie947/social-media-skills, 3.8k stars), Content Writer (chrispangg/deepagentsdk, 128 stars), Adk Style Guide (BrainDAO/adk-ts, 119 stars) and Write Like Meng On X (nirholas/three.ws, 230 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Import X History?

pc-style (a GitHub user) maintains it in pc-style/x-md, which has 159 GitHub stars. The repository holds 2 skills in this directory. The repository was last updated on October 9, 2026.

Source: pc-style/x-md on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.