{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "title": "RoutingEntry",
    "description": "Okapi proxy routing entry",
    "type": "object",
    "additionalProperties": false,
    "properties": {
        "methods": {
            "description": "List of methods GET, POST,.. * (for all)",
            "type": "array",
            "items": {
                "type": "string"
            }
        },
        "pathPattern": {
            "description": "Path pattern match. * matches any path. {x} matches one or more characters but not slash",
            "type": "string"
        },
        "path": {
            "description": "Path prefix match",
            "type": "string"
        },
        "rewritePath": {
            "description": "Rewrite path. e.g. have filter rewrite '/*' to '/events/*'",
            "type": "string"
        },
        "phase": {
            "description": "If given, may be auth, pre or post",
            "type": "string"
        },
        "level": {
            "description": "Processing level. Default is 50 (handlers)",
            "type": "string"
        },
        "type": {
            "description": "Proxy handling. One of: request-response, request-only, headers, redirect, system, internal, request-response-1.0. The default is request-response",
            "type": "string"
        },
        "redirectPath": {
            "description": "If given, path that we internally redirect to",
            "type": "string"
        },
        "unit": {
            "description": "Delay unit",
            "type": "string"
        },
        "delay": {
            "description": "Delay between calls",
            "type": "string"
        },
        "permissionsRequired": {
            "description": "Required permissions for this entry",
            "type": [
                "array",
                "null"
            ],
            "items": {
                "type": "string"
            }
        },
        "permissionsDesired": {
            "description": "Desired permissions for this entry",
            "type": [
                "array",
                "null"
            ],
            "items": {
                "type": "string"
            }
        },
        "modulePermissions": {
            "description": "Module permissions for this entry",
            "type": [
                "array",
                "null"
            ],
            "items": {
                "type": "string"
            }
        },
        "delegateCORS": {
            "description": "Okapi handles CORS by default. Set to true to delegate CORS handling to the module. This only applies to calls made via /_/invoke/tenant/<tid>/<path>",
            "type": "boolean"
        }
    }
}