The corresponding 3-cocycles of $H^3(\mathbb{Z}_n,U(1))=\mathbb{Z}_n$ are very simple: $$ \omega_{{I}}^{}(a,b,c) = \exp \left( \frac{2 \pi i p^{}_{{I}}}{N^{2}} \; a^{}(b^{} +c^{} -[b^{}+c^{}]) \right) $$$$ \omega_{{I}}^{}(a,b,c) = \exp \left( \frac{2 \pi i p^{}_{{I}}}{n^{2}} \; a^{}(b^{} +c^{} -[b^{}+c^{}]) \right) $$ with $p_I \in \mathbb{Z}_n$ labels the element in $H^3(\mathbb{Z}_n,U(1))$. Also $a,b,c \in \mathbb{Z}_n$. $[b^{}+c^{}] \equiv (b^{}+c^{})$mod $N$$n$. You can check explicitly it satisfies 3-cocycles conditions.