Files
hrynco-notification-service/HrynCo.NotificationService.Web/HrynCo.NotificationService.Web.http
T
Anatolii Grynchuk 50828d23ec refactor: replace internal UnitOfWork with NotificationUnitOfWork and NotificationBaseRepository
- Consolidate unit of work implementation with NotificationUnitOfWork.
- Refactor repositories to use NotificationBaseRepository for consistency.
- Simplify request handlers by removing IUnitOfWork dependency.
- Update related tests and service registration.
2026-05-13 02:08:43 +03:00

48 lines
2.9 KiB
HTTP
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
@host = http://localhost:5188
### Create a new email template
POST {{host}}/api/v1/email-templates
Content-Type: application/json
{
"ServiceName": "StoreMate-Prod",
"Key": "ShareInvite",
"LanguageCode": "uk",
"Subject": "Вас запрошено",
"HtmlBody": "<html><body><div style=\"font-family: Arial, sans-serif; color: #1f2937;\"><p>Вітаємо, \u007b\u007bRecipientName\u007d\u007d.</p><h1>Вас запрошено</h1><p>\u007b\u007bInviterName\u007d\u007d запросив вас приєднатися до \u007b\u007bAppName\u007d\u007d, щоб ви могли безпечно співпрацювати.</p><p><a href=\"\u007b\u007bInviteLink\u007d\u007d\">Відкрити запрошення</a></p><p>Запрошення дійсне до <strong>\u007b\u007bValidUntil\u007d\u007d</strong>.</p></div></body></html>",
"TextBody": "Вітаємо, \u007b\u007bRecipientName\u007d\u007d.\n\n\u007b\u007bInviterName\u007d\u007d запросив вас приєднатися до \u007b\u007bAppName\u007d\u007d, щоб ви могли безпечно співпрацювати.\n\nВідкрийте запрошення: \u007b\u007bInviteLink\u007d\u007d\nДійсне до: \u007b\u007bValidUntil\u007d\u007d",
"Variables": [
{ "Name": "RecipientName", "Required": false },
{ "Name": "InviterName", "Required": false },
{ "Name": "AppName", "Required": false },
{ "Name": "InviteLink", "Required": false },
{ "Name": "ValidUntil", "Required": false }
]
}
### Get the created template
GET {{host}}/api/v1/email-templates/StoreMate-Prod/ShareInvite/uk
### List all templates for the service
GET {{host}}/api/v1/email-templates?serviceName=StoreMate-Prod
### Update the template
PUT {{host}}/api/v1/email-templates/StoreMate-Prod/ShareInvite/uk
Content-Type: application/json
{
"Subject": "Вас запрошено",
"HtmlBody": "<html><body><p>Вітаємо, \u007b\u007bRecipientName\u007d\u007d.</p><p>\u007b\u007bInviterName\u007d\u007d запросив вас приєднатися до \u007b\u007bAppName\u007d\u007d.</p><p><a href=\"\u007b\u007bInviteLink\u007d\u007d\">Відкрити запрошення</a></p><p>Дійсне до <strong>\u007b\u007bValidUntil\u007d\u007d</strong>.</p></body></html>",
"TextBody": "Вітаємо, \u007b\u007bRecipientName\u007d\u007d.\n\n\u007b\u007bInviterName\u007d\u007d запросив вас приєднатися до \u007b\u007bAppName\u007d\u007d.\n\nВідкрийте запрошення: \u007b\u007bInviteLink\u007d\u007d\nДійсне до: \u007b\u007bValidUntil\u007d\u007d",
"Variables": [
{ "Name": "RecipientName", "Required": false },
{ "Name": "InviterName", "Required": false },
{ "Name": "AppName", "Required": false },
{ "Name": "InviteLink", "Required": false },
{ "Name": "ValidUntil", "Required": false }
]
}
### Delete the template
DELETE {{host}}/api/v1/email-templates/StoreMate-Prod/ShareInvite/uk