Pregunta de entrevista de Mithun

How an API works and how would you construct it