Platforms / Twitter / X
LivePlatform integration
Ship Your Integration
In Minutes, Not Weeks.
Stop wrestling with X's API pricing and OAuth complexity. letmepost gives you a single, simple endpoint to publish tweets, threads, images, and video. We handle OAuth 2.0 PKCE, rate limits, t.co URL collapse, and every API version change.
Live · v2 API · read the docs →
{
"targets": [{ "platform": "twitter" }],
"accountId": "acc_x_xyz",
"text": "Shipped with letmepost. 280 chars weighted."
}Why letmepost vs X API direct?
Twitter / X Direct
- You pay $100/mo minimum for X API Basic to post
- You implement OAuth 2.0 PKCE + token refresh
- You wrestle with t.co URL collapse (every URL = 23 chars)
- You handle chunked video upload across 3 endpoints
- You track which API version still works this month
- You build retry logic for X's flaky rate limits
letmepost API
- Pay-Per-Use tier works. No $100 Basic required for letmepost users
- OAuth 2.0 PKCE handled server-side, tokens encrypted at rest
- Weighted character counter ships
twitter-text's actual range table - Single
POST /v1/postswith media id, chunked upload abstracted - We pin the version header, monitor sunsets, upgrade internally
- Idempotency-Key handles retries safely
⚠ No X API Basic tier required
X removed free posting in 2025 and gates write access behind a $100/mo Basic plan. letmepost users post via our app's Pay-Per-Use credit pool — no separate X subscription. The cost difference covers letmepost's flat fee multiple times over.
Playground
Connect, configure, post.
OAuth 2.0 PKCE handled in the browser. Click connect, authorize on x.com, you're back in the dashboard with a working account.
CONNECT X →Content types
Every Twitter surface, one shape.
How it works
Three steps, under two minutes.
Get your API key
Sign up at dashboard.letmepost.dev. 30 seconds. No credit card. No X developer account required from you.
Connect an X account
OAuth 2.0 PKCE flow handled by letmepost. Click connect, authorize on x.com, you're done. Access + refresh tokens encrypted at rest.
Send a tweet
One POST /v1/posts with platform: "twitter". We compute weighted chars, push to X v2, fire post.published with the tweet URL.
Features
What we built so you don't.
Skip the $100 tier
letmepost users post via our app's credit pool. You don't pay X's $100/mo Basic plan to send a tweet through us.
Weighted char counter
twitter-text range tables baked in. CJK and emoji count as 2, URLs collapse to t.co (23 chars). Same math X uses server-side.
Chunked video, abstracted
X video upload is 3 endpoints with FINALIZE/STATUS dance. We handle the whole sequence and surface a single status.
Version pin
X has rotated v1.1 → v2 → various sub-versions. We pin the working one, track sunsets, upgrade transparently.
Code example
post a tweet · typescript
import { Letmepost } from '@letmepost/sdk'; const lmp = new Letmepost({ apiKey: process.env.LMP_API_KEY }); // A scheduled tweet with media + reply target const result = await lmp.posts.create({ targets: [{ platform: 'twitter', accountId: 'acc_x_xyz' }], text: 'Tools that ship are tools that get used. https:x1 media: [{ type: 'image', url: 'https://your-image.jpg' }], scheduledAt: '2026-06-01T15:00:00Z', }); for (const r of result.targets) { if (r.status === 'queued') { console.log('Scheduled. Tweet URL on publish:', r.scheduledUrl); } }
X API error reference
X v2 error codes mapped to letmepost's stable envelope. Plus the 14 X-specific preflight rules (weighted chars, media counts, audit states).
Common questions
code-review questions about X posting
Do I need an X developer account?
No. letmepost uses its own X developer app. You connect via our hosted OAuth flow, no developer-portal access required from you.
How does the $100 Basic tier issue work?
X gated write access behind $100/mo in 2025. letmepost users post via our app's Pay-Per-Use credit pool — you don't pay X's tier fee. The credits are bundled into letmepost's flat per-org rate.
What about the weighted character count?
X uses a range-table formula where CJK = 2, emoji = 2, URLs = 23 chars (t.co length). We ship the actual twitter-text library, so our counter agrees with X server-side. See the docs for the counter formula.
Can I post threads?
Yes. Pass an array of text entries: { texts: ["First", "Second", "Third"] }. We thread them automatically via reply_to_tweet_id.
What about videos?
Single MP4 per tweet. Chunked upload abstracted into a single SDK call. We handle the INIT/APPEND/FINALIZE dance and the STATUS poll.
Rate limits?
letmepost's per-org limits apply. X's tweet rate limits are tracked per-account; we surface them as rate_limited errors with Retry-After — never silent.
One API · 8 platforms
Twitter is just one of them.
Learn more
Good to know
Notes from the integration.
OAuth 2.0 PKCE handled in the browser. No client secret in your code. Tokens stored AES-256-GCM encrypted.
280 weighted chars (CJK = 2, emoji = 2, URLs = 23 via t.co). 4 images OR 1 MP4 video. Threads up to 25 tweets.
We pin v2 of the X API. GET /v1/platform-versions exposes the current pin. Sunset notifications via version.deprecated webhook.
post.published fires within 1–2 seconds for text-only, 5–15s for video (transcode dependent).
READY TO PUBLISH TO X?
Skip the developer portal. Skip the $100 Basic tier. Skip the OAuth 2.0 PKCE implementation. Connect in 30 seconds, post in one minute.