If [wheat] flour was added for flavor or sustenance (i.e. not as a binder):
Brocho before eating this: Borei Minei Mezonos
Otherwise:
Brocho before eating this: Borei Pri Ha'eitz
Brocho after eating the proper shiur of this: Borei Nefashos [in the rare case that flour was added for flavor/sustenance, and a proper shiur of Mezonos was eaten it would be Al Hamichya]
Source: Halachos of Brochos (handbook - page 9)