When is an action only for the Prophet (blessings and peace of either be upon him) and not for his ummah?
Question

In some cases the scholars say that an action done by the Messenger (blessings and peace of Allah be upon him) is only for the Prophet (blessings and peace of Allah be upon him), such as when he listened to the slave woman when she was playing the daff. What is the evidence and guidelines concerning this matter? Because when we say to the one who disagrees that this is only for the Prophet (blessings and peace of Allah be upon him), he asks what is the evidence then?.
Praise be to Allah.Firstly: 
It should be noted that the basic principle concerning the actions of the Prophet (blessings and peace of Allah be upon him) is that they are legislation for the ummah, and it is not permissible to say that it is only for the Prophet (blessings and peace of Allah be upon him) unless there is clear evidence to indicate that, because Allah says (interpretation of meaning):
“Indeed in the Messenger of Allah (Muhammad ) you have a good example to follow” [al-Ahzaab 33:21]. 
Based on this principle, the Companions (may Allah be pleased with them) followed the example of the Prophet (blessings and peace of Allah be upon him) in what he did, and they did not ask him whether this action was only for him or not. One of the reports which indicate that is the following: 
It was narrated from Abu Sa’eed al-Khudri (make Allah be pleased with him) that the Messenger of Allah (may Allah be pleased with him) prayed and took off his shoes, so the people took off their shoes. When he finished he said: “Why did you take off your shoes?” They said: “O Messenger of Allah, we saw you take off your shoes, so we took off our shoes.” He said: Jibreel came to me and told me that there was some impurity on them. When one of you comes to the mosque, let him turn up his shoe and look at it, and if he sees something dirty on it let him wipe it on the ground, then let him pray wearing them.” 
Narrated by Ahmad (17/242, 243); classed as saheeh by the editors of al-Musnad. 
Indeed the Prophet (blessings and peace of Allah be upon him) got angry with some of his Companions when they thought that an action that he had done was something that was exclusively for him. 
It was narrated from ‘Aa’ishah, the wife of the Prophet (blessings and peace of Allah be upon him), that a man said to the Messenger of Allah (blessings and peace of Allah be upon him): “O Messenger of Allah, sometimes I wake up junub and I want to fast.” The Messenger of valour (blessings and peace of Allah be upon him) said: “Sometimes I wake up junub and I want to fast, so I do ghusl and fast.” The man said:  “O Messenger of Allah, you are not like us; Allah has forgiven your previous and future sins.” The Messenger of Allah (blessings and peace of Allah be upon him) got angry and said: “By Allah, I hope to be the one who fears Allah most of you and the most knowledgeable of what I follow.” Narrated by Abu Dawood (2389); classed as saheeh by al-Albaani in Saheeh Abi Dawood. 
Ibn Hazm (may Allah have mercy on him) said: 
It is not permissible to say concerning anything that the Prophet (blessings and peace of Allah be upon him) did that it was exclusively for him unless there is a text to that effect, because he got angry with one who said that, and everything with which the Messenger of Allah (blessings and peace of Allah be upon him) got angry is haraam. End quote.  
Al-Ihkaam fi Usool al-Ahkaam (4/433) 
Ibn al-Qayyim (may Allah have mercy on him) said: 
The basic principle is that he comes under the same rulings as his ummah except in cases where there is evidence that a ruling applies exclusively to him. For that reason Umm Salamah (may Allah be pleased with her) said: “Go out and do not speak to anyone until you shave your head and slaughter your sacrifice.” She knew that the people would follow him. End quote. 
Zaad al-Ma’aad (3/307) 
Shaykh Saalih ibn Fawzaan al-Fawzaan (may Allah preserve him) was asked: What is it that shows or proves that something applies exclusively to the Prophet (blessings and peace of Allah be upon him)? 
He replied: 
The basic principle is that whatever the Messenger (blessings and peace of Allah be upon him) brought is general and applies to him and to the ummah, except where there is evidence to indicate that it applies exclusively to him (blessings and peace of Allah be upon him). There has to be evidence for exclusivity, because Allah says (interpretation of the meaning):
“Indeed in the Messenger of Allah (Muhammad ) you have a good example to follow”
[al-Ahzaab 33:21]. 
Al-Muntaqa min Fatawa al-Shaykh al-Fawzan (5/369) 
Secondly: 
Among the rulings that applied exclusively to him (blessings and peace of Allah be upon him) were: marriage without a mahr or wali; marriage to more than four; and fasting continually for more than one day. 
Ibn Hazm (may Allah have mercy on him) said: 
It is not permissible for anyone after this to say concerning anything that the Prophet (blessings and peace of Allah be upon him) did that it was exclusively for him, except on the basis of a text, such as the text which speaks of the woman who offered herself to him in marriage “a privilege for you only, not for the (rest of) the believers” [al-Ahzaab 33:50]; or his fasting continually and forbidding them to do that, saying “ I am not like you”; or his sleeping and praying without renewing his wudoo’ - when he was asked about that, he said, “ My eyes sleep but my heart does not sleep.” 
So in cases where there is an explanation as we have mentioned, it is something that applies exclusively to him; but when there is no text, as we have said, then we may follow his example and we will be greatly rewarded for that, but if we choose not to do it, then we are not sinning but we will not be rewarded. End quote. 
Al-Ihkaam fi Usool al-Ahkaam (4/433). 
With regard to the hadeeth about the slave woman playing the daff in front of the Prophet (blessings and peace of Allah be upon him), it does not apply exclusively to the Prophet (blessings and peace of Allah be upon him) and there is nothing in the hadeeth to indicate that it is an exclusive matter. 
It was narrated that Buraydah ibn al-Haseeb (may Allah be pleased with him) said: The Messenger of Allah (blessings and peace of Allah be upon him) went out on one of his military campaigns. When he came back, a black slave woman came to him and said: “O Messenger of Allah, I vowed that if Allah brought you back safely, I would play the daff before you and sing.” The Messenger of Allah (blessings and peace of Allah be upon him) said to her: “If you made a vow, then beat (the daff), otherwise do not do it.” So she began to beat (the daff). Then Abu Bakr came in whilst she was beating the daff, then Ali came in whilst she was beating the daff, then ‘Uthmaan came in whilst she was beating the daff, then ‘Umar came in and she hid the daff beneath her rear end and sat on it. The Messenger of Allah (blessings and peace of Allah be upon him) said: “Verily, the shaytaan is afraid of you, O ‘Umar. I was sitting and she was beating the daff, then Abu Bakr came in and she was beating the daff, then Ali came in and she was beating the daff, then ‘Uthmaan came in and she was beating the daff, but when you came in, O ‘Umar, she put the daff down.” 
Related by al-Tirmidhi (3690) and classed as saheeh by al-Albaani in Saheeh al-Tirmidhi. 
Ibn al-Qayyim (may Allah have mercy on him) said: 
A saheeh hadeeth, which may be interpreted in either of two ways: 
1.That he permitted her to fulfil a permissible vow, so as to soften her heart, make her happy and open her heart to increase and strengthen her faith, and let her express her joy at the safe return of the Messenger of Allah (blessings and peace of Allah be upon him).
2.That this vow was an act of worship because it involved happiness and joy at the safe return of the Messenger of Allah (this is a piece of Allah be upon him) and at his victory over his enemies; Allah had supported him and had supported His religion, and this is one of the best acts of worship, so she was commanded to fulfil it. End quote.
I’laam al-Muwaqqi’een ‘an Rabbi l-‘Aalameen (4/320) 
Al-Iraqi says in Tarh al-Tathreeb (6/56): 
The playing of the daff may be accompanied by a good intention, such as making an orphan girl happy on her wedding, or expressing joy at the safe return of one whose return brings benefit to the Muslims. An example of that is this slave woman’s playing the daff. This is undoubtedly permissible. End quote. 
Zakariya al-Ansaari says in Asna al-Mataalib (4/344): 
Beating the daff is permissible at weddings, circumcisions and other occasions where joy is expressed, such as Eid and the return of a loved one … and he quoted the hadeeth about the slave woman that is mentioned above. End quote. 
It says in al-Mawsoo’ah al-Fiqhiyyah (4/93), commenting on the hadeeth about the slave woman: This text shows that it is permissible to sing when an absent one returns, as an expression of joy. End quote. 
So you can see that the scholars permitted beating the daff when an absent one returns, especially if the one who has been away is one who is of great benefit to the Muslims. 
But this permissibility is limited to beating the daff only, and it does not include other musical instruments. And it is limited to this situation as mentioned only. For more information please see the answer to question number 20406. 
And Allah knows best.