from typing import Union
import requests


def validate_request_success(resp: Union[requests.Response, str]):
    """
    Validate the response from the webhook request
    """
    return not isinstance(resp, str) and resp.status_code in [200, 201]