It is possible to write Server Side driven tests that work along with Convert Experiences AB testing. The following article is meant to explain how can this be achieved.
There is a Convert Server Side PHP example available to you.
- Determine if customers have been bucketed in the experiment already.
Read the _conv_v cookie and parse it according to the structure described here:
Cookie Structure Article
- Determine if the experiment id is included in the cookie and if it is read the variation id to which the visitor was assigned to.
With the variation id, execute the logic associated with this variation.
If the experiment id is not found, go to the next step.
- Generate a random number between 0 and 1 and use it do decide which variation is to be presented, based on the number of variations you have on the test in question.
Example: if you have 3 variations and the number generated is 0.55 then the variation would be the second one.
Next, you will need to id of the selected variation (second on the example), which you can get from REST Project Endpoint or just hard code the list of variations IDs for that experiment in your code (this more convenient and faster).
- To tell Convert which variation has been selected for this visitor write the following cookie.
Value: experiment_id:variation_id (Replace it with the real values)
Expiration: 10 seconds (This should be enough)
- Based on the selected variation do your internal logic, the same as if variations were there from the previously bucketed visitor as in Step 2.
- The experiment has to be set up. with a Site area that prevents it from firing, and be set to active. This could be achieved by including an unreachable Boolean JS condition.