Building the API client library requires Maven to be installed.
To install the API client library to your local Maven repository, simply execute:
mvn install
Refer to the official documentation for more information.
Add this dependency to your project's POM:
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
<dependency>
<groupId>com.github.moosendr</groupId>
<artifactId>api-wrappers-java</artifactId>
<version>v3.0.0</version>
</dependency>
Add this dependency to your project's build file:
compile "io.swagger:swagger-java-client:1.0.0"
At first generate the JAR by executing:
mvn package
Then manually install the following JARs:
- target/api-wrappers-java-3.0.0.jar
- target/lib/*.jar
Please follow the installation instruction and execute the following Java code:
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.CampaignsApi;
import java.io.File;
import java.util.*;
public class CampaignsApiExample {
public static void main(String[] args) {
CampaignsApi apiInstance = new CampaignsApi();
String format = "format_example"; // String |
String apikey = "apikey_example"; // String | You may find your API Key or generate a new one in your account settings.
String campaignID = "campaignID_example"; // String | The ID of the requested AB test campaign
try {
AbTestCampaignSummaryResponse result = apiInstance.aBTestCampaignSummary(format, apikey, campaignID);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CampaignsApi#aBTestCampaignSummary");
e.printStackTrace();
}
}
}
Class | Method |
---|---|
GetAllCampaigns | Returns a list of all campaigns in your account with detailed information. |
GetCampaignsByPage | Returns a list of all campaigns in your account with detailed information, paging information is required as input. |
GetCampaignsByPageAndPagesize | Returns a list of all campaigns in your account with detailed information, paging information is required as input. |
GettingCampaignDetails | Returns a complete set of properties that describe the requested campaign in detail. |
GettingSenderDetails | Returns basic information for the specified sender identified by its email address. |
CloningAnExistingCampaign | Creates an exact copy of an existing campaign. The new campaign is created as a draft. |
CreatingADraftCampaign | Creates a new campaign in your account. This method does not send the campaign, but rather creates it as a draft, ready for sending or testing. |
UpdatingADraftCampaign | Updates properties of an existing draft A/B campaign in your account. Non-draft campaigns cannot be updated. |
DeletingACampaign | Deletes a campaign from your account, draft or even sent. |
TestingACampaign | Sends a test email of a draft campaign to a list of email addresses you specify for previewing. |
SendingACampaign | Sends an existing draft campaign to all recipients specified in its mailing list. The campaign is sent immediatelly. |
ABTestCampaignSummary | Provides a basic summary of the results for a sent AB test campaign, separately for each version (A and B), such as the number of recipients, opens, clicks, bounces, unsubscribes, forwards etc to date. |
ActivityByLocation | Returns a detailed report of your campaign opens (unique and total) by country. |
CampaignSummary | Provides a basic summary of the results for any sent campaign such as the number of recipients, opens, clicks, bounces, unsubscribes, forwards etc. to date. |
GettingAllYourSenders | Gets a list of your active senders in your account. You may specify any email address of these senders when sending a campaign. |
LinkActivity | Returns a list with your campaign links and how many clicks have been made by your recipients, either unique or total. |
SchedulingACampaign | Assigns a scheduled date and time at which the campaign will be delivered. |
UnschedulingACampaign | Removes a previously defined scheduled date and time from a campaign, so that it will be delivered immediately if already queued or when sent. |
Class | Method |
---|---|
CreatingACustomField | Creates a new custom field in the specified mailing list. |
CreatingAMailingList | Creates a new empty mailing list in your account. |
DeletingAMailingList | Deletes a mailing list from your account. |
GettingAllActiveMailingLists | Gets a list of your active mailing lists in your account. |
GettingAllActiveMailingListsWithPaging | Gets a list of your active mailing lists in your account. Because the results for this call could be quite big, paging information is required as input. |
GettingMailingListDetails | Gets details for a given mailing list. You may include subscriber statistics in your results or not. Any segments existing for the requested mailing list will not be included in the results. |
RemovingACustomField | Removes a custom field definition from the specified mailing list. |
UpdatingACustomField | Updates the properties of an existing custom field in the specified mailing list. |
UpdatingAMailingList | Updates the properties of an existing mailing list. |
Class | Method |
---|---|
GettingSegments | Get a list of all segments with their criteria for the given mailing list. |
GettingSegmentDetails | Gets detailed information on a specific segment and its criteria. However, it does not include the subscribers returned by the segment. |
GettingSegmentSubscribers | Gets a list of the subscribers that the specified segment returns according to its criteria. Because the results for this call could be quite big, paging information is required as input. |
CreatingANewSegment | Creates a new empty segment (without criteria) for the given mailing list. You may specify the name of the segment and the way the criteria will match together. |
UpdatingASegment | Updates the properties of an existing segment. You may update the name and match type of the segment. |
AddingCriteriaToSegments | Adds a new criterion (a rule) to the specified segment. |
UpdatingSegmentCriteria | Updates an existing criterion in the specified segment. |
DeletingASegment | Deletes a segment along with its criteria from the mailing list. The subscribers of the mailing list that the segment returned are not deleted or affected in any way. |
Class | Method |
---|---|
GettingSubscribers | Gets a list of all subscribers in a given mailing list. You may filter the list by setting a date to fetch those subscribed since then and/or by their status. |
GetSubscriberByEmailAddress | Searches for a subscriber with the specified email address in the specified mailing list. |
GetSubscriberById | Searches for a subscriber with the specified unique id in the specified mailing list |
AddingSubscribers | Adds a new subscriber to the specified mailing list. If there is already a subscriber with the specified email address in the list, an update will be performed instead. |
AddingMultipleSubscribers | This method allows you to add multiple subscribers in a mailing list with a single call. If some subscribers already exist with the given email addresses, they will be updated. |
UpdatingASubscriber | Updates a subscriber in the specified mailing list. You can even update the subscribers email, if he has not unsubscribed. |
UnsubscribingSubscribersFromAccount | Unsubscribes a subscriber from the account. |
UnsubscribingSubscribersFromMailingList | Unsubscribes a subscriber from the specified mailing list. The subscriber is not deleted, but moved to the suppression list. |
UnsubscribingSubscribersFromMailingListAndASpecifiedCampaign | Unsubscribes a subscriber from the specified mailing list and the specified campaign. The subscriber is not deleted, but moved to the suppression list. |
RemovingASubscriber | Removes a subscriber from the specified mailing list permanently (without moving to the suppression list). |
RemovingMultipleSubscribers | Removes a list of subscribers from the specified mailing list permanently (without putting them in the suppression list). Any invalid email addresses specified will be ignored. |
- A
- ABCampaignData
- AbTestCampaignSummaryResponse
- ActivityByLocationResponse
- AddingCriteriaToSegmentsRequest
- AddingCriteriaToSegmentsResponse
- AddingMultipleSubscribersRequest
- AddingMultipleSubscribersResponse
- AddingSubscribersRequest
- AddingSubscribersResponse
- Analytic
- B
- Campaign
- CampaignSummaryResponse
- CloningAnExistingCampaignResponse
- Context
- Context110
- Context118
- Context132
- Context140
- Context145
- Context148
- Context17
- Context32
- Context37
- Context52
- Context64
- Context66
- Context72
- Context84
- Context89
- Context93
- CreatingACustomFieldRequest
- CreatingACustomFieldResponse
- CreatingADraftCampaignRequest
- CreatingADraftCampaignResponse
- CreatingAMailingListRequest
- CreatingAMailingListResponse
- CreatingANewSegmentRequest
- CreatingANewSegmentResponse
- Criterion
- CustomField
- CustomField53
- CustomFieldsDefinition
- DeletingACampaignResponse
- DeletingAMailingListResponse
- DeletingASegmentResponse
- Format
- GetAllCampaignsResponse
- GetCampaignStatisticsResponse
- GetCampaignStatisticsWithPagingFilteredResponse
- GetCampaignsByPageAndPagesizeResponse
- GetCampaignsByPageResponse
- GetSubscriberByEmailAddressResponse
- GetSubscriberByIdResponse
- GettingAllActiveMailingListsResponse
- GettingAllActiveMailingListsWithPagingResponse
- GettingAllYourSendersResponse
- GettingCampaignDetailsResponse
- GettingMailingListDetailsResponse
- GettingSegmentDetailsResponse
- GettingSegmentSubscribersResponse
- GettingSegmentsResponse
- GettingSenderDetailsResponse
- GettingSubscribersResponse
- ImportOperation
- ImportOperation19
- LinkActivityResponse
- MailingList
- MailingList68
- MailingList69
- MailingList85
- MailingLists
- MailingLists119
- MailingLists134
- Paging
- Paging76
- RemovingACustomFieldResponse
- RemovingASubscriberRequest
- RemovingASubscriberResponse
- RemovingMultipleSubscribersRequest
- RemovingMultipleSubscribersResponse
- ReplyToEmail
- SchedulingACampaignRequest
- SchedulingACampaignResponse
- Segment
- Sender
- SendingACampaignResponse
- ShortBy
- SortMethod
- Status
- Subscriber
- Subscribers
- Subscribers150
- TestingACampaignRequest
- TestingACampaignResponse
- Type
- UnschedulingACampaignResponse
- UnsubscribingSubscribersFromAccountRequest
- UnsubscribingSubscribersFromAccountResponse
- UnsubscribingSubscribersFromMailingListAndASpecifiedCampaignRequest
- UnsubscribingSubscribersFromMailingListAndASpecifiedCampaignResponse
- UnsubscribingSubscribersFromMailingListRequest
- UnsubscribingSubscribersFromMailingListResponse
- UpdatingACustomFieldRequest
- UpdatingACustomFieldResponse
- UpdatingADraftCampaignRequest
- UpdatingADraftCampaignResponse
- UpdatingAMailingListRequest
- UpdatingAMailingListResponse
- UpdatingASegmentRequest
- UpdatingASegmentResponse
- UpdatingASubscriberRequest
- UpdatingASubscriberResponse
- UpdatingSegmentCriteriaRequest
- UpdatingSegmentCriteriaResponse
- WithStatistics