After the Messenger of Allah (peace be upon him) laid the foundations of the new Islamic society, the Messenger of Allah started to organize the relationship with non-Muslims. Therefore, the Messenger of Allah (peace be upon him) called the Jews in Medinah, and wrote an agreement between him and them.
One of the points the Messenger of Allah wrote in the treaty was that he gave them total freedom with regards to religious matters and their money, each party in the contract had to help the one who was attacked, and they should advise each other and be righteous, not sinning, and help the oppressed. Moreover, the Jews should pay, along with the believers, for any wars they were involved in, and they should overcome those who attack Yathrib. And it was prohibted for the parties in this agreement to fight in Yathrib [The Prophet’s Biography by Ibn Hesham].
Abdullah ibn Salam (may Allah be pleased with him), their leader and scholar, was quick to respond. He embraced Islam, but most of the Jewish masses did not accept anything but disbelief. When Abdullah ibn Salam heard that the Messenger of Allah (peace be upon him) had entered Medinah, he went to him to ask him questions that only a Prophet would know.
When Abdullah ibn Salam saw the Messenger of Allah, he said, “When his face became clear, I realized that it was not the face of a liar.” And when he heard the Messenger of Allah’s reply to his questions, he believed in him at that very time and spot. Then he said to the Messenger of Allah, <‘The Jews are liars, and if they should come to know about my conversion to Islam before you ask them (about me), they would tell a lie about me.’ The Jews came and Abdullah entered the house. Then the Messenger of Allah asked, ‘Who is Abdullah ibn Salam?’ They replied, ‘He is one of our scholars and the son of one of our scholars, and one of the best men among us and the son of one of the best men among us.’ The Messenger of Allah then said, ‘What would you say if Abdullah ibn Salam embraced Islam?’ They replied, ‘May Allah protect him from that.’ At that time, Abdullah entered and said, ‘I bear witness that there is no god (worthy of worship) but Allah, and that Muhammed is the Messenger of Allah.’ They then said, ‘He is the worst of us and the son of the worst of us,’ and they continued to talk badly about him> [related by Al-Bukhari].
Another narration states Abdullah ibn Salam as saying “Oh Jews, fear Allah. By Allah, for Whom there is no god but Him, you know he is the Messenger of Allah and that he brought the truth.” But they replied, “You have lied” [related by Al-Bukhari].