Step 3: Verify the rule artifact download using at.js custom events
The at.js library dispatches two new custom events to support on-device decisioning.
adobe.target.event.ARTIFACT_DOWNLOAD_SUCCEEDED
adobe.target.event.ARTIFACT_DOWNLOAD_FAILED
You can subscribe to listen to these custom events in your application to action upon success or failure of the artifact rules file download.
The following example shows a sample of code listening to artifact download success and failure events:
document.addEventListener(adobe.target.event.ARTIFACT_DOWNLOAD_SUCCEEDED, function(e) {
console.log("Artifact successfully downloaded", e.detail);
}, false);
document.addEventListener(adobe.target.event.ARTIFACT_DOWNLOAD_FAILED, function(e) {
console.log("Artifact failed to download", e.detail);
}, false);
Previous pageRule artifact
Next pageat.js functions overview
Personalization & Experiementation Excellence with Recommendations and AI
Adobe Customer Success Webinars
Tuesday, Mar 4, 4:00 PM UTC
Adobe Target innovations, including GenAI, and best practices on AI-powered personalization and experimentation at scale.
RegisterAdobe Target at Summit
Register for these developer sessions:
- Put the Customer at the Center and Build Relationships That Last a Lifetime (attend online)
- Had Me at First Click: Activate Your Audience with AI Content Discovery
- 3 Pillars of Purpose-driven Experiences: Trust, Data, and GenAI
- A Tax Transformation: How H&R Block and Adobe MarTech Improved Engagement
- B2B Transformation Series: "No Limits" Digital Marketing at GE HealthCare
Connect with Experience League at Summit!
Get front-row access to top sessions, hands-on activities, and networking—wherever you are!
Learn more