{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://weverlabs.com/schemas/agent-handshake-request.schema.json",
  "title": "Agent Handshake Request",
  "description": "Public-safe first contact object for an external agent asking Wever Labs OS what it can do and how to proceed.",
  "type": "object",
  "required": [
    "object_type",
    "agent_name",
    "agent_purpose",
    "requested_domain",
    "callback_url",
    "public_safe_mode"
  ],
  "properties": {
    "object_type": {
      "const": "agent_handshake_request"
    },
    "agent_name": {
      "type": "string",
      "minLength": 2
    },
    "agent_homepage": {
      "type": "string",
      "format": "uri"
    },
    "agent_manifest_url": {
      "type": "string",
      "format": "uri"
    },
    "operator_contact": {
      "type": "string",
      "description": "Public-safe operator contact or system owner reference."
    },
    "agent_purpose": {
      "type": "string"
    },
    "requested_domain": {
      "type": "string",
      "enum": [
        "workflow_intake",
        "packet_operations",
        "distribution_operations",
        "token_operations",
        "agent_paid_os_usage",
        "operating_tool_discovery",
        "unknown"
      ]
    },
    "requested_capabilities": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "preferred_tool": {
      "type": "string",
      "enum": [
        "packetops",
        "distributionops",
        "tokenops",
        "wever_labs_os",
        "unknown"
      ]
    },
    "data_sensitivity": {
      "type": "string",
      "enum": [
        "public_safe",
        "business_confidential",
        "regulated",
        "unknown"
      ],
      "default": "public_safe"
    },
    "callback_url": {
      "type": "string",
      "format": "uri"
    },
    "public_safe_mode": {
      "type": "boolean",
      "description": "True means no credentials, private keys, regulated records, or confidential client data are included."
    },
    "requested_next_step": {
      "type": "string",
      "enum": [
        "preflight_check",
        "trust_profile",
        "quote_request",
        "workflow_intake",
        "human_review"
      ]
    }
  },
  "additionalProperties": true
}
