Grind your robots at the easier patrol level (the less money required) to gain experience and leveling. As the same time, the easier stage has low mortality rate. Later on, once the robots reach higher lvl and you also have optimized the robot population, it is more easy to complete a harder mission.
Try not to lose, if you think you are going to for the next round, then select "retreat" to avoid loosing your alliances (if you lose, you will also lose your alliance who is accompany with you to patrolling)
If you prefer to save some bucks rather than sending your robots to repair, then here are some tips to maximize the factory's productivity and take full advantage from it (helps to recover from battles):
1) Use items to level up the housing in order to occupy for 8 robots
2) User items to level up the robot factory, so it can manufacture more robots per week.