Skip to content

BloFin

Obtaining the API Key

Danger

Do NOT use the same API key that you have created for other services.

To get the API keys for your BloFin account, follow these steps:

  1. Log in to your BloFin account
  2. Click the profile icon in the top right corner
  3. Click API from the dropdown menu
  4. Click + Create API Key

    BloFin Create API Key button

  5. Click Application Name and choose HAAS from the list

  6. Enter a descriptive name for your API key
  7. Check the Trade box to enable trading permissions
  8. Enter a secure passphrase

    BloFin API creation form with Application Name, name field, Trade permissions, and passphrase

    Info

    Make sure to store your passphrase securely. You will need it when configuring the API in HaasOnline.

  9. Enter the IP address:

    • If you are running an TradeServer license, use the IP address of your machine/server
    • If you are trading on HaasOnline TradeServer Cloud, enter the IP address shown in the HaasOnline UI during exchange account setup
  10. Click Next

  11. Confirm your password and complete the 2FA authentication

Once the API key is created, you will see your API credentials displayed on the screen.

Warning

Make sure to copy both your API Key and Secret Key immediately. The Secret Key will only be shown once.

Keep this page open and proceed to add the credentials to your HaasOnline TradeServer.

Adding the API to HaasOnline TradeServer

Log in to your HaasOnline TradeServer.

Navigate to the Exchange Accounts page (user menu in the top right, then Exchange Accounts). The Adding an API to the Platform guide shows these first steps with screenshots.

  1. Click the + button at the bottom of the accounts list (on an empty page it reads Add account)
  2. Select Exchange account
  3. In Connect an exchange account, click BloFin
  4. Under What should this account trade?, choose BloFin SPOT for spot trading, or BloFin COIN / BloFin USDT under Derivatives for the coin- and USDT-margined perpetual futures, then click the Continue with … button, which names the market you picked. Each is a separate exchange account, so add one for every market you want to trade. If you don't have a BloFin account yet, the Register button in the setup form takes you to BloFin's sign-up page

    What should this account trade, with BloFin SPOT selected and BloFin COIN and BloFin USDT under Derivatives.

  5. Enter an Account name

  6. Paste your API Key from BloFin into the API Key field
  7. Paste your API Secret from BloFin into the Secret Key field
  8. Enter the Passphrase you created in BloFin

    BloFin SPOT account setup form with the IP whitelist, account name, API key, secret key and passphrase fields.

    Info

    Make sure there are no extra spaces at the beginning or end of the keys when pasting.

  9. Click Test keys to verify the connection

  10. If the test passes, click Save account to add the account to the platform

Your BloFin exchange account is now connected and ready to use with HaasOnline!