Skip to main content
Credible offers an embedded pre-qualification experience (an embeddable iframe) meant to sit natively on partner content. The user can complete the steps needed to reach pre-qualification and receive offers within the widget. Once a user selects an offer, they are redirected to Credible to provide additional details needed to continue the process.

Embedded Pre-Qualification Integration Guide

Personal Loans Embedded Prequal WidgetHTML Code (replace source value with the one provided by Credible):
<div id="personal-loan-embedded-prequal"> </div>
<script>
var script = document.createElement('script');
script.type = "text/javascript";
script.addEventListener("load", function(event) {
    CredibleSDK.initWidget('#personal-loan-embedded-prequal', {
                environment: 'production',
                product: {
                  marketplace: 'personal-loan',
                  type:  'embedded-prequal',
                },
                ui: {
                  theme: 'default',
                },
                analytics: {
                  source: 'example-source',
                },
              })
});
script.src = "https://sdk.credible.com/sdk.js";
document.getElementsByTagName('head')[0].appendChild(script);
</script>

Embedded Prequal - Advanced Capabilities

For teams that want a greater level of control over Credible’s embedded prequalification widgets, additional configuration is available for common partner needs:
  1. Custom Colors
  2. Passing Sub ID or Campaign ID
  3. Real-Time Events Tracking

Custom Colors

Partners can apply primaryColor and secondaryColor to embedded widgets. These values are applied as CSS variables and restyle components within the widget.
To apply primaryColor or secondaryColor, add customStyles under the ui config:
ui: {
  customStyles: {
    primaryColor: '#182265',
    secondaryColor: '#B9912D',
  }
},
The color values should be HEX format; values above are examples.
Full Code Example
<div id="personal-loan-embedded-prequal"></div>
<script>
var script = document.createElement('script');
script.type = "text/javascript";
script.addEventListener("load", function(event) {
    CredibleSDK.initWidget('#personal-loan-embedded-prequal', {
                environment: 'production',
                product: {
                  marketplace: 'personal-loan',
                  type:  'embedded-prequal',
                },
                ui: {
                  customStyles: {
                     primaryColor: '#182265',
                     secondaryColor: '#B9912D',
                  }
                },
                analytics: {
                  source: 'example-source',
                },
              })
});
script.src = "https://sdk.credible.com/sdk.js";
document.getElementsByTagName('head')[0].appendChild(script);
</script>

Passing Sub ID or Campaign ID

Partners often need to pass an internal tracking identifier (lead ID, campaign name, A/B test variant, etc.) through the widget for reporting and reconciliation.

Sub ID

To pass a submission ID through embedded widgets, include uniqueId in the widget initialization config. This value should be dynamic per user.
analytics: {
  source: 'example-source',
},
uniqueId: 'example-partner-sub-ID',