{
  "typeName" : "AWS::ApiGatewayV2::RoutingRule",
  "description" : "Schema for AWS::ApiGatewayV2::RoutingRule",
  "sourceUrl" : "https://github.com/aws-cloudformation/aws-cloudformation-resource-providers-apigatewayv2.git",
  "properties" : {
    "RoutingRuleId" : {
      "description" : "RoutingRule Id generated by service",
      "type" : "string"
    },
    "RoutingRuleArn" : {
      "type" : "string",
      "description" : "Amazon Resource Name (ARN) of the resource."
    },
    "DomainNameArn" : {
      "type" : "string",
      "description" : "The amazon resource name (ARN) of the domain name resource."
    },
    "Priority" : {
      "type" : "integer"
    },
    "Conditions" : {
      "type" : "array",
      "items" : {
        "$ref" : "#/definitions/Condition"
      }
    },
    "Actions" : {
      "type" : "array",
      "items" : {
        "$ref" : "#/definitions/Action"
      }
    }
  },
  "definitions" : {
    "Condition" : {
      "type" : "object",
      "properties" : {
        "MatchHeaders" : {
          "$ref" : "#/definitions/MatchHeaders"
        },
        "MatchBasePaths" : {
          "$ref" : "#/definitions/MatchBasePaths"
        }
      }
    },
    "MatchHeaders" : {
      "type" : "object",
      "required" : [ "AnyOf" ],
      "properties" : {
        "AnyOf" : {
          "type" : "array",
          "items" : {
            "$ref" : "#/definitions/MatchHeaderValue"
          }
        }
      }
    },
    "MatchBasePaths" : {
      "type" : "object",
      "required" : [ "AnyOf" ],
      "properties" : {
        "AnyOf" : {
          "type" : "array",
          "items" : {
            "type" : "string"
          }
        }
      }
    },
    "MatchHeaderValue" : {
      "type" : "object",
      "required" : [ "Header", "ValueGlob" ],
      "properties" : {
        "Header" : {
          "type" : "string"
        },
        "ValueGlob" : {
          "type" : "string"
        }
      }
    },
    "Action" : {
      "type" : "object",
      "required" : [ "InvokeApi" ],
      "properties" : {
        "InvokeApi" : {
          "$ref" : "#/definitions/ActionInvokeApi"
        }
      }
    },
    "ActionInvokeApi" : {
      "type" : "object",
      "required" : [ "ApiId", "Stage" ],
      "properties" : {
        "ApiId" : {
          "type" : "string"
        },
        "Stage" : {
          "type" : "string"
        },
        "StripBasePath" : {
          "type" : "boolean"
        }
      }
    }
  },
  "additionalProperties" : false,
  "required" : [ "DomainNameArn", "Priority", "Conditions", "Actions" ],
  "createOnlyProperties" : [ "/properties/DomainNameArn" ],
  "primaryIdentifier" : [ "/properties/RoutingRuleArn" ],
  "readOnlyProperties" : [ "/properties/RoutingRuleArn", "/properties/RoutingRuleId" ],
  "tagging" : {
    "taggable" : false,
    "tagOnCreate" : false,
    "tagUpdatable" : false,
    "cloudFormationSystemTags" : false
  },
  "handlers" : {
    "create" : {
      "permissions" : [ "apigateway:CreateRoutingRule" ]
    },
    "read" : {
      "permissions" : [ "apigateway:GetRoutingRule" ]
    },
    "update" : {
      "permissions" : [ "apigateway:UpdateRoutingRule" ]
    },
    "delete" : {
      "permissions" : [ "apigateway:DeleteRoutingRule" ]
    },
    "list" : {
      "permissions" : [ "apigateway:ListRoutingRules" ],
      "handlerSchema" : {
        "properties" : {
          "DomainNameArn" : {
            "$ref" : "resource-schema.json#/properties/DomainNameArn"
          }
        },
        "required" : [ "DomainNameArn" ]
      }
    }
  }
}