Сreating and configuring an instance using the partner key#
-
To create an instance using the partner's method createInstance, when creating the instance, you need to pass instance settings.
-
After creating the instance, it is required to continuously request the status of the created instance every 5 seconds using the method getStateInstance, doing before receiving the status "Not authorized".
The response body
null
when calling thegetStateInstance
method means the instance is still being created. You can use this token until the instance readiness statusnotAuthorized
is received. -
After receiving the
notAuthorized
status, you must request the QR code by calling the QR method every two seconds (so that the client always has an up-to-date QR code). -
After successfully pairing with the device, receiving requests for the QR code must be stopped. The instance settings do not change over time, and there is no need to renew the instance settings. You can check the installation of the settings using the method GetSettings.
General recommendations for creating and configuring an instance.
Optional recommendations (Non requiring):
- For clients, it is recommended to connect the device in an alternative way - by requesting an authorization code using the getAuthorizationCode method.
- To get the current QR code, it is recommended to request it via a websocket connection using the scanqrcode method.