游戏

游戏列表

GET /games

axios.get(`/games`).then(response => {
    console.log(response);

    this.games = response.data.data;
}).catch(error => {
    console.log(error);
});

游戏详情

GET /games/:game

const gameId = route.params.id;

axios.get(`/games/${gameId}`).then(response => {
    console.log(response);
}).catch(error => {
    console.log(error);
});
{
    "data": {
        "id": 2,
        "name": "Dragon and Tiger",
        "subtitle": "Draw every 60 seconds",
        "thumbnail": "https://example.com/games/thumbnails/dragon-and-tiger.png",
        "description": "Dragon and Tiger (Draw every 60 seconds).",
        "meta": {
            "seconds": "60",
            "dragon": "1.96",
            "tie": "15.68",
            "tiger": "1.96"
        }
    }
}
Last Updated:
Contributors: jinfakeji168