The function is periodic with main period of $2\pi$, and it is even. So only the coefficients of the cosine terms remain. Wolfram alpha gives the result for $a_{0}$ as follows:
I guess it is only expressible using some special functions, or contour integration, with me being comfortable with the latter. How do I proceed here? Using contour integration I got that :$$a_{0}=\frac{1}{\pi i}\oint_{\left | z=1 \right | }^{ }\frac{dz}{z\left ( e^{2}e^{\frac{z+z^{-1}}{2}}-1 \right )}$$ which has potential zeroes at $z=$ and at points $z$ such that $$e^{\frac{z+z^{-1}}{2}}=e^{-2}$$. However, the residue at $z=0$ evaluates to zero, and the other two aren't contained within the contour. And also $$a_{n}=\frac{1}{\pi 2i}\oint_{ \left | z \right |=1}^{ }\frac{z^{2n}+1}{z^{n+1}\left ( -1+e^{2} e^{\frac{z+z^{-1}}2{}}\right )}$$, which to my knowledge also evaluates to 0. Maybe we can try a different approach.
You do not need to integrate at all:
$$\frac{1}{1- a e^{\cos(x)}} = \sum_k a^k e^{k\cos(x)} = \sum_{k,m} a^k \frac{k^m}{m!} \cos(x)^m$$
Furthermore $\cos(x)^m = \frac{1}{2^m} \sum_{0\leq j\leq m} \binom{m}{j} \cos((m-2j)x)$. Now put that all together, do some reindexing and you will have a perfectly nice series expression for all fourier coefficients. If I didn't mess up, the fourier series should look like this:
$$\sum_n \left( \sum_{k,j} \frac{a^k (\frac{k}{2})^{n+2j}}{(n+j)! j!} \right) \cos(nx)$$