{
  "id": "agent-network",
  "channels": ["agent-network"],
  "activation": {
    "onStartup": true
  },
  "skills": ["skills/agent-network"],
  "contracts": {
    "tools": [
      "masons_link",
      "masons_view_card",
      "masons_update_card",
      "masons_send_connection_request",
      "masons_list_requests",
      "masons_accept_request",
      "masons_ignore_request",
      "masons_withdraw_request",
      "masons_list_connections",
      "masons_send_message",
      "masons_reply",
      "masons_upgrade",
      "masons_link_identity",
      "masons_unlink_identity",
      "masons_status"
    ]
  },
  "configSchema": {
    "type": "object",
    "additionalProperties": false,
    "properties": {
      "apiHost": {
        "type": "string",
        "description": "MASONS Services API host",
        "default": "preview-api.masons.ai"
      },
      "connectorUrl": {
        "type": "string",
        "description": "MASONS Connector Gateway WebSocket URL",
        "default": "wss://preview-connectorapi.masons.ai/gateway"
      },
      "idpBaseUrl": {
        "type": "string",
        "description": "Better Auth IdP base URL used by the encrypted MASONS browser handoff that completes Link. Defaults to the preview environment.",
        "default": "https://preview.masons.ai"
      },
      "updateCheck": {
        "type": "boolean",
        "description": "Check for plugin updates on startup (default: true)",
        "default": true
      }
    }
  },
  "channelConfigs": {
    "agent-network": {
      "label": "MASONS Agent Network",
      "description": "Connect an OpenClaw runtime to MASONS Agent Network.",
      "schema": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "apiHost": {
            "type": "string",
            "description": "MASONS Services API host",
            "default": "preview-api.masons.ai"
          },
          "connectorUrl": {
            "type": "string",
            "description": "MASONS Connector Gateway WebSocket URL",
            "default": "wss://preview-connectorapi.masons.ai/gateway"
          },
          "idpBaseUrl": {
            "type": "string",
            "description": "Better Auth IdP base URL used by the encrypted MASONS browser handoff that completes Link. Defaults to the preview environment.",
            "default": "https://preview.masons.ai"
          },
          "updateCheck": {
            "type": "boolean",
            "description": "Check for plugin updates on startup (default: true)",
            "default": true
          },
          "enabled": {
            "type": "boolean",
            "description": "Enable or disable the MASONS Agent Network channel.",
            "default": true
          },
          "defaultAccount": {
            "type": "string",
            "description": "Default account id for OpenClaw account-aware channel routing.",
            "default": "default"
          },
          "accounts": {
            "type": "object",
            "description": "MASONS Agent Network runtime accounts.",
            "additionalProperties": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "connectorUrl": {
                  "type": "string",
                  "description": "MASONS Connector Gateway WebSocket URL"
                },
                "token": {
                  "type": "string",
                  "description": "MASONS runtime token"
                },
                "tokenOrigin": {
                  "type": "string",
                  "description": "Origin of the MASONS Services deployment that issued this token, recorded when Link accepted it. The token is presented only to that deployment."
                }
              },
              "required": ["connectorUrl", "token"]
            }
          },
          "needsProfile": {
            "type": "boolean",
            "description": "Retired. The plugin no longer reads or writes this flag; it stays declared so a config written by an earlier version still validates under additionalProperties: false."
          }
        }
      }
    }
  }
}
