added get-subtypes API, integrated into HTML UI