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