Custom API campaigns let you use the power of Dynamic Yield A/B testing and automatic allocation, while fully controlling how the campaigns are rendered on your site. Variations of your custom API campaigns are JSON files, so each call results in a JSON that you can use to render an element on your site.
Creating server-side API custom campaigns
- Go to: API Campaigns › Add New › Custom
- Enter a name, and add notes and labels (optional).
- Specify the API Selector. This selector is needed in API calls to the campaign.
- Optionally, in advanced settings, you can set the experience to serve multiple variations (say, for carousel or grid variations).
- Configure the targeting settings of the experience to determine when, where, and to whom the experience is displayed, and then click Next.
- Create variations in JSON format using templates or based on other experiences, then click Save Variation.
- Set the allocation, primary metric, and advanced experience settings.
- Configure how much of your traffic to allocate to each variation and to the control group.
- Click the preview icon to see how your variation will appear.
- Click Save Experience.
- Click the plus icon to create an additional targeted experience.
- Click Save and Publish when you are ready to go.
Now you're ready to call your campaign using the Choose API call.