Wirex Hosted KYC

Collect basic user data and let users complete KYC verification through Wirex's hosted flow.

Before You Start

Read the following guides before proceeding:

GuideWhy
Getting StartedPlatform overview and setup
Api BasicsRequired headers and request configuration
AuthenticationHow to obtain access tokens
WebhooksReceive status notifications
OnboardingUser and wallet registration
User ProfileUser capabilities and status

When to Use

  • You want Wirex to handle KYC verification
  • You collect minimal user data at registration
  • Users will complete identity verification in the Wirex interface

Registration Methods

Two registration endpoints are available depending on your authentication flow:

MethodEndpointAuth Flow
S2S RegistrationPOST /api/v2/userS2S token (backend-to-backend)
Privy RegistrationPOST /api/v1/user/retailPrivy-based auth (frontend)

Option A: S2S Registration

For backend-to-backend integration using S2S tokens.

POST /api/v2/user
{
  "user_address": "0xA7E41d5680dE394EaA2ed417169DFf56840Fb3EE",
  "initial_data": {
    "profile": {
      "email": "[email protected]"
    },
    "residence_address": {
      "country": "GB"
    }
  }
}

Important: The user_address must be the user's EOA address (the signer), not the Smart Wallet address.

user_address replaces the former wallet_address. Both are accepted; if both are supplied they must match. New integrations should send user_address.

FieldTypeRequiredValidation
user_addressstringYesUser's EOA address
initial_data.profile.emailstringYesValid email format, must be unique
initial_data.residence_address.countrystringYesISO 3166-1 alpha-2 code

Always send residence_address.country: capabilities and the verification token depend on it, and it
cannot be added afterwards.

Option B: Privy Registration

For partners using Privy authorization flow. The email and the wallet come from the Privy identity token,
not from the body.

POST /api/v1/user/retail
{
  "country": "GB"
}
FieldTypeRequiredValidation
countrystringNoISO 3166-1 alpha-2 code. Omitted, it defaults to the country of the caller's IP address

See User Registration with Privy for the full
request.


Code Examples (S2S Registration)

async function registerUserHostedKYC(accessToken, userAddress, email, country, chainId, baseUrl) {
  const response = await fetch(`${baseUrl}/api/v2/user`, {
    method: 'POST',
    headers: {
      'Authorization': `Bearer ${accessToken}`,
      'Content-Type': 'application/json',
      'X-Chain-Id': chainId.toString(),
    },
    body: JSON.stringify({
      user_address: userAddress,
      initial_data: {
        profile: { email },
        residence_address: { country },
      },
    }),
  });

  if (!response.ok) {
    const error = await response.json();
    throw new Error(`Registration failed: ${error.error_description}`);
  }

  return response.json();
}

// Usage
const { id } = await registerUserHostedKYC(
  access_token,
  '0xA7E41d5680dE394EaA2ed417169DFf56840Fb3EE',
  '[email protected]',
  'GB',
  8453,
  'https://api-baas.wirexapp.com'
);
import requests

def register_user_hosted_kyc(access_token, user_address, email, country, chain_id, base_url):
    response = requests.post(
        f"{base_url}/api/v2/user",
        headers={
            "Authorization": f"Bearer {access_token}",
            "Content-Type": "application/json",
            "X-Chain-Id": str(chain_id),
        },
        json={
            "user_address": user_address,
            "initial_data": {
                "profile": {"email": email},
                "residence_address": {"country": country},
            },
        },
    )
    response.raise_for_status()
    return response.json()

# Usage
user = register_user_hosted_kyc(
    access_token,
    "0xA7E41d5680dE394EaA2ed417169DFf56840Fb3EE",
    "[email protected]",
    "GB",
    8453,
    "https://api-baas.wirexapp.com"
)
func RegisterUserHostedKYC(accessToken, userAddress, email, country string, chainID int, baseURL string) (string, error) {
    reqBody, _ := json.Marshal(map[string]interface{}{
        "user_address": userAddress,
        "initial_data": map[string]interface{}{
            "profile":           map[string]string{"email": email},
            "residence_address": map[string]string{"country": country},
        },
    })

    req, _ := http.NewRequest("POST", baseURL+"/api/v2/user", bytes.NewBuffer(reqBody))
    req.Header.Set("Authorization", "Bearer "+accessToken)
    req.Header.Set("Content-Type", "application/json")
    req.Header.Set("X-Chain-Id", fmt.Sprintf("%d", chainID))

    resp, err := http.DefaultClient.Do(req)
    if err != nil {
        return "", err
    }
    defer resp.Body.Close()

    var result struct{ ID string `json:"id"` }
    json.NewDecoder(resp.Body).Decode(&result)
    return result.ID, nil
}

Flow

sequenceDiagram
    participant App as Your App
    participant BaaS as Wirex API
    participant SumSub

    App->>BaaS: 1. POST /api/v2/user or /api/v1/user/retail
    BaaS-->>App: { id }

    App->>BaaS: 2. POST /verification-link or /verification-token
    BaaS-->>App: { redirect_uri } or { token }

    App->>SumSub: 3. User completes KYC (redirect or SDK)

    SumSub->>BaaS: 4. Verification result
    Note over BaaS: 5. Account activated

    BaaS->>App: POST /webhook/users (verification_status)

KYC Completion Options

After registration, the user must complete KYC verification. Two options are available:

OptionEndpointUse Case
Verification LinkPOST /api/v1/user/verification-linkRedirect user to hosted SumSub widget
SDK TokenPOST /api/v1/user/verification-tokenEmbed SumSub SDK in your app

Option A: Verification Link

Redirect the user to a hosted SumSub widget where they complete all KYC steps.

POST /api/v1/user/verification-link

Response:

{
  "redirect_uri": "https://in.sumsub.com/idensic/l/#/HA0Z3b34F9YfWxhQ"
}

Open redirect_uri in a browser or webview. The user completes verification in the hosted interface.

Option B: SDK Token

Obtain a token to initialize the SumSub SDK within your application.

POST /api/v1/user/verification-token

Response:

{
  "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}

Use this token to initialize the SumSub WebSDK or Mobile SDK in your frontend. For integration details, see the SumSub SDK documentation.

To show the WebSDK with your logo, colors and fonts, see WebSDK Customization.

Verification Level

Both endpoints accept an optional body that selects the verification level the SumSub flow runs at:

{
  "verification_level": "XDDBridgeBase"
}
FieldTypeRequiredDescription
verification_levelstringNoBDD, SDD, XDDBridgeBase or EDD. Omitted, the flow runs at SDD
LevelContents
BDDUser information and identity documents
SDDBDD plus address verification
XDDBridgeBaseSDD plus tax identification number. Required for ACH accounts
EDDAdditional checks on the user

The documents the SDK accepts are listed in Supported Identity Documents
and Supported Proof of Address Documents.

Take the level to request from the verification_requirements of the capability the user needs, returned by
GET /api/v2/user.

Trap: an omitted or unrecognised verification_level falls back to SDD without an error.

SDK: sdk.api.baas.user.getVerificationToken() and getVerificationLink() send an empty body, so they
always run at SDD. For any other level, call the REST endpoint directly.


WebSDK Customization

The SumSub WebSDK can be styled to match your brand: logo, colors, fonts, buttons, form controls and some
screens. Wirex sets up the styles in the SumSub dashboard from the values you provide and sends you the
customization name. Pass that name in the customizationName parameter when you initialize the WebSDK, and
the WebSDK renders with your styles. The same customizationName works in sandbox and production.

1. You send brand values to Wirex
        ↓
2. Wirex sets up the styles in the SumSub dashboard
        ↓
3. Wirex sends you the customization name
        ↓
4. You pass customizationName in WebSDK withConf

Scope

Applies toCustomizable
WebSDK embedded with a token from POST /api/v1/user/verification-token (Option B)Yes, through customizationName
Verification link from POST /api/v1/user/verification-link (Option A)No. The endpoint takes no customization parameter
SumSub Mobile SDK (iOS, Android, React Native, Flutter)Not covered by this customization. Theme the Mobile SDK in your app code, see SumSub Mobile SDK customization

The customization changes how the WebSDK looks. It does not change the verification level, the documents
requested or the verification result. Registration, token issuance and webhooks work as described above.

What Can Be Customized

Wirex sets up the customization in the SumSub dashboard. The dashboard has six tabs: General, Logo and colors,
Texts, Images, Buttons and Other. The screenshots below show each tab with its default values. The phone preview
on the right shows how the WebSDK renders with those values.

General settings apply to both themes. Every setting on the other five tabs is set separately for the light
theme and the dark theme. The Default column lists the light theme defaults.

General

ParameterFormatDefault
Theme modelight, dark or light_and_darklight_and_dark
Service nameTextNot set
Supported languagesList of ISO 639-1 codesNot set
Skip warning screentrue or falsefalse
Skip welcome screentrue or falsefalse
Skip instructions screentrue or falsefalse
Enable confirmation screentrue or falsefalse
Skip document type selection screentrue or falsefalse
Hide button Verify nowtrue or falsefalse
Hide button Send to emailtrue or falsefalse
Hide button Copy linktrue or falsefalse
Force mobile devicestrue or falsefalse
Disable continuing on mobiletrue or falsefalse
Hide header progress bartrue or falsefalse
Hide language selectortrue or falsefalse

Trap: with no service name set, the warning screen reads "Wirex App" verification and tells the user
they are submitting data to "Wirex App". Set the service name to your product name so users see the
name they recognize.

Logo and Colors

ParameterFormatDefault
LogoPNG or JPG, max 512 KBNot set. The SumSub logo is shown
Widget backgroundColor#FFFFFF 100%
Page backgroundColor#FFFFFF 100%
Accent colorColor#20252B 100%
Neutral colorColor#20252B 100%
Info colorColor#143BFF 100%
Success colorColor#008C60 100%
Error colorColor#D12424 100%
Warning colorColor#BF8300 100%

Status colors are used in alerts, verification statuses, tip icons and other system messages.

Texts

ParameterFormatDefault
Heading alignmentleft, center or rightleft
Header 1Font, weight, size, colorManrope, Semi Bold, 24 px, #20252B 100%
Header 2Font, weight, size, colorManrope, Bold, 16 px, #20252B 100%
Header 3Font, weight, size, colorManrope, Semi Bold, 16 px, #20252B 100%
Body textFont, weight, size, colorManrope, Medium, 16 px, #20252B 100%
CaptionFont, weight, size, colorManrope, Medium, 14 px, #20252B 70%

Images

ParameterFormatDefault
Main colorColor#143BFF 100%
Secondary colorColor#FFFFFF 100%
Background colorColor#EDEEF2 100%
Background corner radiusRadius28
Step icons: step number colorColor#20252B 100%
Step icons: border colorColor#FFFFFF 100%
Step icons: backgroundtrue or falsetrue
Step icons: background colorColor. Applies when background is true#20252B 5%
Step icons: background corner radiusRadius. Applies when background is true12
Status icons: info colorColor#143BFF 100%
Status icons: success colorColor#008C60 100%
Status icons: warning colorColor#BF8300 100%
Status icons: error colorColor#D12424 100%

Status icon colors start from the status colors on the Logo and colors tab. Set them only if your icons need
different colors from your alerts.

Buttons

ParameterFormatDefault
All buttons: font, weight, sizeFont, weight, sizeManrope, Semi Bold, 16 px
All buttons: vertical paddingSize11
All buttons: corner radiusRadius32
Primary: background colorColor#20252B 100%
Primary: border colorColor#FFFFFF 0%
Primary: border widthSize0
Primary: font colorColor#FFFFFF 100%
Primary: shadowtrue or falsefalse
Secondary: background colorColor#FFFFFF 100%
Secondary: border colorColor#20252B 30%
Secondary: border widthSize1
Secondary: font colorColor#20252B 100%
Secondary: shadowtrue or falsefalse
Link: font colorColor#143BFF 100%

The primary button is the main call to action, such as Continue in the preview. Secondary buttons are
alternative actions. Link buttons are text-only actions.

Other

ParameterFormatDefault
Form controls: background colorColor#FFFFFF 100%
Form controls: border colorColor#20252B 30%
Form controls: border widthSize1
Form controls: corner radiusRadius16
Checkboxes and radio buttons: item active colorColor#20252B 100%
Checkboxes and radio buttons: item background colorColor#FFFFFF 100%
Widget border: colorColor#20252B 30%
Widget border: widthSize1
Widget border: corner radiusRadius32

Form control settings apply to inputs, selects, radio buttons, checkboxes and alerts.

Value Formats

Send every value in the format below. Wirex enters the values into the SumSub dashboard as you send them.

FormatRuleExample
ColorHex color #RRGGBB (6 digits, case-insensitive) followed by opacity in percent, an integer from 0 to 100#0055FF 100%, #20252B 30%
SizeInteger, in pixels16
RadiusInteger, in pixels, from 0 to 3212
FontFont family name from the SumSub font list, a weight and a size in pixelsManrope, Semi Bold, 16
LogoPNG or JPG file, max 512 KB. One file per themelogo-light.png

Color rules:

  • Send colors as 6-digit hex. Convert RGB, HSL, CMYK, Pantone and color names to hex before sending.
  • Do not encode opacity in the hex value. 8-digit hex (#RRGGBBAA) and 3-digit shorthand (#FFF) are not
    accepted. Send the opacity as a separate percentage.
  • 0% opacity makes the element invisible. Use it to hide a border, as the primary button default does with
    #FFFFFF 0%.
  • When the theme mode is light_and_dark, send a value for each theme. Check the contrast of text and button
    colors against the widget background in both themes.

What to Send to Wirex

Send the following to your Wirex integration engineer:

ItemRequiredNotes
Theme modeYeslight, dark or light_and_dark
Service nameYesYour product name, shown on the warning screen
LogoYesOne file per theme. Provide a separate dark theme logo if your logo does not show on a dark background
Brand colorsYesWidget background, page background, accent and neutral colors, per theme
Any other parameter from the tables aboveNoParameters you omit keep their defaults
Website URLNoThe SumSub dashboard can import styles from a website as a starting point

Request Template

The template below lists every parameter with its light theme default. Copy it, change the values you want
to customize, and remove the rest. This is a request template for Wirex, not an API payload.

{
  "service_name": "Your App",
  "theme_mode": "light_and_dark",
  "supported_languages": ["en"],
  "screens": {
    "skip_warning_screen": false,
    "skip_welcome_screen": false,
    "skip_instructions_screen": false,
    "enable_confirmation_screen": false,
    "skip_document_type_selection_screen": false,
    "hide_verify_now_button": false,
    "hide_send_to_email_button": false,
    "hide_copy_link_button": false,
    "force_mobile_devices": false,
    "disable_continuing_on_mobile": false,
    "hide_header_progress_bar": false,
    "hide_language_selector": false
  },
  "light": {
    "logo": "logo-light.png",
    "brand_colors": {
      "widget_background": "#FFFFFF 100%",
      "page_background": "#FFFFFF 100%",
      "accent": "#20252B 100%",
      "neutral": "#20252B 100%"
    },
    "status_colors": {
      "info": "#143BFF 100%",
      "success": "#008C60 100%",
      "error": "#D12424 100%",
      "warning": "#BF8300 100%"
    },
    "texts": {
      "heading_alignment": "left",
      "header_1": { "font": "Manrope", "weight": "Semi Bold", "size": 24, "color": "#20252B 100%" },
      "header_2": { "font": "Manrope", "weight": "Bold", "size": 16, "color": "#20252B 100%" },
      "header_3": { "font": "Manrope", "weight": "Semi Bold", "size": 16, "color": "#20252B 100%" },
      "body_text": { "font": "Manrope", "weight": "Medium", "size": 16, "color": "#20252B 100%" },
      "caption": { "font": "Manrope", "weight": "Medium", "size": 14, "color": "#20252B 70%" }
    },
    "images": {
      "main_color": "#143BFF 100%",
      "secondary_color": "#FFFFFF 100%",
      "background_color": "#EDEEF2 100%",
      "background_corner_radius": 28,
      "step_icons": {
        "step_number_color": "#20252B 100%",
        "border_color": "#FFFFFF 100%",
        "background": true,
        "background_color": "#20252B 5%",
        "background_corner_radius": 12
      },
      "status_icons": {
        "info": "#143BFF 100%",
        "success": "#008C60 100%",
        "warning": "#BF8300 100%",
        "error": "#D12424 100%"
      }
    },
    "buttons": {
      "font": "Manrope",
      "weight": "Semi Bold",
      "size": 16,
      "vertical_padding": 11,
      "corner_radius": 32,
      "primary": {
        "background_color": "#20252B 100%",
        "border_color": "#FFFFFF 0%",
        "border_width": 0,
        "font_color": "#FFFFFF 100%",
        "shadow": false
      },
      "secondary": {
        "background_color": "#FFFFFF 100%",
        "border_color": "#20252B 30%",
        "border_width": 1,
        "font_color": "#20252B 100%",
        "shadow": false
      },
      "link": {
        "font_color": "#143BFF 100%"
      }
    },
    "other": {
      "form_controls": {
        "background_color": "#FFFFFF 100%",
        "border_color": "#20252B 30%",
        "border_width": 1,
        "corner_radius": 16
      },
      "checkboxes_and_radio_buttons": {
        "item_active_color": "#20252B 100%",
        "item_background_color": "#FFFFFF 100%"
      },
      "widget_border": {
        "color": "#20252B 30%",
        "width": 1,
        "corner_radius": 32
      }
    }
  },
  "dark": {}
}
KeyDescription
service_name, theme_mode, supported_languages, screensGeneral tab. Apply to both themes
lightLight theme values. Required when theme_mode is light or light_and_dark
darkDark theme values, with the same keys as light. Required when theme_mode is dark or light_and_dark

Use the Customization

Pass customizationName in withConf when you build the WebSDK instance. The token comes from
POST /api/v1/user/verification-token, called by your backend.

import snsWebSdk from '@sumsub/websdk';

// accessToken: the `token` returned by POST /api/v1/user/verification-token
// getNewAccessToken: calls your backend, which calls the same endpoint again
const snsWebSdkInstance = snsWebSdk
  .init(accessToken, () => getNewAccessToken())
  .withConf({
    lang: 'en',
    // 'light' or 'dark'; omit to follow the device theme
    theme: 'light',
    // value received from Wirex
    customizationName: 'partner_brand_web',
  })
  .withOptions({ addViewportTag: false, adaptIframeHeight: true })
  .on('idCheck.onError', (error) => {
    console.error('WebSDK error', error);
  })
  .build();

snsWebSdkInstance.launch('#sumsub-websdk-container');
FieldTypeRequiredDescription
customizationNamestringRequired to apply the customizationExact name sent by Wirex. Omitted, the WebSDK uses the default style
themestringNolight or dark. Must be a theme included in your customization. Omitted, the WebSDK follows the device theme
langstringNoISO 639-1 language code. Defaults to en

The WebSDK is a browser component, so the example is JavaScript only. The backend call that issues the token
is the same as in Option B.

Trap: customizations work only with WebSDK 2.0 (@sumsub/websdk 2.x). WebSDK 1.0 does not support
customizationName.

Trap: pass customizationName exactly as Wirex sends it. Open the widget in sandbox and check it
renders with your branding before going live.

Theme: when the customization covers both themes, set theme to match your page. Pass only a theme
your customization includes.

For the full list of withConf options and WebSDK events, see the
SumSub WebSDK documentation.


What Happens Next

  1. User completes identity verification (document upload, selfie, etc.)
  2. SumSub sends verification result to Wirex
  3. Wirex sends a webhook to your endpoint with updated verification_status
  4. User account is activated upon successful verification

The user cannot perform restricted operations (card issuance, fiat withdrawals) until KYC is approved.

For webhook payload details, see User Onboarding - Webhooks.

Phone Number: The phone number the user enters in the SumSub form is stored on the profile and automatically marked as confirmed. It will be used for 3DS Authentication OTP codes and Read Card Details OTP verification. No separate confirmation step is required.


Error Handling

Validation Errors

Validation failures are returned as ErrorGeneral Request failed validation, with the field path as the
error_details key:

error_details keyMessageRequirement
user_addressUser address is invalid, must match: …EVM 0x + 40 hex, Stellar G…/C…, XRPL r… or Tron T…
initial_data.profile.emailEmail is invalid or missing^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$
initial_data.residence_address.countryCountry is invalid or missing, must be a valid ISO 3166-1 alpha-2 country code^[A-Z]{2}$

Registration Errors

Error ReasonDescriptionResolution
ErrorNotFoundWallet not registered in Accounts contractComplete on-chain registration first
ErrorAlreadyExistsEmail already existsUse a different email address
ErrorAlreadyExistsWallet address already existsUser already registered

Error Response Format

{
  "error_reason": "ErrorGeneral",
  "error_description": "Request failed validation",
  "error_category": {
    "category": "CategoryValidationFailure",
    "http_status_code": 400
  },
  "error_details": [
    { "key": "initial_data.profile.email", "details": "Email is invalid or missing" }
  ]
}

Did this page help you?