def METHOD_NAME(dest: str, amount: int, message: str) -> str:
    scheme = Net.BITCOIN_URI_PREFIX
    query_parts = ['sv']
    scheme_idx = dest.find(":")
    if scheme_idx != -1:
        scheme = dest[:scheme_idx]
        dest = dest[scheme_idx+1:]
        query_parts = []
    if amount:
        query_parts.append('amount=%s'%format_satoshis_plain(amount))
    if message:
        query_parts.append('message=%s'%urllib.parse.quote(message))
    query_string = ""
    if len(query_parts):
        query_string = '&'.join(query_parts)
    p = urllib.parse.ParseResult(scheme=scheme, netloc='', path=dest,
        params='', query=query_string, fragment='')
    return urllib.parse.urlunparse(p)