OPOS HardwareStationDeviceActionRequest documentation #196
-
Hi Team, This is a request reg. OPOS HardwareStationDeviceActionRequest documentation. Put in a nutshell, what we need is just a list of the actions and how we feed the actions with data( json structure) for all the devices shown in the Hardware Profile of D365 FO, so we can use the standard POS request -> HardwareStationDeviceActionRequest. More information: The Store commerce app makes use of the OPOS technique e.g.,
Examples of requests store commerce sends to the OPOS driver when the app starts up: action: "DisplayText" For 2. action: "GetBarcodes" We would like to do the same but there's missing documentation of the available device names and actions and how the requestBody should be structured etc. We have already written our own text to the LineDisplay device successfully by using the following classes The HardwareStationDeviceActionRequest needs a 'device' and an 'action' as text plus Data in jsonformat like shown below. var data = { DeviceName: "MockOPOSLineDisplay", DeviceType: "OPOS", Lines: ["Test OPOS Line Display", "123456"], Clear: true} Thank you in advance. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Hi @juergenkmsft - for the most common requests for OPOS device actions, customers can instead use the list of Peripheral Requests in the "PosApi/Consume/Peripherals" module of the Pos.Api.d.ts file available on the SDK. These requests serve as a wrapper for the For devices or actions that do not have an associated Peripheral Request in that list, customers will need to create a Hardware Station extension that contains a controller that they can call using |
Beta Was this translation helpful? Give feedback.
Hi @cboconsult - the list of controllers and actions that are exposed by the Hardware Station service are not part of the public contract, which is why they aren't documented. If you want to send a custom command that isn't provided out-of-the-box by the PosApi, our recommendation would be either:
ExecuteOposDeviceMethodRequest
to send the message from the controller to the OPOS device. That method (along withGetOposDevicePropertyValueRequest
andSetOposDevicePropertyValueRequest
) call the corresponding methods sup…