{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/prompeteer-ai/json-schema/prompeteer-ai-generate-response-schema.json",
  "title": "GenerateResponse",
  "x-generated": "2026-11-22",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/prompeteer-ai-openapi.yml#/components/schemas/GenerateResponse",
  "type": "object",
  "properties": {
    "success": {
      "type": "boolean"
    },
    "prompt": {
      "type": "string",
      "description": "The generated prompt text"
    },
    "generatedPrompt": {
      "type": "string",
      "description": "Same as prompt (alias)"
    },
    "promptId": {
      "type": "string",
      "description": "Marketplace vault prompt ID (if savedToVault)"
    },
    "promptDriveId": {
      "type": [
        "string",
        "null"
      ],
      "description": "PromptDrive prompt ID (if savedToDrive)"
    },
    "savedToVault": {
      "type": "boolean",
      "description": "Whether saved to marketplace vault"
    },
    "savedToDrive": {
      "type": "boolean",
      "description": "Whether saved to PromptDrive"
    },
    "tileStatus": {
      "type": "string",
      "description": "Tile image generation status"
    },
    "metadata": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string"
        },
        "category": {
          "type": "string"
        }
      }
    },
    "promptIQ": {
      "type": "object",
      "properties": {
        "overallScore": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100,
          "description": "Overall Prompt Score (0-100)"
        }
      }
    },
    "performance": {
      "type": "object",
      "properties": {
        "totalTime": {
          "type": "integer",
          "description": "Response time in milliseconds"
        },
        "source": {
          "type": "string"
        }
      }
    },
    "memory": {
      "type": "object",
      "description": "Content-free effective Memory decision and citations for passages used during generation.",
      "properties": {
        "status": {
          "type": "string",
          "enum": [
            "applied",
            "skipped"
          ]
        },
        "reason": {
          "type": [
            "string",
            "null"
          ]
        },
        "surface": {
          "type": "string",
          "enum": [
            "web",
            "mcp",
            "api",
            "chrome_extension"
          ]
        },
        "decision": {
          "type": "object",
          "additionalProperties": true
        },
        "citations": {
          "type": "array",
          "items": {
            "type": "object",
            "required": [
              "pageId",
              "title"
            ],
            "properties": {
              "pageId": {
                "type": "string"
              },
              "title": {
                "type": "string"
              }
            }
          }
        }
      }
    },
    "quota": {
      "type": "object",
      "properties": {
        "used": {
          "type": "integer"
        },
        "limit": {
          "type": "integer"
        },
        "remaining": {
          "type": "integer"
        },
        "resetDate": {
          "type": "string",
          "format": "date-time"
        },
        "isPro": {
          "type": "boolean"
        }
      }
    }
  }
}