How to prove that Z operator rotates points on Bloch sphere about Z axis through 180°?

My idea was to apply $Z$ operator 𝐭𝐰𝐢𝐜𝐞, which leads us back to the point where we started from, and also show that after applying the $Z$ operator just 𝐨𝐧𝐜𝐞 we are not at the same point where we started (this is for showing that we are not rotating by a multiple of $360^{\circ}$). Is this the correct proof? What about the general case, where we want to find out through how many degrees a given operator rotates the points?

The Pauli-$$Z$$ gate maps $$|0\rangle$$ to $$|0\rangle$$ and $$|1\rangle$$ to $$-|1\rangle$$.

For Bloch sphere representation, state of a qubit is written like (look at my previous answer for a detailed explanation)

$$|\psi\rangle = \cos(\theta/2)|0\rangle + e^{i\phi}\sin(\theta/2)|1\rangle$$

Apply the Pauli-$$Z$$ gate on this and you get:

$$|\psi'\rangle = \cos(\theta/2)|0\rangle + (-1)e^{i\phi}\sin(\theta/2)|1\rangle$$

$$=\cos(\theta/2)|0\rangle + e^{i(\phi+\pi)}\sin(\theta/2)|1\rangle$$

Thus, the angle $$\phi$$ changes by $$\pi$$. We can call $$\phi + \pi$$ as $$\phi'$$ now.

Remind yourself what the Bloch sphere looks like: Clearly, from the diagram, if the angle $$\phi$$ is changed by $$\pi$$, it will imply that the state of the qubit has been rotated about the Z-axis by $$180$$ degrees.

One can more generally show that $R_z(\theta)=e^{-i \theta Z/2}=\cos(\theta/2)-iZ\sin(\theta/2)$ rotates points on the Bloch sphere by an angle $\theta$ around the $z$-axis, and note that $Z=i R_z(\pi)$.

Let $|\psi\rangle$ be an arbitrary pure state. The coordinates of the point representing $|\psi(\theta)\rangle\equiv R_z(\theta)|\psi\rangle$ on the Bloch sphere are $$x(\theta)=\langle\psi(\theta)|X|\psi(\theta)\rangle, \\ y(\psi)=\langle\psi(\theta)|Y|\psi(\theta)\rangle, \\ z(\psi)=\langle\psi(\theta)|Z|\psi(\theta)\rangle.$$ That this point follows a circular trajectory around the $z$-axis when $\theta$ goes from $0$ to $2\pi$, can be seen by direct calculation as follows:

\begin{align} x(\theta) &=\langle\psi\rvert R_z(-\theta)\,X\,R_z(\theta)\lvert\psi\rangle = \cos\theta\,x(0) + \sin\theta\,y(0), \\ y(\theta) &=\langle\psi\rvert R_z(-\theta)\,Y\,R_z(\theta)\lvert\psi\rangle = -\sin\theta\,x(0) + \cos\theta\,y(0), \\ z(\theta) &= z(0). \end{align}

Note that the same is true more generally for mixed states: the point representing $\rho(\theta)\equiv R_z(\theta)\rho R_z(\theta)^\dagger$ in the Bloch sphere is $$\newcommand{\Tr}{\operatorname{Tr}} x(\theta)=\Tr(X\rho(\theta)), \\ y(\theta)=\Tr(Y\rho(\theta)), \\ z(\theta)=\Tr(Z\rho(\theta)),$$ and one can show by direct calculation that this point evolves similarly to the pure case.