docs/platform/integrations/chat.mdx
The Chat channel delivers messages to your subscribers via their preferred chat platforms and application.
Here’s the typical flow for sending a chat notification through Novu:
<Steps> <Step>Start by adding a chat provider in the integration store on your Novu dashboard.
You can connect one or more integrations for different or even the same providers, for example, multiple Slack workspaces.
To learn how to add a chat provider, refer to the setup guide for that provider.
</Step> <Step>Next, include a Chat step in your workflow.
This step defines when and how a chat message should be sent as part of your notification workflow.
Within the Chat step editor, write the message body.
The editor supports dynamic data for personalized and contextual messages.
Each subscriber must have valid chat credentials, such as a webhookUrl or unique identifier, to receive chat notifications.
You can store or update these credentials using the Novu dashboard, API, or SDKs.
Trigger the workflow using your application code. Novu automatically:
webhookUrl.When you add a chat provider in the Integration Store, you'll configure credentials specific to that provider.
You may need to provide credentials specific to your chat provider, such as an API key, Client ID, or Client Secret. However, some providers, like Discord, may not require any global credentials to be set in the Integration Store.
Each provider has different requirements.
<Note> For detailed setup guides for each provider integration, refer to the supported chat providers list at the end of this page . </Note>The chat channel works by storing specific credentials for each subscriber. This credential is typically a webhookUrl that tells Novu where to send a message for that specific subscriber.
Before triggering a chat notification, you must update the subscriber with this webhookUrl.
Use the subscribers.credentials.update method to store the webhookUrl for a specific subscriber and provider.
Checkout the API reference for more details.
<Tabs> <Tab title="Node.js"> ```typescript import { Novu } from '@novu/api'; import { ChatOrPushProviderEnum } from "@novu/api/models/components";const novu = new Novu({ secretKey: "<NOVU_SECRET_KEY>", // Required if using EU region // serverURL: "https://eu.api.novu.co", });
await novu.subscribers.credentials.update( { providerId: ChatOrPushProviderEnum.Discord, credentials: { webhookUrl: "<WEBHOOK_URL>", }, integrationIdentifier: "discord-MnGLxp8uy", }, "subscriberId" );
</Tab>
<Tab title="Python">
```python
import os
import novu_py
from novu_py import Novu
with Novu(secret_key=os.getenv("NOVU_SECRET_KEY", "")) as novu:
novu.subscribers.credentials.update(
subscriber_id="subscriberId",
update_subscriber_channel_request_dto={
"provider_id": novu_py.ChatOrPushProviderEnum.DISCORD,
"credentials": {
"webhook_url": "<WEBHOOK_URL>",
},
"integration_identifier": "discord-MnGLxp8uy",
},
)
novugo "github.com/novuhq/novu-go"
"github.com/novuhq/novu-go/models/components"
)
integrationIdentifier := "discord-MnGLxp8uy" webhookURL := "<WEBHOOK_URL>"
s := novugo.New(novugo.WithSecurity(os.Getenv("NOVU_SECRET_KEY")))
_, err := s.Subscribers.Credentials.Update(context.Background(), "subscriberId", components.UpdateSubscriberChannelRequestDto{ ProviderID: components.ChatOrPushProviderEnumDiscord, IntegrationIdentifier: &integrationIdentifier, Credentials: components.ChannelCredentials{ WebhookURL: &webhookURL, }, }, nil)
</Tab>
<Tab title="PHP">
```php
use novu;
use novu\Models\Components;
$sdk = novu\Novu::builder()
->setSecurity('<NOVU_SECRET_KEY>')
->build();
$sdk->subscribers->updateCredentials(
subscriberId: 'subscriberId',
updateSubscriberChannelRequestDto: new Components\UpdateSubscriberChannelRequestDto(
providerId: Components\ChatOrPushProviderEnum::Discord,
credentials: new Components\ChannelCredentials(
webhookUrl: '<WEBHOOK_URL>',
),
integrationIdentifier: 'discord-MnGLxp8uy',
),
);
var sdk = new NovuSDK(secretKey: "<NOVU_SECRET_KEY>");
await sdk.Subscribers.UpdateCredentialsAsync( subscriberId: "subscriberId", updateSubscriberChannelRequestDto: new UpdateSubscriberChannelRequestDto() { ProviderId = ChatOrPushProviderEnum.Discord, IntegrationIdentifier = "discord-MnGLxp8uy", Credentials = new ChannelCredentials() { WebhookUrl = "<WEBHOOK_URL>", }, } );
</Tab>
<Tab title="Java">
```java
import co.novu.Novu;
import co.novu.models.components.*;
Novu novu = Novu.builder()
.secretKey("<NOVU_SECRET_KEY>")
.build();
novu.subscribers().updateCredentials()
.subscriberId("subscriberId")
.body(UpdateSubscriberChannelRequestDto.builder()
.providerId(ChatOrPushProviderEnum.DISCORD)
.integrationIdentifier("discord-MnGLxp8uy")
.credentials(ChannelCredentials.builder()
.webhookUrl("<WEBHOOK_URL>")
.build())
.build())
.call();
Here are the chat providers that are currently supported by Novu. Select any provider to see its detailed setup guide.
<Columns cols={2}> <Card title="Discord" href="/platform/integrations/chat/discord"> Learn how to use the Discord provider to send chat notifications using Novu. </Card> <Card title="Mattermost" href="/platform/integrations/chat/mattermost"> Learn how to use the Mattermost provider to send chat notifications using Novu.</Card> <Card title="Microsoft Teams" href="/platform/integrations/chat/ms-teams"> Learn how to use the Microsoft Teams provider to send chat notifications using Novu.</Card> <Card title="Slack" href="/platform/integrations/chat/slack"> Learn how to use the Slack provider to send chat notifications using Novu.</Card> <Card title="Telegram" href="/platform/integrations/chat/telegram"> Learn how to use the Telegram provider for chat notifications and agent conversations.</Card> <Card title="WhatsApp Business" href="/platform/integrations/chat/whats-app"> Learn how to use the WhatsApp Business provider to send chat notifications using Novu.</Card> <Card title="Zulip" href="/platform/integrations/chat/zulip"> Learn how to use the Zulip provider to send chat notifications using Novu.</Card> </Columns>