Popular Categories
« Version Control System - VCS | Main | What is Virtual Machine - VM? »
Friday
Jul242009

What is API?

Application Programming Interface (API) is a specification for interacting with software application or service programmatically. Usually it is exposed as a set of allowed method calls along with:

  • defined parameters and return arguments;
  • calling conventions;
  • usage limitations.

For example, here's how a piece of Twitter REST API looks like:

  • Twitter REST API Method: statuses update
  • URL: http://twitter.com/statuses/update.format
  • Formats: xml, json, rss, atom
  • HTTP Method(s): POST
  • Requires Authentication: true
  • API rate limited: false
  • Parameters: ...
  • Response: ...

There are a few categorizations of APIs in the software development world.

Web APIs define interfaces for interacting with various web sites and services in the Internet. These APIs usually use Hypertext Transfer Protocol (HTTP) requests for passing around data represented in JavaScript Object Notation (JSON) or Extensible Markup Language (XML) formats.

Twitter REST API, mentioned above, is an example of such Web API.

Operating System APIs represent low-level methods exposed by the operating system (OS) that could be used by software applications to integrate with it. Windows API (or Win32) and POSIX definitions are among the most known examples.

Software APIs are usually exposed by software vendors willing to provide integration capabilities for their products.

Reader Comments (5)

Hi, can I ask one question, can you give me some example of software APIs?
thanks, :)

June 6, 2010 | Unregistered CommenterXu

@Xu, examples of software API are well-known Win32 API, Microsoft Office Automation API or even the Quickbooks API.

June 6, 2010 | Registered CommenterRinat Abdullin

@Rinat, thanks for your reply Rinat. :)
But does Win32 API belongs to Operating System APIs?

Also can I say like this, for example eBay API belongs to Web APIs, Win32 API belongs to Operating System APIs and Firefox API belongs to software APIs?

Thanks!

June 7, 2010 | Unregistered CommenterXu

@Xu,

Yes, you can say that. Just keep in mind, that each way of categorization is always subject to argument and there is rarely a pure distinction.

So you can say that Win32 API is OS API because this API exposes low-level methods of OS. Yet, at the same time this API is a software API, because OS is a Software and this API is exposed and supported by Microsoft to provide integration capabilities.

June 8, 2010 | Registered CommenterRinat Abdullin

@Rinat,

Thanks for your reply! :)

June 9, 2010 | Unregistered CommenterXu

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>