One of the first observations we can make is that you're integrating a function over an interval that is symmetric around $0$, i.e. it can be written as $[-c,c]$.
I have a trick for you, whenever you find similar definite integrals start by writing the function you're integrating as a sum of an even function and an odd function. In fact, it can be proven that for every function $f$, there exists two functions such that $f=f_{\mathrm e}+f_{\mathrm o}$ and $f_{\mathrm e}$ is even and $f_{\mathrm o}$ is odd. Specifically $$f_{\mathrm e}(x)=\dfrac{f(x)+f(-x)}{2}\qquad f_{\mathrm o}(x)=\dfrac{f(x)-f(-x)}{2}.$$
You may ask yourself: “Why bother? It seems we're just making a complicated expression to look more intimidating.” But just wait, you'll see the usefulness of this process in a bit. Let's get back to our integral, applying the property we've just discussed for the function $f\colon x\mapsto\tfrac{\cos (x)}{a^x+1}$
$$\eqalign{
\int_{-1}^1 \frac{\cos x}{a^x+1}\mathrm dx&=\int_{-1}^1 \big[f_{\mathrm o}(x)+f_{\mathrm e}(x)\big]\mathrm dx\\
&=\int_{-1}^1 f_{\mathrm o}(x)\,\mathrm dx+\int_{-1}^1 f_{\mathrm e}(x)\,\mathrm dx\\
&=\int_{-1}^1f_{\mathrm e}(x)\,\mathrm dx.}
$$
Since
$$\int_{-c}^c(\text{odd function})(x)\,\mathrm dx=0.\tag{$\forall c\in\Bbb R$}$$
Now if you calculate $f_{\mathrm e}$ you'll find that it has the ridiculously simple form:
$$\require{cancel}\eqalign{f_{\mathrm e}(x)&=\dfrac{f(x)+f(-x)}{2}\\&=\dfrac{\frac{\cos (x)}{a^x+1}+\frac{\cos(-x)}{a^{-x}+1}}{2}\\&=\dfrac{\frac{\cos (x)}{a^x+1}+\frac{\cos(x)}{a^{-x}+1}}{2}\\&=\dfrac{\cos x}{2}\left(\dfrac{1}{a^x+1}+\dfrac1{a^{-x}+1}\right)\\&=\dfrac{\cos x}2{\left(\dfrac{2+a^{-x}+a^x}{a^{-x}a^x+a^x+a^{-x}+1}\right)}\\&=\dfrac{\cos x}{2},
}$$
which is way simpler to integrate than the original function. We thus get $$\int_{-1}^1 \frac{\cos x}{a^x+1}\mathrm dx=\int_{-1}^1\frac{\cos x}2\mathrm dx=\int_0^1\cos x\,\mathrm dx=\sin1.\tag{$\forall a\geqslant1$}$$
We can even give the following generalization:
$$\int_{-c}^c\frac{\cos x}{a^x+1}\mathrm dx=\int_{-c}^c\frac{\cos x}2\mathrm dx=\int_0^c\cos x\,\mathrm dx=\sin c.$$