I posted this on blenderartist.org, but to no avail.
I want to be able copy the Fcurve modifiers applied to ShapeKey drivers and paste them onto their counterparts on other objects, the other object's ShapeKey drivers.
This is manually quite simple to do; as in, you just copy the all the fcurve modifiers on a Driver from the graph editor, select the other object and again in the graph editor paste them whichever fcurve you want, in this case, its drivers... But with scripting in Blender, it turns out to be an enigma, whereas there is only the ability to add and remove an fmodifier to an fcurve, example:
bpy.data.shape_keys['Key'].animation_data.drivers[0].modifiers.new()
bpy.data.shape_keys['Key'].animation_data.drivers[0].modifiers.remove()
But bpy.ops.graph.fmodifier_copy()
seems unbelievably tricky and seems not to play well within a script, like I think you need the area type to graph editor and invoke the command, which sounds pretty redundant.
And since the Blender API is almost totally devoid of real-world examples explaining the application of its commands and procedures, I'm totally stuck. I searched far and wide, even tried digging through other scripts.
How can I accomplish this task?