A negative $b$ or a negative $a$ cannot lead to a solution. So $a,b\ge 0$. For $a=0$ we obtain OP's first solution $3^0+7=2^3$. Else $a\ge 1$. Then taken modulo $3$ the powers of two ($2\equiv -1\ [3]$) for $b=0,1,2,3,\dots$ are $1,-1,1,-1,\dots$, so the involved two-power $b$ is even, $b=2B$ for some natural $B$.
Since $b\ge 3$, considering the L.H.S. modulo four, we have for $a=0,1,2,3,\dots$ the values $1+7, -1+7, 1+7, -1+7,\dots$ so the involved three-power is even, $a=2A$ for some natural $A$. We rewrite now the given relation as follows:
$$
7 = 2^a-3^b=2^{2A}-3^{2B}=(2^A-3^B)(2^A+3^B)\ .
$$
This is possible only when $(2^A-3^B)=1$ and $(2^A+3^B)=7$, so $2^A=(7+1)/2=4$, and $3^B=(7-1)/2=3$, leading to the second solution given by the OP.
$\square$