/// <summary>
        /// Delete statistics on an entity profile, will remove all rankings from associated leaderboards.
        /// </summary>
        public async Task <PlayFabResult <DeleteStatisticsResponse> > DeleteStatisticsAsync(DeleteStatisticsRequest request, object customData = null, Dictionary <string, string> extraHeaders = null)
        {
            if ((request?.AuthenticationContext?.EntityToken ?? PlayFabSettings.staticPlayer.EntityToken) == null)
            {
                throw new PlayFabException(PlayFabExceptionCode.EntityTokenNotSet, "Must call GetEntityToken before calling this method");
            }

            var httpResult = await PlayFabHttp.DoPost("/Statistic/DeleteStatistics", request, "X-EntityToken", PlayFabSettings.staticPlayer.EntityToken, extraHeaders, apiSettings);

            if (httpResult is PlayFabError)
            {
                var error = (PlayFabError)httpResult;
                PlayFabSettings.GlobalErrorHandler?.Invoke(error);
                return(new PlayFabResult <DeleteStatisticsResponse> {
                    Error = error, CustomData = customData
                });
            }

            var resultRawJson = (string)httpResult;
            var resultData    = PluginManager.GetPlugin <ISerializerPlugin>(PluginContract.PlayFab_Serializer).DeserializeObject <PlayFabJsonSuccess <DeleteStatisticsResponse> >(resultRawJson);
            var result        = resultData.data;

            return(new PlayFabResult <DeleteStatisticsResponse> {
                Result = result, CustomData = customData
            });
        }
 /// <summary>
 /// Delete statistics on an entity profile, will remove all rankings from associated leaderboards.
 /// </summary>
 public static void DeleteStatistics(DeleteStatisticsRequest request, Action <DeleteStatisticsResponse> resultCallback, Action <PlayFabError> errorCallback, object customData = null, Dictionary <string, string> extraHeaders = null)
 {
     PlayFabHttp.MakeApiCall("/Statistic/DeleteStatistics", request, AuthType.EntityToken, resultCallback, errorCallback, customData, extraHeaders);
 }