Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(providers): add zulip #4457

Merged
merged 11 commits into from
Oct 31, 2023
4 changes: 3 additions & 1 deletion .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,9 @@
"messagebird",
"Datetime",
"simpletexting",
"Simpletexting"
"Simpletexting",
"Zulip",
"zulip"
],
"flagWords": [],
"patterns": [
Expand Down
14 changes: 14 additions & 0 deletions apps/web/public/static/images/providers/dark/square/zulip.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
19 changes: 19 additions & 0 deletions apps/web/public/static/images/providers/dark/zulip.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions apps/web/public/static/images/providers/light/square/zulip.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
19 changes: 19 additions & 0 deletions apps/web/public/static/images/providers/light/zulip.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions libs/shared/src/consts/providers/channels/chat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,12 @@ export const chatProviders: IProviderConfig[] = [
docReference: 'https://api.ryver.com/ryvrest_api_examples.html#create-chat-message',
logoFileName: { light: 'ryver.png', dark: 'ryver.png' },
},
{
id: ChatProviderIdEnum.Zulip,
displayName: 'Zulip',
channel: ChannelTypeEnum.CHAT,
credentials: [] as IConfigCredentials[],
docReference: 'https://docs.novu.co/channels-and-providers/chat/zulip',
logoFileName: { light: 'zulip.svg', dark: 'zulip.svg' },
},
];
1 change: 1 addition & 0 deletions libs/shared/src/consts/providers/provider.enum.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ export enum ChatProviderIdEnum {
MsTeams = 'msteams',
Mattermost = 'mattermost',
Ryver = 'ryver',
Zulip = 'zulip',
}

export enum PushProviderIdEnum {
Expand Down
1 change: 1 addition & 0 deletions packages/application-generic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@
"@novu/termii": "^0.21.0",
"@novu/testing": "^0.21.0",
"@novu/twilio": "^0.21.0",
"@novu/zulip": "^0.21.0",
"@sentry/node": "^7.12.1",
"analytics-node": "^6.2.0",
"bullmq": "^3.10.2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { DiscordHandler } from './handlers/discord.handler';
import { MSTeamsHandler } from './handlers/msteams.handler';
import { MattermostHandler } from './handlers/mattermost.handler';
import { RyverHandler } from './handlers/ryver.handler';
import { ZulipHandler } from './handlers/zulip.handler';

export class ChatFactory implements IChatFactory {
handlers: IChatHandler[] = [
Expand All @@ -13,6 +14,7 @@ export class ChatFactory implements IChatFactory {
new MSTeamsHandler(),
new MattermostHandler(),
new RyverHandler(),
new ZulipHandler(),
];

getHandler(integration: IntegrationEntity) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { ICredentials, ChatProviderIdEnum } from '@novu/shared';
import { ChannelTypeEnum } from '@novu/stateless';
import { BaseChatHandler } from './base.handler';
import { ZulipProvider } from '@novu/zulip';

export class ZulipHandler extends BaseChatHandler {
constructor() {
super(ChatProviderIdEnum.Zulip, ChannelTypeEnum.CHAT);
}

buildProvider(_credentials: ICredentials) {
this.provider = new ZulipProvider({});
}
}
Loading
Loading