The Command to Prostrate was Given to Angels - Iblis was to Follow Suit
Addressing Iblis in Surah Al-A` raf, it was said: مَا مَنَعَكَ أَلَّا تَسْجُدَ إِذْ أَمَرْتُكَ (What stopped you from prostrating when I ordered you? - 7:12). This shows that the command to prostrate was given, along with the angels, to Iblis as well. However, the verses you have gone through a little earlier apparently give the sense that the command was particular to the an-gels. This could mean that the command was originally given to the angels but, as Iblis too was present among the angels, therefore, he too was covered by this command as a corollary - because, when the command went forth for the most august creation of Allah Ta’ ala, that is, the an-gels, that they pay their homage to Sayyidna 'Adam (علیہ السلام) ، it was obvious that any other creation was bound to follow suit under this command. It was for this reason that Iblis did not respond by saying that he was never asked to prostrate to begin with, so he could not be charged with the crime of non-compliance of the order. Perhaps, the words of the Qur’ an here: ' أَبَىٰ أَن يَكُونَ مَعَ السَّاجِدِينَ ' (He refused to be among those who prostrated - 30) may contain a hint in that direction. Rather than say: أَبَىٰ أَن یَّسجُدَ 1 that is, 'he refused to prostrate', what was actually said was: ' أَبَىٰ أَن يَكُونَ مَعَ السَّاجِدِينَ ' he refused to be among those who prostrated. This indicates that the main prostraters were after all the angels but Iblis too, being present with them, was reason-bound to join the prostrating an-gels. So, the Divine wrath was against his failure to join.