Hi there,
I’m new to Amplitude.
I’m using the Browser SDK and getting the following error in the console only in production env (in local, dev env it works well):
“Amplitude Logger [Error]: Invalid API key”
This is my code
function InitAmplitude() {<br /> if (environment.AMPLITUDE_API_KEY && environment.IS_AMPLITUDE_TRACKED) {<br /> amplitude.init(environment.AMPLITUDE_API_KEY, {<br /> serverZone: 'US',<br /> defaultTracking: true,<br /> });<br /> }<br />}
I double, triple checked and the API key matches what I got from Amplitude’s settings. What am I doing wrong?