is surplus just an approximation? let's say we have a consumer with a demand curve $q^d(p)=10-p$ and the good its price is $5$. So the consumer will consume 5 units. The surplus of the consumer would then be equal to $(10-5)+(9-5)+(8-5)+(7-5)+(6-5) = 5+4+3+2+1 = 15$. However, when solving this in the conventional manner it gives me $(10-5)\times 5/2 = 12.5$
What am I doing wrong? Or is surplus just an approximation?
Your second answer is correct. The problem your first approach has, is that you assume that you may only buy a discrete amount of goods. However, your demand curve is continuous and the usual assumption in microeconomics is that you can consume any amount of this good, for instance $1.478926574$ units. Thus, your first calculation for the surplus is not correct, the correct way to do it is

$$CS = \int_{5}^{10} (10-p) \mathcal{d}p = 10p-\dfrac{p^{2}}{2}|^{10}_{5} = 100-50-50+12.5=12.5$$

This result is equal to the second calculation of yours simply by the fact that it is a triangle. If demand wouldn't be linear, you'd have to use the integral form to calculate CS.