As I already mentioned in the comments, I did not achieve the result through complex-analysis.
Instead I used the following real-analysis approach.
Let
$$f(a)=\int_0^{\infty} \frac{e^{-ax}}{1+x^2}\,\,dx,\;\; a>0.$$
Then,
$$f''(a)=\int_0^{\infty} \frac{x^2\cdot e^{-a\cdot x}}{1+x^2}\ dx.$$
It follows that
$$f''(a)+f(a)=\int_0^{\infty}\ e^{-a\cdot x}\ dx.$$
Evaluate the integral:
$$f''(a)+f(a)=\frac{1}{a}.$$
A general solution to this differential equation can be defined as the sum of a complementary solution and particular solution.
Find the complementary solution by solving the equation:
$$f''(a)+f(a)=0.$$
It can be derived that the complementary solution is given by
$$f_\text{c}(a)=C_{1}\cdot\cos(a)+C_{2}\cdot\sin(a).$$
Find the particular solution to
$$f''(a)+f(a)=\frac{1}{a}$$
by variation of parameters.
List the basis solutions in $f_{\text{c}}(a)$:
$$f_{b,1}(a)=\cos(a),\\ f_{b,2}(a)=\sin(a).$$
Determine the Wronskian of $f_{b,1}(a)$ and $f_{b,2}(a)$:
$$W(a)=
\begin{vmatrix}
\cos(a) & \sin(x) \\
\frac{d}{da}\cos(a) & \frac{d}{da}\sin(a) \\
\end{vmatrix}
=
\begin{vmatrix}
\cos(a) & \sin(x) \\
-\sin(a) & \cos(a) \\
\end{vmatrix}
=\cos^2(a)+\sin^2(a)=1.$$
Let
$$g(a)=\frac{1}{a},\\ h_{1}(a)=-\int \frac{g(a)\cdot f_{b,2}(a)}{W(a)}\ da,\\ h_{2}(a)=\int \frac{g(a)\cdot f_{b,1}(a)}{W(a)}\ da.$$
The particular solution will be given by
$$f_{\text{p}}(a)=h_{1}(a)\cdot f_{b,1}(a)+h_{2}(a)\cdot f_{b,2}(a).$$
Determine $h_{1}(a)$ and $h_{2}(a)$:
$$h_{1}(a)=-\int \frac{\sin(a)}{a}\ da=-\text{Si}(a),\\ h_{2}(a)=\int \frac{\cos(a)}{a}\ da=\text{Ci}(a).$$
The particular equation is given by
$$f_{\text{p}}(a)=\text{Ci}(a)\cdot\sin(a)-\text{Si}(a)\cdot \cos(a).$$
A general solution is defined as the sum of the complementary solution and particular solution:
$$f(a)=C_{1}\cdot\cos(a)+C_{2}\cdot\sin(a)+\text{Ci}(a)\cdot\sin(a)-\text{Si}(a)\cdot \cos(a).$$
From the above expression for $f(a)$ can be derived that $\lim \limits_{a \to \ 0} f(a)=C_{1}$. From the integral form of $f(a)$ can be derived that $\lim \limits_{a \to \ 0} f(a)=\frac{\pi}{2}$. Therefore, $C_{1}=\frac{\pi}{2}$.
From the above expression for $f(a)$ can be derived that $\lim \limits_{a \to \ \infty} f(a)=C_{2}\cdot \sin(\infty)$. From the integral form of $f(a)$ can be derived that $\lim \limits_{a \to \ \infty} f(a)=0$. Therefore, $C_{2}=0$.
Thus, an expression in closed form for your integral is given by
$$f(a)=\frac{\pi}{2}\cdot\cos(a)+\text{Ci}(a)\cdot\sin(a)-\text{Si}(a)\cdot \cos(a),\;\; a>0.$$