Consider the problem
$\nabla^2u=0,\ x^2+y^2<a^2\\u=g, \ x^2+y^2=a$
Prove that in the center of the disk $$u(0)=\frac{1}{2\pi}\int_0^{2\pi}g(\phi)d\phi$$
I have the following Poisson formula $u(\mathbf x)=\frac{a^2-|\mathbf x|^2}{2\pi a}\int_{|\mathbf x'|=a}\frac{u(\mathbf x')}{|\mathbf x-\mathbf x'|}ds'$
Making the substitution I get $u(0)=\frac{a}{2\pi }\int_{|\mathbf x'|=a}\frac{g(\phi)}{|-\mathbf x'|}ds', ds'=ad\phi$
My question is if can I substitute $|\mathbf x'|=a$ in the denominator and how to get the limits $0$ and $2\pi$?
You are missing a square in the denominator of your integrand: $$ u(\mathbf{x}) = \frac{a^2 - |\mathbf{x}|^2}{2\pi a}\int_{|\mathbf{x}'=a|}\frac{u(\mathbf{x}')}{|\mathbf{x} - \mathbf{x}'|^2}\, ds'. $$ Yes, you may substitute $|\mathbf{x}'| = a$ and the limits $0$ and $2\pi$ corresponds to the limit of the angle variable $\phi$, since you parameterise the circle in terms of polar coordinates $(a,\phi)$, which is how you get $ds' = ad\phi$ anyway.