Skip to main content
Use the json reporter when you need a local, machine-readable report after a run finishes.

1. Run with the JSON reporter

npx momentic run tests --reporter json --reporter-dir reports --name checkout
The command writes reports/checkout.momentic.json. Filenames derive from --name, or from the project name when --name is omitted. You can combine the JSON reporter with other reporters:
npx momentic run tests --reporter json --reporter junit --reporter-dir reports

2. Read the report

reports/checkout.momentic.json
{
  "version": 1,
  "runGroup": {
    "startedAt": "2026-06-25T18:00:00.000Z",
    "finishedAt": "2026-06-25T18:02:12.000Z",
    "durationMs": 132000
  },
  "summary": {
    "total": 3,
    "executed": 2,
    "skipped": 1,
    "passed": 1,
    "failed": 1,
    "cancelled": 0,
    "quarantined": 0,
    "recovered": 0
  },
  "runs": [
    {
      "runId": "550e8400-e29b-41d4-a716-446655440000",
      "testId": "checkout-flow",
      "testName": "checkout-flow",
      "filePath": "tests/checkout.test.yaml",
      "labels": ["checkout"],
      "status": "FAILED",
      "startedAt": "2026-06-25T18:01:00.000Z",
      "finishedAt": "2026-06-25T18:02:00.000Z",
      "durationMs": 60000,
      "attempts": 1,
      "quarantined": false,
      "recovered": false,
      "failure": {
        "reason": "The checkout request returned a 500 response.",
        "message": "Error: checkout failed"
      },
      "classification": {
        "category": "BUG",
        "reasoning": "The app returned a 500 response after valid checkout details were submitted.",
        "citations": []
      }
    }
  ],
  "skipped": [
    {
      "testId": "refund-flow",
      "testName": "refund-flow",
      "filePath": "tests/refund.test.yaml",
      "labels": [],
      "quarantined": false
    }
  ]
}
The public JSON schema is available at https://schemas.momentic.ai/momentic-json-report.schema.json.