Guides & Tutorials

A/B test statistics

GET /api/split.php?id=...

Endpoint can be used to retrieve overview and detailed statistics of an A/B test.

Request parameters

Parameter Value
id A/B test ID.

Required.
detailed Include recipients detailed open/click statistics with response.

Default: 0
offset Page number. Value of 0 returns records from 0 to 10 000, 1 returns records from 10 001 to 20 000, etc.

Default: 0
limit Number of records to return per request. When the limit is applied it is capped at 10000.

Default: No limit
0 No emails have been sent to the subscriber yet.

Note! Parameters offset and limit are only applied when the detailed parameter has value of 1.

Response parameters

Response is a JSON list of JSON objects

Parameter Value
name A/B test name.
from Sender address.

Read the "Sender address object parameters" section for more information.
reply_to Reply-To email address.
template Template used in the section.

Note! For deleted templates the value of “DELETED” is returned.

Read the "Template object parameters" section for more information.
total_count Number of messages enqueued.
delivered_count Number of messages successfully delivered.
bounce_count Number of messages bounced.
click_count Number of link clicks.
unique_click_count Number of recipients who have clicked at least one link.
click_percent Percentage of recipients who have clicked at least one link. unique_click_count divided by delivered_count.
view_count Number of times message images were downloaded.
unique_view_count Number of recipients who have downloaded images at least one time.
view_percent Percentage of recipients who have downloaded images at least one time. unique_view_count divided by delivered_count.
opened_count Number of recipients who have opened the messages (clicked a link or downloaded images at least once).
opened_percent Percentage of recipients who have opened the message. opened_count divided by delivered_count.
unsubscribe_count Number of unsubscribed recipients.
complaint_count Number of recipients who reported the message as spam.
forward_count Number of times the message was forwarded.
addresses List of detailed statistics per recipient. Added only when the request parameter detailed is 1.

Read "Addreses object parameters" section for more information.
winner Deprecated.

Sender address object parameters

Parameter Value
email Sender's email address.
name Sender's name. Can be empty.

Template object parameters

Note! For deleted templates the value of “DELETED” is returned.

Parameter Value
id Template ID. Numeric
name Template name.
preview_url URL to template preview.

Addresses object parameters

Parameter Value
email Recipients email address.
sent_at Message delivery date and time.

Formatted as YYYY-MM-DD HH:MM:SS, and presented in Europe/Tallinn timezone.
bounced_at Message bounce date and time.

Formatted as YYYY-MM-DD HH:MM:SS, and presented in Europe/Tallinn timezone.

Default: NULL
bounce_status Message bounce classification. See "Delivery response codes" for classification explanations.

Default: NULL
opens Number of times the recipient opened the message.
clicks Number of times recipient clicked link(s).
links List of links clicked by recipient. See "Links object parameters" for more information.

Links object parameters

Parameter Value
href Link's URL.
visit_at Date and time of first click.

Formatted as YYYY-MM-DD HH:MM:SS, and presented in Europe/Tallinn timezone.
count Number of times the link has been clicked.

Example

$ curl -X GET -u "${USERNAME}:${PASSWORD}" \
  "https://${SUBDOMAIN}.sendsmaily.net/api/split.php?id=5&detailed=1"

(JavaScript/JSON)

[
    {
        "name": "My First A/B test",
        "from": {
            "email": "sender@domain.tld",
            "name": "John Doe"
        },
        "reply_to": "hello@domain.tld",
        "template": {
            "id": 1,
            "name": "Welcome message template",
            "preview_url": "https://[subdomain].sendsmaily.net/template/preview/id/1"
        },
        "total_count": 10445,
        "delivered_count": 10400,
        "bounce_count": 45,
        "click_count": 330,
        "unique_click_count": 123,
        "click_percent": 1.18,
        "view_count": 3220,
        "unique_view_count": 2765,
        "view_percent": 26.59,
        "opened_count": 2833,
        "opened_percent": 27.24,
        "unsubscribe_count": 3,
        "complaint_count": 0,
        "forward_count": 0,
        "addresses": [
            {
                "email": "recipient@domain.tld",
                "sent_at": "2019-03-10 11:34:15",
                "bounced_at": null,
                "bounce_status": null,
                "opens": 3,
                "clicks": 1,
                "links": [
                    {
                        "href": "https://domain.tld",
                        "visit_at": "2019-03-10 13:07:11",
                        "count": 1
                    }
                ]
            },
            {
                "email": "recipient@domain.tld",
                "sent_at": "2019-03-10 11:34:15",
                "bounced_at": "2019-03-10 11:34:20",
                "bounce_status": "mailbox-unknown",
                "opens": 3,
                "clicks": 1,
                "links": []
            },
            ...
        ]
    },
    ...
]