Content type
The JRNI API uses the JSON format. Use
application/json
for the Content-Type
header in POST and PUT requests. Use
application/json
in the Accept
header of requests.
Transport Layer Security
JRNI only accepts API connections using Transport Security Layer (TLS) v1.2. Different operating systems, web browsers and applications still use ciphers that only support 128 bit encryption, ie SSL / TLS v1 and v1.1. Please ensure you use, as a minimum, version 1.2 of the TLS protocol when connecting to all JRNI API environments.
HAL
The JRNI API is a hypermedia REST API. By including links in the API response, clients can discover related resources. More information can be found on this REST API Tutorial or in a good book on REST.
Hypertext Application Language (HAL) is used as the default format for the responses. It’s a relatively simple format but allows us to benefit from hyperlinks without too much overhead. While the links in the responses can be ignored it’s advisable to use them in your projects to help decouple the implementation from some of the specifics of the API.
Pagination
Most of the JRNI API endpoints that return collections have parameters that
enable control of the pagination of the response. The per_page
param sets the
number of items that will be returned while the page
param enables skipping
to a particular set of results. There will be next
and back
links in the
response to indicate how the paged results can be navigated. There is also a
total_entries
attribute so that the total number of items can be established
without paging through all the results.
Response Status Codes
3xx redirection
Further action needs to be taken in order to complete the request.
4xx client error
The request contains bad syntax or cannot be fulfilled.