jackwener/OpenCLI · error · CommandExecutionError
Suno captcha pre-flight failed${captcha?.status ? ` (HTTP ${
Error message
Suno captcha pre-flight failed${captcha?.status ? ` (HTTP ${captcha.status})` : ''}. What it means
A CommandExecutionError from the CAPTCHA pre-flight in `opencli suno generate`: `checkSunoCaptcha(page, deviceId)` did not return ok — either the pre-flight check request failed (the message appends ` (HTTP <status>)` when a status is known) or the response was unusable. It runs before submission so Suno's anti-bot gate is detected early, with remediation guidance as the second argument.
Source
Thrown at clis/suno/generate.js:131
const timeout = requirePositiveInt(kwargs.timeout, '--timeout');
const makeInstrumental = normalizeBooleanFlag(kwargs.instrumental);
const weirdness = clampSlider(kwargs.weirdness, '--weirdness', 0.5);
const styleWeight = clampSlider(kwargs['style-weight'], '--style-weight', 0.5);
// Title: required by API. Auto-derive from first 60 chars of source prompt if not provided.
const titleSource = titleArg || (isCustom ? (tags || lyrics.split('\n')[0]) : description);
const title = titleSource.replace(/\s+/g, ' ').trim().slice(0, 60) || 'Untitled';
const session = await ensureSunoSession(page);
if (!session.planId) {
throw new CommandExecutionError(
`Suno generation needs a resolved plan id for the user_tier field, but billing/info did not surface one for this account (subscription_type=${session.planKey}). Verify the account is active at ${SUNO_URL}/account, then retry.`,
);
}
const deviceId = session.deviceId;
const captcha = await checkSunoCaptcha(page, deviceId);
if (!captcha?.ok) {
throw new CommandExecutionError(
`Suno captcha pre-flight failed${captcha?.status ? ` (HTTP ${captcha.status})` : ''}.`,
`Open ${SUNO_URL}/create in Chrome and verify the account is ready, then retry.`,
);
}
if (captcha?.required) {
throw new CommandExecutionError(
'Suno requires a CAPTCHA challenge for this account/IP right now.',
`Open ${SUNO_URL}/create in Chrome, solve a Create challenge once, then retry.`,
);
}
if (session.totalCreditsAvailable < 10) {
const b = session.breakdown;
throw new CommandExecutionError(
`Suno generation needs ~10 credits; you have ${session.totalCreditsAvailable} (monthly ${b.monthlyRemaining}/${b.monthlyLimit} + packs ${b.purchasedPacks} + leftover ${b.pack}). Top up at ${SUNO_URL}/account.`,
);
}
const transactionUuid = crypto.randomUUID();View on GitHub (pinned to 49907e53dc)
Solutions
- Open https://suno.com/create in the driven Chrome profile and verify the account loads normally, then retry the command.
- Disable VPN / switch to a residential network if your IP is flagged (HTTP 403/429 in the message points at this).
- Refresh the Suno session (re-login in the Chrome profile) so deviceId/cookies are current, then retry.
- If a challenge appears in the browser, solve one Create CAPTCHA manually — a subsequent required-captcha error will say so explicitly — then rerun.
Defensive patterns
Strategy: retry
Validate before calling
// sanity-check connectivity to suno.com and avoid flagged IPs before generating
const res = await fetch('https://suno.com/create', { method: 'HEAD' });
if (!res.ok && res.status !== 200) {
console.warn('suno.com may be gating this IP — disable VPN / change network before running');
} Try / catch
try {
await run('opencli suno generate "..."');
} catch (err) {
if (String(err.message).startsWith('Suno captcha pre-flight failed')) {
// open suno.com/create in the driven Chrome, confirm access (solve a
// challenge if shown), drop VPN if HTTP 403/429, then retry
} else throw err;
} Prevention
- Avoid VPNs/datacenter IPs when driving Suno — they frequently trip anti-bot checks.
- Keep the persistent session warm by opening suno.com periodically instead of after long idle.
- Space out generate calls to avoid rate-limit-induced 429s.
- Solve any Create CAPTCHA manually in the driven browser once; the CLI will then proceed.
When it happens
Trigger: Running `opencli suno generate` when the captcha pre-flight endpoint returns a non-2xx (e.g. 403/429 from IP reputation or rate limiting), the session/deviceId is stale so the check errors, or Cloudflare/anti-bot interstitials intercept the in-page request.
Common situations: Generating from a VPN/datacenter IP flagged by Suno, hitting the endpoint too frequently, stale persistent cookie sessions after long idle, or Suno tightening bot protection after an incident.
Related errors
- IMDb blocked this request
- IMDb blocked this request
- IMDb blocked this request
- IMDb blocked this request
- 12306 queryByTrainNo returned non-JSON body
AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29).
Data as JSON: /api/errors/a00c0138b98a4716.
Report an issue: GitHub.