コード例 #1
0
        public async Task SendNotification()
        {
            var gateway = new NotificationGateway(new ConfigurationComponent());
            List <NotificationEntity> notifications = new List <NotificationEntity>();

            var entity = new NotificationEntity();

            entity.AddWhom(new MemberEntity()
            {
                Email       = "*****@*****.**",
                Name        = "gregory valderrama",
                SlackMember = "UFR3ZBD6Y"
            });

            entity.AddServiceReason(new ServiceEntity()
            {
                Availability = 0.98m,
                SLO          = 0.99m,
                Name         = "service test",
                Budget       = -0.01m,
                Leaders      = "*****@*****.**"
            }, DateTime.Now, DateTime.Now);

            notifications.Add(entity);
            await gateway.SendNotifications(notifications);
        }