update readme

This commit is contained in:
Adrien Marquès 2018-11-19 14:22:57 +01:00
parent a43611f664
commit f4d46a961b
1 changed files with 11 additions and 3 deletions

View File

@ -7,7 +7,7 @@ Simple REST API mixer as a service. A minimal service will be deployed on your l
##### Prerequisites
You need `node` and `npm` installed.
You need `node` and `npm` installed. The project is written using `typescript` that allows type checking and other verifications before creating the real javascript code. Also it adds polyfills (c.f. babel) to ECMAScript that allows the use of `class` and other new ES features.
##### 1. Install dependencies
@ -18,7 +18,7 @@ $ npm i
##### 2. Transpile sources
Then launch the following command inside the project's folder :
Run the following command inside the project's folder :
```bash
$ npm run build
```
@ -46,4 +46,12 @@ $ npm start;
### Test the API
You can now use [Postman](https://www.getpostman.com/) or whatever API client at `127.0.0.1:8000`.
You can now use [Postman](https://www.getpostman.com/) or whatever API client or web browser at `127.0.0.1:8000`. The only allowed request method is **GET** and accepts the research field in a query parameter named 'q'.
Example URL : http://127.0.0.1:8080?q=Nutella that searches for the keyword "Nutella".
> When called in a browser you will get a simple web page that is the representation of the results (with images).
>
> When called with the header `Accept: application/json`, the result will represent the data as a JSON object.