Showing multiple device code for same device

Square List device codes API list the all device codes associated with merchant. Why it is showing multiple entries with same device-id and location-id with different device codes? And Status for devices are “PAIRED”.
Below is the sample JSON response which we got after invoking the list device code API.

:wave: I’m Square Dev AI, here to help answer your question!
Based on the information you’ve provided, the following documentation will help answer your question:

Additional Documentation

Locations API Overview
Merchant APIs
Locations API Overview

If this documentation helped you find a solution, please check the box indicating that this reply solves the problem.
Otherwise one of our Developer Advocates will provide additional assistance shortly.

This happens when you create and pair more then one device code with the Terminal. The device_id is the serial number of the Terminal device. If the Terminal device is paired with multiple locations or multiple device codes created by the Devices API they will all have the same device_id. :slightly_smiling_face:

Hi,

Thanks for reply.

If device is already paired with previously entered device code and user added new paring with new device code then How to remove pairing with previously entered device code?

Currently only possible using the dashboard (under Account & Settings / Business information / Devices).

It would be great to have an API method for this, though!

Hi,

Thanks for reply.

As of now, In Square dashboard, we did not see any option to unpair device with specific device code and location.
In Square dashboard, we can see only one option and which is “forget device”.

Is there any way to unpair device from specific location or device code if it is connected with multiple locations/device codes?

At this time there is only the option to forget a device. The ability to unpair isn’t currently available. :slightly_smiling_face: