The history API for viewing lock opening and closing history is a feature that allows users to view a detailed log of when their lock was opened and closed. This feature can be accessed through a web portal or mobile app, and allows users to view the history of their lock's activity in real-time.
With this feature, users can view the date and time of each lock event, along with the user who initiated the event (if the lock is connected to a user account). This information can be used to see who has been accessing the lock, as well as when the lock was last accessed.
Additionally, the history API can also provide information about the type of event that occurred. For example, whether it was opened with a fingerprint, a passcode, a Bluetooth connection, or remotely through the mobile app. This information can be used to identify patterns in usage and troubleshoot any issues that may arise.
The history API also allows users to filter the events by date range and event type, making it easy to find specific events and analyze the usage of the lock over time.
Overall, the History API for viewing lock opening and closing history is a powerful tool that provides users with a detailed and easily accessible log of their lock's activity, helping to ensure the security of their property and providing valuable insights into how the lock is being used.
This endpoint retrieves a list of history records in the system.
lockuserid: The id of the lock user. (required)
type: A filter for the type of history to retrieve (0 for all, 1 for fingerprint, 2 for application, 3 for internet, 4 for shared, 5 for dashboard, and 6 for key). (required)
pagenumber: The page number of the results to retrieve. (required)
limit: The maximum number of results to retrieve per page. (required)
status: A status code indicating the success or failure of the request. 1 indicates success, and 0 indicates failure.
msg: A message indicating the result of the request.
analytics: An object containing the total number of history records and the breakdown by type.
totalPage: The total number of pages of results.
currentPage: The current page of results being returned.
unlockHistory: An array of objects representing the history records. Each object includes the following fields:
lockname: The name of the lock.
lock_open_status: A boolean indicating whether the lock was opened (1) or closed (0).
user: The user who unlocked the lock.
datetime: The date and time the lock was unlocked.
type: The type of unlock (1 for fingerprint, 2 for application, 3 for internet, 4 for shared, 5 for dashboard, and 6 for key).
location: An object representing the location of the lock when it was unlocked.
created_date: The date and time the history record was created.