Answer
$f(x,y,z)=x+y \sin z+C$
Work Step by Step
The vector field $F$ will be conservative if and only if $curl F=0$
Let us consider $F=P i+Q j+R k$
Then, we have $curl F=[R_y-Q_z]i+[P_z-R_z]j+[Q_x-P_y]k$
Now, $curl F=(\cos z-\cos z)i+(0-0)j+(0-0)k=0$
Thus, the vector field $F$ is conservative.
Consider $f(x,y,z)=x+g(y,z)$
Also, $g'(y)=0 \implies g_y=\sin z$
and $g(y,z)=y \sin z+h(z)$
Further, $f(x,y,z)=x+y \sin z+h(z)$
$\implies h'(z)=0$ and $f_z=y \cos z$
Hence, we get $f(x,y,z)=x+y \sin z+C$
where, $C$ is a constant of proportionality.