John Kennedy actually said...
Our Nation has ever sought Divine guidance in its hours of thanksgiving and its moments of peril.
Context
Message From the President on the Occasion of the Dedication of the Inter-Faith Chapel, Kings Point, New York.
04/30/1961