V3 REFERENCE Event API

/clickstatistics

Click statistics for messages.

List clickstatistics resources available for this apikey, use a GET request. Alternatively, you may want to add one or more filters.

# list clickstatistics resources

curl -s -X GET \
--user "$MJ_APIKEY_PUBLIC:$MJ_APIKEY_PRIVATE" \
https://api.mailjet.com/v3/REST/clickstatistics
Properties
Name Description
ClickedAt Timestamp of registration of click.
  • Read Only
  • [ Type TRFC3339DateTime ]
ClickedDelay Delay between registration of the click and sending of message.
  • Read Only
  • [ Type Int64 ]
ContactID
OR
ContactALT
ContactID
ID reference to Contact
ContactALT
Value of the Email field of the related Contact resource
  • Mandatory
  • Read Only
  • [ Type TContact ]
ID Unique numerical ID for the click event.
  • Read Only
  • [ Type Int64 ]
MessageID ID reference to Message Reference to Message for which click was registered.
  • Mandatory
  • Read Only
  • [ Type TMessage ]
Url URL that was clicked.
  • Mandatory
  • Read Only
  • [ Type AnsiString ]
UserAgent User agent that was used to open the URL.
  • Mandatory
  • Read Only
  • [ Type TUserAgent ]
Filters
Name Description
CampaignID Unique numerical ID for this object.
  • [ Type Int64 ]
CampaignStatus Only retrieve campaigns with status equal to specified value.
  • [ Type SmallInt ]
ContactsList Only retrieve campaigns to given Contacts list.
  • [ Type Int64 ]
CustomCampaign Only retrieve campaigns with given Custom Value.
  • [ Type AnsiString ]
EventFromTs Minimum value for ClickedAt
  • [ Type TRFC3339DateTime ]
EventToTs Maximum value for ClickedAt
  • [ Type TRFC3339DateTime ]
From Only retrieve campaigns with given From header.
  • [ Type AnsiString ]
FromDomain Only retrieve campaigns with given domain in From header.
  • [ Type AnsiString ]
FromID Only retrieve campaigns with this sender ID.
  • [ Type Int64 ]
FromTS Only retrieve campaigns with SendStartAt after this timestamp.
  • [ Type TRFC3339DateTime ]
FromType Only retrieve campaigns with FromType equal to specified value.
  • [ Type LongInt ]
IsDeleted Only retrieve campaigns where isDeleted matches the specified value.
  • [ Type TBooleanFilter ]
IsNewsletterTool Only retrieve campaigns which were started by the newsletter tool.
  • [ Type TBooleanFilter ]
IsStarred Only retrieve campaigns which were marked as starred.
  • [ Type TBooleanFilter ]
MessageID Only retrieve messages with the given ID.
  • [ Type Int64 ]
MessageStatus Only retrieve messages with status equal to specified value.
  • [ Type TMessageStatus ]
Period Set FromTS and ToTS timestamps to beginning of indicated period and current timestamp, respectively.
  • [ Type AnsiString ]
ToTS Only retrieve campaigns with SendStartAt timestamp less than the specified value.
  • [ Type TRFC3339DateTime ]

Access a given clickstatistics resource, use a GET request, providing the clickstatistics's ID value.

# access the clickstatistics resource identified by $ID

curl -s -X GET \
--user "$MJ_APIKEY_PUBLIC:$MJ_APIKEY_PRIVATE" \
https://api.mailjet.com/v3/REST/clickstatistics/$ID

    
    
Properties
Name Description
ClickedAt Timestamp of registration of click.
  • Read Only
  • [ Type TRFC3339DateTime ]
ClickedDelay Delay between registration of the click and sending of message.
  • Read Only
  • [ Type Int64 ]
ContactID
OR
ContactALT
ContactID
ID reference to Contact
ContactALT
Value of the Email field of the related Contact resource
  • Mandatory
  • Read Only
  • [ Type TContact ]
ID Unique numerical ID for the click event.
  • Read Only
  • [ Type Int64 ]
MessageID ID reference to Message Reference to Message for which click was registered.
  • Mandatory
  • Read Only
  • [ Type TMessage ]
Url URL that was clicked.
  • Mandatory
  • Read Only
  • [ Type AnsiString ]
UserAgent User agent that was used to open the URL.
  • Mandatory
  • Read Only
  • [ Type TUserAgent ]