Skip to content

Commit 92f90af

Browse files
Merge pull request #107 from sendinblue/feature_PHP_AP_653
Feature php ap 653
2 parents 986eac4 + 4b17da4 commit 92f90af

File tree

410 files changed

+13667
-3737
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

410 files changed

+13667
-3737
lines changed

README.md

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -113,9 +113,11 @@ Class | Method | HTTP request | Description
113113
*EmailCampaignsApi* | [**createEmailCampaign**](docs/Api/EmailCampaignsApi.md#createemailcampaign) | **POST** /emailCampaigns | Create an email campaign
114114
*EmailCampaignsApi* | [**deleteEmailCampaign**](docs/Api/EmailCampaignsApi.md#deleteemailcampaign) | **DELETE** /emailCampaigns/{campaignId} | Delete an email campaign
115115
*EmailCampaignsApi* | [**emailExportRecipients**](docs/Api/EmailCampaignsApi.md#emailexportrecipients) | **POST** /emailCampaigns/{campaignId}/exportRecipients | Export the recipients of a campaign
116+
*EmailCampaignsApi* | [**getAbTestCampaignResult**](docs/Api/EmailCampaignsApi.md#getabtestcampaignresult) | **GET** /emailCampaigns/{campaignId}/abTestCampaignResult | Get A/B test email campaign result
116117
*EmailCampaignsApi* | [**getEmailCampaign**](docs/Api/EmailCampaignsApi.md#getemailcampaign) | **GET** /emailCampaigns/{campaignId} | Get campaign informations
117118
*EmailCampaignsApi* | [**getEmailCampaigns**](docs/Api/EmailCampaignsApi.md#getemailcampaigns) | **GET** /emailCampaigns | Return all your created campaigns
118-
*EmailCampaignsApi* | [**sendEmailCampaignNow**](docs/Api/EmailCampaignsApi.md#sendemailcampaignnow) | **POST** /emailCampaigns/{campaignId}/sendNow | Send an email campaign id of the campaign immediately
119+
*EmailCampaignsApi* | [**getSharedTemplateUrl**](docs/Api/EmailCampaignsApi.md#getsharedtemplateurl) | **GET** /emailCampaigns/{campaignId}/sharedUrl | Get a shared template url
120+
*EmailCampaignsApi* | [**sendEmailCampaignNow**](docs/Api/EmailCampaignsApi.md#sendemailcampaignnow) | **POST** /emailCampaigns/{campaignId}/sendNow | Send an email campaign immediately, based on campaignId
119121
*EmailCampaignsApi* | [**sendReport**](docs/Api/EmailCampaignsApi.md#sendreport) | **POST** /emailCampaigns/{campaignId}/sendReport | Send the report of a campaigns
120122
*EmailCampaignsApi* | [**sendTestEmail**](docs/Api/EmailCampaignsApi.md#sendtestemail) | **POST** /emailCampaigns/{campaignId}/sendTest | Send an email campaign to your test list
121123
*EmailCampaignsApi* | [**updateCampaignStatus**](docs/Api/EmailCampaignsApi.md#updatecampaignstatus) | **PUT** /emailCampaigns/{campaignId}/status | Update a campaign status
@@ -144,6 +146,7 @@ Class | Method | HTTP request | Description
144146
*ResellerApi* | [**deleteChildDomain**](docs/Api/ResellerApi.md#deletechilddomain) | **DELETE** /reseller/children/{childAuthKey}/domains/{domainName} | Deletes the sender domain of the reseller child based on the childAuthKey and domainName passed
145147
*ResellerApi* | [**deleteResellerChild**](docs/Api/ResellerApi.md#deleteresellerchild) | **DELETE** /reseller/children/{childAuthKey} | Deletes a single reseller child based on the childAuthKey supplied
146148
*ResellerApi* | [**dissociateIpFromChild**](docs/Api/ResellerApi.md#dissociateipfromchild) | **POST** /reseller/children/{childAuthKey}/ips/dissociate | Dissociate a dedicated IP to the child
149+
*ResellerApi* | [**getChildAccountCreationStatus**](docs/Api/ResellerApi.md#getchildaccountcreationstatus) | **GET** /reseller/children/{childAuthKey}/accountCreationStatus | Returns the status of reseller's child account creation, whether it is successfully created (exists) or not based on the childAuthKey supplied
147150
*ResellerApi* | [**getChildDomains**](docs/Api/ResellerApi.md#getchilddomains) | **GET** /reseller/children/{childAuthKey}/domains | Gets all the sender domains of a specific child account
148151
*ResellerApi* | [**getChildInfo**](docs/Api/ResellerApi.md#getchildinfo) | **GET** /reseller/children/{childAuthKey} | Gets the info about a specific child account
149152
*ResellerApi* | [**getResellerChilds**](docs/Api/ResellerApi.md#getresellerchilds) | **GET** /reseller/children | Gets the list of all reseller's children accounts
@@ -162,18 +165,23 @@ Class | Method | HTTP request | Description
162165
*SMSCampaignsApi* | [**sendTestSms**](docs/Api/SMSCampaignsApi.md#sendtestsms) | **POST** /smsCampaigns/{campaignId}/sendTest | Send an SMS
163166
*SMSCampaignsApi* | [**updateSmsCampaign**](docs/Api/SMSCampaignsApi.md#updatesmscampaign) | **PUT** /smsCampaigns/{campaignId} | Updates an SMS campaign
164167
*SMSCampaignsApi* | [**updateSmsCampaignStatus**](docs/Api/SMSCampaignsApi.md#updatesmscampaignstatus) | **PUT** /smsCampaigns/{campaignId}/status | Update the campaign status
165-
*SMTPApi* | [**createSmtpTemplate**](docs/Api/SMTPApi.md#createsmtptemplate) | **POST** /smtp/templates | Create an smtp template
168+
*SMTPApi* | [**createSmtpTemplate**](docs/Api/SMTPApi.md#createsmtptemplate) | **POST** /smtp/templates | Create a transactional email template
166169
*SMTPApi* | [**deleteHardbounces**](docs/Api/SMTPApi.md#deletehardbounces) | **POST** /smtp/deleteHardbounces | Delete hardbounces
167-
*SMTPApi* | [**deleteSmtpTemplate**](docs/Api/SMTPApi.md#deletesmtptemplate) | **DELETE** /smtp/templates/{templateId} | Delete an inactive smtp template
168-
*SMTPApi* | [**getAggregatedSmtpReport**](docs/Api/SMTPApi.md#getaggregatedsmtpreport) | **GET** /smtp/statistics/aggregatedReport | Get your SMTP activity aggregated over a period of time
169-
*SMTPApi* | [**getEmailEventReport**](docs/Api/SMTPApi.md#getemaileventreport) | **GET** /smtp/statistics/events | Get all your SMTP activity (unaggregated events)
170-
*SMTPApi* | [**getSmtpReport**](docs/Api/SMTPApi.md#getsmtpreport) | **GET** /smtp/statistics/reports | Get your SMTP activity aggregated per day
170+
*SMTPApi* | [**deleteSmtpTemplate**](docs/Api/SMTPApi.md#deletesmtptemplate) | **DELETE** /smtp/templates/{templateId} | Delete an inactive transactional email template
171+
*SMTPApi* | [**getAggregatedSmtpReport**](docs/Api/SMTPApi.md#getaggregatedsmtpreport) | **GET** /smtp/statistics/aggregatedReport | Get your transactional email activity aggregated over a period of time
172+
*SMTPApi* | [**getEmailEventReport**](docs/Api/SMTPApi.md#getemaileventreport) | **GET** /smtp/statistics/events | Get all your transactional email activity (unaggregated events)
173+
*SMTPApi* | [**getSmtpReport**](docs/Api/SMTPApi.md#getsmtpreport) | **GET** /smtp/statistics/reports | Get your transactional email activity aggregated per day
171174
*SMTPApi* | [**getSmtpTemplate**](docs/Api/SMTPApi.md#getsmtptemplate) | **GET** /smtp/templates/{templateId} | Returns the template informations
172-
*SMTPApi* | [**getSmtpTemplates**](docs/Api/SMTPApi.md#getsmtptemplates) | **GET** /smtp/templates | Get the list of SMTP templates
175+
*SMTPApi* | [**getSmtpTemplates**](docs/Api/SMTPApi.md#getsmtptemplates) | **GET** /smtp/templates | Get the list of transactional email templates
176+
*SMTPApi* | [**getTransacBlockedContacts**](docs/Api/SMTPApi.md#gettransacblockedcontacts) | **GET** /smtp/blockedContacts | Get the list of blocked or unsubscribed transactional contacts
177+
*SMTPApi* | [**getTransacEmailContent**](docs/Api/SMTPApi.md#gettransacemailcontent) | **GET** /smtp/emails/{uuid} | Get the personalized content of a sent transactional email
178+
*SMTPApi* | [**getTransacEmailsList**](docs/Api/SMTPApi.md#gettransacemailslist) | **GET** /smtp/emails | Get the list of transactional emails on the basis of allowed filters
173179
*SMTPApi* | [**sendTemplate**](docs/Api/SMTPApi.md#sendtemplate) | **POST** /smtp/templates/{templateId}/send | Send a template
174180
*SMTPApi* | [**sendTestTemplate**](docs/Api/SMTPApi.md#sendtesttemplate) | **POST** /smtp/templates/{templateId}/sendTest | Send a template to your test list
175181
*SMTPApi* | [**sendTransacEmail**](docs/Api/SMTPApi.md#sendtransacemail) | **POST** /smtp/email | Send a transactional email
176-
*SMTPApi* | [**updateSmtpTemplate**](docs/Api/SMTPApi.md#updatesmtptemplate) | **PUT** /smtp/templates/{templateId} | Updates an smtp templates
182+
*SMTPApi* | [**smtpBlockedContactsEmailDelete**](docs/Api/SMTPApi.md#smtpblockedcontactsemaildelete) | **DELETE** /smtp/blockedContacts/{email} | Unblock or resubscribe a transactional contact
183+
*SMTPApi* | [**smtpLogMessageIdDelete**](docs/Api/SMTPApi.md#smtplogmessageiddelete) | **DELETE** /smtp/log/{messageId} | Delete an SMTP transactional log
184+
*SMTPApi* | [**updateSmtpTemplate**](docs/Api/SMTPApi.md#updatesmtptemplate) | **PUT** /smtp/templates/{templateId} | Updates a transactional email templates
177185
*SendersApi* | [**createSender**](docs/Api/SendersApi.md#createsender) | **POST** /senders | Create a new sender
178186
*SendersApi* | [**deleteSender**](docs/Api/SendersApi.md#deletesender) | **DELETE** /senders/{senderId} | Delete a sender
179187
*SendersApi* | [**getIps**](docs/Api/SendersApi.md#getips) | **GET** /senders/ips | Return all the dedicated IPs for your account
@@ -193,6 +201,7 @@ Class | Method | HTTP request | Description
193201

194202
## Documentation For Models
195203

204+
- [AbTestCampaignResult](docs/Model/AbTestCampaignResult.md)
196205
- [AddChildDomain](docs/Model/AddChildDomain.md)
197206
- [AddContactToList](docs/Model/AddContactToList.md)
198207
- [AddCredits](docs/Model/AddCredits.md)
@@ -232,6 +241,7 @@ Class | Method | HTTP request | Description
232241
- [GetCampaignOverview](docs/Model/GetCampaignOverview.md)
233242
- [GetCampaignRecipients](docs/Model/GetCampaignRecipients.md)
234243
- [GetCampaignStats](docs/Model/GetCampaignStats.md)
244+
- [GetChildAccountCreationStatus](docs/Model/GetChildAccountCreationStatus.md)
235245
- [GetChildDomain](docs/Model/GetChildDomain.md)
236246
- [GetChildDomains](docs/Model/GetChildDomains.md)
237247
- [GetChildInfoApiKeys](docs/Model/GetChildInfoApiKeys.md)
@@ -248,6 +258,8 @@ Class | Method | HTTP request | Description
248258
- [GetContactCampaignStatsUnsubscriptions](docs/Model/GetContactCampaignStatsUnsubscriptions.md)
249259
- [GetContactDetails](docs/Model/GetContactDetails.md)
250260
- [GetContacts](docs/Model/GetContacts.md)
261+
- [GetDeviceBrowserStats](docs/Model/GetDeviceBrowserStats.md)
262+
- [GetEmailCampaign](docs/Model/GetEmailCampaign.md)
251263
- [GetEmailCampaigns](docs/Model/GetEmailCampaigns.md)
252264
- [GetEmailEventReport](docs/Model/GetEmailEventReport.md)
253265
- [GetEmailEventReportEvents](docs/Model/GetEmailEventReportEvents.md)
@@ -279,6 +291,7 @@ Class | Method | HTTP request | Description
279291
- [GetSendersList](docs/Model/GetSendersList.md)
280292
- [GetSendersListIps](docs/Model/GetSendersListIps.md)
281293
- [GetSendersListSenders](docs/Model/GetSendersListSenders.md)
294+
- [GetSharedTemplateUrl](docs/Model/GetSharedTemplateUrl.md)
282295
- [GetSmsCampaignOverview](docs/Model/GetSmsCampaignOverview.md)
283296
- [GetSmsCampaignStats](docs/Model/GetSmsCampaignStats.md)
284297
- [GetSmsCampaigns](docs/Model/GetSmsCampaigns.md)
@@ -288,8 +301,17 @@ Class | Method | HTTP request | Description
288301
- [GetSmtpTemplateOverviewSender](docs/Model/GetSmtpTemplateOverviewSender.md)
289302
- [GetSmtpTemplates](docs/Model/GetSmtpTemplates.md)
290303
- [GetSsoToken](docs/Model/GetSsoToken.md)
304+
- [GetStatsByBrowser](docs/Model/GetStatsByBrowser.md)
305+
- [GetStatsByDevice](docs/Model/GetStatsByDevice.md)
291306
- [GetStatsByDomain](docs/Model/GetStatsByDomain.md)
292307
- [GetTransacAggregatedSmsReport](docs/Model/GetTransacAggregatedSmsReport.md)
308+
- [GetTransacBlockedContacts](docs/Model/GetTransacBlockedContacts.md)
309+
- [GetTransacBlockedContactsContacts](docs/Model/GetTransacBlockedContactsContacts.md)
310+
- [GetTransacBlockedContactsReason](docs/Model/GetTransacBlockedContactsReason.md)
311+
- [GetTransacEmailContent](docs/Model/GetTransacEmailContent.md)
312+
- [GetTransacEmailContentEvents](docs/Model/GetTransacEmailContentEvents.md)
313+
- [GetTransacEmailsList](docs/Model/GetTransacEmailsList.md)
314+
- [GetTransacEmailsListTransactionalEmails](docs/Model/GetTransacEmailsListTransactionalEmails.md)
293315
- [GetTransacSmsReport](docs/Model/GetTransacSmsReport.md)
294316
- [GetTransacSmsReportReports](docs/Model/GetTransacSmsReportReports.md)
295317
- [GetWebhook](docs/Model/GetWebhook.md)
@@ -305,6 +327,7 @@ Class | Method | HTTP request | Description
305327
- [RemoveContactFromList](docs/Model/RemoveContactFromList.md)
306328
- [RemoveCredits](docs/Model/RemoveCredits.md)
307329
- [RequestContactExport](docs/Model/RequestContactExport.md)
330+
- [RequestContactExportCustomContactFilter](docs/Model/RequestContactExportCustomContactFilter.md)
308331
- [RequestContactImport](docs/Model/RequestContactImport.md)
309332
- [RequestContactImportNewList](docs/Model/RequestContactImportNewList.md)
310333
- [RequestSmsRecipientExport](docs/Model/RequestSmsRecipientExport.md)

docs/Api/EmailCampaignsApi.md

Lines changed: 122 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,11 @@ Method | HTTP request | Description
77
[**createEmailCampaign**](EmailCampaignsApi.md#createEmailCampaign) | **POST** /emailCampaigns | Create an email campaign
88
[**deleteEmailCampaign**](EmailCampaignsApi.md#deleteEmailCampaign) | **DELETE** /emailCampaigns/{campaignId} | Delete an email campaign
99
[**emailExportRecipients**](EmailCampaignsApi.md#emailExportRecipients) | **POST** /emailCampaigns/{campaignId}/exportRecipients | Export the recipients of a campaign
10+
[**getAbTestCampaignResult**](EmailCampaignsApi.md#getAbTestCampaignResult) | **GET** /emailCampaigns/{campaignId}/abTestCampaignResult | Get A/B test email campaign result
1011
[**getEmailCampaign**](EmailCampaignsApi.md#getEmailCampaign) | **GET** /emailCampaigns/{campaignId} | Get campaign informations
1112
[**getEmailCampaigns**](EmailCampaignsApi.md#getEmailCampaigns) | **GET** /emailCampaigns | Return all your created campaigns
12-
[**sendEmailCampaignNow**](EmailCampaignsApi.md#sendEmailCampaignNow) | **POST** /emailCampaigns/{campaignId}/sendNow | Send an email campaign id of the campaign immediately
13+
[**getSharedTemplateUrl**](EmailCampaignsApi.md#getSharedTemplateUrl) | **GET** /emailCampaigns/{campaignId}/sharedUrl | Get a shared template url
14+
[**sendEmailCampaignNow**](EmailCampaignsApi.md#sendEmailCampaignNow) | **POST** /emailCampaigns/{campaignId}/sendNow | Send an email campaign immediately, based on campaignId
1315
[**sendReport**](EmailCampaignsApi.md#sendReport) | **POST** /emailCampaigns/{campaignId}/sendReport | Send the report of a campaigns
1416
[**sendTestEmail**](EmailCampaignsApi.md#sendTestEmail) | **POST** /emailCampaigns/{campaignId}/sendTest | Send an email campaign to your test list
1517
[**updateCampaignStatus**](EmailCampaignsApi.md#updateCampaignStatus) | **PUT** /emailCampaigns/{campaignId}/status | Update a campaign status
@@ -188,6 +190,65 @@ Name | Type | Description | Notes
188190

189191
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
190192

193+
# **getAbTestCampaignResult**
194+
> \SendinBlue\Client\Model\AbTestCampaignResult getAbTestCampaignResult($campaignId)
195+
196+
Get A/B test email campaign result
197+
198+
Obtain winning version of an A/B test email campaign
199+
200+
### Example
201+
```php
202+
<?php
203+
require_once(__DIR__ . '/vendor/autoload.php');
204+
205+
// Configure API key authorization: api-key
206+
$config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKey('api-key', 'YOUR_API_KEY');
207+
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
208+
// $config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('api-key', 'Bearer');
209+
// Configure API key authorization: partner-key
210+
$config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKey('partner-key', 'YOUR_API_KEY');
211+
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
212+
// $config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('partner-key', 'Bearer');
213+
214+
$apiInstance = new SendinBlue\Client\Api\EmailCampaignsApi(
215+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
216+
// This is optional, `GuzzleHttp\Client` will be used as default.
217+
new GuzzleHttp\Client(),
218+
$config
219+
);
220+
$campaignId = 789; // int | Id of the A/B test campaign
221+
222+
try {
223+
$result = $apiInstance->getAbTestCampaignResult($campaignId);
224+
print_r($result);
225+
} catch (Exception $e) {
226+
echo 'Exception when calling EmailCampaignsApi->getAbTestCampaignResult: ', $e->getMessage(), PHP_EOL;
227+
}
228+
?>
229+
```
230+
231+
### Parameters
232+
233+
Name | Type | Description | Notes
234+
------------- | ------------- | ------------- | -------------
235+
**campaignId** | **int**| Id of the A/B test campaign |
236+
237+
### Return type
238+
239+
[**\SendinBlue\Client\Model\AbTestCampaignResult**](../Model/AbTestCampaignResult.md)
240+
241+
### Authorization
242+
243+
[api-key](../../README.md#api-key), [partner-key](../../README.md#partner-key)
244+
245+
### HTTP request headers
246+
247+
- **Content-Type**: application/json
248+
- **Accept**: application/json
249+
250+
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
251+
191252
# **getEmailCampaign**
192253
> \SendinBlue\Client\Model\GetEmailCampaign getEmailCampaign($campaignId)
193254
@@ -312,10 +373,69 @@ Name | Type | Description | Notes
312373

313374
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
314375

376+
# **getSharedTemplateUrl**
377+
> \SendinBlue\Client\Model\GetSharedTemplateUrl getSharedTemplateUrl($campaignId)
378+
379+
Get a shared template url
380+
381+
Get a unique URL to share & import an email template from one Sendinblue account to another.
382+
383+
### Example
384+
```php
385+
<?php
386+
require_once(__DIR__ . '/vendor/autoload.php');
387+
388+
// Configure API key authorization: api-key
389+
$config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKey('api-key', 'YOUR_API_KEY');
390+
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
391+
// $config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('api-key', 'Bearer');
392+
// Configure API key authorization: partner-key
393+
$config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKey('partner-key', 'YOUR_API_KEY');
394+
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
395+
// $config = SendinBlue\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('partner-key', 'Bearer');
396+
397+
$apiInstance = new SendinBlue\Client\Api\EmailCampaignsApi(
398+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
399+
// This is optional, `GuzzleHttp\Client` will be used as default.
400+
new GuzzleHttp\Client(),
401+
$config
402+
);
403+
$campaignId = 789; // int | Id of the campaign or template
404+
405+
try {
406+
$result = $apiInstance->getSharedTemplateUrl($campaignId);
407+
print_r($result);
408+
} catch (Exception $e) {
409+
echo 'Exception when calling EmailCampaignsApi->getSharedTemplateUrl: ', $e->getMessage(), PHP_EOL;
410+
}
411+
?>
412+
```
413+
414+
### Parameters
415+
416+
Name | Type | Description | Notes
417+
------------- | ------------- | ------------- | -------------
418+
**campaignId** | **int**| Id of the campaign or template |
419+
420+
### Return type
421+
422+
[**\SendinBlue\Client\Model\GetSharedTemplateUrl**](../Model/GetSharedTemplateUrl.md)
423+
424+
### Authorization
425+
426+
[api-key](../../README.md#api-key), [partner-key](../../README.md#partner-key)
427+
428+
### HTTP request headers
429+
430+
- **Content-Type**: application/json
431+
- **Accept**: application/json
432+
433+
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)
434+
315435
# **sendEmailCampaignNow**
316436
> sendEmailCampaignNow($campaignId)
317437
318-
Send an email campaign id of the campaign immediately
438+
Send an email campaign immediately, based on campaignId
319439

320440
### Example
321441
```php

0 commit comments

Comments
 (0)