I am too far behind in terms of programming and being into CamBam API to try it myself. And there are already plugins which do almost what I have in mind but not completely. And ... there actually may exist a tool I have missed which does it.Here is the idea: Using a tool with a spherical head (not ball nose but a sphere with a stem) to mill a sphere with a stem, i.e. go below the middle and do a spherical undercut as far as the tool geometry would allow. Both convex and concave spherical shapes. The reason for this is that I want to make a kind of ball joint.Is it doable and anyone (Eddy I mean you ) willing to give it a try?Here is a small graphical representation.

P.S. Even with a lathe and 4-th axis internal cavity would not be that easy IMHO.

We the profile2helix plugin all the time with a winged rounded edge cutter to cut flanges with a curved undercut much deeper than you show. A ball would be really easy. We draw the part profile, offset the line by the tool nose radius, then move that line over in X by the tool radius of winged cutter center line. Then generate the helix and use engrave.