{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "required": [
        "Type",
        "HttpMethod",
        "ResourceId",
        "RestApiId"
    ],
    "additionalProperties": false,
    "properties": {
        "Type": {
            "type": "string",
            "enum": [
                "HTTP",
                "AWS",
                "MOCK"
            ]
        },
        "HttpMethod": {
            "type": "string",
            "enum": [
                "DELETE",
                "GET",
                "HEAD",
                "OPTIONS",
                "PATCH",
                "POST",
                "PUT"
            ]
        },
        "ResourceId": {
            "type": "string",
            "pattern": "^[a-z0-9]+$"
        },
        "RestApiId": {
            "type": "string",
            "pattern": "^[a-z0-9]{10}$"
        },
        "CacheKeyParameters": {
            "type": "array",
            "items": {
                "type": "string"
            }
        },
        "CacheNamespace": {
            "type": "string"
        },
        "Credentials": {
            "type": "string"
        },
        "IntegrationHttpMethod": {
            "type": "string"
        },
        "RequestTemplates": {
            "type": "object",
            "properties": {},
            "patternProperties": {
                ".+": {
                    "type": "string"
                }
            },
            "additionalProperties": false
        },
        "RequestParameters": {
            "type": "object",
            "properties": {},
            "patternProperties": {
                "^integration\\.request\\.(querystring|path|header)\\..+$": {
                    "type": "string",
                    "pattern": "^(method\\.request\\.(querystring|header|path)\\..+)|('.*')$"
                }
            },
            "additionalProperties": false
        },
        "Uri": {
            "type": "string"
        }
    }
}