def METHOD_NAME(url):
    for sleep_time in [10, 30, 0]:
        reply = requests.METHOD_NAME(url, auth=auth)
        api_limit = (
            "message" in reply.json()
            and "API rate limit exceeded" in reply.json()["message"]
        )
        if not api_limit:
            break
        print("API rate limit exceeded, waiting..")
        time.sleep(sleep_time)
    reply.raise_for_status()
    return reply