We know that in $1748$ Euler published the "Introductio in analysin infinitorum", in which, he released the discovery of the Euler's formula:
$$e^{ix} = \cos x+i \sin x$$
But who was the first mathematician to convert this to the form we all know and love, the Euler's identity:
$$e^{i\pi}+1=0$$ When was this formula first explicitly written in this way?
Was it Bernoulli, Euler's teacher and mentor, or another more modern mathematician?
For a reference pointing to Euler, see :
discussing Bernoulli's thesis that $l (-1)=l(+1)=0$ :
In a nutshell, he derive for the area of the first quadrant of the unit circle the formula :
from which : $l (-1) = \pi \sqrt -1$.
See also page 165-on where, starting from his formula "dont la vérité est suffissament prouvée ailleurs" :
posing $C$ as the real logarithm of the positive quantity $\sqrt {(aa+bb)}=c$, he derives the general formula for the logarithm of :
With $c=1$ and $C=0$ he get :
Finally, with $\phi = 0$ [and thus : $\text {cos} \phi = 1$ and $\text {sin} \phi = 0$] :
and, with $\phi = \pi$ :
Euler in : Introductio in analysin infinitorum, Tomus Secundus (1748), Ch.XXI, page 290, uses $i$ for an imaginary quantity :
But he does not say that the symbol $i$ is such that $i^2 = -1$.
In the same Introductio, Tomus Primus, §138, the formula is written as :
In conclusion, Euler "knows" the identity and he is the "iventor" of $i$ to name an imaginary quantity, but it seems that he never writed it in the "modern form", at least because he constantly writes $\sqrt -1$.
Note
See also Cuchy's Cours (1821) for Euler's identity ; again, $\sqrt -1$ is used.
I've not made an extensive research but, due to the fact that Cauchy uses systematically $i$ for denoting an increment [see : Résumé des leçons sur le calcul infinitésimal (1823) ] :
my conjecture is that we hardly find any use of $i$ as imaginary.