### Is there an existing issue for this?

- [X] I have searched the existing issues and read the documentation

### Question

Hello,

I am new in localstack and AWS too. I created AWS Lambda handler, which is integrated with APIGateway. This handler accepts multipart/form-data, because request has to have image in it. If request has all required data in right form and right values, which refer to some data in DynamoDB, then everything is fine, lambda returns response with 200 status code. When data are not in right form, Lambda returns response with 400 status code, but still nothing crashes. But when values stated above are not valid, specifically that values refer to other items in database, which do not exist, my lambda finds that out and returns response with 404 status code and error message in JSON form (Content-Type in header is set to JSON too). After that I see in localstack logs my "Not Found" response, so i assume that lambda successfully handled request, but then there is UnicodeDecodeError, which you can see on image. When I changed status code from 404 to 200 or even 403, I didn't get that error. What am I doing wrong?

Thank you.

![image](https://user-images.githubusercontent.com/93795128/158701029-b595d6af-7897-49a5-92dc-2c51a292a9bc.png)


### Anything else?

_No response_
from localstack.services.awslambda import lambda_api
from localstack.services.generic_proxy import ProxyListener
from localstack.services.kinesis import kinesis_listener
from localstack.services.stepfunctions.stepfunctions_utils import await_sfn_execution_result
from localstack.utils import common
from localstack.utils.analytics import event_publisher
from localstack.utils.aws import aws_responses, aws_stack
from localstack.utils.aws.aws_responses import (
    LambdaResponse,
    flask_to_requests_response,
    request_response_stream,
    requests_response,
)
from localstack.utils.aws.request_context import MARKER_APIGW_REQUEST_REGION, THREAD_LOCAL
from localstack.utils.common import camel_to_snake_case, json_safe, long_uid, to_bytes, to_str
from localstack.utils.http import add_query_params_to_url
LOG = logging.getLogger(__name__)
TARGET_REGEX_PATH_S3_URI = (
    r"^arn:aws:apigateway:[a-zA-Z0-9\-]+:s3:path/(?P<bucket>[^/]+)/(?P<object>.+)$"
)
TARGET_REGEX_ACTION_S3_URI = r"^arn:aws:apigateway:[a-zA-Z0-9\-]+:s3:action/(?:GetObject&Bucket\=(?P<bucket>[^&]+)&Key\=(?P<object>.+))$"
PATH_REGEX_USER_REQUEST = (
    r"^/restapis/([A-Za-z0-9_\\-]+)(?:/([A-Za-z0-9\_($|%%24)\\-]+))?/%s/(.*)$" % PATH_USER_REQUEST
)
HOST_REGEX_EXECUTE_API = (
    r"(?:.*://)?([a-zA-Z0-9-]+)\.execute-api\.(%s|([^\.]+)\.amazonaws\.com)(.*)"
    % LOCALHOST_HOSTNAME
)
REQUEST_TIME_DATE_FORMAT = "%d/%b/%Y:%H:%M:%S %z"
class AuthorizationError(Exception):