Sure At-Tawba

9:7

كَيْفَ يَكُونُ لِلْمُشْرِكِينَ عَهْدٌ عِندَ ٱللَّهِ وَعِندَ رَسُولِهِۦٓ إِلَّا ٱلَّذِينَ عَٰهَدتُّمْ عِندَ ٱلْمَسْجِدِ ٱلْحَرَامِ ۖ فَمَا ٱسْتَقَٰمُوا۟ لَكُمْ فَٱسْتَقِيمُوا۟ لَهُمْ ۚ إِنَّ ٱللَّهَ يُحِبُّ ٱلْمُتَّقِينَ

Wie sollte es denn für die Götzendiener bei Allah und bei Seinem Gesandten einen Vertrag geben, außer (für) diejenigen, mit denen ihr bei der geschützten Gebetsstätte einen Vertrag abgeschlossen habt? Solange sie sich euch gegenüber recht verhalten, verhaltet (auch) ihr euch ihnen gegenüber recht. Gewiß, Allah liebt die Gottesfürchtigen.

Tafsir 9:7

It is not correct for those who associate partners with Allah to have a treaty and an assurance of protection from Allah and His Messenger, except for the treaty you made with those idolaters at the Sacred Mosque in the Treaty of Al-Ḥudaybiyyah. As long as they uphold the treaty with you and do not break it, then you should also not break it. Allah loves those of His servants who are mindful of Him by fulfilling His instructions and avoiding His prohibitions.