Siege of Taif
The Siege of Taif took place in 630, as the Muslims besieged the city of Taif after their victory in the Battle of Hunayn and Autas. However, the city did not succumb to the siege. One of their chieftains, Urwah ibn Mas'ud, was absent in Yemen during that siege. Muhammad brought catapults and testudos to use against the fortress, but was unable to penetrate it, with the weapon.
Sunni sources state regarding the Siege of Ta'if:
Abu Sufyan ibn Harb lost his first eye in the Siege of Taif. He told Muhammad of his loss for Allah to which Muhammad said “Which would you prefer: An eye in heaven or shall I pray to Allah that he brings it back?” To this Abu Sufyan said he would rather have his eye in heaven. He lost his other eye in the Battle of Yarmouk.
Blockade of Taif
A few unsuccessful attempts was made by the Prophet to break through the gates of Taif. Muhammad even allegedly copied the Roman Testudo formation in this siege, but it was reported that the Taif inhabitants break this siege by dropping hot irons upon the Muslim armies from the city walls. Alas, Muhammad threaten to burn and cut down the vineyard, as he saw no other way to force the people of Taif to surrender. He offered amnesty to those who surrendered themselves to Islam. Only 20 people surrendered and became followers of Muhammad.
The siege went on for half a month and some soldiers were becoming impatient. 
Muhammad desired to get the chief of the Banu Hawazan (called Malik) on his side, and promised that his family will be released and all his property given back, if he embraced Islam. He accepted the offer and became a Muslim and engaged in a constant warfare with the citizens of Taif. Malik captured their cattle's wherever they grazed and put them in a difficult situation. 
Although the siege was unsuccessful, Muhammad vowed to return to Ta'if after the sacred months in which fighting was forbidden were over. During this period, the inhabitants of Ta'if, the Banu Thaqif, sent a delegation to Mecca; they begged Muhammad to let them continue to worship their Goddess Al-lāt for a period of three years, Muhammad refused the proposal, he would only accpet their surrender if they agreed to adopt Islam immediately and let the Muslims destroy their temple, eventually the Banu Thaqif consented to Muhammad's demands: they surrendered and allowed the Muslims into their city to detsroy the temple.