AlphaTac-AI / AlphaTac-Backend

The rock of AlphaTac AI
MIT License
1 stars 1 forks source link

DB Schema design #2

Closed PeiShang closed 6 years ago

PeiShang commented 6 years ago

Match detail

api:https://api.opendota.com/api/matches/{match_id}

{
    "match_id": , 
    "barracks_status_dire": ,
    "barracks_status_radiant": ,
    "dire_score": , 
    "dire_team_id": ,
    "radiant_score": ,
    "radiant_team_id": ,
    "duration": ,
    "draft_timings": {...},
    "first_blood_time": ,
    "radiant_gold_adv": ,
    "radiant_xp_adv": ,
    "radiant_win": ,
    "start_time": ,
    "tower_status_dire": ,
    "tower_status_radiant": ,
    "players":
        {
            "account_id": ,
            "assists": ,
            "deaths": ,
            "gold_per_min": ,
            "hero_damage": ,
            "hero_healing": ,
            "hero_id": ,
            "kills": ,
            "level": ,
            "teamfight_participation": ,
            "tower_damage": ,
            "towers_killed": ,
            "xp_per_min": ,
            "total_gold": ,
            "total_xp": ,
            "kda": ,
            "lane_efficiency": ,
            "lane_efficiency_pct": ,
            "lane_role": ,
        }
}

Teams

api: https://api.opendota.com/api/teams/{team_id} https://api.opendota.com/api/teams/{team_id}/players https://api.opendota.com/api/players/{account_id}

{
    "team_id": ,
    "rating": ,
    "wins": ,
    "losses": ,
    "last_match_time": ,
    "name": ,
    "tag": ,
    "logo_url": ,
    "players": 
        {
            "account_id": ,
            "name": ,
            "games_played": ,
            "wins": ,
            "solo_competitive_rank": ,
            "competitive_rank": ,
            "rank_tier": ,
            "leaderboard_rank": ,
            "mmr_estimate": {...}
        }
}

Team matches

api:https://api.opendota.com/api/teams/{team_id}/matches

{
    "team_id": ,
    "match_id": ,
    "start_time": ,
    "leagueid": ,
    "league_name"
}

先获取teams,再获取team matches, 最后获取match details