In this paper, we are interested to investigate a generalization of many functional equations. Namely, we consider the following functional equation \[ ıt_Sf(x+y+t)\,d\mu(t)+ıt_Sf(x+ǎrphi(y)+t)\,du(t)=f(x)+h(y),\quad x,yı S, \] where $(S,+)$ is an abelian semigroup, $\varphi$ is a surjective endomorphism of $S$, $E$ is a linear space over the field $\mathbb K\in\{\mathbb R,\mathbb C\}$ and $\mu$,$\nu$ are linear combinations of Dirac measures. Under appropriate conditions on $\mu$ and $\nu$ and based on Stetk{e}r's result [9], we find and characterize solutions of the previous functional equation.