Example #1
0
    // create a new session
    public void CreateNewSession(string game, string version)
    {
        if (!apiService)
        {
            return;
        }
        Dictionary <string, object> payload = new Dictionary <string, object>();

        payload.Add("timeStart", EnableAPI.GetTimestamp());
        payload.Add("game", game.ToLower());
        payload.Add("version", version.ToLower());
        payload.Add("location", "Home");

        APIService.IRequest req = apiService.CreateRequest(APIService.RequestMethod.POST, this.endpoints["Session"], payload);
        CallAPI(req, this.callback, true);
    }