Skip to main content
Used to validate data of URL category.

Schema Structure

  • type (string) - enum: url - default: url (required) - Defines type of data
  • data (object) (required)
    • url (string) - pattern: (http://www\.|https://www\.|http://|https://)?[a-z... - format: uri (required) - Used for redirecting user to the URL
    • conditions (object - ref: conditional_urls)

Components Used

This category uses the following components:

Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "type": "object",
  "title": "URL Category schema",
  "description": "Used to validate data of URL category.",
  "examples": [],
  "required": [
    "type",
    "data"
  ],
  "additionalProperties": false,
  "properties": {
    "type": {
      "type": "string",
      "enum": [
        "url"
      ],
      "default": "url",
      "description": "Defines type of data"
    },
    "data": {
      "type": "object",
      "required": [
        "url"
      ],
      "additionalProperties": false,
      "properties": {
        "url": {
          "type": "string",
          "format": "uri",
          "title": "URL",
          "pattern": "(http://www\\.|https://www\\.|http://|https://)?[a-z0-9]+([\\-.][a-z0-9]+)*\\.[a-z]{2,10}(:[0-9]{1,5})?(.*)?$",
          "description": "Used for redirecting user to the URL"
        },
        "conditions": {
          "$ref": "components/conditional_urls.json"
        }
      }
    }
  }
}