> ## Documentation Index
> Fetch the complete documentation index at: https://docs.argyle.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Account Connections

How users connect payroll accounts through Link.

## Search

Search is the **default** user experience in Link.

<Tabs>
  <Tab title="Step 1">
    The user searches from a general list of potential incomes sources. This includes employers, government entities, and payroll services.

    <div className="mt-4">
      <Frame>
        <img src="https://mintcdn.com/argyle/zs6lb-w1jQV9DVbr/images/workflows/account-connections/1-account-connections.png?fit=max&auto=format&n=zs6lb-w1jQV9DVbr&q=85&s=be0c4e8f64af01df757a4389aa4cc236" alt="Search screen in Link." width="2100" height="1350" data-path="images/workflows/account-connections/1-account-connections.png" />
      </Frame>
    </div>
  </Tab>

  <Tab title="Step 2">
    If the user cannot find their source of income from this general list, they will be prompted to search from a list of only payroll providers that service multiple employers.

    <div className="mt-4">
      <Frame>
        <img src="https://mintcdn.com/argyle/lpddaw6ggr_B1oHD/images/argyle-guides/workflows/account-connections/2-account-connections.png?fit=max&auto=format&n=lpddaw6ggr_B1oHD&q=85&s=62cb71373764ff4af23f940c714740b1" alt="Can't find income source screen in Link." width="2100" height="1350" data-path="images/argyle-guides/workflows/account-connections/2-account-connections.png" />
      </Frame>
    </div>

    <Note>
      These payroll providers are searchable in step 1, but we have found narrowing the search focus to payroll providers improves the connection success rate for users.
    </Note>
  </Tab>

  <Tab title="Step 3">
    If the user successfully finds their source of income, they are taken to its respective login screen. From the login screen, the user can enter their login credentials to connect their account.

    <div className="mt-4">
      <Frame>
        <img src="https://mintcdn.com/argyle/0Z2zBY-iD5Q5BvPN/images/argyle-guides/link/analytics/3-login-screen.png?fit=max&auto=format&n=0Z2zBY-iD5Q5BvPN&q=85&s=22a866e61fab748d61da3553ab4a8dea" alt="Login screen in Link." width="2116" height="1366" data-path="images/argyle-guides/link/analytics/3-login-screen.png" />
      </Frame>
    </div>

    * If the user cannot remember their login credentials, the login screen provides a link to the platform's username/password reset process.
    * Each login screen is tailored to match the input fields used by the underlying payroll system. For example, some systems require a username and password, others an email and password, while others may use SSO methods to login. You can preview the login screen for any employer or payroll system in Console using <a href="https://console.argyle.com/flows" target="_blank">Flows</a>.
  </Tab>

  <Tab title="Step 4">
    If the user cannot ultimately find their source of income, they are asked to submit a response form and list their employers or payroll providers.

    <div className="mt-4">
      <Frame>
        <img src="https://mintcdn.com/argyle/lpddaw6ggr_B1oHD/images/argyle-guides/workflows/account-connections/4-account-connections.png?fit=max&auto=format&n=lpddaw6ggr_B1oHD&q=85&s=3f9271523e114f21e6af3f1f65bb67bd" alt="Response form screen in Link." width="2100" height="1350" data-path="images/argyle-guides/workflows/account-connections/4-account-connections.png" />
      </Frame>
    </div>
  </Tab>
</Tabs>

### Common customizations

* Excluding specific Items or Item categories (employers, gig platforms, payroll providers, or government benefits).
* Adjusting the fallback experience when users cannot find their source of income.

<Accordion title="Note on groupings:">
  Certain Items are used to "group" other individual Items, and may or may not support payroll connections themselves. These Items will have a **Grouping** tag in Console's <a href="https://console.argyle.com/coverage" target="_blank">Coverage</a> page.

  Groupings can be:

  * Payroll providers that support login credentials for multiple employers.
  * Employers that utilize multiple payroll providers.
  * Common employers such as franchises that allow individual locations or regions to independently choose third-party payroll systems for their employees.

  When a user selects a grouping that *does not* directly support payroll connections, a dropdown menu of individual Items that *do* support payroll connections and are related to the particular grouping are shown.

  <div className="mt-4">
    <Frame>
      <img src="https://mintcdn.com/argyle/lpddaw6ggr_B1oHD/images/argyle-guides/workflows/account-connections/5-account-connections.png?fit=max&auto=format&n=lpddaw6ggr_B1oHD&q=85&s=1a07626d5ef773544a33817c0623ec9a" alt="Groupings in Link." width="2100" height="1350" data-path="images/argyle-guides/workflows/account-connections/5-account-connections.png" />
    </Frame>
  </div>
</Accordion>

## List

As an alternative to search, Link also supports custom lists:

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/zs6lb-w1jQV9DVbr/images/workflows/account-connections/6-account-connections.png?fit=max&auto=format&n=zs6lb-w1jQV9DVbr&q=85&s=e7273fed005f971c6d6f54fe16e34c8e" alt="List screen in Link." width="2100" height="1350" data-path="images/workflows/account-connections/6-account-connections.png" />
  </Frame>
</div>

1. Create a custom list using <a href="https://console.argyle.com/flows" target="_blank">Flows</a> in Console.
2. Apply saved email/SMS template Flows when [sending invites](/console/flows/email-sms-templates#sending-invites), or copy the ID of a saved [embedded experience](/console/flows/embedded-experiences) and add the following line to your embedded [Link initialization](/link/initialization):

   ```json theme={}
   flowId: "<ID of the embedded experience>"
   ```

Alternative:

1. Add an array of Item ID's directly within your Link initialization:

   ```json theme={}
   items: ["<ID of Item 1>", "<ID of Item 2>", "..."]
   ```

## Direct login

Directly connect users to a specific Item in Link, bypassing search entirely.

* The direct login method has the *highest percentage of users that successfully connect a payroll account*.
* Recommended whenever the user's employer or payroll provider is already known.

### New connections

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/0Z2zBY-iD5Q5BvPN/images/argyle-guides/link/analytics/3-login-screen.png?fit=max&auto=format&n=0Z2zBY-iD5Q5BvPN&q=85&s=22a866e61fab748d61da3553ab4a8dea" alt="Login screen in Link." width="2116" height="1366" data-path="images/argyle-guides/link/analytics/3-login-screen.png" />
  </Frame>
</div>

1. [Create a customized Flow](/console/flows/embedded-experiences) in Console with "Direct login" selected in the **Search and connect** section.
2. You customizations will:

* Automatically be applied to the [Shareable URL](/console/flows/shareable-urls) after saving the Shareable URL Flow.
* Be applied when [sending invites](/console/flows/email-sms-templates#sending-invites) if the saved Email/SMS Template Flow is selected from the dropdown.
* Be applied when [embedding Link](/console/flows/embedded-experiences) by copying the `ID` of a saved Embedded Experience Flow and including it within the optional `flowId` [initialization parameter](/link/initialization/overview#optional-initialization-parameters) in your Link initialization:
  ```json theme={}
  flowId: "<ID of the Flow>"
  ```

Alternative:

1. Add an `items` array to your embedded Link initialization with only one Item.
   ```json theme={}
   items: ["<ID of Item 1>"]
   ```
2. (Optional) If you are embedding Link and want to allow users to return to Link's full search experience from the login screen:

* Create a "New Flow" in the <a href="https://console.argyle.com/flows" target="_blank">Flows</a> area of Console and select "Embedded Experience"
* In the **Search and connect** section, select "Search" and adjust the search experience for your users
* Next, in the same **Search and connect** section, select "Direct Login"
* Enable the "Allow users to access full Search experience" toggle
* Select one employer in the "Search to select income sources" selection box

<Note>
  The Item you input in the `items` array (see below) will override this employer when Link is initialized.
</Note>

* Save the Flow and copy the Flow `ID` from the main Flows page
* Add both an `items` array with only one Item, and the copied `flowId` string to your embedded Link initialization:
  ```json theme={}
  items: ["<ID of Item 1>"]
  flowId: "<ID of the Flow>"
  ```

### Existing connections

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/zs6lb-w1jQV9DVbr/images/workflows/account-connections/11-account-connections.png?fit=max&auto=format&n=zs6lb-w1jQV9DVbr&q=85&s=2fb5c9656677896054bfbf49b7d49827" alt="Directly connect a user to an already-connected payroll account." width="2100" height="1350" data-path="images/workflows/account-connections/11-account-connections.png" />
  </Frame>
</div>

* If you originally invited the user through Console's [send invites](/console/flows/email-sms-templates#sending-invites) feature, follow the steps in our Email/SMS Flows Guide for [reconnecting existing users](/console/flows/email-sms-templates#reconnecting-existing-users).
* If you are embedding Link, use the optional `accountId` [initialization parameter](/link/initialization/overview#optional-initialization-parameters) and pass in the [ID of the account](/api-reference/accounts#object).

  ```json theme={}
  accountId: "<ID of the account>"
  ```

### Sample app

If you are [embedding Link](/link/initialization), check out our Employer Search sample app (<a href="https://sampleapps.argyle.com/employer-search" target="_blank">Demo</a>) (<a href="https://github.com/argyle-sample-apps/employer-search" target="_blank">Github</a>) ([Documentation](/overview/employer-search)) to see an example project that showcases the direct login method.

In the sample app, a simple employer search bar powered by Argyle's [employer-search endpoint](/api-reference/employer-search) lets users search for their employer. After making a selection, the user is sent directly to that Item's login screen in Link.

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/lpddaw6ggr_B1oHD/images/argyle-guides/sample-apps/employer-search/1-employer-search-app.png?fit=max&auto=format&n=lpddaw6ggr_B1oHD&q=85&s=53341dc0ebc74f3d93d7ddd7380f991b" alt="A search bar lets users search for their employer and directly connect to the respective login screen." width="1697" height="946" data-path="images/argyle-guides/sample-apps/employer-search/1-employer-search-app.png" />
  </Frame>
</div>

## Doc upload

Directly connect users to the document upload screen in Link, bypassing the payroll account connection process. Visit our [Document Processing Guide](/workflows/document-processing) for more information.

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/zs6lb-w1jQV9DVbr/images/overview/how-argyle-works/5-how-argyle-works.png?fit=max&auto=format&n=zs6lb-w1jQV9DVbr&q=85&s=0adeffff94b9f94a99c58aa50540413b" alt="Link supports directly uploading documents such as paystubs, W-2s, and 1099s." width="2100" height="1350" data-path="images/overview/how-argyle-works/5-how-argyle-works.png" />
  </Frame>
</div>

## Completing MFA

Most payroll systems require multi-factor authentication (MFA) when a user logs in or takes action such as updating their direct deposit settings.

* The MFA process can be completed directly within Link.
* Link is designed to be persistent, meaning users can exit Link to retrieve their authentication information, and return to Link seamlessly without their session or the MFA process being interrupted.

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/0Z2zBY-iD5Q5BvPN/images/argyle-guides/link/analytics/4-MFA-screen.png?fit=max&auto=format&n=0Z2zBY-iD5Q5BvPN&q=85&s=34f6d7702abfa4171f5112bbf8415ee3" alt="MFA screen in Link." width="2100" height="1350" data-path="images/argyle-guides/link/analytics/4-MFA-screen.png" />
  </Frame>
</div>

## Troubleshooting

<div className="argyle-divider" />

### Connection pending

Link will display "Connection pending" if an account connection is experiencing significant delays.

* Users will be able to exit Link or return to the search screen to connect additional accounts.
* You can monitor the account's connection status [via the API](/api-reference/accounts#object-connection-status), through the <a href="https://console.argyle.com/connections" target="_blank">Connections</a> section of Console, or by subscribing to the [`accounts.updated`](/api-reference/accounts-webhooks/updated) webhook. The account will have an initial status of `connecting` (**API**) or "Attempted" (**Console**) until the connection successfully completes or an [account connection error](/api-reference/account-connection-errors) occurs.

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/zs6lb-w1jQV9DVbr/images/workflows/account-connections/12-account-connections.png?fit=max&auto=format&n=zs6lb-w1jQV9DVbr&q=85&s=fd23280167b8938eeb31a4999af8afe3" alt="Link will show connection pending if the connection process does not complete after a certain amount of time." width="2100" height="1350" data-path="images/workflows/account-connections/12-account-connections.png" />
  </Frame>
</div>

### Expired user token

If a user delays completing the MFA process for too long, they may encounter the `expired_user_token` Link error. [Users tokens](/link/user-tokens) allow users to exit and return to Link without interruption, but to ensure security, user tokens expire after one hour.

To re-activate Link for the user, [create a new user token](/api-reference/user-tokens#create) and either:

* Re-initialize Link with the new user token.
* Pass the user token to the [`onTokenExpired`](/link/reference/callbacks#ontokenexpired) callback.

<div className="mt-4">
  <Frame>
    <img src="https://mintcdn.com/argyle/0Z2zBY-iD5Q5BvPN/images/argyle-guides/link/error-codes/4-expired-user-token.png?fit=max&auto=format&n=0Z2zBY-iD5Q5BvPN&q=85&s=063a02ef72fe1816e66c966de4bd1c20" alt="expired_user_token Link error" width="2100" height="1724" data-path="images/argyle-guides/link/error-codes/4-expired-user-token.png" />
  </Frame>
</div>

## Customizations

For more information on customizing the connection process in Link, visit our [Flows Guides](/console/flows/embedded-experiences).
