First up you'll need to establish a connection to the Doshii WebSocket. Please check out this more detailed WebSocket guide
URL wss://socket.<environment>.doshii.co/pos/socket?token=<locationToken>
If you're a Cloud POS Vendor then your connection is slightly different as you no longer need to connect for each location.
URL wss://socket.<environment>.doshii.co/vendor/socket?token=<jwt>&vendor=<apiName>
The JWT token is built using the same technique described in POS Authentication with the only difference being the Vendor API Name is included rather than the location token.
"vendor": The POS Vendor API name
"timestamp": The current timestamp in EPOC-Seconds for validating the request expiry time, default is 10 minutes.
Parameters
Field | Type | Description |
---|---|---|
environment | String |
The environment you'll be connecting to, such as |
locationToken | String |
Unique POS Location token provided by Doshii |
vendor | String |
The POS Vendor API name for Cloud POS vendors. This is only required for Cloud POS vendors. |
Example
Event
{ "type": "message", "data": { "doshii": { "pong": 1539144663417, "version": '3.2.123' } } }
Comments
0 comments
Please sign in to leave a comment.