https://api.sciener.com/v3/gateway/listByLock
The gateway automatically search locks nearby it, and notify the gateway server about the locks it found, the gateway server will create a many-to-many relationship between the gateways and locks if the lock and gateway belong to the same administrator account, the relationship will be cached for 30 minutes, that is if a gateway have notified the gateway server about the lock in 30 minutes, this API will return the gateway.
This API will return all the gateways related to a lock.
The gateway server will choose the gateway with the best RSSI to communication with the lock when user want to operate the lock remotely.
xxxxxxxxxxcurl --location --request GET 'https://api.sciener.com/v3/gateway/listByLock?clientId=4773aa036f7f49c68d876bb4be85c80c&accessToken=dfd5489d0cee31f0bdfaf59d0d42d71f&lockId=163377&date=1626674054000'| Name | Type | Required | Description |
|---|---|---|---|
| clientId | String | Y | client_id from Create application |
| accessToken | String | Y | Access token,refer to: Get access token |
| lockId | Int | Y | Lock ID, generated by Lock init |
| date | Long | Y | Current time (timestamp in millisecond) |
| Parameter | Type | Description |
|---|---|---|
| list | JSONArray | list of records |
The objects in the list:
| Parameter | Type | Description |
|---|---|---|
| gatewayId | Int | Gateway ID |
| gatewayMac | String | Gateway MAC |
| gatewayName | String | Gateway name |
| rssi | Int | The signal intensity between gateway and lock. reference: >-75 is strong, -85<i<-75 is medium, <-85 is weak |
| rssiUpdateDate | Long | The time when the signal intensity updated (timestamp in millisecond) |
xxxxxxxxxx{"list": [{"gatewayId": 78979,"gatewayMac": "C5:40:E0:9C:8C:C1","gatewayName": "Gateway for 1-101","rssi": -65,"rssiUpdateDate": 1626674053000}]}