A year ago i developed an iOS application that was connecting to a server with HTTP requests exchanging JSON files, etc... I was told at that time that the server was a web (REST) service. I didnt care much since for me it was just a black box.
Recently, I've been developing a hybrid mobile application where i use native code + jQuery mobile for the front-end part and PHP + MySQL for the back-end part. The application is for registering new users to the database, having users to subscribe in various kinds of events, get notifications on them, etc...
So for all the communication between the front-end (client) and back-end (server), I make HTTP requests (POST) and Ajax calls using JSON files. For example, if I have a subscribe button and is clicked, I make an Ajax POST request sending in the body a JSON file with all the information needed, like user ID and categories to subscribe, to a PHP script. The PHP script then makes all the necessary actions in the database.
Is this a RESTful Web Service? I am a bit confused on the definition of REST. According to Wikipedia REST is:
REST-style architectures conventionally consist of clients and servers. Clients initiate requests to servers; servers process requests and return appropriate responses.
So is what I am building a RESTful Web Service? Also do we call REST only the server part or in general the client-server architecture?
From other questions I read that a non-REST web service would manage a database like:
/user_create
/user?id=xxx
/user_edit?id=xxx
/user_delete?id=xxx
and a REST web service would just "expose an API with a single base resource":
/user
/user/xxx
I'm really having difficulty understanding what these things mean... Could someone try to explain to me when a service is a REST web service, maybe by giving me an example of what it is and what it is not?