### Is there an existing issue for this?

- [X] I have searched the existing issues

### Current Behavior

VTL template for request is not properly processed. 

Testing with sample project provided at https://github.com/localstack/localstack-terraform-samples/tree/master/apigateway-lambda-velocity several parameters of the request, such as path and identity are not properly parsed. 

For a request like this:

```
curl -X POST "0naclskncu.execute-api.localhost.localstack.cloud:4566/local/test" -H 'content-type: application/json' -d '{ "greeter": "cesar" }'
```

the result is:
```
{
"body": {"greeter": "cesar"},
"method": "POST",
"principalId": "",
"stage": "local",

"cognitoPoolClaims" : {

"sub": ""
},

"enhancedAuthContext":     {
}
,

"headers":     {
}
,

"query":     {
}
,

"path":     {

""proxy"":
""test""
}
,

"identity":     {

""accountId"":
"0"
,
""sourceIp"":
""172.17.0.1""
,
""userAgent"":
""curl/7.84.0""
}
,

"stageVariables":     {
}
,

"requestPath": "/{proxy+}"
}
```
Notice the extra double quotes on path and identity values which results in a non valid JSON document.

From the localstack logs:

```
botocore.errorfactory.UnsupportedMediaTypeException: An error occurred (UnsupportedMediaTypeException) when calling the Invoke operation: The payload is not JSON:


{
"body": {"greeter": "cesar"},
"method": "POST",
"principalId": "",
"stage": "local",

"cognitoPoolClaims" : {

"sub": ""
},

"enhancedAuthContext":     {
}
,

"headers":     {
}
,

"query":     {
}
,

"path":     {

""proxy"":
""test""
}
,

"identity":     {

""accountId"":
"0"
,
""sourceIp"":
""172.17.0.1""
,
""userAgent"":
""curl/7.84.0""
}
,

"stageVariables":     {
}
,

"requestPath": "/{proxy+}"
}

2022-11-16T09:47:17.833  INFO --- [   asgi_gw_0] localstack.request.http    : POST /local/test => 400; Request(b'{ "greeter": "cesar" }', headers={'Host': '0naclskncu.execute-api.localhost.localstack.cloud:4566', 'User-Agent': 'curl/7.84.0', 'Accept': '*/*', 'content-type': 'application/json', 'Content-Length': '22', 'x-localstack-tgt-api': 'apigateway'}); Response(b'{"Type": "User", "message": "Error invoking integration for API Gateway ID \'0naclskncu\': An error occurred (UnsupportedMediaTypeException) when calling the Invoke operation: The payload is not JSON:  \\n\\n  \\n  {\\n    \\"body\\": {\\"greeter\\": \\"cesar\\"},\\n    \\"method\\": \\"POST\\",\\n    \\"principalId\\": \\"\\",\\n    \\"stage\\": \\"local\\",\\n\\n    \\"cognitoPoolClaims\\" : {\\n\\n       \\"sub\\": \\"\\"\\n    },\\n\\n        \\"enhancedAuthContext\\":     {\\n        }\\n  ,\\n\\n        \\"headers\\":     {\\n        }\\n  ,\\n\\n        \\"query\\":     {\\n        }\\n  ,\\n\\n        \\"path\\":     {\\n    \\n                        \\"\\"proxy\\"\\":\\n          \\"\\"test\\"\\"\\n                  }\\n  ,\\n\\n        \\"identity\\":     {\\n    \\n                        \\"\\"accountId\\"\\":\\n          \\"0\\"\\n           ,     \\n                        \\"\\"sourceIp\\"\\":\\n          \\"\\"172.17.0.1\\"\\"\\n           ,     \\n                        \\"\\"userAgent\\"\\":\\n          \\"\\"curl/7.84.0\\"\\"\\n                  }\\n  ,\\n\\n        \\"stageVariables\\":     {\\n        }\\n  ,\\n\\n    \\"requestPath\\": \\"/{proxy+}\\"\\n  }\\n", "__type": "InvalidRequest"}', headers={'Content-Type': 'text/html; charset=utf-8', 'x-amzn-errortype': 'InvalidRequest', 'Content-Length': '1108', 'Connection': 'close'})
```

### Expected Behavior

The template should render a proper JSON document

### 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`)

    LS_LOG=trace-internal localstack start

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

    - localstack-terraform-samples/apigateway-lambda-velocity $ terraform init; terraform plan; terraform apply --auto-approve
   - localstack-terraform-samples/apigateway-lambda-velocity $ curl -X POST "9b2k2o2wd1.execute-api.localhost.localstack.cloud:4566/local/test" -H 'content-type: application/json' -d '{ "greeter": "cesar" }'

*** APIGW ID is taked from the terraform apply output


### Environment

```markdown
- OS: Macos 13.0.1
- LocalStack: 1.2.1.dev 
- Docker Desktop: v4.13.1
```


### Anything else?

Searching for velocity bug, I encountered bug https://github.com/localstack/localstack/issues/5587 which is resolved but actually the bug is still there.
import base64
import json
import os
import re
from collections import namedtuple
from typing import Callable, Optional
import pytest
import xmltodict
from botocore.exceptions import ClientError
from jsonpatch import apply_patch
from moto.apigateway import apigateway_backends
from requests.s import Response
from requests.structures import CaseInsensitiveDict
from localstack import config
from localstack.aws.accounts import get_aws_account_id
from localstack.aws.api.lambda_ import Runtime