Customization

Reconfiguring the exchange

Like setting up the exchange initially, we provide two ways to reconfigure the exchange: the web exchange configurator through bitHolla Dashboard and command-line exchange configurator through HollaEx CLI. We highly recommend using the web exchange configurator to make data at bitHolla Dashboard always up-to-date.

Through Web Exchange Configurator

Once you are done with reconfiguring your exchange and downloaded settings files from bitHolla Dashboard, You should import the downloaded files into your HollaEx Kit. You can use hollaex import command to import them.

hollaex import --path <DOWNLOADED_SETTINGS_FILE(S)>

Once they get imported, make sure to run hollaex restart to apply them on your exchange. This step requires a full restart of the exchange, so be cautious.

hollaex restart (--kube)

Through Command-Line Exchange Configurator

hollaex setup --reconfigure

You can also reconfigure your exchange by using HollaEx CLI command. Once it's all done, make sure to run hollaex restart to apply them on your exchange. This step requires a full restart of the exchange, so be cautious.

hollaex restart (--kube)

Language and Localization

ENVIRONMENT_WEB_DEFAULT_COUNTRY=KR
HOLLAEX_CONFIGMAP_EMAILS_TIMEZONE=Asia/Seoul
HOLLAEX_CONFIGMAP_VALID_LANGUAGES=en,ko
HOLLAEX_CONFIGMAP_NEW_USER_DEFAULT_LANGUAGE=ko

To set the country, timezone, valid languages, and default language for your exchange, either edit these values in your settings/configmap file or run the hollaex setup --reconfigure command.

HollaEx Kit currently officially supports English and Korean.

Check here to see more details for settings up these values.

Currencies & Trading Pairs

Exchange will restart after running the commands below.

Adding

After the exchange initialization, you can add currencies and trading pairs using the HollaEx Cli. The commands for adding a new currency and new trading pair are shown below. Similar to hollaex launch, these commands will bring up an interaction form. Each prompt will have a default value enclosed in parentheses located to its right. Hit enter to go with the default value. Otherwise, type in a value of your choosing.

HollaEx CLI commands:

hollaex toolbox --add_coin
hollaex toolbox --add_trading_pair

Initial Coin Values

  • Coin Symbol The trading symbol for your new coin.

  • Full Name of Coin The full name of the coin.

  • Allow Deposit Enable/disable deposits for this coin.

  • Allow Withdrawal Enable/disable withdrawals for this coin.

  • Fee for Withdrawal The fee amount for when this coin is withdrawn from your exchange.

  • Minimum Price The minimum withdrawal for this coin.

  • Maximum Price The maximum withdrawal for this coin.

  • Increment Amount The minimum numerical quantity this coin's amount increments and decrements.

  • Deposit limit of user level 'x' Set the coin's deposit limit amount for the user level 'x'.

    • HollaEx CLI will ask you to input the deposit limit for every user level.

    • Value 0 means deposits are unlimited, -1 means they are disabled.

  • Withdrawal limit of user level 'x' Set the coin's withdrawal limit amount for the user level 'x'.

    • HollaEx CLI will ask you to input the withdrawal limit for every user level.

    • Value 0 means withdrawals are unlimited, -1 means they are disabled.

  • Activate Coin Enable/disable activation for this coin.

Initial Trading Pair Values

  • Name of new Trading Pair The trading pair symbol.

    • Formatted as <BASE_CURRENCY>-<QUOTE_CURRENCY> e.g. eth-usdt .

  • Taker fee of user level 'x' The trade taker fee for user level 'x' .

    • HollaEx CLI will ask you to input the taker fee for every user level.

    • The taker fees you input are read as a percentage by the system i.e. 1 = 1%. Do not include the percentage sign when inputing these values.

  • Maker fee of user level 'x' The trade maker fee for user level 'x' .

    • HollaEx CLI will ask you to input the maker fee for every user level.

    • The maker and taker fees you input are read as a percentage by the system i.e. 1 = 1%. Do not include the percentage sign when inputing these values.

  • Minimum Amount The minimum amount that can be traded for this pair.

  • Maximum Amount The maximum amount that can be traded for this pair.

  • Minimum Price The minimum price that can be traded for this pair.

  • Maximum Price The maximum price that can be traded for this pair.

  • Increment Amount The minimum numerical quantity this pair's trade amount increments and decrements.

  • Increment Price The minimum numerical quantity this pair's trade price increments and decrements.

  • Activate Enable/disable activation for this trading pair.

Removing

You can also remove currencies and trading pairs with the commands below.

hollaex toolbox --remove_coin
hollaex toolbox --remove_trading_pair

Database Credentials

You can set your own database credentials for the exchange on settings/secret file.

HOLLAEX_SECRET_DB_USERNAME=hollaex
HOLLAEX_SECRET_DB_PASSWORD=hollaex

By default, both username and password are set as hollaex. You should change these values for production.

HOLLAEX_SECRET_INFLUX_DB=hollaex
HOLLAEX_SECRET_INFLUX_USER=hollaex
HOLLAEX_SECRET_INFLUX_PASSWORD=hollaex

Setting up credentials for InfluxDB is also available. You can input custom values in settings/secret.

HOLLAEX_SECRET_REDIS_PASSWORD=hollaex
HOLLAEX_SECRET_PUBSUB_PASSWORD=hollaex

You can modify these values to set password for Redis access.

Email

You should have some basic knowledge of Javascript and HTML before customizing your emails.

HollaEx-Kit allows you to customize your exchange's email content and structure. The /mail directory contains all you need to customize your emails.

The /mail directory contains two subdirectories: /strings and /templates. The /strings directory is responsible for the actual content (strings) of all your emails. The /templates directory is responsible for the layout and design of your emails. Read on to learn how to customize your exchange's email strings and/or templates.

You must save modified files and run hollaex restart to apply customizations you've made.

Strings

How it works

Your /strings directory contains en, ko, and index. You should ignore index and instead focus on the other files. Have a look in en for English email content and ko for Korean email content.

These files contain JS objects that hold the content of the emails being sent. The object names are related to the action or event that triggers them to be sent. For example, theSIGNUP object contains the content of the email your exchange sends after a new user signs up; the WITHDRAWAL object contains the content of the email your exchange sends after a user performs a withdrawal, etc. All email objects contain a TITLE, GREETING, BODY, and CLOSING.

  • TITLE refers to the title of the email sent.

  • GREETING is the first line of the email sent (Dear...).

  • BODY contains the body of the message.

  • CLOSING is the last line of the email (Regards, ...)

There are three email objects (CONTACTFORM, USERVERIFICATION, SUSPICIOUSDEPOSIT) that do not contain a GREETING and a CLOSING.These are only sent to your exchange's support account email for notification purposes.

Customization

If you only want to customize the existing content of your emails without adding new lines, simply modify the strings within the en or ko files.

To add a new line to a BODY, just add a new value to the BODY object. The new value's key should be equal to the last key of BODY + 1. For example, if the BODY has three lines, the new line's key should be 4. To have this new line show up, you would also have to add the new line into the corresponding template file.

Templates

How it works

Each file in the /templates directory contains the HTML and raw text structure of the email being sent. The name of these files represent the action or event that triggers them to be sent. For example, login contains the structure of the email sent after a user logs in and deposit contains the structure of the email sent after a user makes a deposit.

Each of these files contain an html and text function. html returns a string that represents the HTML format of your email. text returns a string that represents the raw text data of your email.

Customization

If you wish to change the HTML structure of your emails, simply rewrite the string being returned by the html function. Make sure to follow correct HTML syntax to avoid any unwanted bugs.

If you added a new line to the BODY section of a template's corresponding string object, add the line to both html and text functions. To do this, you would need to know the key of the new line within the BODY object. For example, if you added a new line in BODY with the key 4, you can refer to it via{<TEMPLATE_NAME>.BODY[4]}.

Theme changes (should move to setup advanced)

HOLLAEX_CONFIGMAP_DEFAULT_THEME=dark

You can select theme for web client by editing this value on settings/configmap file or by running the hollaex setup --reconfigure command.

Supported Values :

  • dark

  • light

Web

Go to our Web Customization tab to learn how to customize your web client.

Nginx

By default, HollaEx CLI generates Nginx configurations automatically based on user's settings values. Generated files would be stored at templates/local/nginx .

You can add your own snippets templates/local/nginx/nginx.conf.

Rate limits

limit_req_zone $remote_addr zone=api:1m rate=4r/s;

In templates/local/nginx/nginx.conf, you can see and modify your rate limit setups based on your needs. Check here to see details how Nginx rate limit works.

  • Both for generic v1 and /order URL endpoints, By default they got 10 burst.