Function autotype_request_get_credentials
pub async fn autotype_request_get_credentials(
ipc_client: &JsIpcClient,
app: AutotypeRunningApp,
abort_signal: Option<AbortSignal>,
) -> Result<AutotypeGetCredentialsResponse, RequestError>Expand description
Sends an AutotypeGetCredentialsRequest to the desktop render process, asking for the
credentials to autotype into the focused app. The response’s credentials is empty when no
vault item matches.
The response doesn’t identify the app it’s for. Keep the focused app’s identity from before sending the request, and confirm that app is still focused before typing. If it isn’t, the user has switched apps, and nothing should be typed.
The render process must have called registerAutotypeRenderHandlers first. Otherwise the
request fails (for example, with a “no handler found” error) or waits until abort_signal
fires.
There is no built-in timeout, so always pass abort_signal (for example
AbortSignal.timeout(ms)). Without one, the request never completes if the render process
doesn’t respond.