According to Tiffany Kemp in her book Essential Contract Drafting Skills (spoken about here), we shouldn’t use “undertakes to” because it’s legalese with no special meaning:
An undertaking is simply a commitment to do, or not do, a particular thing. It has no specific legal interpretation in English law, and adds no value to your drafting [translating, in our case]. p 39
Instead, she suggests using “shall” because it’s “shorter and clearer”.
Of course, if don’t like using shall, you’d just use whatever you use instead of shall but still avoid “undertakes to”.
Off the top of my head, I can think of cases where “undertaken by” still seems to be the best solution (e.g., when referring to obligations taken on by a party), but I’ll think about that next time it comes up.
Apart from avoiding legalese when you can, the other point here is to be consistent with your language for obligations (or promises) and avoid synonyms. Always something to keep in mind when translating from a language that likes synonyms (Spanish) to one that prefers consistency (English), at least in contracts.