HyBridge
  • Getting Started
    • What is HyBridge?
    • How It Works: Swap (Crypto to Hyperliquid)
    • How It Works: Buy (Fiat to Hyperliquid)
    • API
    • API Widget
    • Points
    • Fee
    • New Users on Hyperliquid
Powered by GitBook
On this page
  1. Getting Started

API Widget

πŸ”Œ Embedding the HyBridge Widget

You can embed the HyBridge widget on any website with a simple <iframe> tagβ€”no SDKs or back-end code required. Everything is configurable via URL parameters.


βœ… Basic Example

<iframe
  src="https://v2.hybridge.xyz/?widget=1
       &primary=%23000000
       &text-colour=%23000000
       &border-radius=0
       &paper-bg=%23ffffff
       &border-width=1px
       &border-colour=%23000000
       &input-bg=%23ffffff
       &font-family=georgia"
  width="350"
  height="500"
  style="border:none;overflow:hidden;"
  scrolling="no"
  allowfullscreen>
</iframe>

🎨 Customise the Look & Feel

Pass any of the parameters below as query-string pairs to tailor the widget to your brand. Hex values must be URL-encoded (e.g. #000000 β†’ %23000000).

Parameter
Purpose
Example Value

primary

Accent / button colour (hex)

%23000000

text-colour

Main text colour (hex)

%23000000

paper-bg

Widget background (hex)

%23ffffff

input-bg

Input-field background (hex)

%23ffffff

border-colour

Outline colour (hex)

%23000000

border-width

Outline thickness (any CSS unit)

1px

border-radius

Corner radius (any CSS unit)

8px, 1rem, 0

font-family

Font stack (web-safe or pre-loaded)

georgia, arial


πŸ’Έ Optional Referral-Fee Support

Earn a share of every transfer that passes through your embed by adding two extra parameters:

Parameter
Purpose
Example

referralFee

Percentage fee (0 – 100, decimal form)

0.01 (0.01 %)

referralAddress

Wallet address that receives referral earnings

0xYourWalletAddress

<iframe
  src="https://v2.hybridge.xyz/?widget=1
       &referralFee=0.01
       &referralAddress=0xabc123...
       &primary=%23000000"
  width="350"
  height="500"
  style="border:none;"
  scrolling="no"
  allowfullscreen>
</iframe>

πŸ“ Recommended Size Width: 350px Height: 500px You can adjust these values depending on your layout.

PreviousAPINextPoints

Last updated 13 days ago