chromium/out/Default/gen/chrome/common/extensions/api/passwords_private.h

// Copyright 2024 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// GENERATED FROM THE API DEFINITION IN
//   chrome/common/extensions/api/passwords_private.idl
// by tools/json_schema_compiler.
// DO NOT EDIT.

#ifndef CHROME_COMMON_EXTENSIONS_API_PASSWORDS_PRIVATE_H__
#define CHROME_COMMON_EXTENSIONS_API_PASSWORDS_PRIVATE_H__

#include <stdint.h>

#include <map>
#include <memory>
#include <optional>
#include <string>
#include <vector>

#include "base/values.h"
#include <string_view>


namespace extensions {
namespace api {
namespace passwords_private {

//
// Types
//

// Possible reasons why a plaintext password was requested.
enum class PlaintextReason {};


const char* ToString(PlaintextReason as_enum);
PlaintextReason ParsePlaintextReason(std::string_view as_string);
std::u16string GetPlaintextReasonParseError(std::string_view as_string);

enum class ExportProgressStatus {};


const char* ToString(ExportProgressStatus as_enum);
ExportProgressStatus ParseExportProgressStatus(std::string_view as_string);
std::u16string GetExportProgressStatusParseError(std::string_view as_string);

enum class CompromiseType {};


const char* ToString(CompromiseType as_enum);
CompromiseType ParseCompromiseType(std::string_view as_string);
std::u16string GetCompromiseTypeParseError(std::string_view as_string);

enum class PasswordStoreSet {};


const char* ToString(PasswordStoreSet as_enum);
PasswordStoreSet ParsePasswordStoreSet(std::string_view as_string);
std::u16string GetPasswordStoreSetParseError(std::string_view as_string);

enum class PasswordCheckState {};


const char* ToString(PasswordCheckState as_enum);
PasswordCheckState ParsePasswordCheckState(std::string_view as_string);
std::u16string GetPasswordCheckStateParseError(std::string_view as_string);

enum class ImportResultsStatus {};


const char* ToString(ImportResultsStatus as_enum);
ImportResultsStatus ParseImportResultsStatus(std::string_view as_string);
std::u16string GetImportResultsStatusParseError(std::string_view as_string);

enum class ImportEntryStatus {};


const char* ToString(ImportEntryStatus as_enum);
ImportEntryStatus ParseImportEntryStatus(std::string_view as_string);
std::u16string GetImportEntryStatusParseError(std::string_view as_string);

enum class FamilyFetchStatus {};


const char* ToString(FamilyFetchStatus as_enum);
FamilyFetchStatus ParseFamilyFetchStatus(std::string_view as_string);
std::u16string GetFamilyFetchStatusParseError(std::string_view as_string);

struct PublicKey {};

struct RecipientInfo {};

struct FamilyFetchResults {};

struct ImportEntry {};

struct ImportResults {};

struct UrlCollection {};

struct CompromisedInfo {};

struct DomainInfo {};

struct PasswordUiEntry {};

struct CredentialGroup {};

struct ExceptionEntry {};

struct PasswordExportProgress {};

struct PasswordCheckStatus {};

struct AddPasswordOptions {};

struct PasswordUiEntryList {};


//
// Functions
//

namespace RecordPasswordsPageAccessInSettings {

}  // namespace RecordPasswordsPageAccessInSettings

namespace ChangeCredential {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace ChangeCredential

namespace RemoveCredential {

struct Params {};

}  // namespace RemoveCredential

namespace RemovePasswordException {

struct Params {};

}  // namespace RemovePasswordException

namespace UndoRemoveSavedPasswordOrException {

}  // namespace UndoRemoveSavedPasswordOrException

namespace RequestPlaintextPassword {

struct Params {};

namespace Results {

base::Value::List Create(const std::string& password);
}  // namespace Results

}  // namespace RequestPlaintextPassword

namespace RequestCredentialsDetails {

struct Params {};

namespace Results {

base::Value::List Create(const std::vector<PasswordUiEntry>& entries);
}  // namespace Results

}  // namespace RequestCredentialsDetails

namespace GetSavedPasswordList {

namespace Results {

base::Value::List Create(const std::vector<PasswordUiEntry>& entries);
}  // namespace Results

}  // namespace GetSavedPasswordList

namespace GetCredentialGroups {

namespace Results {

base::Value::List Create(const std::vector<CredentialGroup>& entries);
}  // namespace Results

}  // namespace GetCredentialGroups

namespace GetPasswordExceptionList {

namespace Results {

base::Value::List Create(const std::vector<ExceptionEntry>& exceptions);
}  // namespace Results

}  // namespace GetPasswordExceptionList

namespace MovePasswordsToAccount {

struct Params {};

}  // namespace MovePasswordsToAccount

namespace FetchFamilyMembers {

namespace Results {

base::Value::List Create(const FamilyFetchResults& results);
}  // namespace Results

}  // namespace FetchFamilyMembers

namespace SharePassword {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace SharePassword

namespace ImportPasswords {

struct Params {};

namespace Results {

base::Value::List Create(const ImportResults& results);
}  // namespace Results

}  // namespace ImportPasswords

namespace ContinueImport {

struct Params {};

namespace Results {

base::Value::List Create(const ImportResults& results);
}  // namespace Results

}  // namespace ContinueImport

namespace ResetImporter {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace ResetImporter

namespace ExportPasswords {

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace ExportPasswords

namespace RequestExportProgressStatus {

namespace Results {

base::Value::List Create(const ExportProgressStatus& status);
}  // namespace Results

}  // namespace RequestExportProgressStatus

namespace IsOptedInForAccountStorage {

namespace Results {

base::Value::List Create(bool opted_in);
}  // namespace Results

}  // namespace IsOptedInForAccountStorage

namespace OptInForAccountStorage {

struct Params {};

}  // namespace OptInForAccountStorage

namespace GetInsecureCredentials {

namespace Results {

base::Value::List Create(const std::vector<PasswordUiEntry>& entries);
}  // namespace Results

}  // namespace GetInsecureCredentials

namespace GetCredentialsWithReusedPassword {

namespace Results {

base::Value::List Create(const std::vector<PasswordUiEntryList>& entries);
}  // namespace Results

}  // namespace GetCredentialsWithReusedPassword

namespace MuteInsecureCredential {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace MuteInsecureCredential

namespace UnmuteInsecureCredential {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace UnmuteInsecureCredential

namespace StartPasswordCheck {

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace StartPasswordCheck

namespace GetPasswordCheckStatus {

namespace Results {

base::Value::List Create(const PasswordCheckStatus& status);
}  // namespace Results

}  // namespace GetPasswordCheckStatus

namespace IsAccountStoreDefault {

namespace Results {

base::Value::List Create(bool is_default);
}  // namespace Results

}  // namespace IsAccountStoreDefault

namespace GetUrlCollection {

struct Params {};

namespace Results {

base::Value::List Create(const UrlCollection& url_collection);
}  // namespace Results

}  // namespace GetUrlCollection

namespace AddPassword {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace AddPassword

namespace ExtendAuthValidity {

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace ExtendAuthValidity

namespace SwitchBiometricAuthBeforeFillingState {

namespace Results {

base::Value::List Create(bool result);
}  // namespace Results

}  // namespace SwitchBiometricAuthBeforeFillingState

namespace ShowAddShortcutDialog {

}  // namespace ShowAddShortcutDialog

namespace ShowExportedFileInShell {

struct Params {};

}  // namespace ShowExportedFileInShell

namespace ChangePasswordManagerPin {

namespace Results {

base::Value::List Create(bool success);
}  // namespace Results

}  // namespace ChangePasswordManagerPin

namespace IsPasswordManagerPinAvailable {

namespace Results {

base::Value::List Create(bool available);
}  // namespace Results

}  // namespace IsPasswordManagerPinAvailable

namespace DisconnectCloudAuthenticator {

namespace Results {

base::Value::List Create(bool success);
}  // namespace Results

}  // namespace DisconnectCloudAuthenticator

namespace IsConnectedToCloudAuthenticator {

namespace Results {

base::Value::List Create(bool connected);
}  // namespace Results

}  // namespace IsConnectedToCloudAuthenticator

namespace DeleteAllPasswordManagerData {

namespace Results {

base::Value::List Create(bool success);
}  // namespace Results

}  // namespace DeleteAllPasswordManagerData

//
// Events
//

namespace OnSavedPasswordsListChanged {

extern const char kEventName[];  // "passwordsPrivate.onSavedPasswordsListChanged"

// The updated list of password entries.
base::Value::List Create(const std::vector<PasswordUiEntry>& entries);
}  // namespace OnSavedPasswordsListChanged

namespace OnPasswordExceptionsListChanged {

extern const char kEventName[];  // "passwordsPrivate.onPasswordExceptionsListChanged"

// The updated list of password exceptions.
base::Value::List Create(const std::vector<ExceptionEntry>& exceptions);
}  // namespace OnPasswordExceptionsListChanged

namespace OnPasswordsFileExportProgress {

extern const char kEventName[];  // "passwordsPrivate.onPasswordsFileExportProgress"

// The progress status and an optional UI message.
base::Value::List Create(const PasswordExportProgress& status);
}  // namespace OnPasswordsFileExportProgress

namespace OnAccountStorageOptInStateChanged {

extern const char kEventName[];  // "passwordsPrivate.onAccountStorageOptInStateChanged"

// The new opt-in state.
base::Value::List Create(bool opted_in);
}  // namespace OnAccountStorageOptInStateChanged

namespace OnInsecureCredentialsChanged {

extern const char kEventName[];  // "passwordsPrivate.onInsecureCredentialsChanged"

// The updated insecure credentials.
base::Value::List Create(const std::vector<PasswordUiEntry>& insecure_credentials);
}  // namespace OnInsecureCredentialsChanged

namespace OnPasswordCheckStatusChanged {

extern const char kEventName[];  // "passwordsPrivate.onPasswordCheckStatusChanged"

// The updated status of the password check.
base::Value::List Create(const PasswordCheckStatus& status);
}  // namespace OnPasswordCheckStatusChanged

namespace OnPasswordManagerAuthTimeout {

extern const char kEventName[];  // "passwordsPrivate.onPasswordManagerAuthTimeout"

base::Value::List Create();
}  // namespace OnPasswordManagerAuthTimeout

}  // namespace passwords_private
}  // namespace api
}  // namespace extensions

#endif  // CHROME_COMMON_EXTENSIONS_API_PASSWORDS_PRIVATE_H__