Viewing query log
Last updated on May 17, 2023
If a problem arises with a user device, view the query log. It reflects both Sber Smart Home queries to your webhook and your API queries to Sber Smart Home. For each query, one can see at what time the query was sent, what kind of query it was, and what the response was.
The log is based on the X-Request-Id header (see Query headers) and the user ID in your system – these will be transmitted on each query to your webhook or from API. You will need to keep track of X-Request-Id on your cloud's side yourself.
To retrieve and view the right queries:
- In SmartMarket Studio, open your workspace. Select the project you need.
- In the left part of the screen, click on .
- Fill out the form fields and click on Download logs.
- Wait until the download batch is formed – the download link will appear below the form.
The logs reflect the following query details:
created_at | Date and time query was sent |
partner_id | Vendor's ID in Sber Smart Home |
user_id | User ID in vendor's system |
request_id | Unique ID assigned by Sber Smart Home to the query |
device_id | Device ID in vendor's system |
direction | Query direction:
|
operation | Name of the sent request. See Webhook queries for a list of possible queries |
address | Protocol and address used to send the query |
execution_time | Time until webhook response (in milliseconds) |
error_code | Response code:
|
error_text | The text of the error message returned by webhook |
device_type_id | Mode ID in vendor's system |
category_name | Device type (см. Devices) |
request_body | Request text |
response_body | Response text |