What is an API?

Imagine you’ve got a black box with a big red button on top. When you press the button, the black box lights up.

In this example, pressing the red button means the black box will light up. There is an understanding between you and the box that says “if I press the button, the box will light up.” Think of an interface as the understanding between you and the box.

Now let’s extend the metaphor.

Instead of hitting a mechanical button, let’s pretend that you have to say “Light Up!” to the box in order to light it up. If you could program your computer to say this, the black box will light up. Still functionally the same thing.

Now imagine instead of saying this verbally, you write it out as a written command for the box. And – this part is the most critical – the black box tells you the exact wording to use: ‘lightMeUp()’. The box also has an instruction manual on how to submit this command to the box.

API stands for Application Programming Interface. In this example, the application is the box itself, the interface is the understanding between you and the box, ie, the API lets you know how to write out the commands to make the box do stuff. The API Reference is the instruction manual with all the commands.

In SMS Central’s case, the application is our SMS gateway, the interface is the understanding between you and our application (“if I write SEND, I will send SMS; if i write RECEIVE, i will receive SMS”). The Reference tells you exactly how and what to write in order for our gateway to send/ receive SMS.