Open dorofino opened 9 years ago
@dorofino here's the code I used to get all grouping information:
MailChimpManager mc = new MailChimpManager(APIKEY);
var lists = mc.GetLists().Data;
foreach (var list in lists)
{
var listName = list.Name;
var listId = list.Id;
try
{
// When a group has no interest groupings, an exception is thrown
var groupings = mc.GetListInterestGroupings(listId);
foreach (var grouping in groupings)
{
var groupingId = grouping.Id;
var innerGroups = grouping.GroupNames;
foreach (var innerGroup in innerGroups)
{
var gname = innerGroup.Name;
var gbit = innerGroup.Bit;
}
}
}
catch
{ }
}
Hi ,
On your documentation you mentioned to add your Group ID. This ID is coming from where, MailChimp? if so the GroupID is a string and not a Int.
can some one help me with this, thanks
myMergeVars.Groupings[0].Id = 1234; // replace with your grouping id