File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -189,13 +189,19 @@ send SMS messages::
189
189
#[Route('/login/success')]
190
190
public function loginSuccess(TexterInterface $texter): Response
191
191
{
192
+ $options = (new ProviderOptions())
193
+ ->setPriority('high')
194
+ ;
195
+
192
196
$sms = new SmsMessage(
193
197
// the phone number to send the SMS message to
194
198
'+1411111111',
195
199
// the message
196
200
'A new login was detected!',
197
201
// optionally, you can override default "from" defined in transports
198
202
'+1422222222',
203
+ // you can also add options object implementing MessageOptionsInterface
204
+ $options
199
205
);
200
206
201
207
$sentMessage = $texter->send($sms);
@@ -208,6 +214,10 @@ send SMS messages::
208
214
209
215
The 3rd argument of ``SmsMessage `` (``$from ``) was introduced in Symfony 6.2.
210
216
217
+ .. versionadded :: 6.3
218
+
219
+ The 4th argument of ``SmsMessage `` (``$options ``) was introduced in Symfony 6.3.
220
+
211
221
The ``send() `` method returns a variable of type
212
222
:class: `Symfony\\ Component\\ Notifier\\ Message\\ SentMessage ` which provides
213
223
information such as the message ID and the original message contents.
You can’t perform that action at this time.
0 commit comments