You can use sub-accounts when you need to integrate more than one website using the same account. To enable this feature, you must ask the EBANX Integration Team at integration@ebanx.com.

This feature is available in both Direct API and Checkout Request.

Direct API

In addition to enabling this feature within EBANX, you must also send a new object:

payment.sub_account

JSON object, required

An object containing the sub account’s name. Required for payments where the sub-account feature is being used.

payment.sub_account.name

string, Length: 32, required

Name of the sub-account that will be showed in the cash payment and e-mails.

payment.sub_account.image_url

string, Length: 200, required

URL of the logo of the sub-account. PS: It MUST be an HTTPS URL. Otherwise, you will receive an error message.

An example request is as follows:

Checkout Request

In addition to enabling this feature within EBANX, you must also send two new parameters:

sub_acc_name

string, Length: 32, required

Name of the sub-account.

sub_acc_image_url

string, Length: 200, required

URL of the logo of the sub-account. PS: It MUST be an HTTPS URL. Otherwise, you will receive an error message.

An example request is as follows:

curl -X POST 'https://sandbox.ebanx.com/ws/request' \
    -d 'integration_key=your_test_integration_key' \
    -d 'name=José Silva' \
    -d 'email=josesilva@example.com' \
    -d 'country=br' \
    -d 'payment_type_code=boleto' \
    -d 'merchant_payment_code=d59cb7166e7' \
    -d 'currency_code=BRL' \
    -d 'amount=100'\
    -d 'sub_acc_name=Merchant+Test+Name'\
    -d 'sub_acc_image_url=https://www.colourbox.com/preview/9155263-store-front.jpg'