Have data field automatically load next route after route is completed.

I’m looking into creating a series of chained maps for ultra running.
I have created the code (python soon to be web app) to split a route into sections that don’t exceed max turn by turn. This then saves them as course-name-0.gpx, course-name-1.gpx, course-name-2.gpx …

What I was thinking of doing was either:

Having a field that looks for other .gpx coded on the device and allows the user to overload the lap button on that screen so it laps and unloads the current course and loads the next course.

OR

Having a data-field that looks for the course completed popup and then checks for a course with an incremented name and then uses that event to trigger loading the next course.

I’ve looked around and some old questions here mention limited access to the navigation data via the API so any thoughts on this?