A virtual bank account is a unique account number which is generated so you don’t need to share your sensitive bank account details with your users. A virtual bank account can be paid with ACH credit or wire transfer. Users can make payment of the amount due to this account, and the amount will be matched with the invoice.
Sample virtual bank account [ JSON ]
{
"account_number": "test_544b835aab71",
"bank_name": "TEST BANK",
"created_at": 1517501395,
"customer_id": "__test__KyVnHhSBWSv7Y5F",
"deleted": false,
"email": "apple@apple.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSvqH5J",
"object": "virtual_bank_account",
"reference_id": "cus_I57FgHUl6NNqeT/src_1HUx14Jv9j0DyntJqopyd9ax",
"resource_version": 1517501395000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501395
}
string, max chars=40
Identifier of the virtual bank account
string, max chars=50
Identifier of the customer.
string, max chars=70
Email address associated with the virtual bank account
optional, enumerated string, default=ach_credittype of the credit transfer
Possible values are
ach_creditACH Credit Transfer.sepa_creditSEPA Credit Transfer.
optional, string, max chars=100
Name of the bank
string, min chars=5, max chars=50
The account number to which funds will be transferred.
optional, string, min chars=9, max chars=50
The routing number of the bank
string, min chars=8, max chars=11
Swift code of the bank in which the account exists.
enumerated stringName of the gateway this virtual bank account is stored in.
Possible values are
chargebeeChargebee test gateway.chargebee_paymentsChargebee Payments gateway.stripeStripe is a payment gateway.wepayWePay is a payment gateway.braintreeBraintree is a payment gateway.authorize_netAuthorize.net is a payment gateway.paypal_proPayPal Pro Account is a payment gateway.pinPin is a payment gateway.ewayeWAY Account is a payment gateway.eway_rapideWAY Rapid is a payment gateway.worldpayWorldPay is a payment gateway.balanced_paymentsBalanced is a payment gateway.beanstreamBambora(formerly known as Beanstream) is a payment gateway.bluepayBluePay is a payment gateway.elavonElavon Virtual Merchant is a payment solution.first_data_globalFirst Data Global Gateway Virtual Terminal Account.hdfcHDFC Account is a payment gateway.migsMasterCard Internet Gateway Service payment gateway.nmiNMI is a payment gateway.ogoneIngenico ePayments (formerly known as Ogone) is a payment gateway.paymillPAYMILL is a payment gateway.paypal_payflow_proPayPal Payflow Pro is a payment gateway.sage_paySage Pay is a payment gateway.tco2Checkout is a payment gateway.wirecardWireCard Account is a payment service provider.amazon_paymentsAmazon Payments is a payment service provider.paypal_express_checkoutPayPal Express Checkout is a payment gateway.gocardlessGoCardless is a payment service provider.adyenAdyen is a payment gateway.orbitalChase Paymentech(Orbital) is a payment gateway.moneris_usMoneris USA is a payment gateway.monerisMoneris is a payment gateway.bluesnapBlueSnap is a payment gateway.cybersourceCyberSource is a payment gateway.vantivVantiv is a payment gateway.checkout_comCheckout.com is a payment gateway.paypalPayPal Commerce is a payment gateway.ingenico_directWorldline Online Payments is a payment gateway.exactExact Payments is a payment gateway.mollieMollie is a payment gateway.quickbooksIntuit QuickBooks Payments gateway.razorpayRazorpay is a fast growing payment service provider in India working with all leading banks and support for major local payment methods including Netbanking, UPI etc.global_paymentsGlobal Payments is a payment service provider.bank_of_americaBank of America Gateway.ecentricEcentric provides a seamless payment processing service in South Africa specializing on omnichannel capabilities.not_applicableIndicates that payment gateway is not applicable for this resource.
Show all values[+]
string, max chars=50
The gateway account in which this virtual bank account is stored.
optional, long
Version number of this resource. The resource_version
is updated with a new timestamp in milliseconds for every change made to the resource. This attribute will be present only if the resource has been updated after 2016-09-28.
optional, timestamp(UTC) in seconds
Timestamp indicating when this virtual bank account resource was last updated.
timestamp(UTC) in seconds
Timestamp indicating when this virtual bank account resource is created.
string, max chars=150
Identifier provided by the gateway for the virtual bank account source. In case of Stripe, the reference_id consists of a combination of Stripe Customer ID and Stripe Source ID separated by a forward slash (e.g. cus_63MnDn0t6kfDW7/src_6WjCF20vT9WN1G).
boolean
Indicates that this resource has been deleted.
Creates a virtual bank account using the identifier provided by the gateway.
Notes
Customer's email and virtual bank accounts will always be in sync. Email ID specified for virtual bank account creation will be considered over customers’ email ID.
Sample Request
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/create_using_permanent_token \
-u {site_api_key}:\
-d customer_id="__test__KyVnHhSBWSv7Y5F" \
-d reference_id="cus_I57FgHUl6NNqeT/src_1HUx14Jv9j0DyntJqopyd9ax"
copy
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/create_using_permanent_token \
-u {site_api_key}:\
-d customer_id="__test__KyVnHhSBWSv7Y5F" \
-d reference_id="cus_I57FgHUl6NNqeT/src_1HUx14Jv9j0DyntJqopyd9ax"
Sample Response [ JSON ]
Show more...
{
"customer": {
"allow_direct_debit": false,
"auto_collection": "on",
"billing_address": {
"city": "Walnut",
"country": "US",
"first_name": "Mark",
"last_name": "Henry",
"line1": "PO Box 9999",
"object": "billing_address",
"state": "California",
"state_code": "CA",
"validation_status": "not_validated",
"zip": "91789"
},
"card_status": "no_card",
"created_at": 1517501394,
"deleted": false,
"email": "apple@apple.com",
"excess_payments": 0,
"first_name": "Mark",
"id": "__test__KyVnHhSBWSv7Y5F",
"last_name": "Henry",
"net_term_days": 0,
"object": "customer",
"pii_cleared": "active",
"preferred_currency_code": "USD",
"promotional_credits": 0,
"refundable_credits": 0,
"resource_version": 1517501395000,
"taxability": "taxable",
"unbilled_charges": 0,
"updated_at": 1517501395
},
"virtual_bank_account": {
"account_number": "test_544b835aab71",
"bank_name": "TEST BANK",
"created_at": 1517501395,
"customer_id": "__test__KyVnHhSBWSv7Y5F",
"deleted": false,
"email": "apple@apple.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSvqH5J",
"object": "virtual_bank_account",
"reference_id": "cus_I57FgHUl6NNqeT/src_1HUx14Jv9j0DyntJqopyd9ax",
"resource_version": 1517501395000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501395
}
}
URL Format POST
https://{site}.chargebee.com/api/v2/virtual_bank_accounts/create_using_permanent_token
required, string, max chars=50
Identifier of the customer.
required, string, max chars=150
Identifier provided by the gateway for the virtual bank account source. In case of Stripe, the reference_id consists of a combination of Stripe Customer ID and Stripe Source ID separated by a forward slash (e.g. cus_63MnDn0t6kfDW7/src_6WjCF20vT9WN1G).
optional, enumerated string, default=ach_credittype of the credit transfer.
Possible values are
ach_creditACH Credit Transfersepa_creditSEPA Credit Transfer
always returned
Resource object representing virtual_bank_account
optional
Resource object representing customer
Creates a virtual bank account for a customer. Email address is mandatory for virtual bank account creation. All notifications related to this virtual bank account will be sent to the email address you specify.
Notes
Customer's email and virtual bank accounts will always be in sync.
Sample Request
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts \
-u {site_api_key}:\
-d customer_id="__test__KyVnHhSBWSvsr5M" \
-d email="Duncan@ac.com"
copy
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts \
-u {site_api_key}:\
-d customer_id="__test__KyVnHhSBWSvsr5M" \
-d email="Duncan@ac.com"
Sample Response [ JSON ]
Show more...
{
"customer": {
"allow_direct_debit": false,
"auto_collection": "on",
"billing_address": {
"city": "Walnut",
"country": "US",
"first_name": "Duncan",
"last_name": "Walpole",
"line1": "PO Box 9999",
"object": "billing_address",
"state": "California",
"state_code": "CA",
"validation_status": "not_validated",
"zip": "91789"
},
"card_status": "no_card",
"created_at": 1517501395,
"deleted": false,
"email": "Duncan@ac.com",
"excess_payments": 0,
"first_name": "Duncan",
"id": "__test__KyVnHhSBWSvsr5M",
"last_name": "walpole",
"net_term_days": 0,
"object": "customer",
"pii_cleared": "active",
"preferred_currency_code": "USD",
"promotional_credits": 0,
"refundable_credits": 0,
"resource_version": 1517501395000,
"taxability": "taxable",
"unbilled_charges": 0,
"updated_at": 1517501395
},
"virtual_bank_account": {
"account_number": "test_5a576cb69dc2",
"bank_name": "TEST BANK",
"created_at": 1517501396,
"customer_id": "__test__KyVnHhSBWSvsr5M",
"deleted": false,
"email": "Duncan@ac.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSw7J5O",
"object": "virtual_bank_account",
"reference_id": "cus_I57FLcFhampr4H/src_1HUx16Jv9j0DyntJh6X59egJ",
"resource_version": 1517501396000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501396
}
}
URL Format POST
https://{site}.chargebee.com/api/v2/virtual_bank_accounts
required, string, max chars=50
Identifier of the customer.
optional, string, max chars=70
Email address associated with the virtual bank account.
optional, enumerated string, default=ach_credittype of the credit transfer.
Possible values are
ach_creditACH Credit Transfersepa_creditSEPA Credit Transfer
always returned
Resource object representing virtual_bank_account
optional
Resource object representing customer
Retrieves the virtual bank account identified by the unique identifier.
Sample Request
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/vba___test__KyVnHhSBWSxD05c \
-u {site_api_key}:
copy
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/vba___test__KyVnHhSBWSxD05c \
-u {site_api_key}:
Sample Response [ JSON ]
Show more...
{"virtual_bank_account": {
"account_number": "test_4fd6bbafe466",
"bank_name": "TEST BANK",
"created_at": 1517501401,
"customer_id": "__test__KyVnHhSBWSwxc5a",
"deleted": false,
"email": "Duncan@ac.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSxD05c",
"object": "virtual_bank_account",
"reference_id": "cus_I57F4k8pLWzIxn/src_1HUx1AJv9j0DyntJblhHJSXQ",
"resource_version": 1517501401000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501401
}}
URL Format GET
https://{site}.chargebee.com/api/v2/virtual_bank_accounts/{virtual_bank_account_id}
always returned
Resource object representing virtual_bank_account
Lists all the virtual bank accounts.
Sample Request
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts \
-G \
-u {site_api_key}:\
--data-urlencode limit=5
copy
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts \
-G \
-u {site_api_key}:\
--data-urlencode limit=5
Sample Response [ JSON ]
Show more...
{"list": [
{"virtual_bank_account": {
"account_number": "test_5a576cb69dc2",
"bank_name": "TEST BANK",
"created_at": 1517501396,
"customer_id": "__test__KyVnHhSBWSvsr5M",
"deleted": false,
"email": "Duncan@ac.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSw7J5O",
"object": "virtual_bank_account",
"reference_id": "cus_I57FLcFhampr4H/src_1HUx16Jv9j0DyntJh6X59egJ",
"resource_version": 1517501396000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501396
}},
{..}
]}
URL Format GET
https://{site}.chargebee.com/api/v2/virtual_bank_accounts
optional, integer, default=10, min=1, max=100
The number of resources to be returned.
optional, string, max chars=1000
Determines your position in the list for pagination. To ensure that the next page is retrieved correctly, always set offset
to the value of next_offset
obtained in the previous iteration of the API call.
optional, string filter
Identifier of the customer.
Supported operators : is, is_not, starts_with, in, not_in
Example → customer_id[is_not] = "3bdjnDnsdQn"
optional, timestamp(UTC) in seconds filter
Timestamp indicating when this virtual bank account resource was last updated.
Supported operators : after, before, on, between
Example → updated_at[after] = "1435054328"
optional, timestamp(UTC) in seconds filter
Timestamp indicating when this virtual bank account resource is created.
Supported operators : after, before, on, between
Example → created_at[after] = "1435054328"
always returned
Resource object representing virtual_bank_account
next_offset
optional, string, max chars=1000
This attribute is returned only if more resources are present. To fetch the next set of resources use this value for the input parameter “offset”.
Deletes a virtual bank account. If there is no virtual bank account present in the gateway for the customer, this API will return successfully without throwing an error.
Sample Request
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/vba___test__KyVnHhSBWSwNX5S/delete \
-X POST \
-u {site_api_key}:
copy
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/vba___test__KyVnHhSBWSwNX5S/delete \
-X POST \
-u {site_api_key}:
Sample Response [ JSON ]
Show more...
{"virtual_bank_account": {
"account_number": "test_ad9223150767",
"bank_name": "TEST BANK",
"created_at": 1517501397,
"customer_id": "__test__KyVnHhSBWSw9h5Q",
"deleted": true,
"email": "Duncan@ac.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSwNX5S",
"object": "virtual_bank_account",
"reference_id": "cus_I57FoRRoh1LtvC/src_1HUx17Jv9j0DyntJwz97BE6T",
"resource_version": 1517501397000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501397
}}
URL Format POST
https://{site}.chargebee.com/api/v2/virtual_bank_accounts/{virtual_bank_account_id}/delete
always returned
Resource object representing virtual_bank_account
Deletes virtual bank accounts from Chargebee. Payment method in the payment gateway, and Auto Collection settings in Chargebee are not affected.
Sample Request
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/vba___test__KyVnHhSBWSwuP5X/delete_local \
-X POST \
-u {site_api_key}:
copy
curl https://{site}.chargebee.com/api/v2/virtual_bank_accounts/vba___test__KyVnHhSBWSwuP5X/delete_local \
-X POST \
-u {site_api_key}:
Sample Response [ JSON ]
Show more...
{"virtual_bank_account": {
"account_number": "test_37dd91f91556",
"bank_name": "TEST BANK",
"created_at": 1517501399,
"customer_id": "__test__KyVnHhSBWSweW5V",
"deleted": true,
"email": "Duncan@ac.com",
"gateway": "stripe",
"gateway_account_id": "gw___test__KyVnGlSBWSv3GHt",
"id": "vba___test__KyVnHhSBWSwuP5X",
"object": "virtual_bank_account",
"reference_id": "cus_I57Fwosbo6LGbY/src_1HUx19Jv9j0DyntJeMYS2q0F",
"resource_version": 1517501399000,
"routing_number": "110000000",
"scheme": "ach_credit",
"swift_code": "TSTEZ122",
"updated_at": 1517501399
}}
URL Format POST
https://{site}.chargebee.com/api/v2/virtual_bank_accounts/{virtual_bank_account_id}/delete_local
always returned
Resource object representing virtual_bank_account