{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "id": "http://qiskit.org/qobj/results-01/schema#",
  "title": "qobj results",
  "description": "The results of executing a qobj",
  "type": "object",
  "required": [
    "backend",
    "id",
    "status"
  ],
  "properties": {
    "backend": {
      "type": "string",
      "description": "Backend who produced this result"
    },
    "id": {
      "type": "string",
      "description": "Job id passed back from the input qobj"
    },
    "execution_id": {
      "type": "string",
      "description": "Unique execution id. May be useful for matching with backend logfiles, etc"
    },
    "date": {
      "type": "string",
      "_format": "date-time",
      "description": "Date/time of job execution"
    },
    "result": {
      "type": "array",
      "description": "Corresponding results for array of experiments of the input qobj",
      "items": {
        "type": "object",
        "required": [
          "status",
          "success"
        ],
        "properties": {
          "success": {
            "type": "boolean",
            "description": "If true, we can trust results for this experiment."
          },
          "status": {
            "type": "string",
            "description": "Human-readable description of status of this experiment"
          },
          "name": {
            "type": "string",
            "description": "Experiment name"
          },
          "seed": {
            "type": "string",
            "description": "Experiment-level random seed"
          },
          "shots": {
            "type": "string",
            "description": "Experiment-level number of shots"
          },
          "data": {
            "type": "object",
            "properties": {
              "counts": {
                "type": "object",
                "description": "Histogram of results",
                "example": {
                  "01011": 10,
                  "10001": 102
                },
                "additionalProperties": {
                  "type": "integer",
                  "minimum": 0
                }
              },
              "snapshots": {
                "type": "object",
                "description": "Snapshot of simulator internal representation",
                "example": {
                  "0": {
                    "statevector": [
                      [
                        0,
                        0.707
                      ],
                      [
                        0,
                        0
                      ],
                      [
                        0,
                        0
                      ],
                      [
                        0.707,
                        0
                      ]
                    ],
                    "probabilities": [
                      0.5,
                      0,
                      0,
                      0.5
                    ]
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "success": {
    "type": "boolean",
    "description": "True if complete input qobj executed correctly. (Implies each experiment success)"
  },
  "status": {
    "type": "string",
    "description": "Human-readable status of complete qobj execution"
  }
}