Unintentionally summoned by Cordelia, Anyanka came to Sunnydale as a vengeance demon hell-bent on revenge. Thanks to Giles and The White Hats, she was made mortal when the source of her power [The Amulet] was destroyed.
“Anyanka raised a demon to ruin her unfaithful lover. The demon did her bidding – but then cursed her and turned her into a sort of patron saint for scorned women. Apparently the cry of a wronged woman is like a siren’s call to Anyanka.”
~Giles