Proceeds from a bond at maturity
In some cases, the "sale" of the bond comes at maturity, when the company that issued the bond redeems it. That situation is relatively simple, as you'll receive proceeds that consist of two parts: the final interest payment and the maturity payment.
The final interest payment is calculated by taking the par value of the bond and multiplying it by the coupon rate stated on the bond, usually divided by two to reflect semi-annual payments. The maturity payment is typically the par value of the bond. So, on a bond with a par value of $1,000 and a coupon rate of 5%, you'll typically get $1,025 at maturity: $25 as your last semi-annual interest payment plus the $1,000 par value.