No need to make this complicated. All that is necessary to start subscribing students is to enter a valid MailChimp API key, select the correct MailChimp list and create your segments with one click!
Display subscription form to enrolling students
When enabled for a course, a prompt to subscribe to your newsletter will display during course registration for new students.
Automatically generate list segments for courses
Every course which exists on your LearnDash site will generate a new segment within your chosen MailChimp list. This will allow you to very easily send communications to students enrolled in particular courses.