Also, an API-enabled application can be easily developed further using the API itself.
In order to create an API for your web application, here are 10 tutorials to get you started. But before that, you may want to checkout the video: How To Design A Good API and Why it Matters by Google.
PHP
Create a REST API with PHP
A very detailed yet easy-to-implement tutorial on creating a REST API with PHP.
And, there is a follow-up article: "Making RESTful Requests in PHP" by the same author which can guide you as well.
How to Add an API to your Web Service (PHP)
A detailed tutorial which describes the concepts like REST, SOAP & creates an API step-by-step with PHP.
Implement a Rest API with the Zend Framework
This example utilizes controllers in an MVC style application. Most of the stuff is handled by an instance of Zend_Rest_Server so it shows implementing to our service.