Solution (source code)

= Solution
{c}

The <universal property of a pushout of groups> says: for every <group> $H$ and <group homomorphisms> $u_j:G_j\to H$ satisfying $u_1\phi_1=u_2\phi_2$, there is exactly one <group homomorphism> $u:P\to H$ such that
$$
\boxed{uj_1=u_1,\qquad uj_2=u_2.}
$$
To prove existence, the <universal property of a free product> supplies a unique <group homomorphism> $v:G_1*G_2\to H$ with $vk_j=u_j$. Every defining <relator> of $N$ maps to
$$
u_1(\phi_1(h))\,u_2(\phi_2(h))^{-1}=1.
$$
Since $\ker v$ is a <normal subgroup>, it contains the entire <normal closure> $N$. The <universal property of a quotient group> therefore gives a <group homomorphism> $u:P\to H$ through which $v$ factors. Its restrictions are the required $u_j$.

For uniqueness, $j_1(G_1)$ and $j_2(G_2)$ together generate $P$: their preimages already generate the <free product>. Consequently a <group homomorphism> out of $P$ is determined by its restrictions to these two <subgroups>. Any two candidates for $u$ therefore coincide.

This also proves that the <pushout of groups> is unique up to a unique compatible <group isomorphism>. Given another such object $P'$, apply the <universal property> in both directions. Both composites restrict to the original maps from $G_1,G_2$, so uniqueness makes them the respective <identity maps>.