The 29-year-old mother had pleaded guilty in what is believed to be the first case of its kind in the country.
She was charged with giving a controlled drug to a person under 18, after a police drugs raid on her house.
The Whanganui District Court said the actions of the woman, who has not been named, amounted to child abuse and gave her to a six month supervision order.
"Child abuse is family violence in these circumstances, and it is clear this baby and its mother needed help," senior court official Andrew McDonald told the Wanganui Chronicle.
"People often believe drug-related activities are victimless, but it affects the people around them."
The woman's partner faced other charges relating to the police raid, said the paper.