Add a single location or device to an existing location using the InStore device command-line interface (CLI).
You can use the InStore device CLI to add a location or device directly to your system. This method is useful for quick, ad hoc additions without using the InStore Center application.
Add a location using the CLI
- Complete the initial setup as described in Initial setup via the CLI.
- Run the following command, replacing the JSON string with the required location information:
node index.js create-location '{"location_id": "12345", "location_name": "Test Store", ...}'
If your organization has created payment options with the
default key set to true, a new location can have those payment options automatically associated with it. If there are no default payment options, or if the location requires special options, you can manually add them to the location. See Assign payment options to a location.Add a device using the CLI
-
Complete the initial setup as described in Initial setup via the CLI.
-
Run the following command, replacing
LOCATION_IDwith the identifier of an existing location and{device info}with the required device fields:nametypestatusbrandmodelshared
node index.js create-device LOCATION_ID '{device info}'
If the device you are adding is a workstation, see Initial setup via the CLI for required fields. If your organization has created payment options with the
default key set to true, a new workstation can have those payment options automatically associated with it. If there are no default payment options, or if the workstation requires special options, you can manually add them to the workstation. See Assign payment options to a workstation.Example
node index.js create-device 44444 '{"name": "Epson TM88VI Printer", "type": "Printer", "description": "Printer 1", "status": "Active", "brand": "Epson", "model": "m1", "shared": true, "proxy_address": "127.0.0.1", "ip_address": "127.0.0.1"}'
You cannot delete a device from a location programmatically using the CLI. To delete a device, use the InStore Center if the device is eligible for deletion.