This is a very simple API for udtaleordbog.dk
https://udtaleordbog.dk/api_txt.php?q=eksempel will return /ɛk.ˈsɛm̰p.l/ in plain text.
Adding m=morf will instead return word formation and word class:
https://udtaleordbog.dk/api_txt.php?q=eksempel&m=morf will return Rod, sb. in plain text.