Skip to content

Commit 29a1616

Browse files
committed
Update documentation
1 parent d914a76 commit 29a1616

File tree

1 file changed

+26
-4
lines changed

1 file changed

+26
-4
lines changed

README.md

+26-4
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ Sandbox is minimum application for playing around with PHP MailQ library.
2828

2929
#### Windows
3030

31-
Run `docker run --rm -it -v %cd%:/app composer install` to install PHP dependencies
32-
Run `docker run --rm -it -v %cd%:/app php:cli php /app/sandbox/sandbox.php <API key> <company ID>`
31+
- Run `docker run --rm -it -v %cd%:/app composer install` to install PHP dependencies
32+
- Run `docker run --rm -it -v %cd%:/app php:cli php /app/sandbox/sandbox.php <API key> <company ID>`
3333

3434
#### Unix
3535

36-
Run `docker run --rm -it -v $(pwd):/app composer install` to install PHP dependencies
37-
Run `docker run --rm -it -v $(pwd):/app php:cli php /app/sandbox/sandbox.php <API key> <company ID>`
36+
- Run `docker run --rm -it -v $(pwd):/app composer install` to install PHP dependencies
37+
- Run `docker run --rm -it -v $(pwd):/app php:cli php /app/sandbox/sandbox.php <API key> <company ID>`
3838

3939
Where API key is your private company key used for authentication and company ID is integer number used for identication company.
4040

@@ -134,6 +134,28 @@ $newsletter = new \MailQ\Entities\v2\NewsletterEntity($data);
134134
$mailq->updateNewsletter($newsletter);
135135
$newsletterId = $newsletter->getId();
136136
```
137+
138+
#### Update newsletter in ready state
139+
140+
141+
```php
142+
$data = [
143+
"id" => 1,
144+
"name" => "Awesome newsletter",
145+
"campaign" => "Spring 2016",
146+
"subject" => "Buy our new product",
147+
"senderEmail" => "[email protected]",
148+
"replyToEmail" : "[email protected]",
149+
"sendAs" => "Awesome Company",
150+
"text" => "TmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciwgbmV3c2xldHRlciw=",
151+
"automaticTime" => false,
152+
"templateUrl" => "http://example.org/newsletter.html",
153+
"unsubscribeTemplateUrl" => "http://example.org/unsubscribe.html"
154+
];
155+
$newsletter = new \MailQ\Entities\v2\NewsletterEntity($data);
156+
$mailq->updateNewsletter($newsletter);
157+
$newsletterId = $newsletter->getId();
158+
```
137159
#### Get all newsletters
138160

139161
```php

0 commit comments

Comments
 (0)