Vacuum has an example of modifications to a FleetMemberAPI during a combat Mission in the script that handled in-game Boarding. That said, the cleanest way to do this is probably to:
1. Attach a Tag to the FleetMemberAPI when (whatever) is happening.
2. Intercept the resulting ships when they hit the Mission using EveryFrameCombatScript(), using a HashMap to store which ships have already been checked / modified (because you don't know they'll be spawned on the first frame, you need to keep re-checking but use minimal CPU).
3. Modify accordingly, including subsequent modification of the FleetMemberAPI.
The case in Vacuum doesn't cover all of this, but it at least covers the basics of how to get to the FleetMemberAPI (which is trickier than you'd think).