To pull the chorus together, Bayley had to work with recordings captured through a wide range of devices, from mobile phones to webcams.
Three female singers from different parts of the country were selected to sing the verses and met with Bayley in Auckland for the recording.
Students provided ideas, wrote the music and co-wrote the lyrics through a discussion forum involving more than 300 posts.
Contributors included a student as young as 4, and others living in remote locations, including Maud Island in the Marlborough Sounds, accessible only by boat, as well as in Europe, the United States and Asia.
One student who lives 40 minutes from Turangi, without power or internet connection, was provided with a battery-powered MP3 player so she could practice her dance to the song. Her teacher then travelled to her house to record her on a mobile device.
The original chord structure of Echoes of the Sun was written on guitar by a year 10 student who lives near Whanganui.
Another student in year 12, from Auckland, collaborated to produce orchestral arrangements that Bayley then incorporated into the song.