jackwener/OpenCLI · error · CommandExecutionError

Suno accepted the request but returned no clip ids.

Error message

Suno accepted the request but returned no clip ids.

What it means

If Suno accepted the generation request but `submission.clips` is an empty array, there are no clip ids to poll. The CLI throws to distinguish 'request accepted but nothing produced' from malformed payloads.

Source

Thrown at clis/suno/generate.js:177

            description,
            makeInstrumental,
            weirdness,
            styleWeight,
            userTier: session.planId,
            createSessionToken,
            transactionUuid,
            deviceId,
        });

        if (!Array.isArray(submission.clips)) {
            throw new CommandExecutionError('Suno generation returned malformed clips payload.');
        }
        const clipIds = submission.clips.map(c => c?.id);
        if (clipIds.some(id => !id)) {
            throw new CommandExecutionError('Suno generation returned malformed clip identity.');
        }
        if (!clipIds.length) {
            throw new CommandExecutionError('Suno accepted the request but returned no clip ids.');
        }

        const clips = await pollSunoClips(page, clipIds, timeout, deviceId);
        const completed = clips.filter(c => c.status === 'complete');
        if (!completed.length) {
            const errors = clips.map(c => `${c.id.slice(0, 8)}:${c.status}`).join(', ');
            throw new CommandExecutionError(`All Suno clips failed (${errors}). Open ${SUNO_URL}/song/${clipIds[0]} to inspect.`);
        }

        const rows = [];
        for (const clip of clips) {
            const link = `${SUNO_URL}/song/${clip.id}`;
            if (clip.status !== 'complete') {
                rows.push({
                    status: `❌ ${clip.status}`,
                    clip: clip.id.slice(0, 8),
                    title: clip.title || '(untitled)',
                    files: '-',

View on GitHub (pinned to 49907e53dc)

Solutions

  1. Verify in a browser at https://suno.com/create whether the prompt produces songs (moderation may be silently blocking it).
  2. Inspect the full submission response for alternative keys (e.g. clips nested in data/songs).
  3. Rephrase the prompt/lyrics to avoid content-policy triggers and retry.
  4. Check Suno status/announcements for ongoing incidents.

Example fix

// before: assumes at least one clip
const first = submission.clips[0].id;
// after: check emptiness explicitly
if (!submission.clips?.length) throw new Error('Suno accepted the request but returned no clip ids — prompt may be moderated');
Defensive patterns

Strategy: validation

Validate before calling

if (!Array.isArray(submission.clips) || submission.clips.length === 0) {
  throw new Error('Suno returned no clips — prompt may be moderated or API shape changed');
}

Type guard

function hasClips(v) { return Array.isArray(v?.clips) && v.clips.length > 0; }

Try / catch

try {
  await opencli('suno', 'generate', prompt);
} catch (e) {
  if (/returned no clip ids/i.test(e.message)) {
    return { empty: true, hint: 'check prompt against content policy or verify clips key in API response' };
  }
  throw e;
}

Prevention

When it happens

Trigger: `submitSunoGeneration()` succeeds (HTTP-level) but `submission.clips.length === 0` — Suno created no clips for the request.

Common situations: Prompt rejected by content moderation with a silent empty response, all requested clips failed instantly server-side, or API drift where clips are now under a different key.

Related errors


AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29). Data as JSON: /api/errors/9473cb52adb61086. Report an issue: GitHub.