Tutorial to create an OKX API key

Tutorial to Create API Key in OKX

Step 1: Log in to your OKX account

  1. Go to the OKX website and log in with your user details.
  2. Complete any additional security verification (such as 2FA authentication with Google Authenticator or SMS) if enabled on your account.

Step 2: Access API Settings

  1. Once you're logged into your account, click on your profile icon in the top right corner.
  2. Select the “API” option from the drop-down menu to access the API management section.

Step 3: Create a New API Key

  1. On the API page, select “Create API.”
  2. Give your API a name (for example, “Trading Bot”).
  3. Enter a Passphrase. This phrase is unique and will be used to connect third-party applications to your API, so be sure to remember it.

Step 4: Configure API Permissions

  1. Read-Only Permissions: Select this option if you only want the API to have access to your account information.
  2. Trading Permissions: If you want the bot or app to be able to operate on your account, enable this option.
  3. Withdraw permission: Do not activate this option.
  4. Advice: Select only the necessary permissions (read and trade) and avoid the withdrawal permission for added security.

Step 5: Configure IP Restrictions (NOT APPLICABLE)

OKX allows you to restrict API access to specific IP addresses, a recommended option for security reasons.
  1. If you have a fixed IP address for the device or server that will use the API, add it to the “IP Whitelist” section.
  2. This will limit the API's use to that specific IP, protecting it from unauthorized access.

Step 6: Complete the Security Check

  1. OKX will ask you to verify the API creation using security authentication:
    • SMS or email verification code: OKX will send a confirmation code to your email or phone.
    • Google Authenticator (2FA) Code: Enter the generated code into your authenticator app if it's enabled.
  2. Complete this verification and click Confirm.

Step 7: Save the API Key and API Secret

  1. Once verification is complete, OKX will generate your API Key and API Secret.
  2. Keep this information in a safe place, as the secret key will only be displayed once. Write it down or store it in a password manager.
Important Note: Never share your API key or API secret with anyone, and don't store them in insecure locations.

Step 8: Connect the API to your BULL TRADING BOT Trading Bot

  1. Use the API Key, API Secret, and Security Phrase you set up to connect to the API on your BTB using the corresponding form found in your Bull Trade Bot profile.
  2. Follow the app or bot's instructions for secure setup and verify that permissions and the connection are correct.

Step 9: Check API Status and Test (Optional)

  1. Once you've connected the API, verify that it's working properly.
  2. Once you submit your API key, the system will have 48 hours to notify you whether it has been accepted or rejected; you will be notified via email.
  3. If possible, test with small orders to confirm that the API is configured properly before using it for regular transactions.

Additional Safety Tips

  • Don't share the API with third parties; use it only for BTB.
  • Disable the API if you don't plan to use it immediately or for a while.
  • Review permissions periodically to ensure they haven't changed.
en_USEnglish
Scroll to Top