{
  "_comment": "This Spec is for Phase 1!! Most updated version is at https://github.com/reTHINK-project/specs/tree/master/schemas",
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "anyOf": [
    {
      "$ref": "#/definitions/MessageDataObjectSchema"
    },
    {
      "$ref": "#/definitions/HypertyDataObjectSchema"
    }
  ],
  "properties": {},
  "definitions": {
    "MessageDataObjectSchema": {
      "type": "object",
      "properties": {}
    },
    "HypertyDataObjectSchema": {
      "type": "object",
      "required": [
        "scheme",
        "accessControlPolicy"
      ],
      "anyOf": [
        {
          "$ref": "#/definitions/CommunicationDataObjectSchema"
        },
        {
          "$ref": "#/definitions/ConnectionDataObjectSchema"
        },
        {
          "$ref": "#/definitions/IdentityDataObjectSchema"
        },
        {
          "$ref": "#/definitions/ContextDataObjectSchema"
        }
      ],
      "properties": {
        "scheme": {
          "enum": [
            "comm",
            "connection",
            "context",
            "identity"
          ]
        },
        "accessControlPolicy": {
          "type": "string"
        }
      }
    },
    "AccessControlPolicy": {
      "type": "object",
      "properties": {}
    },
    "CommunicationDataObjectSchema": {
      "type": "object",
      "required": [
        "scheme"
      ],
      "properties": {
        "scheme": {
          "constant": "comm"
        }
      }
    },
    "ConnectionDataObjectSchema": {
      "type": "object",
      "required": [
        "scheme"
      ],
      "properties": {
        "scheme": {
          "constant": "connection"
        }
      }
    },
    "IdentityDataObjectSchema": {
      "type": "object",
      "required": [
        "scheme"
      ],
      "properties": {
        "scheme": {
          "constant": "identity"
        }
      }
    },
    "ContextDataObjectSchema": {
      "type": "object",
      "required": [
        "scheme"
      ],
      "properties": {
        "scheme": {
          "constant": "context"
        }
      }
    }
  }
}