Lets consider a regular Cartesian coordinate system $A$. From its origin, I draw a unit vector, defined by the radial $\theta$ (tilt from $z$-axis) and $\phi$ ( angle between the $x$-axis and the vectors projection on the $xy$ plane).
I would like to define a new plane $S$, that is perpendicular to that vector, and a new coordinate system $A'$ in which the $x'$ and $y'$ axes are parallel to the plane. One more freedom degree is kept, a "rotation" of the $x'y'$ axes in respect to the $z'$ axis. For now, let's define this angle as 0.
I am looking for a transformation $R(\theta,\phi)$ so that: $$(x,y,z)=R(x',y',z')$$