In this work, new polymers with a shape memory effect for self-healing coatings based on oligomers with terminal epoxy groups, synthesized from oligotetramethylene oxide dioles of various molecular weights, were developed. For this purpose, a simple and efficient method for the synthesis of oligoetherdiamines with a high yield of the product, close to 94%, was developed. Oligodiol was treated with acrylic acid in the presence of a catalyst, followed by the reaction of the reaction product with aminoethylpiperazine. This synthetic route can easily be upscaled. The resulting products can be used as hardeners for oligomers with terminal epoxy groups synthesized from cyclic and cycloaliphatic diisocyanates. The effect of the molecular weight of newly synthesized diamines on the thermal and mechanical properties of urethane-containing polymers has been studied. Elastomers synthesized from isophorone diisocyanate showed excellent shape fixity and shape recovery ratios of >95% and >94%, respectively.