IMC, there is a temple that practises temple prostitution. The reasons (or benefits) are numerous.
First, each act in the temple strengthens the goddess.
Second, for each act there is a donation, which means the temple makes quite some money from the practise. (We do not have set the price, just supposed that the bigger the donation, the more attention is paid to the worshipper donating.)
Third, that kind of services gains the temple more influence with nobles and other temples alike, both individually (with many influential people getting targetted by their "own" priestess, but also on a grander scale. The leadership of the army, f.e., is glad for some relatively safe recreational opportunities for the soldiers, where disease and enemy spies do not run rampant. In the same vein the city officials are glad that there is a controlled enviroment for those practises, both because it prevents diseases but also because the alternative would probably be a chain of brothels run by thieves and the like.
Fourth, pillow talk sells. Not only do the priestess, acolytes and slaves overhear whatever the worshippers in the temple may let slip, but the priestesses and the other temple personel have numerous occasions to gather information at receptions, parties etc. of all social classes. The information they gather gives them even more influence.
All in all there are a lot of good reasons for that temple to practise prostitution - although they do not call it like that.