---
title: "prepareInterfaceToConvertAccountToSignInWithApple(for:existingCredential:userInfo:)"
framework: authenticationservices
role: symbol
role_heading: Instance Method
path: "authenticationservices/asaccountauthenticationmodificationviewcontroller/prepareinterfacetoconvertaccounttosigninwithapple(for:existingcredential:userinfo:)"
---

# prepareInterfaceToConvertAccountToSignInWithApple(for:existingCredential:userInfo:)

Prepares the view controller’s interface that displays when converting an account that uses password authentication to use Sign in with Apple.

## Declaration

```swift
func prepareInterfaceToConvertAccountToSignInWithApple(for serviceIdentifier: ASCredentialServiceIdentifier, existingCredential: ASPasswordCredential, userInfo: [AnyHashable : Any]? = nil)
```

## Parameters

- `serviceIdentifier`: An identifier that represents a particular service that the user needs a credential for, like a web site.
- `existingCredential`: The current password credential for the service.
- `userInfo`: A dictionary that contains app-specific values when the request to upgrade to Sign in with Apple initiates from by the parent app. If the request to upgrade to Sign in with Apple doesn’t initiate from the app, this parameter is nil.

## Mentioned in

Upgrading Account Security With an Account Authentication Modification Extension

## See Also

### Upgrading to Sign in with Apple

- [convertAccountToSignInWithAppleWithoutUserInteraction(for:existingCredential:userInfo:)](authenticationservices/asaccountauthenticationmodificationviewcontroller/convertaccounttosigninwithapplewithoutuserinteraction(for:existingcredential:userinfo:).md)
- [ASAccountAuthenticationModificationSupportsUpgradeToSignInWithApple](bundleresources/information-property-list/nsextension/asaccountauthenticationmodificationsupportsupgradetosigninwithapple.md)
