{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "success": {
      "type": "boolean",
      "enum": [
        true
      ]
    },
    "ctx": {
      "type": "object",
      "patternProperties": {
        "^[0-9a-zA-Z_-]{1,255}$": {
          "anyOf": [
            {
              "properties": {
                "a": {
                  "type": "string",
                  "maxLength": 32767
                },
                "b": {
                  "type": "number"
                },
                "c": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string",
                      "pattern": "^[0-9a-zA-Z_-]{1,255}$"
                    },
                    "value": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    }
                  },
                  "additionalProperties": false
                }
              }
            },
            {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[A-Fa-f\\d]{24}$"
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 255
                },
                "description": {
                  "type": "string",
                  "maxLength": 32767
                },
                "tags": {
                  "type": "object",
                  "patternProperties": {
                    "^[0-9a-zA-Z_-]{1,255}$": {
                      "type": "array",
                      "minItems": 1,
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255
                      }
                    }
                  }
                }
              }
            }
          ]
        }
      },
      "additionalProperties": false
    }
  }
}
