We know the usual myth that Meenakshi Amman was born as Pandiya princess and married Sivaperuman.
The Pandya king Malayattuvacan and his wife Kanchani(a chola princess) performed sacrifice and a daughter appeared in the sacrificial fire, aged three with three breast. She was named Thathakai and she ruled over the land and conquered all the lands in her sight and went to Kailash and when she saw Shiva, she fell in love with him and her third breast disappeared and she married him in Madurai and became Meenakshi , while Shiva became Somasundarar and lived in Madurai.
This legend is first written in Halasyamahatmayam(1400 AD) and a tamil book based on it ,Thiruvilayadalpuranam(around 16 century AD). The legend of Tatakai and Sundarapandiyan is also written in Sundarapantiyam(1564)
Megasthenes who was a Greek ambassador of at the court of Chandragupta Maurya,at the end of 4th century BC has given the account of a Pandya Princess who was worshiped as protective deity in Madurai.
During the Pallava’s reign in Tamil Nadu , they brought in a concept of King- God or rather they wanted the subjects to look upon them as Gods and tried to bring in some divine connection to their ancestry. The Pallavas claimed Vishnu,Bhrama,Angiras,Brhaspathi,Drona and Asvathamman as thier ancestors. The Chola rulers claimed they were sun dynasty with Sun as their ancestors.Simliarly the Pandyas calimed they were from Lunar race.
With the same objective in mind, the legend of Minakshi was produced as legitimation of divine origin of Pandya dynasty of Madurai . They changed the already prevalent Pre- Aryan protective deity as Minakshi( a form of Sakthi) to integrate them selves with the strong Bhramanic religion which got prevalent during the Pallava period.
 Tamil Traditions on Subramanya Murugan, Kamil V.Zvelebil,Institute of Asian Studies , Pg 18
 Tamil Traditions on Subramanya Murugan, Kamil V.Zvelebil,Institute of Asian Studies , Pg61
History and Culture of Tamil Nadu, Chitra Mahadevan,D.k.Print world , Pg 26
Tamil Traditions on Subramanya Murugan, Kamil V.Zvelebil,Institute of Asian Studies , Pg 17