I agree it is not a good user experience when the calendars accumulate each year.
I acknowledge and as already pointed out, users can simply unsubscribe or hide the calendars themselves. In an ideal world this would be enough but I don't think it is reasonable for all staff/students to have to do that for all Google Classrooms they were ever a member of.
I haven't used GAM but it would be possible as the APIs do exist. I have done it with the PSGSuite PowerShell module before.
Some rough pointers for you:
- The calendar IDs are returned with each course object from the Classroom API.
- You can get the list of calendar subscriptions for each user, one at a time using the Calendar API.
- Where a subscription is found for one of the calendars you remove it for each user, one at a time, using the Calendar API.
@Kristal or other Googles, can this feedback be provided to the Google Classroom team?