Giter VIP home page Giter VIP logo

notifo-io / notifo Goto Github PK

View Code? Open in Web Editor NEW
718.0 14.0 69.0 24.86 MB

Multi channel notification service for collaboration tools, e-commerce, news service and more.

License: MIT License

Dockerfile 0.05% C# 68.31% HTML 1.84% PowerShell 0.05% JavaScript 0.23% TypeScript 24.03% SCSS 4.73% CSS 0.14% Liquid 0.64%
asp-net notifications web-push mobile-push react bootstrap email email-marketing sms-messages mjml-template

notifo's Introduction

Notifo - Notification Service

Release Docker Image Version (latest by date)

Try it out at https://app.notifo.io!

Notifo is a multi-channel notification service for collaboration tools, e-commerce, news, magazines and everybody who wants to notify their users.

Notifo Tour

Features

  • Powerful and rich REST API with OpenAPI documentation.
  • Management UI to create notification templates, users, subscription, projects, settings and email templates.
  • Email templates with MJML and Liquid Templates.
  • Rich notification with a lot of formatting options like small and large images.
  • Abstraction over multiple channels and providers
    • Emails (currently Amazon SES)
    • Web (Sockets)
    • WebPush (custom built)
    • MobilePush (currently Google Firebase)
    • SMS (currently MessageBird)
  • Reliable through retry mechanisms and message queues for all notifications and channels.
  • Tracking which notification has been read or confirmed.
  • Integrated plugin to add a notification overlay to your web application.

Integrations

Integrations

How it works

  • Users subscribe to topics that are defined by a path such as clothes/shoes/nike. It is your job to provide a good UI for that.
  • Backend creates events using very specific topic paths, such as clothes/shoes/nike/<model>.
  • Notifo creates user events based on the matching subscriptions. Subscriptions are either for specific paths or parent paths as in the example above and having individual notification preferences.
  • Queues and schedulers are responsible to send notifications to users when the notification has not been confirmed yet.

This allows a wide range of scenarios:

  • In a task management system you can automatically subscribe users to a project, e.g. project/123 and use a notification preference to only send web notifiations or web push notifications. When a user manually subscribes to a specific task, e.g. project/123/tasks/abc you can create this subscription with a preference to send out emails as well.

  • Notifications can have a confirmation preference (None, Explicit, Seen). Only unconfirmed notifications are sent through a channel and you can configure a delay when sending notifications. This means that a user does not receive a confirmation when he or she has already explicitly confirmed it (Explicit Mode) or has seen it (Seen mode). This avoids to spam your users which notifications he does not need anymore and you can also track who has seen or confirmed urgent and important notifications.

Have a look to the presentation to understand how it works.

How to run it

Before you install it, try it out at https://app.notifo.io

Install it using the docker image

docker images are available: https://hub.docker.com/r/squidex/notifo, you can try the docker-compose file.

Read more about the installation in the wiki.

How to configure it

Have a look to the settings for all configuration options: appsettings.json. Everything in the settings can be configured using environment variables.

The following setting

"mongoDB": {
    "connectionString": "mongodb://localhost",
},

is mapped to the enviornment variable MONGODB__CONNECTIONSTRING (note the double underscore).

Read more about configuration in the wiki.

Tech Stack

Notifo uses the following technologies.

Server

  • ASP.NET Core 6 for Multi-Platform Support
  • SignalR for Sockets
  • MongoDB (support for more Databases is planned)
  • OpenID Connect

Frontend

  • React
  • React Router
  • Formik
  • Redux
  • Redux Toolkit
  • Typescript
  • Bootstrap with custom Sass and Argon Design Theme.
  • ...many more libraries.

Where is it used?

It was originally developed for Squidex Headless CMS (https://squidex.io), it is also used in a few other commercial applications in a testing stage.

Currently it is still in Beta and some features such as Mobile Push and Emails are not used in production yet.

How to contribute?

There is still a lot to do:

  • Support for other databases (I would prefer https://github.com/sebastienros/yessql)
  • Other Email providers.
  • Other SMS providers.
  • Test application for mobile push (iOS and Android)
  • Hardening scheduling and message queues.
  • More channels (e.g. WhatsApp or Voice).
  • Testing and tests
  • Automated API and UI tests and more tests in general.

Sponsors

Notifo is sponsored and used by the following companies.

Squidex Squidex

notifo's People

Contributors

alibildir avatar arciiix avatar cazim avatar cr4567 avatar jannishuebl avatar matthiez avatar sanyandreichuk avatar sebastianstehle avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

notifo's Issues

Templatename is not set in editing Mode

Hi,

when trying to edit an Email Template the name is not set in the name Textfield. Which causes the name to be empty after saving the Template:

image

image

My current version: docker image: dev-362

Firebase Token Error response handling

I'm wondering about the error code handling of firebase.
See


There is a handling for error code "NotFound" and "InvalidArgument", but on firebase admin doc I can't find the notFound code. Instead for invalidating the token we should wait for "Unregistered". I would expect that this is the also the only response that should trigger an invalidation. All other errors are not related to the life of the token.
Bildschirmfoto 2021-12-14 um 14 21 48
https://firebase.google.com/docs/reference/admin/dotnet/namespace/firebase-admin/messaging#namespace_firebase_admin_1_1_messaging_1ac3482b9d4581255dee08b81ac3f677c9

Push details popover overlaps Publish dialog.

  1. Go to the User Details page
  2. Click on the mobile push icon.
  3. Click on Publish button.

Actual result: push details popover visible and overlaps publish dialog.
Expected result: push details popover hidden or publish dialog is above push details popover.

chrome_2021-06-25_16-15-15

Query of allowed topics

When creating a allowed topic with:

https://app.notifo.io/api/docs/index.html?url=/api/openapi.json#operation/Users_PostAllowedTopic

There is no possiblity to query the allowed topics again.

I would propose returning them as a field in the GET users/:id endpoint and GET /me:

eg:

{

    "fullName": "string",
    "emailAddress": "string",
    "phoneNumber": "string",
    "preferredLanguage": "string",
    "preferredTimezone": "string",
    "allowedTopics": 

[

    "string"

],
    "supportedLanguages": 

[

    "string"

],
"supportedTimezones": 
[

    "string"

],
"settings": 
{

    "property1": 

{},
"property2": 

        {}
    }

}

Exception when sending WebPush

Currently, I get some "A task was canceled" exceptions when sending WebPush Messages.
Is this related to the change of the exception handling in the last build?

 at System.Net.Http.HttpClient.HandleFailure(Exception e, Boolean telemetryStarted, HttpResponseMessage response, CancellationTokenSource cts, CancellationToken cancellationToken, CancellationTokenSource pendingRequestsCts)
   at System.Net.Http.HttpClient.<SendAsync>g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
   at WebPush.WebPushClient.SendNotificationAsync(PushSubscription subscription, String payload, Dictionary`2 options, CancellationToken cancellationToken)
   at Notifo.Domain.Channels.WebPush.WebPushChannel.SendCoreAsync(WebPushJob job, CancellationToken ct) in /src/src/Notifo.Domain/Channels/WebPush/WebPushChannel.cs:line 191
   at Notifo.Domain.Channels.WebPush.WebPushChannel.SendAsync(WebPushJob job, CancellationToken ct) in /src/src/Notifo.Domain/Channels/WebPush/WebPushChannel.cs:line 160
   at Notifo.Domain.Channels.WebPush.WebPushChannel.HandleAsync(WebPushJob job, Boolean isLastAttempt, CancellationToken ct) in /src/src/Notifo.Domain/Channels/WebPush/WebPushChannel.cs:line 139
   at Notifo.Infrastructure.Scheduling.Implementation.DelegatingScheduleHandler`1.OnSuccessAsync(List`1 jobs, Boolean isLastAttempt, CancellationToken ct) in /src/src/Notifo.Infrastructure/Scheduling/Implementation/DelegatingScheduleHandler.cs:line 43
   at Notifo.Infrastructure.Scheduling.Implementation.TimerBased.TimerConsumer`1.HandleAsync(SchedulerBatch`1 document) in /src/src/Notifo.Infrastructure/Scheduling/Implementation/TimerBased/TimerConsumer.cs:line 160

Propagate context

Propage context of telemetry operations through queues and link them.

Exception when trying to create new user

Currently our notifo instance is throwing an exception "System.InvalidOperationException" when trying to create a user via API.
see stack trace:

at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)

at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider)

at Notifo.Domain.Users.UpdateUser.ExecuteAsync(User user, IServiceProvider serviceProvider, CancellationToken ct) in /src/src/Notifo.Domain/Users/UpdateUser.cs:line 140

at Notifo.Domain.Users.UserStore.<>c__DisplayClass14_0.<<UpsertAsync>b__0>d.MoveNext() in /src/src/Notifo.Domain/Users/UserStore.cs:line 157
--- End of stack trace from previous location ---
at Notifo.Infrastructure.Updater.UpdateRetriedAsync[T](Int32 numRetries, Func1 action)

at Notifo.Areas.Api.Controllers.Users.UsersController.PostUsers(String appId, UpsertUsersDto request) in /src/src/Notifo/Areas/Api/Controllers/Users/UsersController.cs:line 189

at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfIActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)

at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Logged|12_1(ControllerActionInvoker invoker)   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)

at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)

at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)

at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)

at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextExceptionFilterAsync>g__Awaited|26_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)

"Error message": "No service for type 'Notifo.Domain.Utils.IApiKeyGenerator' has been registered."

Updating users is still working.

Prepare teaser images

  • Make screenshots
  • Make teaser tour with USPs.
  • Create Gif from screenshots
  • Embed to Readme.md

Allow subscribing for subtopics for users

Hi,

I am implementing notifo notifications in my application right now. But what I would need is:

  1. User can subscribe to "subtopics" eg:
    /users/:id/topic1
    /users/:id/topic2
    /users/:id/topic3

  2. Only the user with :id is allowed to do this, since otherwise other users could subscribe to notifications for another user

Current state:

In the version docker: notifo:dev-364 it is allowed to subscribe to the subtopics also for other users, but you don't recive notifications for this subtopics at all.

Is there the plan to support such a feature? I could try to help, but i have no experience in C#, but i could help with the documentation instead.

Create v1.0 Tag

  • Ensure that nuget package has correct version
  • Publish package
  • Publish to producthunt

App does not work after reboot

Hi,

after a reboot of my dev machine and restart of the notifo container, the webapp shows a blank page and gives me following output in the console:

UserManager.getUser: user not found in storage

A new (private) browser window shows the login page. So i guess it could have something to do which cookies/session/caching?

I am runing notifo via docker (latest version)

Password Reset/Recovery

What to do if a user forgot the login password?
A recovery email would be helpful.

Maybe as a button on the login page and/or a function for admins

TokenRefreshManager Exception

Hi,
since one of the last builds - 360/361, I get lots of exceptions for action "HandleJob".
It looks like there is an issue in receiving new push tokens. I attached the stack trace:

   at Google.Apis.Auth.OAuth2.TokenRefreshManager.GetAccessTokenForRequestAsync(CancellationToken cancellationToken)
   at Google.Apis.Auth.OAuth2.ServiceAccountCredential.GetAccessTokenForRequestAsync(String authUri, CancellationToken cancellationToken)
   at Google.Apis.Auth.OAuth2.ServiceCredential.GetAccessTokenWithHeadersForRequestAsync(String authUri, CancellationToken cancellationToken)
   at Google.Apis.Auth.OAuth2.ServiceCredential.InterceptAsync(HttpRequestMessage request, CancellationToken cancellationToken)
   at Google.Apis.Http.ConfigurableMessageHandler.CredentialInterceptAsync(HttpRequestMessage request, CancellationToken cancellationToken)
   at Google.Apis.Http.ConfigurableMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
   at System.Net.Http.HttpClient.<SendAsync>g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
   at FirebaseAdmin.Util.ErrorHandlingHttpClient`1.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
   at FirebaseAdmin.Util.ErrorHandlingHttpClient`1.SendAndReadAsync(HttpRequestMessage request, CancellationToken cancellationToken)
   at FirebaseAdmin.Util.ErrorHandlingHttpClient`1.SendAndDeserializeAsync[TResult](HttpRequestMessage request, CancellationToken cancellationToken)
   at FirebaseAdmin.Messaging.FirebaseMessagingClient.SendAsync(Message message, Boolean dryRun, CancellationToken cancellationToken)
   at FirebaseAdmin.Messaging.FirebaseMessaging.SendAsync(Message message, Boolean dryRun, CancellationToken cancellationToken)
   at FirebaseAdmin.Messaging.FirebaseMessaging.SendAsync(Message message, CancellationToken cancellationToken)
   at Notifo.Domain.Integrations.Firebase.FirebaseMobilePushSender.SendAsync(UserNotification userNotification, MobilePushOptions options, CancellationToken ct) in /src/src/Notifo.Domain.Integrations/Firebase/FirebaseMobilePushSender.cs:line 48
   at Notifo.Domain.Channels.MobilePush.MobilePushChannel.SendCoreAsync(MobilePushJob job, UserNotification notification, App app, List`1 senders, CancellationToken ct) in /src/src/Notifo.Domain/Channels/MobilePush/MobilePushChannel.cs:line 267
   at Notifo.Domain.Channels.MobilePush.MobilePushChannel.SendAsync(MobilePushJob job, CancellationToken ct) in /src/src/Notifo.Domain/Channels/MobilePush/MobilePushChannel.cs:line 249
   at Notifo.Domain.Channels.MobilePush.MobilePushChannel.HandleAsync(MobilePushJob job, Boolean isLastAttempt, CancellationToken ct) in /src/src/Notifo.Domain/Channels/MobilePush/MobilePushChannel.cs:line 200
   at Notifo.Infrastructure.Scheduling.Implementation.DelegatingScheduleHandler`1.OnSuccessAsync(List`1 jobs, Boolean isLastAttempt, CancellationToken ct) in /src/src/Notifo.Infrastructure/Scheduling/Implementation/DelegatingScheduleHandler.cs:line 43
   at Notifo.Infrastructure.Scheduling.Implementation.TimerBased.TimerConsumer`1.HandleAsync(SchedulerBatch`1 document) in /src/src/Notifo.Infrastructure/Scheduling/Implementation/TimerBased/TimerConsumer.cs:line 160

Prepare setup page

User should see an initial setup page when system has no user.

  • Setup page should check for basic settings
    • Https enabled
    • Base URL correctly.
  • Setup page should allow to create admin user.

Documentation needed

Hello,

I love your project, and see some huge potential in it. After all I'm stuck in a validation process of the software, is there any kind of documentation using the API to publish to a topic with some payload?

Also I'm unable to assigne a specific topic to a given user.

Kind regards Eric

Exception on WebPushChannel

After upgrading to the last docker version 360, I can see a new Exception occurring. Not sure if it's related to the last changes but haven't seen this before.

at Notifo.Infrastructure.Collections.ReadonlyDictionary`2.get_Item (ReadonlyDictionary{TKey,TValue}.cs:24)
at Notifo.Domain.Channels.WebPush.WebPushChannel.SendCoreAsync (WebPushChannel.cs:154)
at Notifo.Domain.Channels.WebPush.WebPushChannel.SendAsync (WebPushChannel.cs:137)
at Notifo.Domain.Channels.WebPush.WebPushChannel.HandleAsync (WebPushChannel.cs:122)
at Notifo.Infrastructure.Scheduling.Implementation.DelegatingScheduleHandler`1.OnSuccessAsync (DelegatingScheduleHandler.cs:43)
at Notifo.Infrastructure.Scheduling.Implementation.TimerBased.TimerConsumer`1.HandleAsync (TimerConsumer.cs:160)

Profile page

  • View profile information.
  • Edit password, display name and email.

Dynamic user properties for integrations

Some integration need custom user properties, for example to store ThreemaId or TelegramID and so on. But adding an integration should not change any other aspects of the code.

Therefore we need dynamic properties for users. just a Dictionary<string, string>. To support it in the UI an integration should also provide a list of all properties.

Tracking of not delivered message

Hey,
I was wondering if it's possible to get more insights in notification confirmation.
In our current push system it's sometimes possible that a customers' push token gets invalid but for any reason the mobile app was not uploading a new one. So new messages can't be pushed to the customer.

With notifo and the confirmation handling it should be possible to get insights in how many notifications are not handled for a specific user. With this information we could investigate if there is an issue in uploading the tokens or user disabled push or something else. Maybe it would be also possible to user alerts for higher amounts of not confirmed messages over a specific time. But I guess this could be handled by an external tool like new relic if we have this data.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.