{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/nothumansearch-ai/json-schema/nothumansearch-ai-selected-site-detail-schema.json",
  "title": "SelectedSiteDetail",
  "x-generated": "2026-11-19",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/nothumansearch-ai-openapi.yaml#/components/schemas/SelectedSiteDetail",
  "allOf": [
    {
      "$ref": "#/$defs/Site"
    },
    {
      "type": "object",
      "properties": {
        "selection_recorded": {
          "type": "boolean",
          "enum": [
            true
          ],
          "description": "Present only when this request newly recorded an exact returned-result selection; it does not assert action interest"
        },
        "action_interest": {
          "type": "object",
          "description": "Optional provider-independent next step for the one selected organic domain; invoking it still requires explicit current-principal attestation",
          "required": [
            "available",
            "search_id",
            "eligible_domains",
            "action_types",
            "caller_attestation_required",
            "confirmation_version",
            "confirmation_url",
            "invocation_condition",
            "call_contract",
            "endpoint",
            "provider_contacted",
            "commercial_proof",
            "organic_rank_affected"
          ],
          "properties": {
            "available": {
              "type": "boolean",
              "enum": [
                true
              ]
            },
            "search_id": {
              "type": "string"
            },
            "eligible_domains": {
              "type": "array",
              "minItems": 1,
              "maxItems": 1,
              "items": {
                "type": "string"
              }
            },
            "action_types": {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "quote",
                  "trial",
                  "demo",
                  "booking",
                  "application",
                  "signup",
                  "purchase"
                ]
              }
            },
            "caller_attestation_required": {
              "type": "boolean",
              "enum": [
                true
              ]
            },
            "endpoint": {
              "type": "string",
              "format": "uri"
            },
            "confirmation_version": {
              "type": "string",
              "enum": [
                "nhs-action-interest-v1"
              ]
            },
            "confirmation_url": {
              "type": "string",
              "format": "uri"
            },
            "invocation_condition": {
              "type": "string",
              "description": "Requires explicit current principal intent and forbids inference from discovery or selection"
            },
            "call_contract": {
              "$ref": "#/$defs/ActionInterestCallContract"
            },
            "provider_contacted": {
              "type": "boolean",
              "enum": [
                false
              ]
            },
            "commercial_proof": {
              "type": "boolean",
              "enum": [
                false
              ]
            },
            "organic_rank_affected": {
              "type": "boolean",
              "enum": [
                false
              ]
            }
          }
        }
      }
    }
  ],
  "$defs": {
    "ActionInterestCallContract": {
      "type": "object",
      "description": "Non-executable call contract. Fixed receipt and confirmation fields are supplied only for use after the explicit invocation condition is met; the principal-requested domain and action type remain required choices.",
      "required": [
        "available",
        "tool",
        "fixed_arguments_if_invocation_condition_met",
        "domain_must_be_one_of",
        "action_type_must_be_one_of",
        "arguments_must_contain_only",
        "invoke_only_if",
        "executable_without_explicit_principal_intent",
        "query_prompt_contact_identity_fields_are_accepted"
      ],
      "properties": {
        "available": {
          "type": "boolean"
        },
        "tool": {
          "type": "string",
          "enum": [
            "record_action_interest"
          ]
        },
        "fixed_arguments_if_invocation_condition_met": {
          "type": "object",
          "additionalProperties": false,
          "properties": {
            "search_id": {
              "type": "string"
            },
            "caller_attests_principal_interest": {
              "type": "boolean",
              "enum": [
                true
              ]
            },
            "confirmation_version": {
              "type": "string",
              "enum": [
                "nhs-action-interest-v1"
              ]
            }
          }
        },
        "domain_must_be_one_of": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "action_type_must_be_one_of": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "quote",
              "trial",
              "demo",
              "booking",
              "application",
              "signup",
              "purchase"
            ]
          }
        },
        "arguments_must_contain_only": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "search_id",
              "domain",
              "action_type",
              "caller_attests_principal_interest",
              "confirmation_version"
            ]
          }
        },
        "invoke_only_if": {
          "type": "string",
          "description": "Explicit current-principal intent is required; discovery",
          "ranking": null,
          "selection": null,
          "and provider availability are insufficient": null
        },
        "executable_without_explicit_principal_intent": {
          "type": "boolean",
          "enum": [
            false
          ]
        },
        "query_prompt_contact_identity_fields_are_accepted": {
          "type": "boolean",
          "enum": [
            false
          ]
        }
      }
    },
    "Site": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "domain": {
          "type": "string"
        },
        "url": {
          "type": "string",
          "format": "uri"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "has_llms_txt": {
          "type": "boolean"
        },
        "has_ai_plugin": {
          "type": "boolean"
        },
        "has_openapi": {
          "type": "boolean"
        },
        "has_robots_ai": {
          "type": "boolean"
        },
        "has_structured_api": {
          "type": "boolean"
        },
        "has_mcp_server": {
          "type": "boolean"
        },
        "has_schema_org": {
          "type": "boolean"
        },
        "agentic_score": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100
        },
        "category": {
          "type": "string"
        },
        "tags": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "is_verified": {
          "type": "boolean"
        },
        "is_featured": {
          "type": "boolean",
          "deprecated": true,
          "description": "Legacy display metadata only; never affects organic score or ordering"
        }
      }
    }
  }
}