Skip to content

Commit 12fc60a

Browse files
author
Ruben Bisharyan
committed
Update Readme.md
1 parent 2c4cece commit 12fc60a

File tree

1 file changed

+18
-8
lines changed

1 file changed

+18
-8
lines changed

Readme.md

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -241,8 +241,8 @@ public interface ISmsService
241241

242242
public interface IEmailService
243243
{
244-
Task SendAsync(EmailMessage emailMessage, CancellationToken cancellationToken = default);
245-
Task SendBulkAsync(List<EmailMessage> emailMessages, CancellationToken cancellationToken = default);
244+
Task<GeneralEmailResponse> SendAsync(EmailMessage emailMessage, CancellationToken cancellationToken = default);
245+
Task<List<GeneralEmailResponse>> SendBulkAsync(List<EmailMessage> emailMessages, CancellationToken cancellationToken = default);
246246
}
247247
```
248248

@@ -258,13 +258,10 @@ var sms = new SmsMessage
258258
await smsService.SendAsync(sms);
259259
```
260260

261-
Sms service return as well response for each service individually (Not generic), which can be used in the code if you need to store related information into the Database.
261+
Sms service returns general response which includes general properties in already integrated services.
262262

263-
The responses are:
264-
- **DexatelSmsSendResponse**
265-
- **TwilioSmsSendResponse**
266-
267-
Both responses return with list (ex. List<GeneralSmsResponse>) when you use any of the methods to send sms.
263+
Both methods return `List<GeneralSmsResponse>` when you use them while sending sms.
264+
If you set a variable to the call, you will be able to use returned response.
268265

269266
```csharp
270267
public class GeneralSmsResponse
@@ -292,6 +289,19 @@ var email = new EmailMessage
292289
};
293290
await emailService.SendAsync(email);
294291
```
292+
Both methods return response (SendAsync - `GeneralEmailResponse`; SendBulkAsync - `List<GeneralEmailResponse>`) when you use them while sending email.
293+
If you set a variable to the call, you will be able to use returned response.
294+
295+
```csharp
296+
public class GeneralEmailResponse
297+
{
298+
public string Status { get; set; } = null!;
299+
public string Code { get; set; } = null!;
300+
public string TrackingId { get; set; } = null!;
301+
public string Id { get; set; } = null!;
302+
public string Service { get; set; } = null!;
303+
}
304+
```
295305

296306
## 1.6. Limitations
297307

0 commit comments

Comments
 (0)