@nunosans For AfterEffects, it depends a lot on what you want to accomplish, but there are a number options with different licenses and varying degrees of usability.
#foss - #Natron, #Friction, #SynfigStudio, #Glaxnimate, #Pencil2D, #Enve, or possibly #Blender
Proprietary - www.keyshapeapp.com (Mac only), cavalry.scenegroup.co (subscription-based)
I can't really vouch for any of them, but I've experimented with some of the free ones and Friction is what I'm planning to dive into eventually.