Take a morphism $f:X\to X$ in a category with the same domain and codomain. I want to test whether $f$ is a monomorphism. This means, taking arbitrary $g_1,g_2:Y \to X$ with $f\circ g_1=f\circ g_2$ it should follow that $g_1=g_2$.
Does it suffice for a retraction $f:X\to X$ to be a monomorphism that for all $g_1,g_2:X \to X$ with $f\circ g_1=f\circ g_2$ it follows that $g_1=g_2$?