To solve the debate of whether pregnancies are beneficial or detrimental to a woman's health, we may first need to define what parameters of the woman's health we are interested in. It may so happen that pregnancies might be beneficial for one of those but detrimental for some others and have no effect on the remaining parameters. This might have led to the confusion and the debate in the first place.
Here, I will try to define the parameters that constitute a woman's health in relation to pregnancy:
During-pregnancy effects on health:
a. Psychological - well-being (affected due to the effect of pregnancy on work), mood changes due to underlying hormonal changes
b. Physiological - morphometric changes, immunity, pregnancy-related changes (like morning sickness)
2. Short-term post-pregnancy effects on health: Affected due to extensive maternal care (lack of sleep, disturbed meal timings, etc.), breastfeeding, etc.
a. Psychological - post-partum depression, well-being, the joy of maternal care
b. Physiological - morphometric changes, regularizing the menstrual cycle
3. Long-term post-pregnancy effects on health
a. Psychological - affected by maternal care, child-raising
b. Physiological - lifespan, other diseases, risk of cancer (mentioned separately since it is studied widely), less painful periods
4. Complications in pregnancies including stillbirths add another dimension of parameters that can have short-term as well as long-term effects on the woman's health. As an example, the protective effect of pregnancy on the risk of future breast cancer is observed if the pregnancy continues after the 34th week. If the pregnancy is terminated before that, the risk of breast cancer is not reduced. Moreover, the authors found that parity, socioeconomic status, and vital status of the child at birth does not affect the risk of breast cancer, suggesting that the effect is maximally (if not entirely) physiological.
5. Number of previous pregnancies also affects the severity of the changes associated and can, in turn, modulate their effect on the woman's health. In the above study, the authors found that the pregnancies lasting 34 weeks or longer were associated with a substantial reduction in the risk of breast cancer. The average risk was reduced by 12.9% per birth. So a woman with 3 pregnancies has a 3 times lower risk of breast cancer as compared to a woman having 1 pregnancy and parous women have a reduced risk than nulliparous women.
Do let me know if there is any parameter that I have missed. After going through all these parameters, I think calculating a cumulative health effect of pregnancy will average out its effects on the different parameters (underestimate/ overestimate its effect on individual parameters). To avoid that, we can come up with different categories of the parameters. Broadly, there can be six categories - physiological and psychological effects during pregnancy, in the short-term after parturition, and in the long-term. The effect of pregnancy on a woman's health can be defined in terms of these 6 categories.