def METHOD_NAME(self, method, url, expect_stream=False):
    if (method, url) in self._entries:
        rbody, rcode, rheaders, is_streaming = self._entries.pop(
            (method, url)
        )
        if expect_stream != is_streaming:
            return None
        if not isinstance(rbody, str):
            rbody = json.dumps(rbody)
        if is_streaming:
            stripe_response = StripeStreamResponse(
                util.io.BytesIO(str.encode(rbody)), rcode, rheaders
            )
        else:
            stripe_response = StripeResponse(rbody, rcode, rheaders)
        return stripe_response
    return None