The city was ruled in turn by the Lydians , the Persians , and the Attalid kings of Pergamum , until 133 b.c. , when Attalus III bequeathed his kingdom , and Ephesus with it , to the Romans .
Attalus III died fighting the Romans , and it took a bloody battle for the Romans to seize control of the kingdom .