You can pre-fill data about your customer by passing in their information to the prefillData
key of the widget configuration:
Copy authenticWidget.init({
insurancePortal: {
url: "https://<tenant-name>.<environment>.authenticinsurance.com",
},
customerId: "unique_cid1",
prefillData: {
lead: {
email: "customer@email.com",
stateCodes: ["OH"],
},
responses: {
exposures: [{
exposureName: "business_location",
fieldValues: {
"ADDRESS": "100 street, UNIT 2, city, OH 33333, US",
}
}],
questions: {
"BUSINESS_LEGAL_NAME": "Customer Business Name",
"NAME": "Customer Full Name"
}
}
}
});
Copy interface PrefillData {
lead?: {
email?: string;
businessClassCode?: string;
stateCodes?: string[];
productIds?: string[];
};
responses?: {
exposures?: Array<{
exposureName: string;
fieldValues: Record<string, string>;
}>;
questions?: Record<string, string>;
};
};