Package org.linphone.core

# Interface AccountCreator

public interface AccountCreator
The object used to configure an account on a server via XML-RPC See: Override
account creator request
The object used to configure an account on a server via XML-RPC See: Override
account creator request

## Nested Class Summary

Nested Classes
Modifier and Type
Interface
Description
`static enum`
`AccountCreator.ActivationCodeStatus`
`static enum`
`AccountCreator.AlgoStatus`
`static enum`
`AccountCreator.Backend`
`static enum`
`AccountCreator.DomainStatus`
`static enum`
`AccountCreator.EmailStatus`
`static enum`
`AccountCreator.LanguageStatus`
`static enum`
`AccountCreator.PasswordStatus`
`static enum`
`AccountCreator.PhoneNumberStatus`
`static enum`
`AccountCreator.Status`
`static enum`
`AccountCreator.TransportStatus`
`static enum`
`AccountCreator.UsernameStatus`

## Method Summary

Modifier and Type
Method
Description
`AccountCreator.Status`
`activateAccount()`
Deprecated.
`AccountCreator.Status`
`activateAlias()`
Deprecated.
`void`
`addListener(AccountCreatorListener listener)`
`AccountCreator`
`create(Core core)`
Deprecated.
`AccountCreator.Status`
`createAccount()`
Deprecated.
`Account`
`createAccountInCore()`
Deprecated.
`ProxyConfig`
`createProxyConfig()`
Deprecated.
`AccountCreator.Status`
`createPushAccount()`
Deprecated.
`String`
`getAccountCreationRequestToken()`
Deprecated.
`String`
`getActivationCode()`
Deprecated.
`String`
`getAlgorithm()`
Deprecated.
`String`
`getDisplayName()`
Deprecated.
`String`
`getDomain()`
Deprecated.
`String`
`getEmail()`
Deprecated.
`String`
`getHa1()`
Deprecated.
`String`
`getLanguage()`
Deprecated.
`long`
`getNativePointer()`
Gets the native pointer used by this class to make native method calls.
`String`
`getPassword()`
Deprecated.
`String`
`getPhoneCountryCode()`
Deprecated.
`String`
`getPhoneNumber()`
Deprecated.
`String`
`getPnParam()`
Deprecated.
`String`
`getPnPrid()`
Deprecated.
`String`
`getPnProvider()`
Deprecated.
`String`
`getRoute()`
Get the route.
`boolean`
`getSetAsDefault()`
Deprecated.
`String`
`getToken()`
Deprecated.
`TransportType`
`getTransport()`
Deprecated.
`Object`
`getUserData()`
Gets the object stored in this object user's data
`String`
`getUsername()`
Deprecated.
`AccountCreator.Status`
`isAccountActivated()`
Deprecated.
`AccountCreator.Status`
`isAccountExist()`
Deprecated.
`AccountCreator.Status`
`isAccountLinked()`
Deprecated.
`AccountCreator.Status`
`isAliasUsed()`
Deprecated.
`AccountCreator.Status`
`linkAccount()`
Deprecated.
`AccountCreator.Status`
`loginLinphoneAccount()`
Deprecated.
`AccountCreator.Status`
`recoverAccount()`
Deprecated.
`void`
`removeListener(AccountCreatorListener listener)`
`AccountCreator.Status`
`requestAccountCreationRequestToken()`
Deprecated.
`AccountCreator.Status`
`requestAccountCreationTokenUsingRequestToken()`
Deprecated.
`AccountCreator.Status`
`requestAuthToken()`
Deprecated.
`void`
`reset()`
Deprecated.
`void`
`setAccount(Account account)`
Deprecated.
`void`
`setAccountCreationRequestToken(String token)`
Deprecated.
`AccountCreator.ActivationCodeStatus`
`setActivationCode(String activationCode)`
Deprecated.
`AccountCreator.AlgoStatus`
`setAlgorithm(String algorithm)`
Deprecated.
`AccountCreator.Status`
`setAsDefault(boolean setAsDefault)`
Deprecated.
`AccountCreator.UsernameStatus`
`setDisplayName(String displayName)`
Deprecated.
`AccountCreator.DomainStatus`
`setDomain(String domain)`
Deprecated.
`AccountCreator.EmailStatus`
`setEmail(String email)`
Deprecated.
`AccountCreator.PasswordStatus`
`setHa1(String ha1)`
Deprecated.
`AccountCreator.LanguageStatus`
`setLanguage(String lang)`
Deprecated.
`AccountCreator.PasswordStatus`
`setPassword(String password)`
Deprecated.
`int`
`setPhoneNumber(String phoneNumber, String countryCode)`
Deprecated.
`void`
`setPnParam(String pnParam)`
Deprecated.
`void`
`setPnPrid(String pnPrid)`
Deprecated.
`void`
`setPnProvider(String pnProvider)`
Deprecated.
`void`
`setProxyConfig(ProxyConfig cfg)`
Deprecated.
`AccountCreator.Status`
`setRoute(String route)`
Set the route.
`void`
`setToken(String token)`
Deprecated.
`AccountCreator.TransportStatus`
`setTransport(TransportType transport)`
Deprecated.
`void`
`setUserData(Object data)`
Sets the object to store in this object user's data
`AccountCreator.UsernameStatus`
`setUsername(String username)`
Deprecated.
`String`
`toString()`
`AccountCreator.Status`
`updateAccount()`
Deprecated.
`void`
`useTestAdminAccount()`
Deprecated.

## Method Details

### setAccount

@Deprecated void setAccount(@Nullable Account account)
Deprecated.
Assign a proxy config pointer to the LinphoneAccountCreator.

Parameters:
  `account` - The LinphoneAccount to associate with the
  LinphoneAccountCreator.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getAccountCreationRequestToken

@Deprecated @Nullable String getAccountCreationRequestToken()
Deprecated.
Get the account creation request token received to be used to check user
validation.

Returns:
  The token set, if any
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setAccountCreationRequestToken

@Deprecated void setAccountCreationRequestToken(@Nullable String token)
Deprecated.
Set the account creation request token received to be used to check user
validation.

Parameters:
  `token` - The token to set
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getActivationCode

@Deprecated @Nullable String getActivationCode()
Deprecated.
Get the activation code.

Returns:
  The activation code of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setActivationCode

@Deprecated AccountCreator.ActivationCodeStatus setActivationCode(@Nullable String activationCode)
Deprecated.
Set the activation code.

Parameters:
  `activationCode` - The activation code to set
Returns:
  `AccountCreator.ActivationCodeStatus.Ok` if everything is OK, or a specific
  error otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getAlgorithm

@Deprecated @Nullable String getAlgorithm()
Deprecated.
Get the algorithm configured in the account creator.

Returns:
  The algorithm of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setAlgorithm

@Deprecated AccountCreator.AlgoStatus setAlgorithm(@Nullable String algorithm)
Deprecated.
Set the supported algorithm.

Parameters:
  `algorithm` - The algorithm to use
Returns:
  LinphoneAccountCreatorAlgoStatusOk if everything is OK, or a specific
  error otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setAsDefault

@Deprecated AccountCreator.Status setAsDefault(boolean setAsDefault)
Deprecated.
Set the set_as_default property.

Parameters:
  `setAsDefault` - true for the created proxy config to be set as default in
  `Core`, false otherwise
Returns:
  `AccountCreator.Status.RequestOk` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getDisplayName

@Deprecated @Nullable String getDisplayName()
Deprecated.
Get the display name.

Returns:
  The display name of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setDisplayName

@Deprecated AccountCreator.UsernameStatus setDisplayName(@Nullable String displayName)
Deprecated.
Set the display name.

Parameters:
  `displayName` - The display name to set
Returns:
  `AccountCreator.UsernameStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getDomain

@Deprecated @Nullable String getDomain()
Deprecated.
Get the domain.

Returns:
  The domain of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setDomain

@Deprecated AccountCreator.DomainStatus setDomain(@Nullable String domain)
Deprecated.
Set the domain.

Parameters:
  `domain` - The domain to set
Returns:
  `AccountCreator.DomainStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getEmail

@Deprecated @Nullable String getEmail()
Deprecated.
Get the email.

Returns:
  The email of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setEmail

@Deprecated AccountCreator.EmailStatus setEmail(@Nullable String email)
Deprecated.
Set the email.

Parameters:
  `email` - The email to set
Returns:
  `AccountCreator.EmailStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getHa1

@Deprecated @Nullable String getHa1()
Deprecated.
Get the ha1.

Returns:
  The ha1 of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setHa1

@Deprecated AccountCreator.PasswordStatus setHa1(@Nullable String ha1)
Deprecated.
Set the ha1.

Parameters:
  `ha1` - The ha1 to set
Returns:
  `AccountCreator.PasswordStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getLanguage

@Deprecated @Nullable String getLanguage()
Deprecated.
Get the language use in email of SMS.

Returns:
  The language of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setLanguage

@Deprecated AccountCreator.LanguageStatus setLanguage(@Nullable String lang)
Deprecated.
Set the language to use in email or SMS if supported.

Parameters:
  `lang` - The language to use
Returns:
  `AccountCreator.LanguageStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getPassword

@Deprecated @Nullable String getPassword()
Deprecated.
Get the password.

Returns:
  The password of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setPassword

@Deprecated AccountCreator.PasswordStatus setPassword(@Nullable String password)
Deprecated.
Set the password.

Parameters:
  `password` - The password to set
Returns:
  `AccountCreator.PasswordStatus.Ok` if everything is OK, or specific(s) error(s)
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getPhoneCountryCode

@Deprecated @Nullable String getPhoneCountryCode()
Deprecated.
Get the international prefix.

Returns:
  The international prefix (or phone country code) of the `AccountCreator`
  .
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getPhoneNumber

@Deprecated @Nullable String getPhoneNumber()
Deprecated.
Get the RFC 3966 normalized phone number.

Returns:
  The phone number of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getPnParam

@Deprecated @Nullable String getPnParam()
Deprecated.
Get the param to be used by the backend to send the push notification to the
device asking for an auth token.

Returns:
  The pn_param set, if any
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setPnParam

@Deprecated void setPnParam(@Nullable String pnParam)
Deprecated.
Set the param to be used by the backend to send the push notification to the
device asking for an auth token.

Parameters:
  `pnParam` - The pn_param to set
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getPnPrid

@Deprecated @Nullable String getPnPrid()
Deprecated.
Get the prid to be used by the backend to send the push notification to the
device asking for an auth token.

Returns:
  The pn_prid set, if any
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setPnPrid

@Deprecated void setPnPrid(@Nullable String pnPrid)
Deprecated.
Set the prid to be used by the backend to send the push notification to the
device asking for an auth token.

Parameters:
  `pnPrid` - The pn_prid to set
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getPnProvider

@Deprecated @Nullable String getPnProvider()
Deprecated.
Get the provider to be used by the backend to send the push notification to the
device asking for an auth token.

Returns:
  The pn_provider set, if any
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setPnProvider

@Deprecated void setPnProvider(@Nullable String pnProvider)
Deprecated.
Set the provider to be used by the backend to send the push notification to the
device asking for an auth token.

Parameters:
  `pnProvider` - The pn_provider to set
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setProxyConfig

@Deprecated void setProxyConfig(@Nullable ProxyConfig cfg)
Deprecated.
Assign a proxy config pointer to the LinphoneAccountCreator.

Parameters:
  `cfg` - The LinphoneProxyConfig to associate with the
  LinphoneAccountCreator.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getRoute

@Nullable String getRoute()
Get the route.

Returns:
  The route of the `AccountCreator`.

### setRoute

AccountCreator.Status setRoute(@Nullable String route)
Set the route.

Parameters:
  `route` - The route to set
Returns:
  `AccountCreator.Status.RequestOk` if everything is OK, or a specific error
  otherwise.

### getSetAsDefault

@Deprecated boolean getSetAsDefault()
Deprecated.
Get the set_as_default property.

Returns:
  true if account will be set as default, false otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getToken

@Deprecated @Nullable String getToken()
Deprecated.
Get the authentication token set (if any) to be used to authenticate next
queries, if required.

Returns:
  The token set, if any
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setToken

@Deprecated void setToken(@Nullable String token)
Deprecated.
Set the authentication token received by push notification to be used to
authenticate next queries, if required.

Parameters:
  `token` - The token to set
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getTransport

@Deprecated TransportType getTransport()
Deprecated.
Get Transport.

Returns:
  The `TransportType` of the creator.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setTransport

@Deprecated AccountCreator.TransportStatus setTransport(TransportType transport)
Deprecated.
Set Transport.

Parameters:
  `transport` - The `TransportType` to set
Returns:
  `AccountCreator.TransportStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### getUsername

@Deprecated @Nullable String getUsername()
Deprecated.
Get the username.

Returns:
  The username of the `AccountCreator`.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### setUsername

@Deprecated AccountCreator.UsernameStatus setUsername(@Nullable String username)
Deprecated.
Set the username.

Parameters:
  `username` - The username to set
Returns:
  `AccountCreator.UsernameStatus.Ok` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### activateAccount

@Deprecated AccountCreator.Status activateAccount()
Deprecated.
Send a request to activate an account on server.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### activateAlias

@Deprecated AccountCreator.Status activateAlias()
Deprecated.
Send a request to activate an alias.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### createAccount

@Deprecated AccountCreator.Status createAccount()
Deprecated.
Send a request to create an account on server.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### createAccountInCore

@Deprecated @Nullable Account createAccountInCore()
Deprecated.
Create and configure a `Account` and a `AuthInfo` from informations
set in the `AccountCreator`.

Returns:
  A `Account` object if successful, null otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### createProxyConfig

@Deprecated @Nullable ProxyConfig createProxyConfig()
Deprecated.
Create and configure a proxy config and a authentication info for an account
creator.

Returns:
  A `ProxyConfig` object if successful, null otherwise.
  deprecated: 05/05/2023 Use `createAccountInCore()` instead.

### createPushAccount

@Deprecated AccountCreator.Status createPushAccount()
Deprecated.
Send a request to create a push account on server.
Push accounts are used in account dependent situation when account cannot send
push notifications. A username and password are automatically generated, an
account is automatically activated.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### isAccountActivated

@Deprecated AccountCreator.Status isAccountActivated()
Deprecated.
Send a request to know if an account is activated on server.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### isAccountExist

@Deprecated AccountCreator.Status isAccountExist()
Deprecated.
Send a request to know the existence of account on server.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### isAccountLinked

@Deprecated AccountCreator.Status isAccountLinked()
Deprecated.
Send a request to know if an account is linked.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### isAliasUsed

@Deprecated AccountCreator.Status isAliasUsed()
Deprecated.
Send a request to know if an alias is used.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### linkAccount

@Deprecated AccountCreator.Status linkAccount()
Deprecated.
Send a request to link an account to an alias.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### loginLinphoneAccount

@Deprecated AccountCreator.Status loginLinphoneAccount()
Deprecated.
Send a request to get the password & algorithm of an account using the
confirmation key.

Returns:
  `AccountCreator.Status.RequestOk` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### recoverAccount

@Deprecated AccountCreator.Status recoverAccount()
Deprecated.
Send a request to recover an account.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### requestAccountCreationRequestToken

@Deprecated AccountCreator.Status requestAccountCreationRequestToken()
Deprecated.
Request an account creation "request_token" to be used on account creations.
The request_token is retrieved from the callback
linphone_account_creator_cbs_get_account_creation_request_token

Returns:
  `AccountCreator.Status.RequestOk` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### requestAccountCreationTokenUsingRequestToken

@Deprecated AccountCreator.Status requestAccountCreationTokenUsingRequestToken()
Deprecated.
Send a request to get a token to be used for account creation from a
request_token.
The token is retrieved from the callback
linphone_account_creator_cbs_get_account_creation_token_using_request_token

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### requestAuthToken

@Deprecated AccountCreator.Status requestAuthToken()
Deprecated.
Request an auth token to be send by the backend by push notification.

Returns:
  `AccountCreator.Status.RequestOk` if everything is OK, or a specific error
  otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### reset

@Deprecated void reset()
Deprecated.
Reset the account creator entries like username, password, phone number...
deprecated: 11/06/2024 use `AccountManagerServices` instead

### setPhoneNumber

@Deprecated int setPhoneNumber(@Nullable String phoneNumber, @Nullable String countryCode)
Deprecated.
Set the phone number normalized.

Parameters:
  `phoneNumber` - The phone number to set
  `countryCode` - Country code to associate phone number with
Returns:
  `AccountCreator.PhoneNumberStatus.Ok` if everything is OK, or specific(s)
  error(s) otherwise.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### updateAccount

@Deprecated AccountCreator.Status updateAccount()
Deprecated.
Send a request to update an account.

Returns:
  `AccountCreator.Status.RequestOk` if the request has been sent, `AccountCreator.Status.RequestFailed`
  otherwise
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### useTestAdminAccount

@Deprecated void useTestAdminAccount()
Deprecated.
Require the account creator to use special "test admin account".
warning: The "test admin account" is a special feature required for automated
test, and requires the APP_EVERYONE_IS_ADMIN property to be enabled on the
remote Flexisip Account Manager (FlexiAPI). This feature must never be turned
on for a production-stage app.
deprecated: 11/06/2024 use `AccountManagerServices` instead

### create

@Deprecated @NonNull AccountCreator create(@NonNull Core core)
Deprecated.
Create a `AccountCreator` and set Linphone Request callbacks.

Parameters:
  `core` - The `Core` used for the XML-RPC communication
Returns:
  The new `AccountCreator` object.
  deprecated: 11/06/2024 use `AccountManagerServices` instead

### addListener

void addListener(AccountCreatorListener listener)

### removeListener

void removeListener(AccountCreatorListener listener)

### setUserData

void setUserData(Object data)
Sets the object to store in this object user's data

Parameters:
  `data` - the object to store

### getUserData

Object getUserData()
Gets the object stored in this object user's data

Returns:
  the object store if any, null otherwise

### getNativePointer

long getNativePointer()
Gets the native pointer used by this class to make native method calls.

Returns:
  the nativer pointer, as long

### toString

String toString()

Overrides:
  `toString` in class `Object`