#import <CredentialManagement/Credential.idl>

[Exposed=Window, SecureContext]
interface FederatedCredential : Credential {
    constructor(FederatedCredentialInit data);
    readonly attribute USVString provider;
    readonly attribute DOMString? protocol;
};
FederatedCredential includes CredentialUserData;

dictionary FederatedCredentialRequestOptions {
    sequence<USVString> providers;
    sequence<DOMString> protocols;
};

partial dictionary CredentialRequestOptions {
    FederatedCredentialRequestOptions federated;
};

dictionary FederatedCredentialInit : CredentialData {
    USVString name;
    USVString iconURL;
    required USVString origin;
    required USVString provider;
    DOMString protocol;
};

partial dictionary CredentialCreationOptions {
    FederatedCredentialInit federated;
};
