There is nothing wrong in making du`aa’ asking Allah to grant one a baby boy. Actually, there are no prescribed prayers in the sources for this, but we can simply ask Allah Almighty to grant a baby boy and to bless him for you and make him a cause of happiness and guidance for you.

One can also make use of any general prayers from the Qur’an and the Sunnah for this purpose. We are recommended to earnestly persist in asking Allah to grant you good offspring. Make Du`aa’ in the good times such as in prostration, in night vigil, etc. At the same time, you should perform Prayer and obey Allah, Most High. Obedience of Allah and reciting the Qur’an and Du`aa’ are means of attaining Allah’s favours.

There are two supplications which we can infer from the Qur’an. We quote them below:
Rabbi laa tadharnee fardan wa anta khayru al-waritheen
(My Lord, do not leave me childless; You are the best of heirs).
Rabbi hab lee min ladunka dhurriyyatan tayyibatan innaka samee’ al-ddu’ai
(My Lord, grant me a righteous offsrping as a pure gift of Yours; for verily You are the Hearer of prayers).
Both of the above prayers are from Prophet Zakari’ah who prayed for a progeny; Allah heard his prayers and granted him his son Yahya.
So, we should believe in the promise of Allah and pray sincerely and also follow up our supplications with penitence and lots of charities, for charities are truly effective and beneficial in helping us attain and realize our aspirations and prayers.