/// <summary> /// Returns the list of email campaigns you have in your Sendloop account /// </summary> /// <returns></returns> public async Task <ResultCampaignGetList> GetListAsync(ParamCampaignList param) { if (param.IsNull()) { param = new ParamCampaignList(); } var arry = new Dictionary <string, string> { { nameof(param.IgnoreApproval), param.IgnoreApproval.ToBinary().ToString() }, { nameof(param.IgnoreDrafts), param.IgnoreDrafts.ToBinary().ToString() }, { nameof(param.IgnoreFailed), param.IgnoreFailed.ToBinary().ToString() }, { nameof(param.IgnorePaused), param.IgnorePaused.ToBinary().ToString() }, { nameof(param.IgnoreSending), param.IgnoreSending.ToBinary().ToString() }, { nameof(param.IgnoreSent), param.IgnoreSent.ToBinary().ToString() } }; return(await Http.Value.PostAsync <ResultCampaignGetList>(SendloopAddress.CampaignGetList, arry)); }
/// <summary> /// Returns the list of email campaigns you have in your Sendloop account /// </summary> /// <returns></returns> public ResultCampaignGetList GetList(ParamCampaignList param) => GetListAsync(param).GetAwaiter().GetResult();