Edit in GitHubLog an issue


This function is for applying the response content with Adobe Target.

The options parameter is mandatory and has the following structure:

mboxStringYesMbox name
With at.js 1.3.0 (and later) Target enforces that the mbox key is used. This key has been required in the past, but Target now enforces its use to ensure that Target has proper validation and customers are using the function correctly.
selectorString or DOM ElementNoHTML element or CSS selector used to identify the HTML element where Target should place the offer content. If selector is not provided, Target assumes that the HTML element should use HTML HEAD.
OfferArrayYesAn array actions that should be applied to the element.


The following example shows how to use getOffer and applyOffer together:

Copied to your clipboard
2 "mbox": "mbox",
3 "success": function(offers) {
4 adobe.target.applyOffer( {
5 "mbox": "mbox",
6 "offer": offers
7 } );
8 },
9 "error": function(status, error) {
10 if (console && console.log) {
11 console.log(status);
12 console.log(error);
13 }
14 },
15 "timeout": 5000
Was this helpful?
  • Privacy
  • Terms of Use
  • Do not sell my personal information
  • AdChoices
Copyright © 2022 Adobe. All rights reserved.