General API question

Since I am very bad at coding I fired up google and found the following;

I followed the steps but could not make it work and I wonder what I did wrong