Answer
$f(x,y,z)=x+y \sin z+k$
Work Step by Step
The vector field $F$ will be conservative if and only if $curl F=0$
consider $F=A i+B j+C k$
$curl F=[C_y-B_z]i+[A_z-C_z]j+[B_x-A_y]k$
Here, we have $curl F=(\cos z-\cos z)i+(0-0)j+(0-0)k=0$
Thus, the vector field $F$ is conservative.
$f(x,y,z)=x+g(y,z)$
and $g'(y)=0$
Thus, $g_y=\sin z$
$g(y,z)=y \sin z+h(z)$
Now, $f(x,y,z)=x+y \sin z+h(z)$
and $h'(z)=0$
Thus, $f_z=y \cos z$
Hence, $f(x,y,z)=x+y \sin z+k$