### Is there an existing issue for this?

- [X] I have searched the existing issues

### Current Behavior

Currently the VTL template for `request_templates` is not processed properly:

```
#set( $body = $input.json("$") )

#macro( loop $map )
{
    #foreach($key in $map.keySet())
        #set( $k = $util.escapeJavaScript($key) )
        #set( $v = $util.escapeJavaScript($map.get($key)).replaceAll("\\'", "'") )
        "$k": "$v"
        #if( $foreach.hasNext ) , #end
    #end
}
#end

{
    "enhancedAuthContext": #loop($context.authorizer),

    "headers": #loop($input.params().header),

    "query": #loop($input.params().querystring),

    "path": #loop($input.params().path),

    "identity": #loop($context.identity),

    "stageVariables": #loop($stageVariables),
}
EOF
}
```

results in,

```
'

{
    "enhancedAuthContext": {
    }
,

    "headers": {
    }
,

    "query": {
    }
,

    "path": {
    }
,

    "identity": {
    }
,

    "stageVariables": {
    }
,
}
'
```

### Expected Behavior

The template should be rendered and have the JSON properties.

### How are you starting LocalStack?

Custom (please describe below)

### Steps To Reproduce

#### How are you starting localstack (e.g., `bin/localstack` command, arguments, or `docker-compose.yml`)

    docker run localstack/localstack

#### Client commands (e.g., AWS SDK code snippet, or sequence of "awslocal" commands)

    awslocal s3 mb s3://mybucket


### Environment

```markdown
- OS: MacOS
- LocalStack: 0.14
```


### Anything else?

This example can be used to validate.
https://github.com/localstack/localstack-terraform-samples/tree/master/apigateway-lambda-velocity
return to_response_json("documentationpart", data, api_id=api_id)
def to_base_mapping_response_json(domain_name, base_path, data):
    self_link = "/domainnames/%s/basepathmappings/%s" % (domain_name, base_path)
    return to_response_json("basepathmapping", data, self_link=self_link)
def to_account_response_json(data):
    return to_response_json("account", data, self_link="/account")
def to_vpc_link_response_json(data):
    return to_response_json("vpclink", data)
def to_client_cert_response_json(data):
    return to_response_json("clientcertificate", data, id_attr="clientCertificateId")
def to_response_json(model_type, data, api_id=None, self_link=None, id_attr=None):
    if isinstance(data, list) and len(data) == 1:
        data = data[0]
    id_attr = id_attr or "id"
    result = common.clone(data)
    if not self_link:
        self_link = "/%ss/%s" % (model_type, data[id_attr])
        if api_id:
            self_link = "/restapis/%s/%s" % (api_id, self_link)
    if "_links" not in result:
        result["_links"] = {}
    result["_links"]["self"] = {"href": self_link}
    result["_links"]["curies"] = {
        "href": "https://docs.aws.amazon.com/apigateway/latest/developerguide/restapi-authorizer-latest.html",
        "name": model_type,
        "templated": True,
    }
    result["_links"]["%s:delete" % model_type] = {"href": self_link}
    return result
def find_api_subentity_by_id(api_id, entity_id, map_name):