Bug: [REFACTOR] retrieve extended card info config during business profile get call



During business profile get call, send the extended card info config of merchant in the response so that dashboard can make use of it
diff --git a/crates/api_models/src/admin.rs b/crates/api_models/src/admin.rs
index 12d9832ada6..dc64947bf08 100644
--- a/crates/api_models/src/admin.rs
+++ b/crates/api_models/src/admin.rs
@@ -1010,6 +1010,9 @@ pub struct BusinessProfileResponse {
 
     // Whether to use the billing details passed when creating the intent as payment method billing
     pub use_billing_as_payment_method_billing: Option<bool>,
+
+    /// Merchant's config to support extended card info feature
+    pub extended_card_info_config: Option<ExtendedCardInfoConfig>,
 }
 
 #[derive(Clone, Debug, Deserialize, ToSchema, Serialize)]
diff --git a/crates/router/src/types/api/admin.rs b/crates/router/src/types/api/admin.rs
index 8fc3ebb721f..20083afb1c9 100644
--- a/crates/router/src/types/api/admin.rs
+++ b/crates/router/src/types/api/admin.rs
@@ -8,7 +8,7 @@ pub use api_models::admin::{
 };
 use common_utils::ext_traits::{Encode, ValueExt};
 use error_stack::ResultExt;
-use masking::Secret;
+use masking::{ExposeInterface, Secret};
 
 use crate::{
     core::errors,
@@ -81,6 +81,10 @@ impl ForeignTryFrom<storage::business_profile::BusinessProfile> for BusinessProf
                 })
                 .transpose()?,
             use_billing_as_payment_method_billing: item.use_billing_as_payment_method_billing,
+            extended_card_info_config: item
+                .extended_card_info_config
+                .map(|config| config.expose().parse_value("ExtendedCardInfoConfig"))
+                .transpose()?,
         })
     }
 }
diff --git a/openapi/openapi_spec.json b/openapi/openapi_spec.json
index b87b516de28..18ec7577a98 100644
--- a/openapi/openapi_spec.json
+++ b/openapi/openapi_spec.json
@@ -6949,6 +6949,14 @@
           "use_billing_as_payment_method_billing": {
             "type": "boolean",
             "nullable": true
+          },
+          "extended_card_info_config": {
+            "allOf": [
+              {
+                "$ref": "#/components/schemas/ExtendedCardInfoConfig"
+              }
+            ],
+            "nullable": true
           }
         }
       },

## Type of Change
<!-- Put an `x` in the boxes that apply -->

- [ ] Bugfix
- [ ] New feature
- [ ] Enhancement
- [x] Refactoring
- [ ] Dependency updates
- [ ] Documentation
- [ ] CI/CD

## Description
<!-- Describe your changes in detail -->
During business profile get call, send the extended card info config of merchant (public key and ttl) in the response so that dashboard can make use of it

### Additional Changes

- [x] This PR modifies the API contract
- [ ] This PR modifies the database schema
- [ ] This PR modifies application configuration/environment variables

<!--
Provide links to the files with corresponding changes.

Following are the paths where you can find config files:
1. `config`
2. `crates/router/src/configs`
3. `loadtest/config`
-->


## Motivation and Context
<!--
Why is this change required? What problem does it solve?
If it fixes an open issue, please link to the issue here.

If you don't have an issue, we'd recommend starting with one first so the PR
can focus on the implementation (unless it is an obvious bug or documentation fix
that will have little conversation).
-->


## How did you test it?
<!--
Did you write an integration/unit/API test to verify the code changes?
Or did you test this change manually (provide relevant screenshots)?
-->
1. Create merchant account (get default profile_id)
2. Create api key
3. Use update endpoint of business profile to pass config.
```
curl --location 'http://localhost:8080/account/merchant_1716883344/business_profile/pro_5PdcjX4zYfC8X2PFjCel' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: test_admin' \
--data '{
    "extended_card_info_config": {
        "ttl_in_secs": 300,
        "public_key": "pub_key"
    }
}'
```
![image](https://github.com/juspay/hyperswitch/assets/70657455/67787f0e-724c-4bed-ae37-a2636093e481)

4. Retrieve the business profile and the config should be returned in the response

```
curl --location 'http://localhost:8080/account/merchant_1716883344/business_profile/pro_5PdcjX4zYfC8X2PFjCel' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: test_admin' \
--data ''
```

![image](https://github.com/juspay/hyperswitch/assets/70657455/eefcd267-ad39-447f-aa7a-8536537f935d)


## Checklist
<!-- Put an `x` in the boxes that apply -->

- [x] I formatted the code `cargo +nightly fmt --all`
- [x] I addressed lints thrown by `cargo clippy`
- [x] I reviewed the submitted code
- [ ] I added unit tests for my changes where possible
