1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 /** @fileoverview Externs generated from namespace: passwordsPrivate */
10 chrome.passwordsPrivate = {};
17 * @see https://developer.chrome.com/extensions/passwordsPrivate#type-LoginPair
23 * loginPair: LoginPair,
24 * numCharactersInPassword: number,
25 * federationText: (string|undefined)
27 * @see https://developer.chrome.com/extensions/passwordsPrivate#type-PasswordUiEntry
33 * loginPair: LoginPair,
34 * plaintextPassword: string
36 * @see https://developer.chrome.com/extensions/passwordsPrivate#type-PlaintextPasswordEventParameters
38 var PlaintextPasswordEventParameters;
41 * Determines whether account's passwords can be managed via
42 * https://passwords.google.com/settings/passwords.
43 * @param {function(boolean):void} callback Callback which will be passed the
44 * boolean of whether the account can be managed.
45 * @see https://developer.chrome.com/extensions/passwordsPrivate#method-canPasswordAccountBeManaged
47 chrome.passwordsPrivate.canPasswordAccountBeManaged = function(callback) {};
50 * Removes the saved password corresponding to |loginPair|. If no saved password
51 * for this pair exists, this function is a no-op.
52 * @param {LoginPair} loginPair The LoginPair corresponding to the entry to
54 * @see https://developer.chrome.com/extensions/passwordsPrivate#method-removeSavedPassword
56 chrome.passwordsPrivate.removeSavedPassword = function(loginPair) {};
59 * Removes the saved password exception corresponding to |exceptionUrl|. If no
60 * exception with this URL exists, this function is a no-op.
61 * @param {string} exceptionUrl The URL corresponding to the exception to
63 * @see https://developer.chrome.com/extensions/passwordsPrivate#method-removePasswordException
65 chrome.passwordsPrivate.removePasswordException = function(exceptionUrl) {};
68 * Returns the plaintext password corresponding to |loginPair|. Note that on
69 * some operating systems, this call may result in an OS-level reauthentication.
70 * Once the password has been fetched, it will be returned via the
71 * onPlaintextPasswordRetrieved event.
72 * @param {LoginPair} loginPair The LoginPair corresponding to the entry whose
73 * password is to be returned.
74 * @see https://developer.chrome.com/extensions/passwordsPrivate#method-requestPlaintextPassword
76 chrome.passwordsPrivate.requestPlaintextPassword = function(loginPair) {};
79 * Fired when the saved passwords list has changed, meaning that an entry has
80 * been added or removed. Note that this event fires as soon as a listener is
82 * @type {!ChromeEvent}
83 * @see https://developer.chrome.com/extensions/passwordsPrivate#event-onSavedPasswordsListChanged
85 chrome.passwordsPrivate.onSavedPasswordsListChanged;
88 * Fired when the password exceptions list has changed, meaning that an entry
89 * has been added or removed. Note that this event fires as soon as a listener
91 * @type {!ChromeEvent}
92 * @see https://developer.chrome.com/extensions/passwordsPrivate#event-onPasswordExceptionsListChanged
94 chrome.passwordsPrivate.onPasswordExceptionsListChanged;
97 * Fired when a plaintext password has been fetched in response to a call to
98 * chrome.passwordsPrivate.requestPlaintextPassword().
99 * @type {!ChromeEvent}
100 * @see https://developer.chrome.com/extensions/passwordsPrivate#event-onPlaintextPasswordRetrieved
102 chrome.passwordsPrivate.onPlaintextPasswordRetrieved;