---
page_title: Adding Plugins
product: UPI Plugin SDK
platform: Flutter
page_source: https://juspay.io/in/docs/upi-plugin-sdk/flutter/getting-the-sdk/getting-sdk
llms_txt: https://juspay.io/in/docs/llms.txt
product_llms_txt: https://juspay.io/in/docs/upi-plugin-sdk/llms.txt
---


## Adding Plugins



In order to use UPI In-app, the very first step is to install UPI In-app SDK into your application and add proper configurations. This has three steps to it:

1. [Installing Flutter Plugin](#installing-assets-plugin)
2. [Installing Asset Plugin - Android](#installing-assets-plugin-android)
3. [Installing Asset Plugin - iOS](#installing-assets-plugin-ios)

Following sections describe how to complete above steps


### 1. Installing Flutter Plugin




### Step 1.1 Add Plugin Dependency


Add flutter plugin dependency in `pubspec.yaml`



#### Code Snippets: -

#### Flutter Code Snippet:

```flutter
{"success":false,"message":"Failed to fetch snippet"}
```



### 2. Installing Assets Plugin - Android



UPI In-app SDK depends on certain assets to function. These are available over the air and are supposed to be present while building the SDK. The Assets Plugin is a build time dependency that downloads all required assets and ensures the availability of the latest assets at build time.

To install Assets Plugin follow the below steps


### Step 2.1 Add the clientId ext property


Add the clientId ext property in root(top) `build.gradle`



#### Code Snippets: -

#### Flutter Code Snippet:

```flutter
{"success":false,"message":"Failed to fetch snippet"}
```



### For Sandbox environment



To run UPI in sandbox environment. Follow these additional steps:


### Step 2.2 Add secure component


Include the secure component dependency in your `application build.gradle` under dependencies section.



#### Code Snippets: -

#### Flutter Code Snippet:

```flutter
implementation'in.juspay:secure-component-uat:4.1.8'
```



### Step 2.3 Add configurations block


Add following block below the dependencies section in `application build.gradle`.



#### Code Snippets: -

#### Flutter Code Snippet:

```flutter
{"success":false,"message":"Failed to fetch snippet"}
```



### 3. Installing Assets Plugin - iOS



To install Assets Plugin follow the below steps


### Step 3.1 Add Post Install Script to Podfile


This Ruby Script will download all the latest assets required for proper functioning of your SDK integration



#### Code Snippets: -

#### Flutter Code Snippet:

```flutter
{"success":false,"message":"Failed to fetch snippet"}
```



### Step 3.2 Add MerchantConfig.txt


The MerchantConfig.txt contains a clientId which helps the Assets plugin to download assets specific to your application

Create a .txt file named `MerchantConfig.txt` inside the app directory of your project. Add `clientId = your_client_id`to this file. Please note that the file has to added in the top directory of your app



#### Code Snippets: -

#### Flutter Code Snippet:

```flutter
clientId = <clientId> shared by Juspay Team
```


---

## Complete Code Reference

The following code files are referenced in the steps above:

### pubspec.yaml

```
{"success":false,"message":"Failed to fetch snippet"}
```

### build(root).gradle

```
{"success":false,"message":"Failed to fetch snippet"}
```

### build(sbx).gradle

```
{"success":false,"message":"Failed to fetch snippet"}
```

### Podfile

```
{"success":false,"message":"Failed to fetch snippet"}
```

### MerchantConfig.txt

```
{"success":false,"message":"Failed to fetch snippet"}
```


---

## See Also

- [Integration Checklist](https://juspay.io/in/docs/upi-plugin-sdk/flutter/overview/integration-checklist)
- [Adding Frameworks (iOS)](https://juspay.io/in/docs/upi-plugin-sdk/flutter/getting-the-sdk/adding-frameworks)
