chef 3745 Posted January 27, 2020 Share Posted January 27, 2020 In the NotificationRequest class the UserIds param would like an array of long integers. But I'm pretty sure it should be an array of GUID's because User Ids are usually GUIDs. I think. @Luke Link to comment Share on other sites More sharing options...
Luke 37008 Posted January 27, 2020 Share Posted January 27, 2020 No, internally everything is based on the long id's now. Only beyond the borders of the api are the guids used. 1 Link to comment Share on other sites More sharing options...
chef 3745 Posted January 27, 2020 Author Share Posted January 27, 2020 Nevermind, I think it's the internal Id's... which would satify the condition. Link to comment Share on other sites More sharing options...
chef 3745 Posted January 27, 2020 Author Share Posted January 27, 2020 Just read this as you where answering, thank you sir. Link to comment Share on other sites More sharing options...
chef 3745 Posted January 27, 2020 Author Share Posted January 27, 2020 Slightly confused here sir. 1. I have created my NotificationFactory class which has created the Notification options in the server. I have Enabled this notification. public IEnumerable<NotificationTypeInfo> GetNotificationTypes() { return new List<NotificationTypeInfo> { new NotificationTypeInfo { Type = "foofoo", Name = "fooBar", Category = "System", //By the way this will not place the notification under System - it creates a new System heading Enabled = true, IsBasedOnUserEvent = false } }; } 2. I have a scheduled task which runs once a day, and will trigger a notification like this: var request = new NotificationRequest() { Date = DateTimeOffset.Now, Description = "foo", Level = NotificationLevel.Warning, Name = "fooBar", NotificationType = "foofoo", SendToUserMode = SendToUserType.Admins, Url = "", //Is this an imageUrl or a link to more information? It's an empty url right now... UserIds = UserManager.Users.Where(i => i.Policy.IsAdministrator).Select(i => i.InternalId).ToArray() }; await NotificationManager.SendNotification(request, CancellationToken.None).ConfigureAwait(false); My question is, what does the notification look like? is it the rectangle that is suppose to appear in the right corner of the browser? I just don;t see anything happen when I run the task, but I'm also not sure what I'm look for. Thank you sir. @@Luke Link to comment Share on other sites More sharing options...
Luke 37008 Posted January 27, 2020 Share Posted January 27, 2020 No, it's the notification outputs that are enabled in server settings. Link to comment Share on other sites More sharing options...
chef 3745 Posted January 27, 2020 Author Share Posted January 27, 2020 I don't think I'm going completely crazy... The emby wiki notifications section mentions one built in notification system (https://support.emby.media/support/solutions/articles/44001159719-notifications) which might have been available on an older version of the server, but is not available anymore? for piece of mind, the notifications (once setup) can only work with plugins (email pushalot etc..). There currently is no internal notification system, and we aren't (necessarily) able to access the Alert List on the dashboard? Link to comment Share on other sites More sharing options...
Luke 37008 Posted January 27, 2020 Share Posted January 27, 2020 There's no built-in notification output. Link to comment Share on other sites More sharing options...
chef 3745 Posted January 27, 2020 Author Share Posted January 27, 2020 Thank you. 2 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now