def validate_template(TemplateBody=None, TemplateURL=None):
    """
    Validates a specified template. AWS CloudFormation first checks if the template is valid JSON. If it isn't, AWS CloudFormation checks if the template is valid YAML. If both these checks fail, AWS CloudFormation returns a template validation error.
    See also: AWS API Documentation
    
    Examples
    This example validates the specified template.
    Expected Output:
    
    :example: response = client.validate_template(
        TemplateBody='string',
        TemplateURL='string'
    )
    
    
    :type TemplateBody: string
    :param TemplateBody: Structure containing the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes. For more information, go to Template Anatomy in the AWS CloudFormation User Guide.
            Conditional: You must pass TemplateURL or TemplateBody . If both are passed, only TemplateBody is used.
            

    :type TemplateURL: string
    :param TemplateURL: Location of file containing the template body. The URL must point to a template (max size: 460,800 bytes) that is located in an Amazon S3 bucket. For more information, go to Template Anatomy in the AWS CloudFormation User Guide.
            Conditional: You must pass TemplateURL or TemplateBody . If both are passed, only TemplateBody is used.
            

    :rtype: dict
    :return: {
        'Parameters': [
            {
                'ParameterKey': 'string',
                'DefaultValue': 'string',
                'NoEcho': True|False,
                'Description': 'string'
            },
        ],
        'Description': 'string',
        'Capabilities': [
            'CAPABILITY_IAM'|'CAPABILITY_NAMED_IAM',
        ],
        'CapabilitiesReason': 'string',
        'DeclaredTransforms': [
            'string',
        ]
    }
    
    
    :returns: 
    (string) --
    
    """
    pass
