Integration Flow

Learn how to add beneficiaries to an account using ZWITCH APIs.

The figure below shows the steps involved to add a beneficiary to an account.

364

Beneficiary Integration Flow

Follow the below steps to add a beneficiary to your account.

  1. [Prerequisite] Create or Link Account: First, you must create a new account or link your existing current account to ZWITCH.
  2. Create Beneficiary: Next, add a beneficiary to your account.

1. Create or Link an Account

To add a beneficiary to your account. First, you need to create an account with ZWITCH or link your existing current account to ZWITCH.

Use our Account APIs to create an account with ZWITCH. Contact our integration team to link your current account with ZWITCH.

2. Create Beneficiary

To transfer money to an individual or an entity, account holders must add them to their account as a beneficiary. Currently, we support 2 types of beneficiaries:

2.1. Bank Account Beneficiary

This type of beneficiary is created using the account number and IFSC. This type of beneficiary supports transfers via NEFT, IMPS, and RTGS.

Bank account beneficiaries can be added to:

  • Savings accounts
  • Current accounts
  • Linked current accounts
  • Virtual account wallets

Use the below endpoint to create a bank account beneficiary.

POST: https://api.zwitch.io/v1/accounts/{account_id}/beneficiaries

Below is a sample request and response for Create Bank Account Beneficiary API.

{
  "type": "account_number",
  "name_of_account_holder": "Anil Reddy",
  "email": "[email protected]",
  "phone": "9876543210",
  "bank_account_number": "123455678901234",
  "bank_ifsc_code": "HDFC0000123",
  "bank_name": "hdfc",
  "metadata": {
    "key_1": "DD",
    "key_2": "XOF"
  }
}
{
  "id": "vab_cXjVBV6x1KdjPQHlNWlyAsiOq",
  "object": "beneficiary",
  "type": "account_number",
  "name_of_account_holder": "Anil Reddy",
  "email": "[email protected]",
  "phone": "9876543210",
  "bank_account_number": "123455678901234",
  "bank_ifsc_code": "HDFC0000123",
  "bank_name": "hdfc",
  "vpa": null,
  "metadata": {
    "key_1": "DD",
    "key_2": "XOF"
  },
  "created_at": 1656068124,
  "is_sandbox": false,
  "account_id": "va_0S2gghUY2wZqayy4Mw95M8zzQ"
}

Learn more about the Beneficiary API.

2.2. VPA (UPI ID) Beneficiary

This type of beneficiary is created using a VPA handle (UPI ID). This type of beneficiary supports transfers only via UPI.

This type of beneficiary can be added to:

  • Virtual account wallets

Use the below endpoint to create a VPA beneficiary

POST: https://api.zwitch.io/v1/accounts/{account_id}/beneficiaries

Below is a sample request and response for Create VPA Beneficiary API.

{
  "type": "vpa",
  "name_of_account_holder": "Anil Reddy",
  "email": "[email protected]",
  "phone": "9000000094",
  "vpa": "anilreddy@example",
  "metadata": {
    "key_1": "DD",
    "key_2": "XOF"
  }
}
{
  "id": "vab_TUmH9DBaM5u6mdsJPiQo8YiQZ",
  "object": "beneficiary",
  "type": "vpa",
  "name_of_account_holder": "Anil Reddy",
  "email": "[email protected]",
  "phone": "9000000094",
  "bank_account_number": null,
  "bank_ifsc_code": null,
  "bank_name": null,
  "vpa": "anilreddy@example",
  "metadata": {
    "key_1": "DD",
    "key_2": "XOF"
  },
  "created_at": 1656068144,
  "is_sandbox": false,
  "account_id": "va_0S2gghUY2wZqayy4Mw95M8zzQ"
}

Learn more about the Beneficiary API.