Quick Start
Identify your user, fetch banners for a placement, and render each result with your own component:Placement System
Banners attach to your UI via a placement identifier — a string you define in the dashboard and pass togetBanners(). Use whatever naming convention makes sense for your app:
Fetching Banners
getBanners() automatically caches results for 5 minutes to reduce API calls. Use the optional second argument to control caching and rendering behaviour:
| Option | Type | Default | Description |
|---|---|---|---|
autoRender | boolean | false | When true, the SDK automatically renders eligible banners for the placement immediately after fetching, without requiring you to call banners.display() separately. |
forceRefresh | boolean | false | Bypass the 5-minute result cache and request fresh data from the API. |
Banner Response Structure
Each item in the response array contains abanner object and the winning variant object selected for the current user:
Rendering Banners in React Native
Build a reusableBanner component that reads from the banner and variant objects returned by the API:
Manual Event Tracking
Call thebanners tracking methods explicitly when you need fine-grained control over when events are recorded:
Track display
Call
banners.display() when the banner becomes visible. Store the returned
displayId — you need it for click and dismiss tracking.Banner Position Handling
Use theposition value from variant.design to apply the correct layout style:
Features
Audience Targeting
Show banners only to specific customer segments or users matching custom
attribute rules. Banners with targeting enabled are only returned when the
identified user meets the criteria.
Scheduling
Set start and end dates, restrict banners to specific hours of the day or
days of the week, and define a timezone for accurate schedule calculations.
Frequency Capping
Limit how many times a banner is shown to an individual user. Configure a
maximum display count and a reset period — session, hour, day, week, or
month.
A/B Testing
Run experiments with multiple variants. Set traffic allocation percentages
for each variant and let the SDK automatically assign users based on their
customer ID.
Analytics
Every banner interaction is tracked automatically when you call thebanners.* methods:
| Metric | Description |
|---|---|
| Views | Times the banner was displayed |
| Clicks | Times the CTA was tapped |
| Dismissals | Times the banner was closed |
| Conversions | Downstream conversions attributed to the banner |
| CTR | Click-through rate (clicks ÷ views) |
API Reference
Fetch eligible banners for a placement.
selector(string, required) — Placement identifier (screen name, component name, etc.)options.autoRender(boolean, defaultfalse) — Automatically render eligible banners after fetching, without a separatebanners.display()call.options.forceRefresh(boolean, defaultfalse) — Bypass the 5-minute cache and fetch fresh data.
Track a banner display. Returns a
displayId string you must store and pass to banners.click() and banners.dismiss().Track a banner CTA click. Pass the
displayId returned by banners.display().Track a banner dismissal. Pass the
displayId returned by banners.display().Best Practices
Troubleshooting
Banners not displaying
Banners not displaying
Banners displaying incorrectly
Banners displaying incorrectly
Tracking not working
Tracking not working
If clicks and dismissals aren’t appearing in Tappd analytics:
- Confirm
apiUrlin your SDK config points tohttps://sdk.gotappd.com/api/v1/sdk. - Make sure you’re storing the
displayIdreturned bybanners.display()and passing it tobanners.click()andbanners.dismiss(). - Check device logs for network errors on the tracking API calls.
- Verify your
appIdis correct.