Jabir bin Abdullah reported,

On the day of Hudaybiyah we numbered one thousand four hundred, and we pledged allegiance to him while Umar held his hand beneath the tree, which was a samura tree. He said, "We pledged to him that we would not flee, but we did not pledge to him unto death."

Azami 7840

Sahih

عن جابر قال

كنا يوم الحديبية ألفا وأربعمائة فبايعناه، وعمر آخذ بيده تحت الشجرة، - وهي سمرة- وقال: بايعناه على أن لا نفر، ولم نبايعه على الموت.

الأعظمي 7840صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Jihad
Chapter
Rulings on jihad and its etiquette
Section
Pledging allegiance to the leader of the army before fighting
Numbering
Jami al-Kamil 7840 (2nd edition)
Azami 7840