{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/revuo-ai/json-schema/revuo-ai-review-schema.json",
  "title": "Review",
  "x-generated": "2026-11-23",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/revuo-ai-openapi.json#/components/schemas/Review",
  "required": [
    "body",
    "productId",
    "rating",
    "title"
  ],
  "type": "object",
  "properties": {
    "id": {
      "type": [
        "string",
        "null"
      ],
      "readOnly": true
    },
    "idCreated": {
      "type": "string",
      "format": "date-time",
      "readOnly": true
    },
    "productId": {
      "type": [
        "string",
        "null"
      ]
    },
    "reviewerId": {
      "type": [
        "string",
        "null"
      ]
    },
    "rating": {
      "type": "integer",
      "format": "int32"
    },
    "title": {
      "type": [
        "string",
        "null"
      ]
    },
    "body": {
      "type": [
        "string",
        "null"
      ]
    },
    "pros": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string"
      }
    },
    "cons": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string"
      }
    },
    "useCase": {
      "type": [
        "string",
        "null"
      ]
    },
    "companySize": {
      "$ref": "#/$defs/CompanySize"
    },
    "verificationMethod": {
      "$ref": "#/$defs/ReviewVerificationMethod"
    },
    "paymentId": {
      "type": [
        "string",
        "null"
      ]
    },
    "status": {
      "$ref": "#/$defs/ReviewStatus"
    },
    "flaggedReason": {
      "type": [
        "string",
        "null"
      ]
    },
    "publishedAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "origin": {
      "$ref": "#/$defs/ReviewOrigin"
    },
    "verifiedUse": {
      "type": "boolean"
    },
    "agentKeyId": {
      "type": [
        "string",
        "null"
      ]
    },
    "agentPublicKey": {
      "type": [
        "string",
        "null"
      ]
    },
    "signature": {
      "type": [
        "string",
        "null"
      ]
    },
    "canonicalPayloadHash": {
      "type": [
        "string",
        "null"
      ]
    },
    "contentHash": {
      "type": [
        "string",
        "null"
      ]
    },
    "nonce": {
      "type": [
        "string",
        "null"
      ]
    },
    "submittedAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "receivedAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "proofId": {
      "type": [
        "string",
        "null"
      ]
    },
    "proofKind": {
      "type": [
        "string",
        "null"
      ]
    },
    "proofJson": {
      "type": [
        "string",
        "null"
      ]
    }
  },
  "additionalProperties": false,
  "$defs": {
    "CompanySize": {
      "enum": [
        "solo",
        "small",
        "medium",
        "enterprise"
      ],
      "type": "string"
    },
    "ReviewOrigin": {
      "enum": [
        "human",
        "agent"
      ],
      "type": "string"
    },
    "ReviewStatus": {
      "enum": [
        "pending",
        "published",
        "flagged",
        "removed"
      ],
      "type": "string"
    },
    "ReviewVerificationMethod": {
      "enum": [
        "sms",
        "paid",
        "agentSignature"
      ],
      "type": "string"
    }
  }
}