The operation was in the month of Shawwal in the second year of Hijrah, after returning from Badr. Al-Kudr is the place that contains the water of Banu Saleem, which is in Najd, on the northern trade route between Mecca and Ash-Sham.
The Prophet (peace be upon him) led the army in this operation, straight after the battle of Badr
The anger of the enemies of Allah intensified after the major battle of Badr. The enemies included the Jews, Bedouins, and the tribes who had agreed to side with Quraish, including Banu Saleem who had mobilized to attack Medinah. Therefore, P, who was always wary of the evil plots of the enemy, made a surprise attack on Banu Saleem.
The first news that reached the Prophet (peace be upon him) in Medinah after the battle of Badr was that Banu Saleem, one of the Ghatafan tribes, had mobilized its forces to attack Medinah.
They were a group of many tribes who had agreed to side with Quraish, and intended to take revenge for their men that were killed in the battle of Badr.
Therefore, the Prophet (peace be upon him) made a surprise attack on Banu Saleem, who had mobilized 200 riders, attacking them in their homes.
The Prophet (peace be upon him) left Sabaa ibn Arfatah, some reports state Ibn Um Maktoom, in Medinah to look after the affairs there [Ibn Hesham, 2/44].
When the Prophet (peace be upon him) reached Banu Saleem at Al-Kudr, Banu Saleem fled leaving 500 cattle in the valley, which the army of Medinah took as spoils of war.
A youngster called Yasar was injured, so the Prophet (peace be upon him) took him as a captive. The Prophet stayed 3 days in the town of Banu Saleem, and then returned to Medinah.
There was no fighting in this military operation, and the Prophet (peace be upon him) took only one youth as a captive. The Muslims took 500 cattle as spoils of war.
The bravery of the Prophet (peace be upon him) as a fighter and a leader in the battles of the Muslims was clear in this operation; he did not limit himself to only the noble task of calling others to Allah and taking care of the affairs of the Muslims.
Taking precautions and being vigilant is a way of protecting the Islamic nation.
The mercy of the Prophet (peace be upon him) with captives (eg. the youngster Yassar, who he later freed).