Encore.placement(id).show() (and the inline Encore.show()) resolves when the offer flow
ends. On web there are no global purchase handlers to register: when a user claims an offer,
the SDK opens the advertiser’s URL directly, inside the claim gesture. Your integration is
just: await the call, branch on the result.
Branch on the result
show() resolves a bare ShowResult and never
rejects:
Loading state
The placement builder exposes a loading callback for spinners and button states:Cross-cutting telemetry
For consistent analytics across many placements, wrap the placement call in a small helper instead of duplicating tracking at each call site:Rules of thumb
- Always handle all three statuses.
unavailableis a normal outcome (no eligible offers), not an error; have a fallback path. - Never gate access on the client result.
claimedis not a conversion; verify entitlements server-side, by user, via Encore’s server-side entitlements API. - Persist
transactionIdon a claim. It is how a completion landing days later is traced back to this user, and it is optional on the result, so handle its absence. - Present from real moments. A cancel tap, a checkout success, a milestone. You do not
need a click handler for
show()itself: the advertiser tab opens inside the user’s tap on Claim, within the SDK’s own sheet, so popup blockers have nothing to catch.
See also
- The Claim Flow: what a claim does, and what its payload carries
show()·placement()