{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/theblueprint-xyz/json-schema/theblueprint-xyz-code-integrity-response-schema.json",
  "title": "CodeIntegrityResponse",
  "x-generated": "2026-11-26",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/theblueprint-xyz-openapi.json#/components/schemas/CodeIntegrityResponse",
  "type": "object",
  "properties": {
    "purpose": {
      "type": "string",
      "description": "Purpose of this endpoint — verify deployed code integrity"
    },
    "gitCommit": {
      "type": "string",
      "description": "Git commit hash of the deployed code"
    },
    "sourceHashes": {
      "type": "object",
      "description": "SHA-256 hashes of deployed source files for integrity verification",
      "properties": {
        "description": {
          "type": "string",
          "description": "Explanation of how to use source hashes"
        },
        "files": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "Map of filename to SHA-256 hash"
        }
      }
    },
    "sourceCode": {
      "type": "object",
      "description": "Direct URLs to read the deployed TypeScript source code",
      "properties": {
        "description": {
          "type": "string",
          "description": "Explanation of how to read source code"
        },
        "files": {
          "type": "object",
          "additionalProperties": {
            "type": "string",
            "format": "uri"
          },
          "description": "Map of filename to source URL"
        }
      }
    },
    "openSource": {
      "type": "string",
      "description": "Status of open-source availability"
    },
    "verificationSteps": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Step-by-step instructions to verify code integrity"
    },
    "memoProgram": {
      "type": "object",
      "description": "Memo Program details for on-chain transaction verification",
      "properties": {
        "programId": {
          "type": "string",
          "description": "Solana Memo Program ID"
        },
        "expectedMemo": {
          "type": "string",
          "description": "Expected memo string in Blueprint transactions"
        },
        "description": {
          "type": "string",
          "description": "Explanation of how the memo is used for verification"
        }
      }
    },
    "_meta": {
      "$ref": "#/$defs/ResponseMeta"
    }
  },
  "$defs": {
    "ResponseMeta": {
      "type": "object",
      "description": "Navigation metadata included in most responses",
      "properties": {
        "endpoint": {
          "type": "string",
          "description": "The endpoint that generated this response"
        },
        "description": {
          "type": "string",
          "description": "Brief description of the response"
        },
        "timestamp": {
          "type": "string",
          "format": "date-time",
          "description": "ISO 8601 timestamp when this response was generated"
        },
        "relatedEndpoints": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "Related REST endpoints for next actions"
        },
        "relatedTools": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "Related MCP tool names (MCP responses only)"
        },
        "nextSteps": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "Contextual next steps based on response data"
        },
        "verifyThisCode": {
          "type": "string",
          "description": "Endpoint to verify code integrity"
        },
        "cacheTtlSeconds": {
          "type": "integer",
          "description": "Cache TTL for this response"
        },
        "documentation": {
          "type": "string",
          "description": "Link to documentation"
        },
        "support": {
          "type": "object",
          "description": "Optional donation info — Blueprint is free, donation-supported infrastructure",
          "properties": {
            "address": {
              "type": "string",
              "description": "Solana address for donations"
            },
            "message": {
              "type": "string",
              "description": "Context about why donations help"
            },
            "donate": {
              "type": "string",
              "description": "How to build a donation transaction via API/MCP"
            }
          }
        }
      }
    }
  }
}