A Massachusetts man offered to give his three-month-old daughter to a maintenance man outside a gas station convenience store in exchange for two beers, authorities say.

Matthew Brace, 24, made the offer for the beer — each about 1.1 litres — on Monday, said police in Chicopee, in the northwestern part of the state.

The maintenance man called police, who found Brace hiding with the girl behind a trash container. State child welfare officials took the baby into custody.

Brace was not arrested, but will be summoned to court to face a charge of reckless endangerment of a child, police said.

The child's mother was in the store at the time buying cigarettes. She has not been charged.