---
page_title: Register Intent
product: UPI Merchant Stack
page_source: https://juspay.io/in/docs/upi-merchant-stack/docs/transactions/register-intent
openapi:
  V3: https://juspay.io/in/docs/api/swagger?document=https%3A%2F%2Fjuspay.io%2Fin%2Fdocs%2Fupi-merchant-stack%2Fdocs%2Ftransactions%2Fregister-intent%3Fversion%3DV3
  V2: https://juspay.io/in/docs/api/swagger?document=https%3A%2F%2Fjuspay.io%2Fin%2Fdocs%2Fupi-merchant-stack%2Fdocs%2Ftransactions%2Fregister-intent%3Fversion%3DV2
  V1: https://juspay.io/in/docs/api/swagger?document=https%3A%2F%2Fjuspay.io%2Fin%2Fdocs%2Fupi-merchant-stack%2Fdocs%2Ftransactions%2Fregister-intent%3Fversion%3DV1
  Default: https://juspay.io/in/docs/api/swagger?document=https%3A%2F%2Fjuspay.io%2Fin%2Fdocs%2Fupi-merchant-stack%2Fdocs%2Ftransactions%2Fregister-intent%3Fversion%3DDefault
llms_txt: https://juspay.io/in/docs/llms.txt
product_llms_txt: https://juspay.io/in/docs/upi-merchant-stack/llms.txt
---

## API Version: V3


# Merchant Register Intent



This api can be used to register intent for a payment. The response parameters should be used to construct deeplink url. Refer below table for mapping of response parameters to the deeplink url parameters.


| Response Parameter	 | Deeplink URL Parameter | Type |
|---|---|---|
| payeeVpa | pa | Mandatory |
| payeeName | pn | Mandatory |
| payeeMcc | mc | Mandatory |
| gatewayTransactionId | tid | Mandatory |
| orderId | tr | Mandatory |
| amount | am | Mandatory |
| currency | cu | Mandatory |
| remarks | tn | Optional |
| refUrl | url | Optional |
| purpose | purpose | Conditional |
| TxnInitiationMode | mode | Mandatory |
| refCategory | category | Optional |


**Sample Deeplink URL** 

upi://pay?pa=something@handle&pn=Swiggy&mc=5812&tid=YJP5566ca9ca6e64e76ba07c2d545f25&tr=swiggy567172772271&am=1.00&cu=INR&tn=Pay%20for%20Intent&mode=00

> **Note**
> For mode information, please check “Initiation Mode” sub-module in “**Miscellaneous** ” module. 



**Host URLs for IOS:** Gpay : [tez://upi/pay](tez://upi/pay)? PhonePe : [phonepe://pay](phonepe://pay)? Paytm : [paytmmp://pay](paytmmp://pay)? Cred : [credpay://upi/pay](credpay://upi/pay)? BHIM : [bhim://pay](bhim://pay)?

Merchant can then construct the URI and invoke the APP using chrome intent feature. It can also be used for generating the Dynamic UPI QR & display on Merchant App/Website for users to scan & pay from any UPI App.

> **Note**
> The URI must be generated dynamically based on the parameters received in the response. Ensure that there are no spaces in the URI; any spaces should be encoded as `%20`




### **Mutual Fund Use case:** 



Mutual Fund information using which the file to be shared with ICCL needs to be created to be passed in this API as a JSON (Refer request params & API format below).


### **TPV Use case:** 



For TPV (Third Party Validation) payerAccountHashes needs to be passed in the request body and the same will be passed back in response along with corresponding values. PayerAccountHashes will be taken as an array so that merchants can send multiple account hashes which will be verified against the account details selected by user shared by NPCI.

PSP will reject the request if the customer makes the payment with a different account details and send a failure callback to the merchant.


### **Split Settlement Use case:** 



Merchants must enter the split settlement details in the API calls whenever they want to split the payment and process multiple split settlements. Fields in this object (SplitSettlement) are both required and optional. Merchants can utilize these fields to settle to your vendors/partners by numerous categories, such as AMOUNT, PERCENTAGE, DEFAULT, and LATER, with the maximum flexibility possible.## Endpoints:
- Production: {{host}}/api/{{uri}}/merchants/transactions/registerIntent

## Request Type: 
POST

## Headers:

#### jpupi-routing-id:
Header value should be same as of merchantRequestId sent in request body
- Tags: String, Mandatory
## Sample Code Snippets:
### Code Snippets:

#### Shell Code Snippet:

```shell
curl -L -X POST '{{host}}/api/{{uri}}/merchants/transactions/registerIntent' \
-H 'content-type: application/json' \
-H 'x-merchant-id: TEST' \
-H 'x-merchant-channel-id: TESTAPP' \
-H 'x-timestamp: 1700158230380' \
-H 'jpupi-routing-id: ORDMxNameTransaction170357165578' \
-H 'x-api-version: 3' \
--data-raw '{ 
    "signature":"kHeeZD0f3E...",
    "payload":"eyJtZXJjaG...",
    "protected":"eyJhbGciOi..."
}'
```

### Sample Request and Response:

#### Request:
```json
{
  "merchantRequestId": "ORDMxNameTransaction170357165578",
  "amount": "2.00",
  "intentRequestExpiryMinutes": "10",
  "flow": "TRANSACTION",
  "remarks": "Payment for order",
  "refUrl": "www.xyz.com",
  "refCategory": "01",
  "iat": "1700158230380",
  "udfParameters": "{}",
  "mutualFundDetails": [
    {
      "memberId": "ABCDE",
      "userId": "ABCDEFGHIJ",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983010",
      "orderNumber": "order_zer12345",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIUI",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    },
    {
      "memberId": "ERTYU",
      "userId": "VTYUIOPFT",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983011",
      "orderNumber": "order_zer12346",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIFT",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    }
  ],
  "payerAccountHashes": [
    "ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674",
    "ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"
  ],
  "splitSettlementDetails": {
    "splitType": "AMOUNT",
    "merchantSplit": "30.00",
    "partnersSplit": [
        {
            "partnerId": "vendor1",
            "value": "40.00"
        },
        {
            "partnerId": "vendor2",
            "value": "55.00"
        }
    ]
  }
}
```

#### Response:
```json
{
  "status": "SUCCESS",
  "responseCode": "SUCCESS",
  "responseMessage": "SUCCESS",
  "payload": {
    "merchantId": "TEST",
    "merchantChannelId": "TESTAPP",
    "merchantRequestId": "ord50894574",
    "gatewayTransactionId": "TXNef1a2908395239df56663244f8c7deaa",
    "orderId": "ord50894574",
    "payeeVpa": "merchant@xyz",
    "payeeName": "John Doe",
    "payeeMcc": "1520",
    "amount": "2.00",
    "currency": "INR",
    "flow":"TRANSACTION",
    "payerAccountHashes": ["ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"],
    "mutualFundDetails": [
        {
          "memberId": "ABCDE",
          "userId": "ABCDEFGHIJ",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983010",
          "orderNumber": "order_zer12345",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIUI",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        },
        {
          "memberId": "ERTYU",
          "userId": "VTYUIOPFT",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983011",
          "orderNumber": "order_zer12346",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIFT",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        }
      ],
      "splitSettlementDetails": {
        "splitType": "AMOUNT",
        "merchantSplit": "30.00",
        "partnersSplit": [
            {
                "partnerId": "vendor1",
                "value": "40.00"
            },
            {
                "partnerId": "vendor2",
                "value": "55.00"
            }
        ]
    },
      "remarks": "Payment for order",
      "refUrl": "www.xyz.com",
      "refCategory": "01"
    },
    "udfParameters": "{}"
  }
```

## Body Parameters:
### Basic Params:

#### merchantRequestId:
- Description: Merchant generated unique id for the transaction.

**Constraint:** Max**** 35 characters alphanumeric, can also contain hyphen(-), dot(.) & underscore(_)
- Tags: String, Mandatory

#### amount:
- Description: Amount of intent transaction being registered.

**Constraint:** Amount in two decimals. Decimals are mandatory.
- Tags: String, Mandatory

#### intentRequestExpiryMinutes:
- Description: Minutes for which intent is valid. It should be <= order fulfilment time.

**Constraint:** number > 0
- Tags: String, Optional But Mandatory For New Integration

#### flow:
- Description: In order to differentiate between transactions and mandates. 

Values: TRANSACTION or MANDATE.
- Tags: String, Mandatory

#### remarks:
- Description: Any transaction summary.**Constraints:** The transaction note must be alphanumeric, with a **minimum length of 1 character and a maximum length of 50**  characters.
- Value:  TRANSACTION or MANDATE
- Tags: String, Optional

#### refUrl:
- Description: Reference url for the intent transaction being registered.
- Tags: String, optional

#### refCategory:
- Description: Details for refUrl for the intent transaction being registered, whether it is 01 (Advertisement), 02(Invoice).
- Tags: String, optional

#### iat:
- Description: Current Epoch Unix timestamp string. Has to be of 13 digit in Milliseconds.

Example: 1496918882000.
- Tags: String, Mandatory

#### udfParameters:
- Description: Merchant Defined Parameters.

Example: "{\"udf1\":\"value1\",\"udf2\":\"value2\",…}"**Note** : Few special characters are not allowed. Regex for the characters which are not allowed : **^[^/#-()*!%~`]+$** 
- Tags: Stringified Json, Optional
### Mutual Funds Params:

#### mutualFundDetails:
- Description: Contains details of Mutual Funds
- Value:
  - **MemberId**:
    - Description: Member Id with ICCL or ARN_RIA with RTA.
    - Tags: String, Mandatory
  - **UserId**:
    - Description: Client Id with ICCL or USER_CODE with RTA.
    - Tags: String, Mandatory
  - **MfPartner**:
    - Description: One of the below;**Constraints:** NSE, BSE, KFIN, CAMS.
    - Tags: String, Mandatory
  - **FolioNumber**:
    - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **OrderNumber**:
    - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA.
    - Tags: String, Mandatory
  - **Amount**:
    - Description: Individual MF amount within the array of MF being purchased.
      
      (Amount in two decimals. Decimals are mandatory).
    - Tags: String, Mandatory
  - **SchemeCode**:
    - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **AmcCode**:
    - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **PanNumber**:
    - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **InvestmentType**:
    - Description: One of the below; 
      
      **Constraints:** LUMPSUM, SIP.
    - Tags: String, Mandatory
  - **IhNumber**:
    - Description: In-house Number of the SIP (Mandatory for K-Fin RTA)
    - Tags: String, optional
- Tags: Json String, optional
### TPV Params:

#### payerAccountHashes:
- Description: Hashed value of accounts to be passed by merchant for TPV. 

**Hashing logic** **:** 

payerAccountHash = sha256( account Number + first 4 digit of account IFSC)From account Number the leading zeros should be removed and then the hash should be calculated.Eg: Account No. = 0000123456789 & IFSC = ABCD0000345

Hash will be calculated on 123456789ABCD.
- Value: value
- Tags: Array of String, conditional
### Split Settlement Params:

#### splitSettlementDetails:
- Description: Split Settlement details of merchant and partners for this transactions
- Value:
  - **SplitType**:
    - Description: The type of split for this transaction. Can be AMOUNT,  PERCENTAGE, DEFAULT, LATER.
    - Tags: String, Mandatory
  - **MerchantSplit**:
    - Description: Split share for merchant pool account.
    - Tags: String, optional
  - **PartnersSplit**:
    - Description: List of partners for which the split needs to be divided with the value.
    - Value:
      - **PartnerId**:
        - Description: The LSP id provided by the bank.
        - Tags: String, Mandatory
      - **Value**:
        - Description: Split share for LSP account. Decimal Value.
        - Tags: String, Mandatory
    - Tags: String, conditional
- Tags: Json String, optional
## API Responses:
### 200:

#### status:
- Description: PSP status of the API
- Value: Values: SUCCESS | FAILURE
- Tags: Mandatory, String

#### responseCode:
- Description: PSP response code for the API

**Values:** Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### responseMessage:
- Description: PSP response message for the API 

**Values:** Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### payload:
- Value:
  - **MerchantId**:
    - Description: Unique id for the merchant as passed in request headers
    - Tags: String, Mandatory
  - **MerchantChannelId**:
    - Description: Unique id for the merchant channel as passed in request headers
    - Tags: String, Mandatory
  - **GatewayTransactionId**:
    - Description: Gateway transaction id to be used for the intent transaction
    - Tags: String, Mandatory
  - **OrderId**:
    - Description: Transaction refernce to be used for the intent transaction
    - Tags: String, Mandatory
  - **PayeeVpa**:
    - Description: Payee VPA to be used for the intent transaction
    - Tags: String, Mandatory
  - **PayeeName**:
    - Description: Payee name to be used for the intent transaction
    - Tags: String, Mandatory
  - **PayeeMcc**:
    - Description: Payee mcc to be used for the intent transaction
    - Tags: String, Optional
  - **Amount**:
    - Description: Amount to be used for the intent transaction
    - Tags: String, Mandatory
  - **Currency**:
    - Description: Currency to be used for the intent transaction
    - Tags: String, Optional
  - **Remarks**:
    - Description: Remarks to be used for the intent transaction
    - Tags: String, optional
  - **Flow**:
    - Description: In order to differentiate between transactions and mandates. It can take the values as TRANSACTION or MANDATE.
    - Tags: String, Optional
  - **MutualFundDetails**:
    - Description: Contains details of Mutual Funds (as passed in the request)
    - Value:
      - **MemberId**:
        - Description: Member Id with ICCL or ARN_RIA with RTA
        - Tags: String, Mandatory
      - **UserId**:
        - Description: Client Id with ICCL or USER_CODE with RTA
        - Tags: String, Mandatory
      - **MfPartner**:
        - Description: One of the below;**Values:** NSE, BSE, KFIN, CAMS
        - Tags: String, Mandatory
      - **FolioNumber**:
        - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **OrderNumber**:
        - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA
        - Tags: String, Mandatory
      - **Amount**:
        - Description: Individual MF amount within the array of MF being purchased.
        - Tags: String, Mandatory
      - **SchemeCode**:
        - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **AmcCode**:
        - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **PanNumber**:
        - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **InvestmentType**:
        - Description: One of the below; 
          
          **Values:** LUMPSUM, SIP
        - Tags: String, Mandatory
    - Tags: String, Mandatory
  - **PayerAccountHashes**:
    - Description: As passed in the request body.
    - Tags: Array of String, conditional
  - **SplitSettlementDetails**:
    - Description: Split Settlement details of merchant and partners for this transactions
    - Value:
      - **PartnersSplit**:
        - Description: List of partners for which the split needs to be divided with the value.
        - Value:
          - **PartnerId**:
            - Description: The LSP id provided by the bank.
            - Tags: String, Mandatory
          - **Value**:
            - Description: Split share for LSP account. Decimal Value
            - Tags: String, Mandatory
        - Tags: String, conditional
      - **SplitType**:
        - Description: The type of split for this transaction. Can be AMOUNT,  PERCENTAGE, DEFAULT, LATER.
        - Tags: String, Mandatory
      - **MerchantSplit**:
        - Description: Split share for merchant pool account.
        - Tags: String, optional
    - Tags: String, Optional
  - **RefUrl**:
    - Description: Reference URL to be used for the intent transaction
    - Tags: String, optional
  - **RefCategory**:
    - Description: Reference URL category to be used for the intent transaction
    - Tags: String, optional
  - **MerchantCustomerId**:
    - Description: Merchant generated unique profile id for customer
    - Tags: String, Optional
  - **MerchantRequestId**:
    - Description: Merchant generated unique id for collect request.
      
      **Constraint** : Max 35 characters & Alphanumeric.
    - Tags: String, Mandatory
- Tags: Json, Mandatory

#### udfParameters:
- Description: Udf parameters as passed in the request
- Tags: Json String, optional


---

## API Version: V2


# Merchant Register Intent



This api can be used to register intent for a payment. The response parameters should be used to construct deeplink url. Refer below table for mapping of response parameters to the deeplink url parameters.


| Response Parameter | Deeplink URL Parameter | Type |
|---|---|---|
| payeeVpa  | pa | Mandatory |
| payeeName   | pn | Mandatory |
| payeeMcc  | mc | Mandatory |
| gatewayTransactionId  | tid | Mandatory |
| orderId  | tr | Mandatory |
| amount  | am | Mandatory |
| currency  | cu | Mandatory |
| remarks | tn | Optional |
| refUrl  | url | Optional |
| refCategory  | category | Optional |



#### **Sample Deeplink URL** 



upi://pay?pa=swiggytest@yespay&pn=Swiggy&mc=5812&tid=YJP5566ca9ca6e64e76ba07c2d545f25&tr=swiggy567172772271&am=1.0&cu=INR&tn=Pay%20for%20Intent**Host URLs for IOS:** Gpay : [tez://upi/pay](tez://upi/pay)?PhonePe : [phonepe://pay](phonepe://pay)?Paytm : [paytmmp://pay](paytmmp://pay)?Cred : [credpay://upi/pay](credpay://upi/pay)?BHIM : [bhim://pay](bhim://pay)?

Merchant can then construct the URI and invoke the APP using chrome intent feature. It can also be used for generating the Dynamic UPI QR & display on Merchant App/Website for users to scan & pay from any UPI App.

> **Note**
> 1. In the URI spaces are replaced by "%20". Kindly generate the intent URI dynamically ie, based on the params received in the response.
> 2. If **refUrl**  is passed in request, **refCategory**  becomes essential for the API to work. So it's either both as combination or none.




### **Mutual Fund Use case:** 



Mutual Fund information using which the file to be shared with ICCL needs to be created to be passed in this API as a JSON (Refer request params & API format below).


### **TPV Use case:** 



For TPV (Third Party Validation) payerAccountHashes needs to be passed in the request body and the same will be passed back in response along with corresponding values. PayerAccountHashes will be taken as an array so that merchants can send multiple account hashes which will be verified against the account details selected by user shared by NPCI.

PSP will reject the request if the customer makes the payment with a different account details and send a failure callback to the merchant.## Endpoints:
- Production: {{host}}/api/{{uri}}/merchants/transactions/registerIntent

## Request Type: 
POST

## Headers:

#### jpupi-routing-id:
Header value should be same as of merchantRequestId sent in request body
- Tags: String, Mandatory
## Sample Code Snippets:
### Code Snippets:

#### Shell Code Snippet:

```shell
curl -L -X POST '{{host}}/api/{{uri}}/merchants/transactions/registerIntent' \
-H 'content-type: application/json' \
-H 'x-merchant-id: TEST' \
-H 'x-merchant-channel-id: TESTAPP' \
-H 'x-timestamp: 1700158230380' \
-H 'jpupi-routing-id: ord50894574' \
-H 'x-api-version: 2' \
--data-raw '{ 
    "signature":"kHeeZD0f3E...",
    "payload":"eyJtZXJjaG...",
    "protected":"eyJhbGciOi..."
}'
```

### Sample Request and Response:

#### Request:
```json
{
  "merchantRequestId": "ord50894574",
  "amount": "2.00",
  "intentRequestExpiryMinutes": "10",
  "flow":"TRANSACTION",
  "payerAccountHashes": [
    "ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"
  ],
  "mutualFundDetails": [
    {
      "memberId": "ABCDE",
      "userId": "ABCDEFGHIJ",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983010",
      "orderNumber": "order_zer12345",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIUI",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    },
    {
      "memberId": "ERTYU",
      "userId": "VTYUIOPFT",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983011",
      "orderNumber": "order_zer12346",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIFT",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    }
  ],
  "remarks": "Payment for order",
  "refUrl": "www.xyz.com",
  "refCategory": "01",
  "udfParameters": "{}"
}
```

#### Response:
```json
{
  "status": "SUCCESS",
  "responseCode": "SUCCESS",
  "responseMessage": "SUCCESS",
  "payload": {
    "merchantId": "TEST",
    "merchantChannelId": "TESTAPP",
    "merchantRequestId": "ord50894574",
    "gatewayTransactionId": "TXNef1a2908395239df56663244f8c7deaa",
    "orderId": "ord50894574",
    "payeeVpa": "merchant@xyz",
    "payeeName": "John Doe",
    "payeeMcc": "1520",
    "amount": "2.00",
    "currency": "INR",
    "flow":"TRANSACTION",
    "payerAccountHashes": ["ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"],
    "mutualFundDetails": [
        {
          "memberId": "ABCDE",
          "userId": "ABCDEFGHIJ",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983010",
          "orderNumber": "order_zer12345",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIUI",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        },
        {
          "memberId": "ERTYU",
          "userId": "VTYUIOPFT",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983011",
          "orderNumber": "order_zer12346",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIFT",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        }
      ],
      "remarks": "Payment for order",
      "refUrl": "www.xyz.com",
      "refCategory": "01"
    },
    "udfParameters": "{}"
  }
```

## Body Parameters:
### Basic Params:

#### merchantRequestId:
- Description: Merchant generated id for the transaction

**Constraint:** Max**** 35 characters alphanumeric, can also contain hyphen(-), dot(.) & underscore(_)
- Tags: String, Mandatory

#### upiRequestId:
- Description: Unique id sent to UPI switch for the transaction

**Constraint** :**** 35 character alphanumeric
- Tags: String, Optional

#### amount:
- Description: Amount of intent transaction being registered

**Constraint:** Amount in two decimals. Decimals are mandatory
- Tags: String, mandatory

#### intentRequestExpiryMinutes:
- Description: Minutes for which intent is valid. If this value is not passed, the default value will be used from merchant configurations. if both of them aren't available, intent will never expire.

**Constraint:** number > 0 (as string)
- Tags: String, optional

#### remarks:
- Description: Remarks for the intent transaction being registered
- Tags: String, optional

#### flow:
- Description: In order to differentiate between transactions and mandates. It can take the values as TRANSACTION or MANDATE.
- Value:  TRANSACTION or MANDATE
- Tags: String, Mandatory

#### refUrl:
- Description: Reference url for the intent transaction being registered
- Tags: String, optional

#### refCategory:
- Description: Details for refUrl for the intent transaction being registered, whether it is 01 (Advertisement), 02(Invoice)
- Tags: String, optional

#### merchantCustomerId:
- Description: Merchant generated unique profile id for customer
- Tags: String, Optional

#### udfParameters:
- Description: Merchant Defined Parameters

**Example** : "{\"udf1\":\"value1\",\"udf2\":\"value2\",…}"**Note** : Few special characters are not allowed. Regex for the characters which are not allowed : **^[^/#-()*!%~`]+$** 
- Tags: Stringified JSON, Optional
### Mutual funds params:

#### mutualFundDetails:
- Description: Contains details of Mutual Funds
- Value:
  - **MemberId**:
    - Description: Member Id with ICCL or ARN_RIA with RTA
    - Tags: String, Mandatory
  - **UserId**:
    - Description: Client Id with ICCL or USER_CODE with RTA
    - Tags: String, Mandatory
  - **MfPartner**:
    - Description: One of the below;**Constraints:** NSE, BSE, KFIN, CAMS
    - Tags: String, Mandatory
  - **FolioNumber**:
    - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting
    - Tags: String, optional
  - **OrderNumber**:
    - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA
    - Tags: String, Mandatory
  - **Amount**:
    - Description: Individual MF amount within the array of MF being purchased.
      
      (Amount in two decimals. Decimals are mandatory)
    - Tags: String, Mandatory
  - **SchemeCode**:
    - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting
    - Tags: String, optional
  - **AmcCode**:
    - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting
    - Tags: String, optional
  - **PanNumber**:
    - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting
    - Tags: String, optional
  - **InvestmentType**:
    - Description: One of the below; 
      
      **Constraints:** LUMPSUM, SIP
    - Tags: String, Mandatory
- Tags: Json String, Mandatory
### TPV Params:

#### payerAccountHashes:
- Description: Hashed value of accounts to be passed by merchant for TPV.

**Hashing logic** **:** 

payerAccountHash = sha256( account Number + first 4 digit of account IFSC)From account Number the leading zeros should be removed and then the hash should be calculated.Eg: Account No. = 0000123456789 & IFSC = ABCD0000345

Hash will be calculated on 123456789ABCD.
- Value: value
- Tags: Array of String, conditional
## API Responses:
### 200:

#### status:
- Description: PSP status of the API.
- Value: Values: SUCCESS | FAILURE.
- Tags: Mandatory, String

#### responseCode:
- Description: PSP response code for the API.

**Values:**  Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### responseMessage:
- Description: PSP response message for the API.

**Values:**  Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### payload:
- Value:
  - **MerchantId**:
    - Description: Unique id for the merchant as passed in request headers.
    - Tags: String, Mandatory
  - **MerchantChannelId**:
    - Description: Unique id for the merchant channel as passed in request headers.
    - Tags: String, Mandatory
  - **GatewayTransactionId**:
    - Description: Gateway transaction id to be used for the intent transaction.
    - Tags: String, Mandatory
  - **OrderId**:
    - Description: Transaction refernce to be used for the intent transaction.
    - Tags: String, Mandatory
  - **PayeeVpa**:
    - Description: Payee VPA to be used for the intent transaction.
    - Tags: String, Optional
  - **PayeeName**:
    - Description: Payee name to be used for the intent transaction.
    - Tags: String, Mandatory
  - **PayeeMcc**:
    - Description: Payee mcc to be used for the intent transaction.
    - Tags: String, Optional
  - **Amount**:
    - Description: Amount to be used for the intent transaction.
    - Tags: String, Mandatory
  - **Currency**:
    - Description: Currency to be used for the intent transaction.
    - Tags: String, Optional
  - **Remarks**:
    - Description: Remarks to be used for the intent transaction.
    - Tags: String, optional
  - **Flow**:
    - Description: In order to differentiate between transactions and mandates. It can take the values as TRANSACTION or MANDATE.
    - Tags: String, Mandatory
  - **MutualFundDetails**:
    - Description: Contains details of Mutual Funds (as passed in the request).
    - Value:
      - **MemberId**:
        - Description: Member Id with ICCL or ARN_RIA with RTA.
        - Tags: String, Mandatory
      - **UserId**:
        - Description: Client Id with ICCL or USER_CODE with RTA.
        - Tags: String, Mandatory
      - **MfPartner**:
        - Description: One of the below;**Values:** NSE, BSE, KFIN, CAMS.
        - Tags: String, Mandatory
      - **FolioNumber**:
        - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **OrderNumber**:
        - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA.
        - Tags: String, Mandatory
      - **Amount**:
        - Description: Individual MF amount within the array of MF being purchased.
        - Tags: String, Mandatory
      - **SchemeCode**:
        - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **AmcCode**:
        - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **PanNumber**:
        - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **InvestmentType**:
        - Description: One of the below;
          
          **Values:**  LUMPSUM, SIP.
        - Tags: String, Mandatory
    - Tags: String, Optional
  - **PayerAccountHashes**:
    - Description: As passed in the request body.
    - Tags: Array of String, conditional
  - **RefUrl**:
    - Description: Reference URL to be used for the intent transaction.
    - Tags: String, optional
  - **RefCategory**:
    - Description: Reference URL category to be used for the intent transaction.
    - Tags: String, optional
  - **MerchantCustomerId**:
    - Description: Merchant generated unique profile id for customer
    - Tags: String, Optional
  - **MerchantRequestId**:
    - Description: Merchant generated id for the transaction
    - Tags: String, Mandatory
- Tags: Json, Mandatory

#### udfParameters:
- Description: Udf parameters as passed in the request.
- Tags: Json String, optional


---

## API Version: V1


# Merchant Register Intent



This api can be used to register intent for a payment. The response parameters should be used to construct deeplink url. Refer below table for mapping of response parameters to the deeplink url parameters.


| Response Parameter | Deeplink URL Parameter | Type |
|---|---|---|
| payeeVpa   | pa | Mandatory |
| payeeName  | pn | Mandatory |
| payeeMcc  | mc | Mandatory |
| gatewayTransactionId  | tid | Mandatory |
| orderId | tr | Mandatory |
| amount | am | Mandatory |
| currency | cu | Mandatory |
| remarks  | tn | Optional |
| refUrl  | url | Optional |
| refCategory  | category | Optional |



#### **Sample Deeplink URL** 



upi://pay?pa=swiggytest@yespay&pn=Swiggy&mc=5812&tid=YJP5566ca9ca6e64e76ba07c2d545f25&tr=swiggy567172772271&am=1.0&cu=INR&tn=Pay%20for%20Intent**Host URLs for IOS:** Gpay : [tez://upi/pay](tez://upi/pay)?PhonePe : [phonepe://pay](phonepe://pay)?Paytm : [paytmmp://pay](paytmmp://pay)?Cred : [credpay://upi/pay](credpay://upi/pay)?BHIM : [bhim://pay](bhim://pay)?

Merchant can then construct the URI and invoke the APP using chrome intent feature. It can also be used for generating the Dynamic UPI QR & display on Merchant App/Website for users to scan & pay from any UPI App.

> **Note**
> 1. In the URI spaces are replaced by "%20". Kindly generate the intent URI dynamically ie, based on the params received in the response.
> 2. If **refUrl**  is passed in request, **refCategory**  becomes essential for the API to work. So it's either both as combination or none.




### **Mutual Fund Use case:** 



Mutual Fund information using which the file to be shared with ICCL needs to be created to be passed in this API as a JSON (Refer request params & API format below).


### **TPV Use case:** 



For TPV (Third Party Validation) payerAccountHashes needs to be passed in the request body and the same will be passed back in response along with corresponding values. PayerAccountHashes will be taken as an array so that merchants can send multiple account hashes which will be verified against the account details selected by user shared by NPCI.

PSP will reject the request if the customer makes the payment with a different account details and send a failure callback to the merchant.## Endpoints:
- Production: {{host}}/api/{{uri}}/merchants/transactions/registerIntent

## Request Type: 
POST

## Headers:

#### jpupi-routing-id:
Header value should be same as of merchantRequestId sent in request body
- Tags: String, Mandatory
## Sample Code Snippets:
### Code Snippets:

#### Shell Code Snippet:

```shell
curl -L -X POST '{{host}}/api/{{uri}}/merchants/transactions/registerIntent' \
-H 'content-type: application/json' \
-H 'x-merchant-id: TEST' \
-H 'x-merchant-channel-id: TESTAPP' \
-H 'x-timestamp: 1700158230380' \
-H 'jpupi-routing-id: ord50894574' \
-H 'x-api-version: 1' \
--data-raw '{ 
    "signature":"kHeeZD0f3E...",
    "payload":"eyJtZXJjaG...",
    "protected":"eyJhbGciOi..."
}'
```

### Sample Request and Response:

#### Request:
```json
{
  "merchantRequestId": "ord50894574",
  "amount": "2.00",
  "intentRequestExpiryMinutes": "10",
  "payerAccountHashes": [
    "ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"
  ],
  "mutualFundDetails": [
    {
      "memberId": "ABCDE",
      "userId": "ABCDEFGHIJ",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983010",
      "orderNumber": "order_zer12345",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIUI",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    },
    {
      "memberId": "ERTYU",
      "userId": "VTYUIOPFT",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983011",
      "orderNumber": "order_zer12346",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIFT",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    }
  ],
  "remarks": "Payment for order",
  "refUrl": "www.xyz.com",
  "refCategory": "01",
  "udfParameters": "{}"
}
```

#### Response:
```json
{
  "status": "SUCCESS",
  "responseCode": "SUCCESS",
  "responseMessage": "SUCCESS",
  "payload": {
    "merchantId": "TEST",
    "merchantChannelId": "TESTAPP",
    "merchantRequestId": "ord50894574",
    "gatewayTransactionId": "TXNef1a2908395239df56663244f8c7deaa",
    "orderId": "ord50894574",
    "payeeVpa": "merchant@xyz",
    "payeeName": "John Doe",
    "payeeMcc": "1520",
    "amount": "2.00",
    "currency": "INR",
    "payerAccountHashes": ["ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"],
    "mutualFundDetails": [
        {
          "memberId": "ABCDE",
          "userId": "ABCDEFGHIJ",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983010",
          "orderNumber": "order_zer12345",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIUI",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        },
        {
          "memberId": "ERTYU",
          "userId": "VTYUIOPFT",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983011",
          "orderNumber": "order_zer12346",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIFT",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        }
      ],
      "remarks": "Payment for order",
      "refUrl": "www.xyz.com",
      "refCategory": "01"
    },
    "udfParameters": "{}"
  }
```

## Body Parameters:
### Basic Params:

#### merchantRequestId:
- Description: Merchant generated id for the transaction.

**Constraint:** Max**** 35 characters alphanumeric, can also contain hyphen(-), dot(.) & underscore(_)
- Tags: String, Mandatory

#### upiRequestId:
- Description: Unique id sent to UPI switch for the transaction.

**Constraint** :**** 35 character alphanumeric.
- Tags: String, Optional

#### amount:
- Description: Amount of intent transaction being registered.

**Constraint:** Amount in two decimals. Decimals are mandatory.
- Tags: String, Mandatory

#### intentRequestExpiryMinutes:
- Description: Minutes for which intent is valid. If this value is not passed, the default value will be used from merchant configurations. if both of them aren't available, intent will never expire.

**Constraint:** number > 0 (as string).
- Tags: String, optional

#### remarks:
- Description: Remarks for the intent transaction being registered.
- Tags: String, optional

#### refUrl:
- Description: Reference url for the intent transaction being registered.
- Tags: String, optional

#### refCategory:
- Description: Details for refUrl for the intent transaction being registered, whether it is 01 (Advertisement), 02(Invoice).
- Tags: String, optional

#### merchantCustomerId:
- Description: Merchant generated unique profile id for customer
- Tags: String, Optional

#### udfParameters:
- Description: Merchant Defined Parameters

**Example** : "{\"udf1\":\"value1\",\"udf2\":\"value2\",…}"**Note** : Few special characters are not allowed. Regex for the characters which are not allowed : **^[^/#-()*!%~`]+$** 
- Tags: Stringified JSON, optional
### Mutual funds params:

#### mutualFundDetails:
- Description: Contains details of Mutual Funds.
- Value:
  - **MemberId**:
    - Description: Member Id with ICCL or ARN_RIA with RTA.
    - Tags: String, Mandatory
  - **UserId**:
    - Description: Client Id with ICCL or USER_CODE with RTA.
    - Tags: String, Mandatory
  - **MfPartner**:
    - Description: One of the below;**Constraints:** NSE, BSE, KFIN, CAMS.
    - Tags: String, Mandatory
  - **FolioNumber**:
    - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **OrderNumber**:
    - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA.
    - Tags: String, Mandatory
  - **Amount**:
    - Description: Individual MF amount within the array of MF being purchased.
      
      (Amount in two decimals. Decimals are mandatory).
    - Tags: String, Mandatory
  - **SchemeCode**:
    - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **AmcCode**:
    - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **PanNumber**:
    - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **InvestmentType**:
    - Description: One of the below; 
      
      **Constraints:** LUMPSUM, SIP.
    - Tags: String, Mandatory
- Tags: Json String, optional
### TPV Params:

#### payerAccountHashes:
- Description: Hashed value of accounts to be passed by merchant for TPV.

**Hashing logic** **:** 

payerAccountHash = sha256( account Number + first 4 digit of account IFSC)From account Number the leading zeros should be removed and then the hash should be calculated.Eg: Account No. = 0000123456789 & IFSC = ABCD0000345

Hash will be calculated on 123456789ABCD.
- Value: value
- Tags: Array of String, Optional
## API Responses:
### 200:

#### status:
- Description: PSP status of the API.
- Value: Values: SUCCESS | FAILURE.
- Tags: Mandatory, String

#### responseCode:
- Description: PSP response code for the API.

**Values:**  Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### responseMessage:
- Description: PSP response message for the API.

**Values:**  Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### payload:
- Value:
  - **MerchantId**:
    - Description: Unique id for the merchant as passed in request headers.
    - Tags: String, Mandatory
  - **MerchantChannelId**:
    - Description: Unique id for the merchant channel as passed in request headers.
    - Tags: String, Mandatory
  - **GatewayTransactionId**:
    - Description: Gateway transaction id to be used for the intent transaction.
    - Tags: String, Mandatory
  - **OrderId**:
    - Description: Transaction refernce to be used for the intent transaction.
    - Tags: String, Mandatory
  - **PayeeVpa**:
    - Description: Payee VPA to be used for the intent transaction.
    - Tags: String, Optional
  - **PayeeName**:
    - Description: Payee name to be used for the intent transaction.
    - Tags: String, Mandatory
  - **PayeeMcc**:
    - Description: Payee mcc to be used for the intent transaction.
    - Tags: String, Optional
  - **Amount**:
    - Description: Amount to be used for the intent transaction.
    - Tags: String, Mandatory
  - **Currency**:
    - Description: Currency to be used for the intent transaction.
    - Tags: String, Optional
  - **Remarks**:
    - Description: Remarks to be used for the intent transaction.
    - Tags: String, optional
  - **MutualFundDetails**:
    - Description: Contains details of Mutual Funds (as passed in the request).
    - Value:
      - **MemberId**:
        - Description: Member Id with ICCL or ARN_RIA with RTA.
        - Tags: String, Mandatory
      - **UserId**:
        - Description: Client Id with ICCL or USER_CODE with RTA.
        - Tags: String, Mandatory
      - **MfPartner**:
        - Description: One of the below;**Values:** NSE, BSE, KFIN, CAMS.
        - Tags: String, Mandatory
      - **FolioNumber**:
        - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **OrderNumber**:
        - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA.
        - Tags: String, Mandatory
      - **Amount**:
        - Description: Individual MF amount within the array of MF being purchased.
        - Tags: String, Mandatory
      - **SchemeCode**:
        - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **AmcCode**:
        - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **PanNumber**:
        - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting.
        - Tags: String, optional
      - **InvestmentType**:
        - Description: One of the below; 
          
          **Values:** LUMPSUM, SIP.
        - Tags: String, Mandatory
    - Tags: String, Optional
  - **PayerAccountHashes**:
    - Description: As passed in the request body.
    - Tags: Array of String, conditional
  - **RefUrl**:
    - Description: Reference URL to be used for the intent transaction.
    - Tags: String, optional
  - **RefCategory**:
    - Description: Reference URL category to be used for the intent transaction.
    - Tags: String, optional
  - **MerchantCustomerId**:
    - Description: Merchant generated unique profile id for customer
    - Tags: String, Optional
  - **MerchantRequestId**:
    - Description: Merchant generated id for the transaction
    - Tags: String, Mandatory
- Tags: Json, Mandatory

#### udfParameters:
- Description: Udf parameters as passed in the request.
- Tags: Json String, optional


---

## API Version: Default


# Merchant Register Intent



This api can be used to register intent for a payment. The response parameters should be used to construct deeplink url. Refer below table for mapping of response parameters to the deeplink url parameters.


| Response Parameter | Deeplink URL Parameter | Type |
|---|---|---|
| payeeVpa | pa | Mandatory |
| payeeName | pn | Mandatory |
| payeeMcc | mc | Mandatory |
| gatewayTransactionId | tid | Mandatory |
| orderId | tr | Mandatory |
| amount | am | Mandatory |
| currency | cu | Mandatory |
| remarks | tn | Optional |
| refUrl | url | Optional |
| refCategory | category | Optional |



#### **Sample Deeplink URL** 



upi://pay?pa=swiggytest@yespay&pn=Swiggy&mc=5812&tid=YJP5566ca9ca6e64e76ba07c2d545f25&tr=swiggy567172772271&am=1.0&cu=INR&tn=Pay%20for%20Intent**Host URLs for IOS:** Gpay : [tez://upi/pay](tez://upi/pay)?PhonePe : [phonepe://pay](phonepe://pay)?Paytm : [paytmmp://pay](paytmmp://pay)?Cred : [credpay://upi/pay](credpay://upi/pay)?BHIM : [bhim://pay](bhim://pay)?

Merchant can then construct the URI and invoke the APP using chrome intent feature. It can also be used for generating the Dynamic UPI QR & display on Merchant App/Website for users to scan & pay from any UPI App.

> **Note**
> 1. In the URI spaces are replaced by "%20". Kindly generate the intent URI dynamically ie, based on the params received in the response.
> 2. If **refUrl**  is passed in request, **refCategory**  becomes essential for the API to work. So it's either both as combination or none.




### **Mutual Fund Use case:** 



Mutual Fund information using which the file to be shared with ICCL needs to be created to be passed in this API as a JSON (Refer request params & API format below).


### **TPV Use case:** 



For TPV (Third Party Validation) payerAccountHashes needs to be passed in the request body and the same will be passed back in response along with corresponding values. PayerAccountHashes will be taken as an array so that merchants can send multiple account hashes which will be verified against the account details selected by user shared by NPCI.

PSP will reject the request if the customer makes the payment with a different account details and send a failure callback to the merchant.## Endpoints:
- Production: {{host}}/api/{{uri}}/merchants/transactions/registerIntent

## Request Type: 
POST

## Headers:

#### jpupi-routing-id:
Header value should be same as of merchantRequestId sent in request body
- Tags: String, Mandatory
## Sample Code Snippets:
### Code Snippets:

#### Shell Code Snippet:

```shell
curl -L -X POST '{{host}}/api/{{uri}}/merchants/transactions/registerIntent' \
-H 'content-type: application/json' \
-H 'x-merchant-id: TEST' \
-H 'x-merchant-channel-id: TESTAPP' \
-H 'x-timestamp: 1700158230380' \
-H 'jpupi-routing-id: ord50894574' \
--data-raw '{ 
    "signature":"kHeeZD0f3E...",
    "payload":"eyJtZXJjaG...",
    "protected":"eyJhbGciOi..."
}'
```

### Sample Request and Response:

#### Request:
```json
{
  "merchantRequestId": "ord50894574",
  "amount": "2.00",
  "intentRequestExpiryMinutes": "10",
  "payerAccountHashes": [
    "ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"
  ],
  "mutualFundDetails": [
    {
      "memberId": "ABCDE",
      "userId": "ABCDEFGHIJ",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983010",
      "orderNumber": "order_zer12345",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIUI",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    },
    {
      "memberId": "ERTYU",
      "userId": "VTYUIOPFT",
      "mfPartner": "BSE/NSE/CAMS/KFIN",
      "folioNumber": "190983011",
      "orderNumber": "order_zer12346",
      "amount": "5000.00",
      "schemeCode": "LT",
      "amcCode": "UYTIFT",
      "panNumber": "TYLIO7823U",
      "investmentType": "LUMPSUM/SIP"
    }
  ],
  "remarks": "Payment for order",
  "refUrl": "www.xyz.com",
  "refCategory": "01",
  "udfParameters": "{}"
}
```

#### Response:
```json
{
  "status": "SUCCESS",
  "responseCode": "SUCCESS",
  "responseMessage": "SUCCESS",
  "payload": {
    "merchantId": "TEST",
    "merchantChannelId": "TESTAPP",
    "merchantRequestId": "ord50894574",
    "gatewayTransactionId": "TXNef1a2908395239df56663244f8c7deaa",
    "orderId": "ord50894574",
    "payeeName": "John Doe",
    "payerAccountHashes": ["ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330dd2ff3a674","ef907b670f92ba102daeadb0a9ea347c44bde9f4340e9330ddaka"],
    "mutualFundDetails": [
        {
          "memberId": "ABCDE",
          "userId": "ABCDEFGHIJ",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983010",
          "orderNumber": "order_zer12345",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIUI",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        },
        {
          "memberId": "ERTYU",
          "userId": "VTYUIOPFT",
          "mfPartner": "BSE/NSE/CAMS/KFIN",
          "folioNumber": "190983011",
          "orderNumber": "order_zer12346",
          "amount": "5000.00",
          "schemeCode": "LT",
          "amcCode": "UYTIFT",
          "panNumber": "TYLIO7823U",
          "investmentType": "LUMPSUM/SIP"
        }
      ]
    },
    "udfParameters": "{}"
  }
```

## Body Parameters:
### Basic Params  :

#### merchantRequestId:
- Description: Merchant generated id for the transaction.

**Constraint:** Max**** 35 characters alphanumeric, can also contain hyphen(-), dot(.) & underscore(_)
- Tags: String, Mandatory

#### amount:
- Description: Amount of intent transaction being registered.

**Constraint:** Amount in two decimals. Decimals are mandatory.
- Tags: String, Optional but Mandatory for new Integration

#### intentRequestExpiryMinutes:
- Description: Minutes for which intent is valid. It should be <= order fulfilment time.

**Constraint:** number > 0
- Tags: String, Optional But Mandatory For New Integration

#### flow:
- Description: Used to differentiate between transactions and mandates. 

Values: TRANSACTION or MANDATE
- Tags: String, Optional But Mandatory For New Integration

#### refUrl:
- Description: Reference url for the intent transaction being registered.
- Tags: String, optional

#### refCategory:
- Description: Details for refUrl for, whether it is 01 (Advertisement), 02(Invoice).
- Tags: String, optional

#### remarks:
- Description: Remarks for the intent transaction being registered.
- Tags: String, Optional

#### iat:
- Description: Current Epoch Unix timestamp string. Has to be of 13 digit in Milliseconds.

Example: 1496918882000.
- Tags: String, Mandatory

#### udfParameters:
- Description: Merchant Defined Parameters.

Example: "{\"udf1\":\"value1\",\"udf2\":\"value2\",…}"**Note** : Few special characters are not allowed. Regex for the characters which are not allowed : **^[^/#-()*!%~`]+$** 
- Tags: stringified json, Optional
### Mutual Funds Params:

#### mutualFundDetails:
- Description: Contains details of Mutual Funds.
- Value:
  - **MemberId**:
    - Description: Member Id with ICCL or ARN_RIA with RTA.
    - Tags: String, Mandatory
  - **UserId**:
    - Description: Client Id with ICCL or USER_CODE with RTA.
    - Tags: String, Mandatory
  - **MfPartner**:
    - Description: One of the below;**Constraints:** NSE, BSE, KFIN, CAMS.
    - Tags: String, Mandatory
  - **FolioNumber**:
    - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **OrderNumber**:
    - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA.
    - Tags: String, Mandatory
  - **Amount**:
    - Description: Individual MF amount within the array of MF being purchased.
      
      (Amount in two decimals. Decimals are mandatory).
    - Tags: String, Mandatory
  - **SchemeCode**:
    - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **AmcCode**:
    - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **PanNumber**:
    - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting.
    - Tags: String, optional
  - **InvestmentType**:
    - Description: One of the below; 
      
      **Constraints:** LUMPSUM, SIP.
    - Tags: String, Mandatory
- Tags: Json String, optional
### TPV Params:

#### payerAccountHashes:
- Description: Hashed value of accounts to be passed by merchant for TPV. 

**Hashing logic** **:** 

payerAccountHash = sha256( account Number + first 4 digit of account IFSC)From account Number the leading zeros should be removed and then the hash should be calculated.Eg: Account No. = 0000123456789 & IFSC = ABCD0000345

Hash will be calculated on 123456789ABCD.
- Value: value
- Tags: Array of String, conditional
## API Responses:
### 200:

#### status:
- Description: PSP status of the API.
- Value: Values: SUCCESS | FAILURE.
- Tags: Mandatory, String

#### responseCode:
- Description: PSP response code for the API.

**Values:**  Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### responseMessage:
- Description: PSP response message for the API.

**Values:**  Refer Codes Guide in Resource Section.
- Tags: Mandatory, String

#### payload:
- Value:
  - **MerchantId**:
    - Description: Unique id for the merchant as passed in request headers.
    - Tags: String, Mandatory
  - **MerchantChannelId**:
    - Description: Unique id for the merchant channel as passed in request headers.
    - Tags: String, Mandatory
  - **GatewayTransactionId**:
    - Description: Gateway transaction id to be used for the intent transaction.
    - Tags: String, Mandatory
  - **OrderId**:
    - Description: Transaction refernce to be used for the intent transaction.
    - Tags: String, Mandatory
  - **PayeeVpa**:
    - Description: Payee VPA to be used for the intent transaction.
    - Tags: String, Optional
  - **PayeeName**:
    - Description: Payee name to be used for the intent transaction.
    - Tags: String, Mandatory
  - **PayeeMcc**:
    - Description: Payee mcc to be used for the intent transaction.
    - Tags: String, Optional
  - **Amount**:
    - Description: Amount to be used for the intent transaction.Constraint: Amount in two decimals. Decimals are mandatory.
    - Tags: String, Optional
  - **Currency**:
    - Description: Currency to be used for the intent transaction.
    - Tags: String, Optional
  - **Remarks**:
    - Description: Remarks to be used for the intent transaction.
    - Tags: String, optional
  - **MutualFundDetails**:
    - Description: Contains details of Mutual Funds (as passed in the request).
    - Value:
      - **MemberId**:
        - Description: Member Id with ICCL or ARN_RIA with RTA
        - Tags: String, Mandatory
      - **UserId**:
        - Description: Client Id with ICCL or USER_CODE with RTA
        - Tags: String, Mandatory
      - **MfPartner**:
        - Description: One of the below;NSE, BSE, KFIN, CAMS
        - Tags: String, Mandatory
      - **FolioNumber**:
        - Description: Folio Number of the MF, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **OrderNumber**:
        - Description: Unique order number of each MF. Oder Number in ICCL or APPL_NO in RTA
        - Tags: String, Mandatory
      - **Amount**:
        - Description: Individual MF amount within the array of MF being purchased.
        - Tags: String, Mandatory
      - **SchemeCode**:
        - Description: Scheme Code of the MF, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **AmcCode**:
        - Description: AMC Code of the MF, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **PanNumber**:
        - Description: PAN Number of the user, used for RTA reporting. Mandatory for RTA reporting
        - Tags: String, optional
      - **InvestmentType**:
        - Description: One of the below; LUMPSUM, SIP
        - Tags: String, Mandatory
    - Tags: String, Optional
  - **PayerAccountHashes**:
    - Description: As passed in the request body.
    - Tags: Array of String, conditional
  - **RefUrl**:
    - Description: Reference URL to be used for the intent transaction.
    - Tags: String, optional
  - **RefCategory**:
    - Description: Reference URL category to be used for the intent transaction.
    - Tags: String, optional
  - **MerchantCustomerId**:
    - Description: Merchant generated unique profile id for customer
    - Tags: String, Optional
  - **MerchantRequestId**:
    - Description: Merchant generated unique id for collect request.
      
      **Constraint** : Max 35 characters & Alphanumeric.
    - Tags: String, Mandatory
- Tags: Json, Mandatory

#### udfParameters:
- Description: Merchant Defined Parameters

Example: "{\"udf1\":\"value1\",\"udf2\":\"value2\",…}"
- Tags: Stringified JSON, optional


---

## See Also

- [Web Collect 360](https://juspay.io/in/docs/upi-merchant-stack/docs/transactions/web-collect-360)
- [Transaction Status 360](https://juspay.io/in/docs/upi-merchant-stack/docs/transactions/transaction-status-360)
