Skip to content

Errors

The Mosaic Motion API returns JSON errors.

Common errors

400 Invalid request

The request body failed validation.

Examples:

  • Missing prompt.
  • More than 10 attachments.
  • Invalid attachment URL.
  • Non-YouTube style_reference_url.

401 Mosaic Motion API key authentication required

The request did not include a valid motion_ API key.

402 Insufficient credits

The API key owner's account does not have enough Mosaic Motion credits to start or continue the job.

Purchase credits and configure auto top-ups in the Motion frontend at motion.so. Credit purchasing and auto top-up settings are not available through the API.

Example:

json
{
  "error": "insufficient_credits",
  "code": "insufficient_credits_minimum_kickoff_balance",
  "message": "Starting a new Mosaic Motion session requires at least 300 credits in your balance.",
  "minimum_required_credits": 300,
  "current_balance": 0
}

404 Job not found

The job does not exist or is not owned by the API key user.

409 Followup requires completed job

Followups can only be created for completed jobs.

json
{
  "error": "followup_requires_completed_job",
  "message": "Followups can only be created for completed Mosaic Motion jobs.",
  "status": "running"
}

500 Internal server error

The job could not be created or read due to an internal service error.

Validation error example

json
{
  "error": "Invalid request",
  "details": [
    {
      "code": "too_big",
      "maximum": 10,
      "type": "array",
      "inclusive": true,
      "message": "Array must contain at most 10 element(s)",
      "path": ["attachments"]
    }
  ]
}

Mosaic Motion documentation.