Mishneh Torah — Positive Mitzvot מצוות עשה, Chapter 82
The full Hebrew text of Mishneh Torah, Positive Mitzvot, Chapter 82, with English translation by Maimonides (Rambam).
לערוף פטר חמור, שנאמר: "ואם לא תפדה וערפתו" (שמות יג,יג; שמות לד,כ).
To decapitate a firstling donkey [which is not redeemed], as [Exodus 34:20] states: "If you do not redeem it, you must decapitate it."