def METHOD_NAME(cmd, repo):
    repo = repo_url_to_name(repo)
    secret_store = _get_github_token_secret_store(cmd)
    cache = secret_store.load()
    if isinstance(cache, list):
        for entry in cache:
            if isinstance(entry, dict) and repo in entry.get("repos", []):
                return entry.get("value")
    return None