from typing import Dict
from typing import Any


def text_response(message: str, code: int = 200) -> Dict[str, Any]:
    """Build text response

    Parameters
    ----------
    message : str
        Message body
    code :
        Http status code

    Returns
    -------
    Dict
        API gateway response
    """
    return {
        "statusCode": code,
        "headers": {"Content-Type": "text/plain"},
        "body": message,
    }