Child pages
  • Interceptors

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


This detects when a request is coming from a browser and returns HTML with syntax highlighted XML/JSON instead of just the raw text. In other words, if a user uses a browser to request "http://localhost:8080/openmrs/ws/fhir/Person/d9648997-4e01-406e-b47b-c00cb9b143bb" by typing this address into their URL bar, they will get nice formatted HTML back with a human readable version of the content. This is helpful for testers.


This  can be used to generate a new log line (via SLF4j) for each incoming request. 

Example log line:

2015-08-09 17:29:45 INFO  accesslog:103 - Source[] Operation[read Person/d9648997-4e01-406e-b47b-c00cb9b143bb] UA[Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.134 Safari/537.36] Params[]

The following substitution variables are supported: