Getting Started
Get up and running with the relay Embedded SDK in four steps.
Installation
Add the SDK script to your HTML:
<script src="https://sdk.ir.app/v0/latest.js"></script>
To lock to a specific version, replace latest.js with the version number (no extra v prefix on the filename):
<script src="https://sdk.ir.app/v0/0.10.2.js"></script>
Authentication
Your platform is the authentication provider. The SDK does not manage user identity — your application must authenticate users and pass their identity to the SDK via userContext at initialization.
userId— A stable, unique identifier for the authenticated user from your auth system (e.g., Cognitosub, Auth0user_id, or your own database primary key). Never use email address or display name — these are mutable and will cause the user to lose access to their screenings if they change.userType— Indicates the user's role for the mounted screen:TSP(tenant screening provider managing the dashboard),END_USER(agent or property manager enrolling for screenings), orCONSUMER(renter being screened).
userContext is required on every Intellirent.init() call. The SDK uses it to scope access and determine the appropriate flow.
The userId you provide scopes which screenings a user can see and access. The SDK trusts whatever value you pass — never derive it from client-provided input. Always pull userId from a server-validated session token (e.g., a verified Cognito JWT sub or Auth0 user_id), and ensure it is stable across sessions. If userId changes, the user will lose access to screenings tied to their previous identifier.
See Authentication and userId in Best Practices for full guidance.
The Four Steps
Follow these steps in order to build a complete integration:
- Step 1: Dashboard — Set up your account, view API keys, and configure settings from the embedded dashboard.
- Step 2: Enroll End Users — Walk end users through identity verification to generate their publishable keys, which are required before screening consumers.
- Step 3: Screen a Consumer — Run a consumer screening using the enrolled end user's publishable key, and capture the
idreturned inonScreeningSuccess. - Step 4: View Reports — Mount the report or reports view using that
idasreport.id, with an understanding of how user type and key scope the visible data.
All pk_test_* keys operate in test mode. Real consumer PII will not work in test mode — you must use test consumers when testing screenings with a pk_test_* key.