### Is there an existing issue for this?

- [X] I have searched the existing issues

### Current Behavior

I Created an REST APIGatway with lambda handler using AWS CDK. when I hit the API the response header content type is always  set to "text/html"  instead of `application/json` . even if I changed the response template or added the header to lambda returned response. when I deploy the same stack on AWS account  the response header is fine and work as expected

### Expected Behavior

Response Header content-type to be `application/json`

### How are you starting LocalStack?

  `localstack start` command

### Steps To Reproduce

#### How are you starting localstack (e.g., `bin/localstack` command`)

    `localstack start` command

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

I'm using AWS CDK typescript application and deploy it using `cdklocal` command on localstack

Using CDK follow the steps:
- create  REST ApiGateway
- create Lambda function 
- integrate lambda with APIGatway

On Command line:
- deploy using `cdklocal deploy` command

Finally
- test the endpoint and check the response header content-type




### Environment

```markdown
- OS: Windows 
- LocalStack: latest
```


### Anything else?

When I deploy the same stack on AWS account everything works fine and the response header content-type is `application/json`
result = sqs_client.receive_message(QueueUrl=queue_event_source_mapping)
                msg = result["Messages"][0]
                body = json.loads(msg["Body"])
                assert body["requestContext"]["condition"] == "RetryAttemptsExhausted"
                assert body["KinesisBatchInfo"]["batchSize"] == 1
                assert body["KinesisBatchInfo"]["streamArn"] == kinesis_arn
            retry(verify_failure_received, retries=50, sleep=5, sleep_before=5)
        finally:
            kinesis_client.delete_stream(StreamName=kinesis_name, EnforceConsumerDeletion=True)
            lambda_client.delete_event_source_mapping(UUID=event_source_mapping_uuid)
def _await_event_source_mapping_enabled(lambda_client, uuid, retries=30):
    def assert_mapping_enabled():
        assert lambda_client.get_event_source_mapping(UUID=uuid)["State"] == "Enabled"
    retry(assert_mapping_enabled, sleep_before=2, retries=retries)
def _await_dynamodb_table_active(dynamodb_client, table_name, retries=6):
    def assert_table_active():
        assert (
            dynamodb_client.describe_table(TableName=table_name)["Table"]["TableStatus"] == "ACTIVE"
        )
    retry(assert_table_active, retries=retries, sleep_before=2)
def _get_lambda_invocation_events(logs_client, function_name, expected_num_events, retries=30):
    def get_events():
        events = get_lambda_log_events(function_name, logs_client=logs_client)
        assert len(events) == expected_num_events
        return events
    return retry(get_events, retries=retries, sleep_before=2)