Modifying readme

This commit is contained in:
Loann 2020-04-10 13:10:48 +02:00
parent e619f68be8
commit 34986e1a99
1 changed files with 12 additions and 6 deletions

View File

@ -46,15 +46,21 @@ BMAIL_API_URL=the_api_url
```bash
$template = (new BMailTemplate("** template_id **"))
->sender("john.doe@gmail.com", 'John')
->replyTo("jean.grey@gmail.com", 'Jean')
->sender("john.doe@gmail.com", 'John OPTIONNAL') OPTIONNAL
->replyTo("jean.grey@gmail.com", 'Jean OPTIONNAL') OPTIONNAL
->recipients([
['elvis@gmail.com', ['name' => 'Elvis']],
['matthew@gmail.com', ['name' => 'Matthew', 'parameters' => ['key' => 'value']]
[
'elvis@gmail.com', [
'name' => 'Elvis' OPTIONNAL,
'parameters' => ['key' => 'value'] OPTIONNAL
]
],
[
'robert@gmail.com'
]
])
->addRecipient('edward@gmail.com')
->addRecipient("robert@gmail.com", ['name' => 'Rob', 'parameters' => ['key' => 'value']])
->parameters(['foo' => 'bar', 'foo' => 'fighter'])
->parameters(['key1' => 'value1', 'key2' => 'value2'])
->addParameter('key', 'value');
```