Iframe Integration
The fastest way to integrate Offerlia into your web application. Drop in a single iframe tag and you're done.
Basic Integration
Add the Offerlia offerwall to your page with a single iframe tag:
<iframe
src="https://offerlia.com/wall?pid=YOUR_PUBLISHER_ID&uid=USER_ID"
width="100%"
height="600"
frameborder="0"
allowfullscreen
/>URL Parameters
| Parameter | Required | Description |
|---|---|---|
pid | Yes | Your publisher ID from the dashboard |
uid | Yes | Unique identifier for the current user |
country | No | ISO 3166-1 alpha-2 country code (e.g., US, GB) |
device | No | Device type: mobile, desktop, or tablet |
theme | No | Theme: dark (default) or light |
Example with All Parameters
<iframe
src="https://offerlia.com/wall?pid=pub_abc123&uid=user_456&country=US&device=mobile&theme=dark"
width="100%"
height="600"
frameborder="0"
allowfullscreen
/>PostMessage Communication
The iframe can communicate with your parent page using postMessage for events like conversions:
window.addEventListener('message', (event) => {
// Verify origin
if (event.origin !== 'https://offerlia.com') return;
if (event.data.type === 'conversion') {
const { conversionId, amount, currency } = event.data;
// Handle conversion in your app
console.log('Conversion:', conversionId, amount, currency);
}
});Security Best Practices
Always verify postMessage origin
Check that event.origin matches https://offerlia.com before processing messages.
Use HTTPS
Always serve your pages over HTTPS to ensure secure communication with the iframe.
Validate user IDs
Never trust user IDs from client-side code. Always validate conversions server-side via webhooks.