I never quite understood the definition of "API", it's been years now
For me in the beginning, it was fetching data from some server like twitter api, discord api, and reddit api, API acts the bridge. But then in MDN docs, some stuff (maybe methods i dont remember) is declared as API.