def webpush(subscription_info,<EOL>data=None,<EOL>vapid_private_key=None,<EOL>vapid_claims=None,<EOL>content_encoding="<STR_LIT>",<EOL>curl=False,<EOL>timeout=None,<EOL>ttl=<NUM_LIT:0>):
vapid_headers = None<EOL>if vapid_claims:<EOL><INDENT>if not vapid_claims.get('<STR_LIT>'):<EOL><INDENT>url = urlparse(subscription_info.get('<STR_LIT>'))<EOL>aud = "<STR_LIT>".format(url.scheme, url.netloc)<EOL>vapid_claims['<STR_LIT>'] = aud<EOL><DEDENT>if not vapid_claims.get('<STR_LIT>'):<EOL><INDENT>vapid_claims['<STR_LIT>'] = int(time.time()) + (<NUM_LIT:12> * <NUM_LIT> * <NUM_LIT>)<EOL><DEDENT>if not vapid_private_key:<EOL><INDENT>raise WebPushException("<STR_LIT>")<EOL><DEDENT>if isinstance(vapid_private_key, Vapid):<EOL><INDENT>vv = vapid_private_key<EOL><DEDENT>elif os.path.isfile(vapid_private_key):<EOL><INDENT>vv = Vapid.from_file(<EOL>private_key_file=vapid_private_key)  <EOL><DEDENT>else:<EOL><INDENT>vv = Vapid.from_string(private_key=vapid_private_key)<EOL><DEDENT>vapid_headers = vv.sign(vapid_claims)<EOL><DEDENT>response = WebPusher(subscription_info).send(<EOL>data,<EOL>vapid_headers,<EOL>ttl=ttl,<EOL>content_encoding=content_encoding,<EOL>curl=curl,<EOL>timeout=timeout,<EOL>)<EOL>if not curl and response.status_code > <NUM_LIT>:<EOL><INDENT>raise WebPushException("<STR_LIT>".format(<EOL>response.status_code, response.reason),<EOL>response=response)<EOL><DEDENT>return response<EOL>
One call solution to endcode and send `data` to the endpoint
    contained in `subscription_info` using optional VAPID auth headers.

    in example:

    .. code-block:: python

    from pywebpush import python

    webpush(
        subscription_info={
            "endpoint": "https://push.example.com/v1/abcd",
            "keys": {"p256dh": "0123abcd...",
                     "auth": "001122..."}
             },
        data="Mary had a little lamb, with a nice mint jelly",
        vapid_private_key="path/to/key.pem",
        vapid_claims={"sub": "YourNameHere@example.com"}
        )

    No additional method call is required. Any non-success will throw a
    `WebPushException`.

:param subscription_info: Provided by the client call
:type subscription_info: dict
:param data: Serialized data to send
:type data: str
:param vapid_private_key: Vapid instance or path to vapid private key PEM \
                          or encoded str
:type vapid_private_key: Union[Vapid, str]
:param vapid_claims: Dictionary of claims ('sub' required)
:type vapid_claims: dict
:param content_encoding: Optional content type string
:type content_encoding: str
:param curl: Return as "curl" string instead of sending
:type curl: bool
:param timeout: POST requests timeout
:type timeout: float or tuple
:param ttl: Time To Live
:type ttl: int
:return requests.Response or string