Repository: Expensify/App
Pull request #61850: [Internal QA]: Company Cards -> Plaid -> Country Selector + Feed Selector
Author: login: narefyev91
Labels: name: InternalQA
description: This pull request required internal QA
Created: 2025-05-12T13:59:13Z | Merged: 2025-05-14T11:40:02Z

### Explanation of Change

Part of Plaid import card feeds: https://github.com/Expensify/Expensify/issues/474149

Design doc section for Country Selector: https://docs.google.com/document/d/1v_iaIiLwNqSvtSeJFejKjL9mYz7UH_6Ik5VmySY8XZs/edit?tab=t.0#bookmark=kix.suqjbyjpm5y

Design doc section for Feed Selector: https://docs.google.com/document/d/1v_iaIiLwNqSvtSeJFejKjL9mYz7UH_6Ik5VmySY8XZs/edit?tab=t.0#bookmark=kix.lzcl3orz8y7a

### Fixed Issues

$ https://github.com/Expensify/App/issues/61713, https://github.com/Expensify/App/issues/61714
PROPOSAL:

### Tests

1. Be sure that company cards is available on WS and plaidCompanyCards is on.
2. Set In WS any non EUR currency 
3. Click on Company Cards -> Add Cards
4. Verify that country will be pre-selected (PR on BE still in progress)
5. Click next - verify that Feed selector page is shown.
6. Click back - verify that Select Country screen is shown
7. Choose any other country/search for any other country -> click next
8. Go back
9. Verify that selected country is shown

Test for EU countries - you should be in EU zone or change Onyxkeys.Country to any country in Europe with EUR currency
1. Set In WS EUR currency 
2. Click on Company Cards -> Add Cards
3. Verify that Your european country will be pre-selected
4. Do the same points from 5-9 from tests above.

Test for feed selector:
1. Do 1-5
2. If US or any of  PLAID_INCLUDED_COUNTRIES is selected - Direct Feed menu item should be pre-selected and should be on the 1th position
3. Go back -> Select any other country -> Next
4. Verify that only option Commercial feed is shown

- [x] Verify that no errors appear in the JS console

### Offline tests
No changes

### QA Steps

1. Be sure that company cards is available on WS and plaidCompanyCards is on.
5. Set In WS any non EUR currency 
6. Click on Company Cards -> Add Cards
7. Verify that country will be pre-selected (PR on BE still in progress) (for test purpose change line like this:
`const country = selectedCurrency?.countries?.[0] ?? 'US';`
8. Click next - verify that Feed selector account page is shown.
9. Click back - verify that Select Country screen is shown
10. Choose any other country/search for any other country -> click next
11. Go back
12. Verify that selected country is shown

Test for EU countries - you should be in EU zone or change Onyxkeys.Country to any country in Europe with EUR currency
1. Set In WS EUR currency 
2. Click on Company Cards -> Add Cards
3. Verify that Your european country will be pre-selected
4. Do the same points from 5-9 from tests above.

Test for feed selector:
1. Do 1-5
2. If US or any of  PLAID_INCLUDED_COUNTRIES is selected - Direct Feed menu item should be pre-selected and should be on the 1th position
3. Go back -> Select any other country -> Next
4. Verify that only option Commercial feed is shown

- [x] Verify that no errors appear in the JS console

### PR Author Checklist

- [x] I linked the correct issue in the `### Fixed Issues` section above
- [x] I wrote clear testing steps that cover the changes made in this PR
    - [x] I added steps for local testing in the `Tests` section
    - [x] I added steps for the expected offline behavior in the `Offline steps` section
    - [x] I added steps for Staging and/or Production testing in the `QA steps` section
    - [x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    - [x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
    - [x] I tested this PR with a [High Traffic account](https://github.com/Expensify/App/blob/main/contributingGuides/CONTRIBUTING.md#high-traffic-accounts) against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).
- [x] I included screenshots or videos for tests on [all platforms](https://github.com/Expensify/App/blob/main/contributingGuides/CONTRIBUTING.md#make-sure-you-can-test-on-all-platforms)
- [x] I ran the tests on **all platforms** & verified they passed on:
    - [x] Android: Native
    - [x] Android: mWeb Chrome
    - [x] iOS: Native
    - [x] iOS: mWeb Safari
    - [x] MacOS: Chrome / Safari
    - [x] MacOS: Desktop
- [x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
- [x] I verified there are no new alerts related to the `canBeMissing` param for `useOnyx`
- [x] I followed proper code patterns (see [Reviewing the code](https://github.com/Expensify/App/blob/main/contributingGuides/PR_REVIEW_GUIDELINES.md#reviewing-the-code))
    - [x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. `toggleReport` and not `onIconClick`)
    - [x] I verified that comments were added to code that is not self explanatory
    - [x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    - [x] I verified any copy / text shown in the product is localized by adding it to `src/languages/*` files and using the [translation method](https://github.com/Expensify/App/blob/4bd99402cebdf4d7394e0d1f260879ea238197eb/src/components/withLocalize.js#L60)
      - [x] If any non-english text was added/modified, I used [JaimeGPT](https://chatgpt.com/g/g-2dgOQl5VM-english-to-spanish-translator-aka-jaimegpt) to get English > Spanish translation. I then posted it in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:
    - [x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the [localization methods](https://github.com/Expensify/App/blob/4bd99402cebdf4d7394e0d1f260879ea238197eb/src/components/withLocalize.js#L60-L68)
    - [x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    - [x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    - [x] I verified the JSDocs style guidelines (in [`STYLE.md`](https://github.com/Expensify/App/blob/main/contributingGuides/STYLE.md#jsdocs)) were followed
- [x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
- [x] I followed the guidelines as stated in the [Review Guidelines](https://github.com/Expensify/App/blob/main/contributingGuides/PR_REVIEW_GUIDELINES.md)
- [x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like `Avatar`, I verified the components using `Avatar` are working as expected)
- [x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
- [x] I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
- [x] I verified that if a function's arguments changed that all usages have also been updated correctly
- [x] If any new file was added I verified that:
    - [x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
- [x] If a new CSS style is added I verified that:
    - [x] A similar style doesn't already exist
    - [x] The style can't be created with an existing [StyleUtils](https://github.com/Expensify/App/blob/main/src/styles/utils/index.ts) function (i.e. `StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)`)
- [x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
- [x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like `Avatar` is modified, I verified that `Avatar` is working as expected in all cases)
- [x]  If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
- [x] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
- [x] If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    - [x] I verified that all the inputs inside a form are aligned with each other.
    - [x] I added `Design` label and/or tagged `@Expensify/design` so the design team can review the changes.
- [x] If a new page is added, I verified it's using the `ScrollView` component to make it scrollable when more elements are added to the page.
- [x] I added [unit tests](https://github.com/Expensify/App/blob/main/tests/README.md) for any new feature or bug fix in this PR to help automatically prevent regressions in this user flow.
- [x] If the `main` branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the `Test` steps.

### Screenshots/Videos
<details>
<summary>Android: Native</summary>


https://github.com/user-attachments/assets/ebb85bc4-6206-4d18-be82-b4025469ce1d

Feed type selector:


https://github.com/user-attachments/assets/6a7074d5-30f9-4acd-80b9-bc2011ac8b7c




</details>

<details>
<summary>Android: mWeb Chrome</summary>


https://github.com/user-attachments/assets/8824cdbe-c7da-4f08-92d8-58a4d0273950

Feed type selector:


https://github.com/user-attachments/assets/c750c88c-5657-4839-a21f-a14b8195b1aa




</details>

<details>
<summary>iOS: Native</summary>


https://github.com/user-attachments/assets/d99261a0-5c52-40f1-a00f-8aaaf5084f2a

Feed type selector:


https://github.com/user-attachments/assets/73e06baf-3b6f-4783-aa0d-578e63d7c32e




</details>

<details>
<summary>iOS: mWeb Safari</summary>


https://github.com/user-attachments/assets/1b337dae-1dc3-44cc-92a2-185d3145e236

Feed type selector:


https://github.com/user-attachments/assets/76a89b66-4201-4420-9371-dfd2497037de




</details>

<details>
<summary>MacOS: Chrome / Safari</summary>


https://github.com/user-attachments/assets/77e6a3d3-d52d-43f3-9c06-bb9ab0719715


https://github.com/user-attachments/assets/da4ec122-7da4-48c7-bea3-12c94764f938

Feed type selector:


https://github.com/user-attachments/assets/dbdef555-6db0-439e-8849-284813170129




</details>

<details>
<summary>MacOS: Desktop</summary>


https://github.com/user-attachments/assets/a5ee4b6a-dc81-4c1e-8c4f-8d2a8ae1bfa2

Feed type selector:


https://github.com/user-attachments/assets/8652dc74-0930-4f98-a2d1-e3af3b05cd46




</details>



Diff:
diff --git a/src/CONST.ts b/src/CONST.ts
index 798e963df78d..16c385bfcbcd 100755
--- a/src/CONST.ts
+++ b/src/CONST.ts
@@ -821,6 +821,7 @@ const CONST = {
         PRIVATE_DOMAIN_ONBOARDING: 'privateDomainOnboarding',
         IS_TRAVEL_VERIFIED: 'isTravelVerified',
         NEWDOT_MULTI_FILES_DRAG_AND_DROP: 'newDotMultiFilesDragAndDrop',
+        PLAID_COMPANY_CARDS: 'plaidCompanyCards',
     },
     BUTTON_STATES: {
         DEFAULT: 'default',
@@ -3270,6 +3271,7 @@ const CONST = {
             CARD_DETAILS: 'CardDetails',
             BANK_CONNECTION: 'BankConnection',
             AMEX_CUSTOM_FEED: 'AmexCustomFeed',
+            SELECT_COUNTRY: 'SelectCountry',
         },
         CARD_TYPE: {
             AMEX: 'amex',
@@ -4087,6 +4089,9 @@ const CONST = {
         SE: 'Sweden',
     },
 
+    PLAID_EXCLUDED_COUNTRIES: ['IR', 'CU', 'SY', 'UA', 'KP'] as string[],
+    PLAID_SUPPORT_COUNTRIES: ['US', 'CA', 'GB', 'AT', 'BE', 'DK', 'EE', 'FI', 'FR', 'DE', 'IE', 'IT', 'LV', 'LT', 'NL', 'NO', 'PL', 'PT', 'ES', 'SE'] as string[],
+
     // Sources: https://github.com/Expensify/App/issues/14958#issuecomment-1442138427
     // https://github.com/Expensify/App/issues/14958#issuecomment-1456026810
     COUNTRY_ZIP_REGEX_DATA: {
diff --git a/src/languages/en.ts b/src/languages/en.ts
index f7d16b0a552c..c299a18729b0 100755
--- a/src/languages/en.ts
+++ b/src/languages/en.ts
@@ -3781,12 +3781,14 @@ const translations = {
                 },
                 yourCardProvider: `Who's your card provider?`,
                 whoIsYourBankAccount: 'Who’s your bank?',
+                whereIsYourBankLocated: 'Where’s your bank located?',
                 howDoYouWantToConnect: 'How do you want to connect to your bank?',
                 learnMoreAboutOptions: {
                     text: 'Learn more about these ',
                     linkText: 'options.',
                 },
                 commercialFeedDetails: 'Requires setup with your bank. This is typically used by larger companies and is often the best option if you qualify.',
+                commercialFeedPlaidDetails: `Requires setup with your bank, but we'll guide you. This is typically limited to larger companies.`,
                 directFeedDetails: 'The simplest approach. Connect right away using your master credentials. This method is most common.',
                 enableFeed: {
                     title: ({provider}: GoBackMessageParams) => `Enable your ${provider} feed`,
@@ -3826,6 +3828,7 @@ const translations = {
                     pleaseSelectProvider: 'Please select a card provider before continuing',
                     pleaseSelectBankAccount: 'Please select a bank account before continuing',
                     pleaseSelectBank: 'Please select a bank before continuing',
+                    pleaseSelectCountry: 'Please select a country before continuing',
                     pleaseSelectFeedType: 'Please select a feed type before continuing',
                 },
             },
diff --git a/src/languages/es.ts b/src/languages/es.ts
index 95ad439d4a16..af5a1d3afacf 100644
--- a/src/languages/es.ts
+++ b/src/languages/es.ts
@@ -3819,12 +3819,14 @@ const translations = {
                 },
                 yourCardProvider: `¿Quién es su proveedor de tarjetas?`,
                 whoIsYourBankAccount: '¿Cuál es tu banco?',
+                whereIsYourBankLocated: '¿Dónde está ubicado tu banco?',
                 howDoYouWantToConnect: '¿Cómo deseas conectarte a tu banco?',
                 learnMoreAboutOptions: {
                     text: 'Obtén más información sobre estas ',
                     linkText: 'opciones.',
                 },
                 commercialFeedDetails: 'Requiere configuración con tu banco. Esto suele ser utilizado por empresas más grandes y a menudo es la mejor opción si calificas.',
+                commercialFeedPlaidDetails: 'Requiere configurarlo con tu banco, pero te guiaremos. Esto suele estar limitado a empresas más grandes.',
                 directFeedDetails: 'El enfoque más simple. Conéctate de inmediato usando tus credenciales maestras. Este método es el más común.',
                 enableFeed: {
                     title: ({provider}: GoBackMessageParams) => `Habilita tu feed ${provider}`,
@@ -3865,6 +3867,7 @@ const translations = {
                     pleaseSelectProvider: 'Seleccione un proveedor de tarjetas antes de continuar',
                     pleaseSelectBankAccount: 'Seleccione una cuenta bancaria antes de continuar',
                     pleaseSelectBank: 'Seleccione una bancaria antes de continuar',
+                    pleaseSelectCountry: 'Seleccione un país antes de continuar',
                     pleaseSelectFeedType: 'Seleccione un tipo de pienso antes de continuar',
                 },
             },
diff --git a/src/libs/Permissions.ts b/src/libs/Permissions.ts
index 4383bfeb9771..40051c7b3013 100644
--- a/src/libs/Permissions.ts
+++ b/src/libs/Permissions.ts
@@ -70,6 +70,10 @@ function canUsePrivateDomainOnboarding(betas: OnyxEntry<Beta[]>): boolean {
     return !!betas?.includes(CONST.BETAS.PRIVATE_DOMAIN_ONBOARDING) || canUseAllBetas(betas);
 }
 
+function canUsePlaidCompanyCards(betas: OnyxEntry<Beta[]>): boolean {
+    return !!betas?.includes(CONST.BETAS.PLAID_COMPANY_CARDS) || canUseAllBetas(betas);
+}
+
 function canUseRetractNewDot(betas: OnyxEntry<Beta[]>): boolean {
     return !!betas?.includes(CONST.BETAS.RETRACT_NEWDOT) || canUseAllBetas(betas);
 }
@@ -101,4 +105,5 @@ export default {
     canUseRetractNewDot,
     canUseCallScheduling,
     canUseMultiFilesDragAndDrop,
+    canUsePlaidCompanyCards,
 };
diff --git a/src/pages/workspace/companyCards/addNew/AddNewCardPage.tsx b/src/pages/workspace/companyCards/addNew/AddNewCardPage.tsx
index faf41ec077bb..772a734a1157 100644
--- a/src/pages/workspace/companyCards/addNew/AddNewCardPage.tsx
+++ b/src/pages/workspace/companyCards/addNew/AddNewCardPage.tsx
@@ -3,6 +3,7 @@ import {useOnyx} from 'react-native-onyx';
 import DelegateNoAccessWrapper from '@components/DelegateNoAccessWrapper';
 import FullScreenLoadingIndicator from '@components/FullscreenLoadingIndicator';
 import ScreenWrapper from '@components/ScreenWrapper';
+import usePermissions from '@hooks/usePermissions';
 import useWorkspaceAccountID from '@hooks/useWorkspaceAccountID';
 import BankConnection from '@pages/workspace/companyCards/BankConnection';
 import withPolicyAndFullscreenLoading from '@pages/workspace/withPolicyAndFullscreenLoading';
@@ -17,6 +18,7 @@ import CardNameStep from './CardNameStep';
 import CardTypeStep from './CardTypeStep';
 import DetailsStep from './DetailsStep';
 import SelectBankStep from './SelectBankStep';
+import SelectCountryStep from './SelectCountryStep';
 import SelectFeedType from './SelectFeedType';
 
 function AddNewCardPage({policy}: WithPolicyAndFullscreenLoadingProps) {
@@ -24,6 +26,7 @@ function AddNewCardPage({policy}: WithPolicyAndFullscreenLoadingProps) {
     const workspaceAccountID = useWorkspaceAccountID(policyID);
     const [addNewCardFeed, addNewCardFeedMetadata] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: false});
     const {currentStep} = addNewCardFeed ?? {};
+    const {canUsePlaidCompanyCards} = usePermissions();
 
     const [isActingAsDelegate] = useOnyx(ONYXKEYS.ACCOUNT, {selector: (account) => !!account?.delegatedAccess?.delegate, canBeMissing: false});
 
@@ -72,7 +75,7 @@ function AddNewCardPage({policy}: WithPolicyAndFullscreenLoadingProps) {
         case CONST.COMPANY_CARDS.STEP.AMEX_CUSTOM_FEED:
             return <AmexCustomFeed />;
         default:
-            return <SelectBankStep />;
+            return canUsePlaidCompanyCards ? <SelectCountryStep policyID={policyID} /> : <SelectBankStep />;
     }
 }
 
diff --git a/src/pages/workspace/companyCards/addNew/SelectBankStep.tsx b/src/pages/workspace/companyCards/addNew/SelectBankStep.tsx
index 4c845ebd39fc..ad04cd1925c0 100644
--- a/src/pages/workspace/companyCards/addNew/SelectBankStep.tsx
+++ b/src/pages/workspace/companyCards/addNew/SelectBankStep.tsx
@@ -11,6 +11,7 @@ import SelectionList from '@components/SelectionList';
 import RadioListItem from '@components/SelectionList/RadioListItem';
 import Text from '@components/Text';
 import useLocalize from '@hooks/useLocalize';
+import usePermissions from '@hooks/usePermissions';
 import useThemeIllustrations from '@hooks/useThemeIllustrations';
 import useThemeStyles from '@hooks/useThemeStyles';
 import {getBankCardDetailsImage, getCorrectStepForSelectedBank} from '@libs/CardUtils';
@@ -28,8 +29,9 @@ function SelectBankStep() {
     const route = useRoute<PlatformStackRouteProp<WorkspaceSplitNavigatorParamList, typeof SCREENS.WORKSPACE.COMPANY_CARDS_ADD_NEW>>();
     const styles = useThemeStyles();
     const illustrations = useThemeIllustrations();
+    const {canUsePlaidCompanyCards} = usePermissions();
 
-    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD);
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
     const [bankSelected, setBankSelected] = useState<ValueOf<typeof CONST.COMPANY_CARDS.BANKS>>();
     const [hasError, setHasError] = useState(false);
     const isOtherBankSelected = bankSelected === CONST.COMPANY_CARDS.BANKS.OTHER;
@@ -62,7 +64,11 @@ function SelectBankStep() {
             Navigation.navigate(route.params.backTo);
             return;
         }
-        Navigation.goBack();
+        if (canUsePlaidCompanyCards) {
+            setAddNewCompanyCardStepAndData({step: CONST.COMPANY_CARDS.STEP.SELECT_FEED_TYPE});
+        } else {
+            Navigation.goBack();
+        }
     };
 
     const data = Object.values(CONST.COMPANY_CARDS.BANKS).map((bank) => ({
diff --git a/src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx b/src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx
new file mode 100644
index 000000000000..6045ac979ab2
--- /dev/null
+++ b/src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx
@@ -0,0 +1,158 @@
+import {useRoute} from '@react-navigation/native';
+import React, {useCallback, useEffect, useMemo, useState} from 'react';
+import {View} from 'react-native';
+import {useOnyx} from 'react-native-onyx';
+import FormHelpMessage from '@components/FormHelpMessage';
+import HeaderWithBackButton from '@components/HeaderWithBackButton';
+import ScreenWrapper from '@components/ScreenWrapper';
+import SelectionList from '@components/SelectionList';
+import RadioListItem from '@components/SelectionList/RadioListItem';
+import Text from '@components/Text';
+import useDebouncedState from '@hooks/useDebouncedState';
+import useLocalize from '@hooks/useLocalize';
+import usePolicy from '@hooks/usePolicy';
+import useThemeStyles from '@hooks/useThemeStyles';
+import searchOptions from '@libs/searchOptions';
+import type {Option} from '@libs/searchOptions';
+import StringUtils from '@libs/StringUtils';
+import Navigation from '@navigation/Navigation';
+import type {PlatformStackRouteProp} from '@navigation/PlatformStackNavigation/types';
+import type {WorkspaceSplitNavigatorParamList} from '@navigation/types';
+import {clearAddNewCardFlow, setAddNewCompanyCardStepAndData} from '@userActions/CompanyCards';
+import CONST from '@src/CONST';
+import type {TranslationPaths} from '@src/languages/types';
+import ONYXKEYS from '@src/ONYXKEYS';
+import type SCREENS from '@src/SCREENS';
+
+type CountryStepProps = {
+    policyID?: string;
+};
+
+function SelectCountryStep({policyID}: CountryStepProps) {
+    const {translate} = useLocalize();
+    const route = useRoute<PlatformStackRouteProp<WorkspaceSplitNavigatorParamList, typeof SCREENS.WORKSPACE.COMPANY_CARDS_ADD_NEW>>();
+    const styles = useThemeStyles();
+    const policy = usePolicy(policyID);
+    const [currencyList = {}] = useOnyx(ONYXKEYS.CURRENCY_LIST, {canBeMissing: true});
+    const [countryByIp] = useOnyx(ONYXKEYS.COUNTRY, {canBeMissing: false});
+
+    const [searchValue, debouncedSearchValue, setSearchValue] = useDebouncedState('');
+    const [currentCountry, setCurrentCountry] = useState<string | undefined>('');
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
+    const [hasError, setHasError] = useState(false);
+
+    const submit = () => {
+        if (!currentCountry) {
+            setHasError(true);
+        } else {
+            if (addNewCard?.data.selectedCountry !== currentCountry) {
+                clearAddNewCardFlow();
+            }
+            setAddNewCompanyCardStepAndData({
+                step: CONST.COMPANY_CARDS.STEP.SELECT_FEED_TYPE,
+                data: {
+                    selectedCountry: currentCountry,
+                },
+                isEditing: false,
+            });
+        }
+    };
+
+    useEffect(() => {
+        if (addNewCard?.data?.selectedCountry) {
+            setCurrentCountry(addNewCard.data.selectedCountry);
+            return;
+        }
+        const selectedCurrency = policy?.outputCurrency ? currencyList?.[policy.outputCurrency] : null;
+        const countries = selectedCurrency?.countries;
+
+        if (policy?.outputCurrency === CONST.CURRENCY.EUR && countryByIp && countries?.includes(countryByIp)) {
+            setCurrentCountry(countryByIp);
+            return;
+        }
+        const country = countries?.[0];
+
+        if (country) {
+            setCurrentCountry(country);
+        }
+    }, [addNewCard?.data.selectedCountry, countryByIp, currencyList, policy?.outputCurrency]);
+
+    const handleBackButtonPress = () => {
+        if (route?.params?.backTo) {
+            Navigation.navigate(route.params.backTo);
+            return;
+        }
+        Navigation.goBack();
+    };
+
+    const onSelectionChange = useCallback((country: Option) => {
+        setCurrentCountry(country.value);
+    }, []);
+
+    const countries = useMemo(
+        () =>
+            Object.keys(CONST.ALL_COUNTRIES)
+                .filter((countryISO) => !CONST.PLAID_EXCLUDED_COUNTRIES.includes(countryISO))
+                .map((countryISO) => {
+                    const countryName = translate(`allCountries.${countryISO}` as TranslationPaths);
+                    return {
+                        value: countryISO,
+                        keyForList: countryISO,
+                        text: countryName,
+                        isSelected: currentCountry === countryISO,
+                        searchValue: StringUtils.sanitizeString(`${countryISO}${countryName}`),
+                    };
+                }),
+        [translate, currentCountry],
+    );
+
+    const searchResults = searchOptions(debouncedSearchValue, countries);
+    const headerMessage = debouncedSearchValue.trim() && !searchResults.length ? translate('common.noResultsFound') : '';
+
+    return (
+        <ScreenWrapper
+            testID={SelectCountryStep.displayName}
+            enableEdgeToEdgeBottomSafeAreaPadding
+            shouldEnablePickerAvoiding={false}
+            shouldEnableMaxHeight
+        >
+            <HeaderWithBackButton
+                title={translate('workspace.companyCards.addCards')}
+                onBackButtonPress={handleBackButtonPress}
+            />
+
+            <Text style={[styles.textHeadlineLineHeightXXL, styles.ph5, styles.mv3]}>{translate('workspace.companyCards.addNewCard.whereIsYourBankLocated')}</Text>
+            <SelectionList
+                headerMessage={headerMessage}
+                sections={[{data: searchResults}]}
+                textInputValue={searchValue}
+                textInputLabel={translate('common.search')}
+                onChangeText={setSearchValue}
+                onSelectRow={onSelectionChange}
+                onConfirm={submit}
+                ListItem={RadioListItem}
+                initiallyFocusedOptionKey={currentCountry}
+                shouldSingleExecuteRowSelect
+                shouldStopPropagation
+                shouldUseDynamicMaxToRenderPerBatch
+                showConfirmButton
+                addBottomSafeAreaPadding
+                confirmButtonText={translate('common.next')}
+                shouldUpdateFocusedIndex
+            >
+                {hasError && (
+                    <View style={[styles.ph3, styles.mb3]}>
+                        <FormHelpMessage
+                            isError={hasError}
+                            message={translate('workspace.companyCards.addNewCard.error.pleaseSelectCountry')}
+                        />
+                    </View>
+                )}
+            </SelectionList>
+        </ScreenWrapper>
+    );
+}
+
+SelectCountryStep.displayName = 'SelectCountryStep';
+
+export default SelectCountryStep;
diff --git a/src/pages/workspace/companyCards/addNew/SelectFeedType.tsx b/src/pages/workspace/companyCards/addNew/SelectFeedType.tsx
index 53bd6ce4ea78..ec523cec0dad 100644
--- a/src/pages/workspace/companyCards/addNew/SelectFeedType.tsx
+++ b/src/pages/workspace/companyCards/addNew/SelectFeedType.tsx
@@ -10,6 +10,7 @@ import RadioListItem from '@components/SelectionList/RadioListItem';
 import Text from '@components/Text';
 import TextLink from '@components/TextLink';
 import useLocalize from '@hooks/useLocalize';
+import usePermissions from '@hooks/usePermissions';
 import useThemeStyles from '@hooks/useThemeStyles';
 import {setAddNewCompanyCardStepAndData} from '@userActions/CompanyCards';
 import CONST from '@src/CONST';
@@ -18,9 +19,11 @@ import ONYXKEYS from '@src/ONYXKEYS';
 function SelectFeedType() {
     const {translate} = useLocalize();
     const styles = useThemeStyles();
-    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD);
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
     const [typeSelected, setTypeSelected] = useState<ValueOf<typeof CONST.COMPANY_CARDS.FEED_TYPE>>();
     const [hasError, setHasError] = useState(false);
+    const {canUsePlaidCompanyCards} = usePermissions();
+    const isCountrySupportPlaid = addNewCard?.data?.selectedCountry ? CONST.PLAID_SUPPORT_COUNTRIES.includes(addNewCard.data.selectedCountry) : false;
 
     const submit = () => {
         if (!typeSelected) {
@@ -34,18 +37,24 @@ function SelectFeedType() {
     };
 
     useEffect(() => {
-        setTypeSelected(addNewCard?.data.selectedFeedType);
-    }, [addNewCard?.data.selectedFeedType]);
+        if (addNewCard?.data.selectedFeedType) {
+            setTypeSelected(addNewCard?.data.selectedFeedType);
+            return;
+        }
+        if (isCountrySupportPlaid) {
+            setTypeSelected(CONST.COMPANY_CARDS.FEED_TYPE.DIRECT);
+        }
+    }, [addNewCard?.data.selectedFeedType, isCountrySupportPlaid]);
 
     const handleBackButtonPress = () => {
-        setAddNewCompanyCardStepAndData({step: CONST.COMPANY_CARDS.STEP.SELECT_BANK});
+        setAddNewCompanyCardStepAndData({step: canUsePlaidCompanyCards ? CONST.COMPANY_CARDS.STEP.SELECT_COUNTRY : CONST.COMPANY_CARDS.STEP.SELECT_BANK});
     };
 
     const data = [
         {
             value: CONST.COMPANY_CARDS.FEED_TYPE.CUSTOM,
             text: translate('workspace.companyCards.commercialFeed'),
-            alternateText: translate('workspace.companyCards.addNewCard.commercialFeedDetails'),
+            alternateText: translate(canUsePlaidCompanyCards ? 'workspace.companyCards.addNewCard.commercialFeedPlaidDetails' : 'workspace.companyCards.addNewCard.commercialFeedDetails'),
             keyForList: CONST.COMPANY_CARDS.FEED_TYPE.CUSTOM,
             isSelected: typeSelected === CONST.COMPANY_CARDS.FEED_TYPE.CUSTOM,
         },
@@ -58,6 +67,19 @@ function SelectFeedType() {
         },
     ];
 
+    const getFinalData = () => {
+        if (!canUsePlaidCompanyCards) {
+            return data;
+        }
+        if (isCountrySupportPlaid) {
+            return data.reverse();
+        }
+
+        return data.slice(0, 1);
+    };
+
+    const finalData = getFinalData();
+
     return (
         <ScreenWrapper
             testID={SelectFeedType.displayName}
@@ -82,11 +104,11 @@ function SelectFeedType() {
                     setTypeSelected(value);
                     setHasError(false);
                 }}
-                sections={[{data}]}
+                sections={[{data: finalData}]}
                 shouldSingleExecuteRowSelect
                 isAlternateTextMultilineSupported
                 alternateTextNumberOfLines={3}
-                initiallyFocusedOptionKey={addNewCard?.data.selectedFeedType}
+                initiallyFocusedOptionKey={typeSelected}
                 shouldUpdateFocusedIndex
                 showConfirmButton
                 confirmButtonText={translate('common.next')}
diff --git a/src/types/onyx/CardFeeds.ts b/src/types/onyx/CardFeeds.ts
index 48e29fe89c8d..16d78acbfbdd 100644
--- a/src/types/onyx/CardFeeds.ts
+++ b/src/types/onyx/CardFeeds.ts
@@ -103,6 +103,9 @@ type AddNewCardFeedData = {
 
     /** Name of the bank */
     bankName?: string;
+
+    /** Selected country */
+    selectedCountry?: string;
 };
 
 /** Issue new card flow steps */
diff --git a/src/types/onyx/Currency.ts b/src/types/onyx/Currency.ts
index 69b4203cdbf1..80deea5e00bd 100644
--- a/src/types/onyx/Currency.ts
+++ b/src/types/onyx/Currency.ts
@@ -20,6 +20,9 @@ type Currency = {
 
     /** Cache burst */
     cacheBurst?: number;
+
+    /** Countries based on ISO4217 code */
+    countries?: string[];
 };
 
 /** Record of currencies, index by currency code */


Reviews:
user: login: dominictb
state: CHANGES_REQUESTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T16:04:06Z
user: login: dominictb
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T16:08:47Z
user: login: dominictb
body: :shipit: 
state: APPROVED
author_association: CONTRIBUTOR
submitted_at: 2025-05-13T17:04:33Z
user: login: nkuoch
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T09:42:24Z
user: login: nkuoch
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T09:45:12Z
user: login: nkuoch
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T09:45:35Z
user: login: narefyev91
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T10:39:49Z
user: login: nkuoch
state: APPROVED
author_association: CONTRIBUTOR
submitted_at: 2025-05-14T11:38:18Z

Review comments:
diff_hunk: @@ -4074,6 +4076,9 @@ const CONST = {
         SE: 'Sweden',
     },
 
+    PLAID_EXCLUDED_COUNTRIES: ['IR', 'CU', 'SY', 'UA', 'KP'] as string[],
+    PLAID_INCLUDED_COUNTRIES: ['US', 'CA', 'GB', 'AT', 'BE', 'DK', 'EE', 'FI', 'FR', 'DE', 'IE', 'IT', 'LV', 'LT', 'NL', 'NO', 'PL', 'PT', 'ES', 'SE'] as string[],
path: src/CONST.ts
user: login: dominictb
body: ```suggestion
    PLAID_SUPPORT_COUNTRIES: ['US', 'CA', 'GB', 'AT', 'BE', 'DK', 'EE', 'FI', 'FR', 'DE', 'IE', 'IT', 'LV', 'LT', 'NL', 'NO', 'PL', 'PT', 'ES', 'SE'] as string[],
```
created_at: 2025-05-13T15:30:01Z
author_association: CONTRIBUTOR
diff_hunk: @@ -0,0 +1,157 @@
+import {useRoute} from '@react-navigation/native';
+import React, {useCallback, useEffect, useMemo, useState} from 'react';
+import {View} from 'react-native';
+import {useOnyx} from 'react-native-onyx';
+import FormHelpMessage from '@components/FormHelpMessage';
+import HeaderWithBackButton from '@components/HeaderWithBackButton';
+import ScreenWrapper from '@components/ScreenWrapper';
+import SelectionList from '@components/SelectionList';
+import RadioListItem from '@components/SelectionList/RadioListItem';
+import Text from '@components/Text';
+import useDebouncedState from '@hooks/useDebouncedState';
+import useLocalize from '@hooks/useLocalize';
+import usePolicy from '@hooks/usePolicy';
+import useThemeStyles from '@hooks/useThemeStyles';
+import searchOptions from '@libs/searchOptions';
+import type {Option} from '@libs/searchOptions';
+import StringUtils from '@libs/StringUtils';
+import Navigation from '@navigation/Navigation';
+import type {PlatformStackRouteProp} from '@navigation/PlatformStackNavigation/types';
+import type {WorkspaceSplitNavigatorParamList} from '@navigation/types';
+import {clearAddNewCardFlow, setAddNewCompanyCardStepAndData} from '@userActions/CompanyCards';
+import CONST from '@src/CONST';
+import type {TranslationPaths} from '@src/languages/types';
+import ONYXKEYS from '@src/ONYXKEYS';
+import type SCREENS from '@src/SCREENS';
+
+type CountryStepProps = {
+    policyID?: string;
+};
+
+function SelectCountryStep({policyID}: CountryStepProps) {
+    const {translate} = useLocalize();
+    const route = useRoute<PlatformStackRouteProp<WorkspaceSplitNavigatorParamList, typeof SCREENS.WORKSPACE.COMPANY_CARDS_ADD_NEW>>();
+    const styles = useThemeStyles();
+    const policy = usePolicy(policyID);
+    const [currencyList = {}] = useOnyx(ONYXKEYS.CURRENCY_LIST, {canBeMissing: true});
+    const [countryByIp] = useOnyx(ONYXKEYS.COUNTRY, {canBeMissing: false});
+
+    const [searchValue, debouncedSearchValue, setSearchValue] = useDebouncedState('');
+    const [currentCountry, setCurrentCountry] = useState<string | undefined>('');
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
+    const [hasError, setHasError] = useState(false);
+    const isEur = policy?.outputCurrency === CONST.CURRENCY.EUR;
+
+    const submit = () => {
+        if (!currentCountry) {
+            setHasError(true);
+        } else {
+            if (addNewCard?.data.selectedBank !== currentCountry) {
path: src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx
user: login: dominictb
body: ```suggestion
            if (addNewCard?.data.selectedCountry !== currentCountry) {
```
created_at: 2025-05-13T15:43:59Z
author_association: CONTRIBUTOR
diff_hunk: @@ -3817,12 +3817,14 @@ const translations = {
                 },
                 yourCardProvider: `¿Quién es su proveedor de tarjetas?`,
                 whoIsYourBankAccount: '¿Cuál es tu banco?',
+                whereIsYourBankLocated: '¿Dónde está ubicado su banco?',
path: src/languages/es.ts
user: login: dominictb
body: ```suggestion
                whereIsYourBankLocated: '¿Dónde está ubicado tu banco?',
```
created_at: 2025-05-13T15:53:16Z
author_association: CONTRIBUTOR
diff_hunk: @@ -3817,12 +3817,14 @@ const translations = {
                 },
                 yourCardProvider: `¿Quién es su proveedor de tarjetas?`,
                 whoIsYourBankAccount: '¿Cuál es tu banco?',
+                whereIsYourBankLocated: '¿Dónde está ubicado su banco?',
                 howDoYouWantToConnect: '¿Cómo deseas conectarte a tu banco?',
                 learnMoreAboutOptions: {
                     text: 'Obtén más información sobre estas ',
                     linkText: 'opciones.',
                 },
                 commercialFeedDetails: 'Requiere configuración con tu banco. Esto suele ser utilizado por empresas más grandes y a menudo es la mejor opción si calificas.',
+                commercialFeedPlaidDetails: `Requiere configuración con su banco, pero le guiaremos. Esto suele estar limitado a empresas grandes.`,
path: src/languages/es.ts
user: login: dominictb
body: ```suggestion
                commercialFeedPlaidDetails: 'Requiere configurarlo con tu banco, pero te guiaremos. Esto suele estar limitado a empresas más grandes.',
```
created_at: 2025-05-13T15:53:56Z
author_association: CONTRIBUTOR
diff_hunk: @@ -3817,12 +3817,14 @@ const translations = {
                 },
                 yourCardProvider: `¿Quién es su proveedor de tarjetas?`,
                 whoIsYourBankAccount: '¿Cuál es tu banco?',
+                whereIsYourBankLocated: '¿Dónde está ubicado su banco?',
path: src/languages/es.ts
user: login: dominictb
body: Reference from this [translations doc](https://docs.google.com/document/d/1EEXqcXnisA5Tz7yajqcuH9Rtt48Qc_y2hGAWuSaqj4w/edit?usp=sharing)
created_at: 2025-05-13T16:08:47Z
author_association: CONTRIBUTOR
diff_hunk: @@ -821,6 +821,7 @@ const CONST = {
         PRIVATE_DOMAIN_ONBOARDING: 'privateDomainOnboarding',
         IS_TRAVEL_VERIFIED: 'isTravelVerified',
         NEWDOT_MULTI_FILES_DRAG_AND_DROP: 'newDotMultiFilesDragAndDrop',
+        PLAID_COMPANY_CARDS: 'plaidCompanyCards',
path: src/CONST.ts
user: login: nkuoch
body: FYI, adding this beta back end side in [this PR](https://github.com/Expensify/Web-Expensify/pull/46735).
created_at: 2025-05-14T09:42:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -0,0 +1,157 @@
+import {useRoute} from '@react-navigation/native';
+import React, {useCallback, useEffect, useMemo, useState} from 'react';
+import {View} from 'react-native';
+import {useOnyx} from 'react-native-onyx';
+import FormHelpMessage from '@components/FormHelpMessage';
+import HeaderWithBackButton from '@components/HeaderWithBackButton';
+import ScreenWrapper from '@components/ScreenWrapper';
+import SelectionList from '@components/SelectionList';
+import RadioListItem from '@components/SelectionList/RadioListItem';
+import Text from '@components/Text';
+import useDebouncedState from '@hooks/useDebouncedState';
+import useLocalize from '@hooks/useLocalize';
+import usePolicy from '@hooks/usePolicy';
+import useThemeStyles from '@hooks/useThemeStyles';
+import searchOptions from '@libs/searchOptions';
+import type {Option} from '@libs/searchOptions';
+import StringUtils from '@libs/StringUtils';
+import Navigation from '@navigation/Navigation';
+import type {PlatformStackRouteProp} from '@navigation/PlatformStackNavigation/types';
+import type {WorkspaceSplitNavigatorParamList} from '@navigation/types';
+import {clearAddNewCardFlow, setAddNewCompanyCardStepAndData} from '@userActions/CompanyCards';
+import CONST from '@src/CONST';
+import type {TranslationPaths} from '@src/languages/types';
+import ONYXKEYS from '@src/ONYXKEYS';
+import type SCREENS from '@src/SCREENS';
+
+type CountryStepProps = {
+    policyID?: string;
+};
+
+function SelectCountryStep({policyID}: CountryStepProps) {
+    const {translate} = useLocalize();
+    const route = useRoute<PlatformStackRouteProp<WorkspaceSplitNavigatorParamList, typeof SCREENS.WORKSPACE.COMPANY_CARDS_ADD_NEW>>();
+    const styles = useThemeStyles();
+    const policy = usePolicy(policyID);
+    const [currencyList = {}] = useOnyx(ONYXKEYS.CURRENCY_LIST, {canBeMissing: true});
+    const [countryByIp] = useOnyx(ONYXKEYS.COUNTRY, {canBeMissing: false});
+
+    const [searchValue, debouncedSearchValue, setSearchValue] = useDebouncedState('');
+    const [currentCountry, setCurrentCountry] = useState<string | undefined>('');
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
+    const [hasError, setHasError] = useState(false);
+    const isEur = policy?.outputCurrency === CONST.CURRENCY.EUR;
+
+    const submit = () => {
+        if (!currentCountry) {
+            setHasError(true);
+        } else {
+            if (addNewCard?.data.selectedCountry !== currentCountry) {
+                clearAddNewCardFlow();
+            }
+            setAddNewCompanyCardStepAndData({
+                step: CONST.COMPANY_CARDS.STEP.SELECT_FEED_TYPE,
+                data: {
+                    selectedCountry: currentCountry,
+                },
+                isEditing: false,
+            });
+        }
+    };
+
+    useEffect(() => {
+        if (addNewCard?.data?.selectedCountry) {
+            setCurrentCountry(addNewCard.data.selectedCountry);
+            return;
+        }
+        if (isEur) {
+            setCurrentCountry(countryByIp);
path: src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx
user: login: nkuoch
body: Only set to countryByIp if it is a european country (in `selectedCurrency?.countries`)
created_at: 2025-05-14T09:45:12Z
author_association: CONTRIBUTOR
diff_hunk: @@ -0,0 +1,157 @@
+import {useRoute} from '@react-navigation/native';
+import React, {useCallback, useEffect, useMemo, useState} from 'react';
+import {View} from 'react-native';
+import {useOnyx} from 'react-native-onyx';
+import FormHelpMessage from '@components/FormHelpMessage';
+import HeaderWithBackButton from '@components/HeaderWithBackButton';
+import ScreenWrapper from '@components/ScreenWrapper';
+import SelectionList from '@components/SelectionList';
+import RadioListItem from '@components/SelectionList/RadioListItem';
+import Text from '@components/Text';
+import useDebouncedState from '@hooks/useDebouncedState';
+import useLocalize from '@hooks/useLocalize';
+import usePolicy from '@hooks/usePolicy';
+import useThemeStyles from '@hooks/useThemeStyles';
+import searchOptions from '@libs/searchOptions';
+import type {Option} from '@libs/searchOptions';
+import StringUtils from '@libs/StringUtils';
+import Navigation from '@navigation/Navigation';
+import type {PlatformStackRouteProp} from '@navigation/PlatformStackNavigation/types';
+import type {WorkspaceSplitNavigatorParamList} from '@navigation/types';
+import {clearAddNewCardFlow, setAddNewCompanyCardStepAndData} from '@userActions/CompanyCards';
+import CONST from '@src/CONST';
+import type {TranslationPaths} from '@src/languages/types';
+import ONYXKEYS from '@src/ONYXKEYS';
+import type SCREENS from '@src/SCREENS';
+
+type CountryStepProps = {
+    policyID?: string;
+};
+
+function SelectCountryStep({policyID}: CountryStepProps) {
+    const {translate} = useLocalize();
+    const route = useRoute<PlatformStackRouteProp<WorkspaceSplitNavigatorParamList, typeof SCREENS.WORKSPACE.COMPANY_CARDS_ADD_NEW>>();
+    const styles = useThemeStyles();
+    const policy = usePolicy(policyID);
+    const [currencyList = {}] = useOnyx(ONYXKEYS.CURRENCY_LIST, {canBeMissing: true});
+    const [countryByIp] = useOnyx(ONYXKEYS.COUNTRY, {canBeMissing: false});
+
+    const [searchValue, debouncedSearchValue, setSearchValue] = useDebouncedState('');
+    const [currentCountry, setCurrentCountry] = useState<string | undefined>('');
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
+    const [hasError, setHasError] = useState(false);
+    const isEur = policy?.outputCurrency === CONST.CURRENCY.EUR;
+
+    const submit = () => {
+        if (!currentCountry) {
+            setHasError(true);
+        } else {
+            if (addNewCard?.data.selectedCountry !== currentCountry) {
+                clearAddNewCardFlow();
+            }
+            setAddNewCompanyCardStepAndData({
+                step: CONST.COMPANY_CARDS.STEP.SELECT_FEED_TYPE,
+                data: {
+                    selectedCountry: currentCountry,
+                },
+                isEditing: false,
+            });
+        }
+    };
+
+    useEffect(() => {
+        if (addNewCard?.data?.selectedCountry) {
+            setCurrentCountry(addNewCard.data.selectedCountry);
+            return;
+        }
+        if (isEur) {
+            setCurrentCountry(countryByIp);
path: src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx
user: login: nkuoch
body: Otherwise, just don't preselect
created_at: 2025-05-14T09:45:35Z
author_association: CONTRIBUTOR
diff_hunk: @@ -0,0 +1,157 @@
+import {useRoute} from '@react-navigation/native';
+import React, {useCallback, useEffect, useMemo, useState} from 'react';
+import {View} from 'react-native';
+import {useOnyx} from 'react-native-onyx';
+import FormHelpMessage from '@components/FormHelpMessage';
+import HeaderWithBackButton from '@components/HeaderWithBackButton';
+import ScreenWrapper from '@components/ScreenWrapper';
+import SelectionList from '@components/SelectionList';
+import RadioListItem from '@components/SelectionList/RadioListItem';
+import Text from '@components/Text';
+import useDebouncedState from '@hooks/useDebouncedState';
+import useLocalize from '@hooks/useLocalize';
+import usePolicy from '@hooks/usePolicy';
+import useThemeStyles from '@hooks/useThemeStyles';
+import searchOptions from '@libs/searchOptions';
+import type {Option} from '@libs/searchOptions';
+import StringUtils from '@libs/StringUtils';
+import Navigation from '@navigation/Navigation';
+import type {PlatformStackRouteProp} from '@navigation/PlatformStackNavigation/types';
+import type {WorkspaceSplitNavigatorParamList} from '@navigation/types';
+import {clearAddNewCardFlow, setAddNewCompanyCardStepAndData} from '@userActions/CompanyCards';
+import CONST from '@src/CONST';
+import type {TranslationPaths} from '@src/languages/types';
+import ONYXKEYS from '@src/ONYXKEYS';
+import type SCREENS from '@src/SCREENS';
+
+type CountryStepProps = {
+    policyID?: string;
+};
+
+function SelectCountryStep({policyID}: CountryStepProps) {
+    const {translate} = useLocalize();
+    const route = useRoute<PlatformStackRouteProp<WorkspaceSplitNavigatorParamList, typeof SCREENS.WORKSPACE.COMPANY_CARDS_ADD_NEW>>();
+    const styles = useThemeStyles();
+    const policy = usePolicy(policyID);
+    const [currencyList = {}] = useOnyx(ONYXKEYS.CURRENCY_LIST, {canBeMissing: true});
+    const [countryByIp] = useOnyx(ONYXKEYS.COUNTRY, {canBeMissing: false});
+
+    const [searchValue, debouncedSearchValue, setSearchValue] = useDebouncedState('');
+    const [currentCountry, setCurrentCountry] = useState<string | undefined>('');
+    const [addNewCard] = useOnyx(ONYXKEYS.ADD_NEW_COMPANY_CARD, {canBeMissing: true});
+    const [hasError, setHasError] = useState(false);
+    const isEur = policy?.outputCurrency === CONST.CURRENCY.EUR;
+
+    const submit = () => {
+        if (!currentCountry) {
+            setHasError(true);
+        } else {
+            if (addNewCard?.data.selectedCountry !== currentCountry) {
+                clearAddNewCardFlow();
+            }
+            setAddNewCompanyCardStepAndData({
+                step: CONST.COMPANY_CARDS.STEP.SELECT_FEED_TYPE,
+                data: {
+                    selectedCountry: currentCountry,
+                },
+                isEditing: false,
+            });
+        }
+    };
+
+    useEffect(() => {
+        if (addNewCard?.data?.selectedCountry) {
+            setCurrentCountry(addNewCard.data.selectedCountry);
+            return;
+        }
+        if (isEur) {
+            setCurrentCountry(countryByIp);
path: src/pages/workspace/companyCards/addNew/SelectCountryStep.tsx
user: login: narefyev91
body: Updated thanks!
created_at: 2025-05-14T10:39:48Z
author_association: CONTRIBUTOR

PR comments:
user: login: melvin-bot[bot]
created_at: 2025-05-12T13:59:19Z
body: @dominictb Please copy/paste the Reviewer Checklist from [here](https://raw.githubusercontent.com/Expensify/App/main/contributingGuides/REVIEWER_CHECKLIST.md) into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button]
author_association: NONE
user: login: dominictb
created_at: 2025-05-13T10:39:12Z
body: ## Reviewer Checklist

- [x] I have verified the author checklist is complete (all boxes are checked off).
- [x] I verified the correct issue is linked in the `### Fixed Issues` section above
- [x] I verified testing steps are clear and they cover the changes made in this PR
    - [x] I verified the steps for local testing are in the `Tests` section
    - [x] I verified the steps for Staging and/or Production testing are in the `QA steps` section
    - [x] I verified the steps cover any possible failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    - [x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
- [x] I checked that screenshots or videos are included for tests on [all platforms](https://github.com/Expensify/App/blob/main/contributingGuides/CONTRIBUTING.md#make-sure-you-can-test-on-all-platforms)
- [x] I included screenshots or videos for tests on [all platforms](https://github.com/Expensify/App/blob/main/contributingGuides/CONTRIBUTING.md#make-sure-you-can-test-on-all-platforms)
- [x] I verified that the composer does not automatically focus or open the keyboard on mobile unless explicitly intended. This includes checking that returning the app from the background does not unexpectedly open the keyboard.
- [x] I verified tests pass on **all platforms** & I tested again on:
    - [x] Android: HybridApp
    - [x] Android: mWeb Chrome
    - [x] iOS: HybridApp
    - [x] iOS: mWeb Safari
    - [x] MacOS: Chrome / Safari
    - [x] MacOS: Desktop
- [x] If there are any errors in the console that are unrelated to this PR, I either fixed them (preferred) or linked to where I reported them in Slack
- [x] I verified there are no new alerts related to the `canBeMissing` param for `useOnyx`
- [x] I verified proper code patterns were followed (see [Reviewing the code](https://github.com/Expensify/App/blob/main/contributingGuides/PR_REVIEW_GUIDELINES.md#reviewing-the-code))
    - [x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. `toggleReport` and not `onIconClick`).
    - [x] I verified that comments were added to code that is not self explanatory
    - [x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    - [x] I verified any copy / text shown in the product is localized by adding it to `src/languages/*` files and using the [translation method](https://github.com/Expensify/App/blob/4bd99402cebdf4d7394e0d1f260879ea238197eb/src/components/withLocalize.js#L60)
    - [x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the [localization methods](https://github.com/Expensify/App/blob/4bd99402cebdf4d7394e0d1f260879ea238197eb/src/components/withLocalize.js#L60-L68)
    - [x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    - [x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    - [x] I verified the JSDocs style guidelines (in [`STYLE.md`](https://github.com/Expensify/App/blob/main/contributingGuides/STYLE.md#jsdocs)) were followed
- [x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
- [x] I verified that this PR follows the guidelines as stated in the [Review Guidelines](https://github.com/Expensify/App/blob/main/contributingGuides/PR_REVIEW_GUIDELINES.md)
- [x] I verified other components that can be impacted by these changes have been tested, and I retested again (i.e. if the PR modifies a shared library or component like `Avatar`, I verified the components using `Avatar` have been tested & I retested again)
- [x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
- [x] I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
- [x] If a new component is created I verified that:
    - [x] A similar component doesn't exist in the codebase
    - [x] All props are defined accurately and each prop has a `/** comment above it */`
    - [x] The file is named correctly
    - [x] The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
    - [x] The only data being stored in the state is data necessary for rendering and nothing else
    - [x] For Class Components, any internal methods passed to components event handlers are bound to `this` properly so there are no scoping issues (i.e. for `onClick={this.submit}` the method `this.submit` should be bound to `this` in the constructor)
    - [x] Any internal methods bound to `this` are necessary to be bound (i.e. avoid `this.submit = this.submit.bind(this);` if `this.submit` is never passed to a component event handler like `onClick`)
    - [x] All JSX used for rendering exists in the render method
    - [x] The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions
- [x] If any new file was added I verified that:
    - [x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
- [x] If a new CSS style is added I verified that:
    - [x] A similar style doesn't already exist
    - [x] The style can't be created with an existing [StyleUtils](https://github.com/Expensify/App/blob/main/src/utils/index.ts) function (i.e. `StyleUtils.getBackgroundAndBorderStyle(theme.componentBG`)
- [x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
- [x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like `Avatar` is modified, I verified that `Avatar` is working as expected in all cases)
- [x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
- [x] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
- [x] If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    - [x] I verified that all the inputs inside a form are aligned with each other.
    - [x] I added `Design` label and/or tagged `@Expensify/design` so the design team can review the changes.
- [x] If a new page is added, I verified it's using the `ScrollView` component to make it scrollable when more elements are added to the page.
- [x] For any bug fix or new feature in this PR, I verified that sufficient [unit tests](https://github.com/Expensify/App/blob/main/tests/README.md) are included to prevent regressions in this flow.
- [x] If the `main` branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the `Test` steps.
- [x] I have checked off every checkbox in the PR reviewer checklist, including those that don't apply to this PR.

### Screenshots/Videos
<details>
<summary>Android: HybridApp</summary>

<!-- add screenshots or videos here -->

https://github.com/user-attachments/assets/cff34009-bc32-4f00-a674-3009df14a830


</details>

<details>
<summary>Android: mWeb Chrome</summary>

<!-- add screenshots or videos here -->

https://github.com/user-attachments/assets/2e06906c-2ca7-4c99-809a-daf23b9a767e


</details>

<details>
<summary>iOS: HybridApp</summary>

<!-- add screenshots or videos here -->

https://github.com/user-attachments/assets/a0b9f3f1-3e64-45cb-af9c-24cb36a302f3


</details>

<details>
<summary>iOS: mWeb Safari</summary>

<!-- add screenshots or videos here -->

https://github.com/user-attachments/assets/53fcfffd-79c3-420d-8e2b-3e5240e7c1be


</details>

<details>
<summary>MacOS: Chrome / Safari</summary>

<!-- add screenshots or videos here -->

https://github.com/user-attachments/assets/dbc41136-b6ce-4ba5-ae6c-bd2208e7a4cd


</details>

<details>
<summary>MacOS: Desktop</summary>

<!-- add screenshots or videos here -->

https://github.com/user-attachments/assets/5ff2345b-f197-4865-bad3-579a40e758c4


</details>

author_association: CONTRIBUTOR
user: login: joekaufmanexpensify
created_at: 2025-05-13T15:31:49Z
body: @dominictb do you think you'll be able to review this one today? Also I am getting you added to #convert where we are discussing this project. 
author_association: CONTRIBUTOR
user: login: dominictb
created_at: 2025-05-13T15:37:01Z
body: Thanks @joekaufmanexpensify. I'm reviewing it. It should be done in < 1 hour.
author_association: CONTRIBUTOR
user: login: joekaufmanexpensify
created_at: 2025-05-13T15:51:30Z
body: Sweet, thank you!
author_association: CONTRIBUTOR
user: login: dominictb
created_at: 2025-05-13T16:05:01Z
body: @narefyev91 This section `Selecting Next with direct feed selected will ...` of the feed type selector has not been implemented.
author_association: CONTRIBUTOR
user: login: narefyev91
created_at: 2025-05-13T16:10:12Z
body: > @narefyev91 This section `Selecting Next with direct feed selected will ...` of the feed type selector has not been implemented.

yeah - it will be a part of bank selector
author_association: CONTRIBUTOR
user: login: dominictb
created_at: 2025-05-13T16:11:56Z
body: Ah okay it's up to you. Because I saw it noted under `Feed type selector`.
author_association: CONTRIBUTOR
user: login: narefyev91
created_at: 2025-05-13T16:13:52Z
body: > Ah okay it's up to you. Because I saw it noted under `Feed type selector`.

yeah - it will required already to add Plaid UI screen - which prefer to avoid for now as a part of other ticket 😄 
author_association: CONTRIBUTOR
user: login: dominictb
created_at: 2025-05-13T17:02:03Z
body: Everything looks fine so far except for the UT failure. I already completed the checklist and will approve one the checks are resolved.
author_association: CONTRIBUTOR
user: login: dominictb
created_at: 2025-05-13T17:04:11Z
body: Hmm I think the test is flaky. Same problem here https://github.com/Expensify/App/issues/61890. Will approve anyway. I think someone from the internal team will create a separate ticket to fix that flaky test cc @mountiny 
author_association: CONTRIBUTOR
user: login: OSBotify
created_at: 2025-05-14T11:50:12Z
body: :hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.
author_association: CONTRIBUTOR
user: login: joekaufmanexpensify
created_at: 2025-05-16T18:50:10Z
body: Tested and works really well! I was not able to test the EU specific portion. @narefyev91 or @nkuoch if you could test that piece, please do. 
author_association: CONTRIBUTOR
user: login: joekaufmanexpensify
created_at: 2025-05-16T18:52:46Z
body: One piece of feedback, I noticed if you select a non-Plaid country, we still bring you to the feed selector and show commercial feed as the only option (see video below). However, given this is the only option, we can skip the feed type selector and go directly to the commercial feed selector. This is what was contemplated in the design doc. 


https://github.com/user-attachments/assets/210bbf5e-1f82-42ca-abb2-602ecf976a9a


<img width="772" alt="image" src="https://github.com/user-attachments/assets/bb09b0f2-4899-4bca-aad9-fe8adad1ce91" />

author_association: CONTRIBUTOR
user: login: narefyev91
created_at: 2025-05-16T19:02:49Z
body: Yeah commercial feed is a separate ticket. It will be implemented later
author_association: CONTRIBUTOR
user: login: arosiclair
created_at: 2025-05-19T15:22:28Z
body: > Tested and works really well! I was not able to test the EU specific portion. @narefyev91 or @nkuoch if you could test that piece, please do.

Do we still need to verify this? @joekaufmanexpensify @narefyev91 @nkuoch 
author_association: CONTRIBUTOR
user: login: joekaufmanexpensify
created_at: 2025-05-19T16:35:34Z
body: This feature is behind beta, so it is not essential for deploy. But if @narefyev91 or @nkuoch could test quickly since they're in Europe, that would be great. 
author_association: CONTRIBUTOR
user: login: nkuoch
created_at: 2025-05-20T09:38:31Z
body: Worked well! 
<img width="1456" alt="image" src="https://github.com/user-attachments/assets/b088d56b-79cd-4ae1-b3c7-840d8b9b6ee9" />

France was automatically selected
<img width="1728" alt="image" src="https://github.com/user-attachments/assets/4d50ba15-0136-4d37-a0f7-7ba0dc7bca8c" />

Then was led to the feed type choice
<img width="1728" alt="image" src="https://github.com/user-attachments/assets/2342a800-aacc-4f6d-b29d-77519d18d437" />


author_association: CONTRIBUTOR
user: login: github-actions[bot]
created_at: 2025-05-20T10:00:20Z
body: 🚀 [Deployed](https://github.com/Expensify/App/actions/runs/15134205990) to production by https://github.com/mountiny in version: 9.1.46-12 🚀

platform | result
---|---
🖥 desktop 🖥|success ✅
🕸 web 🕸|success ✅
🤖 android 🤖|failure ❌
🍎 iOS 🍎|success ✅
author_association: CONTRIBUTOR