The Show A/B Definitions command allows you to return a list of all A/B Test Definitions in your realm. This command returns the Details of the definitions as well as the Samples in each definition.
Arguments
Show A/B Definitions requires the following arguments: Command, Realm, and Password.
api_web?r=myrealm&p=mypass&c=show_abdefinitions
The command is ‘show_abdefinitions’, the realm is ‘myrealm’ and the password is ‘mypass’.
The Show A/B Definition command supports the following arguments:
Name |
Req? |
Description |
Argument |
Command |
Yes |
Defines the command to use. |
cmd= show_abdefinitions c= show_abdefinitions |
Realm |
Yes |
Name of the realm to run the command. This is required, and the command will fail if the realm and password do not match. |
realm=[realm_name] r=[realm_name] |
Password |
Yes |
Authentication code for API access. This is required, and the command will fail if the realm and password do not match. |
pwd=[password] p=[password] |
Output Format |
|
To specify the format of the list output, use one of two arguments. If no argument is included, the default output is space-delimited plain text string, which may not include all data columns.
|
csv=1 or output_format=[csv,csv_tab, csv_pipe,xml] |
Example
Using all commands and arguments (please note the command is wrapped for display purposes only):
api_web?r=myrealm&p=mypass&c=show_abdefinitions&output_format=csv
Successful results return the Details and Samples for each definition in the realm:
D,123,myabtest,description,66,mylist,0,,5,Responder Rate,2,300,percent,1,1,1,when test time reached,0,Let user manually determine winner S,A,66,Sample A,sampleEmailA@domain.com S,B,67,Sample B,SampleEmailB@domain.com
The results do not support displaying with a header.
Results
The Show A/B Definitions command outputs either the results of the search or a FAILURE message.
SUCCESS
The Show A/B Definitions command does not explicitly return a Success code. Instead, it outputs the following details:
For record_type D (Data Details):
Record Type (CSV ONLY), A/B Definition ID, A/B Definition Name, Description, List ID, List Name, Segmentation Rule ID, Suppression List, Max Time, Measuring, Number Samples, Sample Size, sample Type, Test Subject Line, Test From Address, Test Content, Test Ends When, Threshold, Post Test Action
For record type S (Sample):
Record Type (CSV ONLY), sample, Template ID, subject Line, From Address
FAILURE
A Show A/B Definitions command will fail for several reasons. The result format is:
FAILURE: [Reason]