
Examples
Examples are provided to show various ways that the OpenAPI interfaces can be used. The examples are intended to show how various OpenAPI calls can be utilised.
- The examples are generally showing a call to dev.fieldpine.com using HTTPS.
- The RmSystem (aka Retailer Identifier) used is 1,2,3,4. This is an invalid value and you will need to use your own value
- The X-Api-Key authorisation header is shown with a dummy value that you will need to add your own key value
- If your application will only be operating within your own network to a private server, you may be able to forgo the RmSystem and X-Api-Key but we recommend using them anyway in case you need to talk to a shared server in future
- Examples are intended to show the usage of the API and may not use the latest techniques and styles for different languages
- Error handling and cleanup code may be missing and production code should add this. Examples are clearer when they only show the 'no problems' path
-
Javascript examples may use a function eLink_ExtractNum(....) which is a helper function used by Fieldpine to retrieve a nested value, you will almost certainly replace
this line with your own equivalent.
For Example, the call
var X = eLink_ExtractNum(reply, "data.LaneRegister[0].EftposCount", 0);
Will set X to reply.data.LaneRegister[0].EftposCount if it exists, otherwise 0.