It is narrated from Sayyiduna al-Sharid bin Suwayd al-Thaqafi (may Allah be pleased with him), who said: I said: O Messenger of Allah! My mother left a bequest that a slave be freed on her behalf, and I have a black servant girl. He (peace and blessings be upon him) said: "Call her." So she came, and he (peace and blessings be upon him) asked: "Who is your Lord?" She said: Allah. He (peace and blessings be upon him) asked: "Who am I?" She said: The Messenger of Allah. He (peace and blessings be upon him) said: "Then free her, for she is a believer."
Hadith Referenceالمعجم الكبير للطبراني / باب الشين / 7226