Everything you need to know about NexoPOS.
This the object used to perform asynchronous requests to NexoPOS 4.x backend. This is a variant of Axios combined with RxJS, with a customized header and handler. This object is directly available on the "window" object. So you can use it anywhere on a page that uses NexoPOS 4.x headers. Here is how to perform requests.
For creating a GET request, you need to use the method "get" available on nsHttpClient. You'll use the same strategy for DELETE, but changing the method from "get" to "delete".
For creating a POST request, you need to use the method "post" available on nsHttpClient. However, that method accepts another argument that is the post that should be submitted. You'll use the same strategy to create PUT request, but changing the method "post" to "put".