There are several ways to build API on the web
- HTTP/RPC
- REST
RPC(Remote Procedure Call) is used to call methods across the web. That means RPC is more about the action and HTTP verbs include the RPC url.
REST
REST is all about resources. For example, with a truly RESTful service you would never call something like
http://service.com/user/charith/add. In REST url we only reference to a resource and define what to do with the resource by HTTP verbs. for example if we need to get users information we use http://service.com/users/ with GET request and same url we use for add user to system with POST request to delete users from system we can use same url with DELETE request like wise we can use same url with different verbs.