From 2cb6111c62475424b5367e5c9178af13224990d1 Mon Sep 17 00:00:00 2001 From: Gustavo Martin Morcuende Date: Tue, 4 Oct 2016 21:14:56 +0200 Subject: [PATCH] Update README --- README.md | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 575ab02..c20a5fc 100644 --- a/README.md +++ b/README.md @@ -17,37 +17,42 @@ java -jar target/http-services-1.0-SNAPSHOT-jar-with-dependencies.jar ## Available URIs by means of Web Browser + +``` http://localhost:8080/app/login/login.html http://localhost:8080/app/pages/page_1.html http://localhost:8080/app/pages/page_2.html http://localhost:8080/app/pages/page_3.html http://localhost:8080/app/login/logout.html - +``` ## Testing API, POSTMAN Retrieve user data as XML: +``` GET /app/api/users/GUMARTIN HTTP/1.1 Host: localhost:8080 Authorization: Basic R1VNQVJUSU46bGFtZQ== Accept: application/xml Cache-Control: no-cache Postman-Token: 7eb3642c-57a4-3d42-c455-b81cee18c010 - +``` Retrieve user data as JSON: +``` GET /app/api/users/GUMARTIN HTTP/1.1 Host: localhost:8080 Authorization: Basic VVNFUjFzc3M6Z29k Accept: application/json Cache-Control: no-cache Postman-Token: 72935dcb-a57f-fc42-5795-a2fea96a4df4 - +``` Create user, payload JSON: +``` POST /app/api/users/ HTTP/1.1 Host: localhost:8080 Content-Type: application/json @@ -62,10 +67,11 @@ Postman-Token: b844d75b-4df1-57da-d900-b84db477317d "password": "bobo", "role": "ROLE_APP_ADMIN" } - +``` Create user, payload XML: +``` POST /app/api/users/ HTTP/1.1 Host: localhost:8080 Content-Type: application/xml @@ -80,3 +86,4 @@ Postman-Token: 7d8c92b4-3259-361d-8e32-2294534ea91e pepe ROLE_APP_PAGE_1 +``` -- 2.1.4