/// <summary> /// Send an arbitrary string to the user's sandbox /// </summary> /// <param name="data"></param> /// <returns></returns> private IEnumerator SetUserSandboxDataCor(string data) { var requestData = RewardMobWebRequestFactory.CreateSendSandboxDataRequest(data); WWW postUserDataRequest = new WWW(RewardMobEndpoints.GetSendUserDataEndpoint(), requestData.Payload, requestData.Headers); yield return(postUserDataRequest); }
/// <summary> /// Get the user data stored in the user's sandbox /// </summary> /// <param name="callback"></param> /// <returns></returns> private IEnumerator GetUserSandboxDataCor(Action <string> callback) { var requestData = RewardMobWebRequestFactory.CreateGetSandboxDataRequest(); WWW postUserDataRequest = new WWW(RewardMobEndpoints.GetSendUserDataEndpoint(), requestData.Payload, requestData.Headers); yield return(postUserDataRequest); callback(postUserDataRequest.text); }