Let $d$ be a positive integer, and suppose $c$ is an integer such that $\gcd(c,d) = 1$. Then the following identity holds:
$$\displaystyle \left \lvert \{b \pmod{d} : b^2 \equiv c \pmod{d} \}\right \rvert = \sum_{\substack{\chi \pmod{d} \\ \chi^2 = \chi_0}} \chi(c).$$
What is the correct analogue for the right hand side when we replace the left hand side with
$$\displaystyle \left \lvert \{b \pmod{d} : b^k \equiv c \pmod{d}\}\right \rvert$$
with $k \geq 3$?