ArgoCD Notifications lets you send alerts to Slack (and other services) when application syncs succeed or fail, health degrades, or apps are deployed. That keeps your team informed about GitOps pipeline status without opening the ArgoCD UI. This guide walks you through creating a Slack app and bot, storing the token securely in the cluster, configuring triggers and message templates, and subscribing individual applications or whole AppProjects to Slack channels.
In this guide you’ll:
- Create a Slack app and bot, get the Bot User OAuth Token, and add the bot to a channel
- Store the Slack token in a Kubernetes Secret and configure the ArgoCD Notifications ConfigMap (triggers and templates)
- Subscribe applications or projects to Slack using annotations, and optionally set the ArgoCD URL for message links
Related: How to deploy and configure ArgoCD in Kubernetes · Deploy with ArgoCD, GitHub Actions, and Helm
Events you can notify on
ArgoCD Notifications supports many triggers you can subscribe to. Common ones:
| Trigger | When it fires |
|---|---|
on-deployed | App synced and healthy (e.g. once per commit) |
on-sync-succeeded | Sync operation completed successfully |
on-sync-failed | Sync failed |
on-sync-running | Sync in progress |
on-sync-status-unknown | Sync status unknown |
on-health-degraded | Application health became Degraded |
on-app-created | Application resource created |
on-app-deleted | Application resource deleted |
You’ll configure which of these to use and then subscribe Slack channels per application or per project.
Prerequisites
- ArgoCD installed and running in your cluster. If not, see how to deploy and configure ArgoCD in Kubernetes first.
- kubectl access to the cluster where ArgoCD is installed (namespace
argocd). - A Slack workspace where you can create an app and a channel for notifications.
Step 1: Create a Slack app and bot
- Open Create a Slack app and click Create New App → From Scratch.
- Enter an App name (e.g.
ArgoCD Notifications) and select your Slack workspace. - In the left sidebar go to OAuth & Permissions. Under Scopes → Bot Token Scopes, add:
chat:write— so the bot can post messageschat:write.customize— optional, for custom usernames/icons
- At the top of the same page, click Install to Workspace, approve the permissions, then copy the Bot User OAuth Token (starts with
xoxb-).
Keep this token secret. You’ll store it in a Kubernetes Secret in the next step; don’t commit it to Git.
Step 2: Create a Slack channel and add the bot
Create a Slack channel for deployment alerts (public or private). If you already have one, use it.
Important: Invite the bot into the channel. In the channel, type /invite @ArgoCD Notifications (or whatever you named the app). If the bot is not in the channel, it cannot post there and you will not see any notifications.
Step 3: Store the Slack token in ArgoCD
Create a Secret in the argocd namespace so ArgoCD Notifications can use your Slack token. Save the following as argocd-notifications-secret.yaml (replace the placeholder with your Bot User OAuth Token):
apiVersion: v1
kind: Secret
metadata:
name: argocd-notifications-secret
namespace: argocd
stringData:
slack-token: "xoxb-your-bot-oauth-token"
Apply it:
kubectl apply -f argocd-notifications-secret.yaml
Step 4: Configure triggers and templates (ConfigMap)
Create or update the argocd-notifications-cm ConfigMap. The key service.slack tells ArgoCD Notifications to use the slack-token key from argocd-notifications-secret. The trigger on-deployed fires when the app is synced and healthy (once per revision); the template defines the Slack message and attachment.
apiVersion: v1
kind: ConfigMap
metadata:
name: argocd-notifications-cm
namespace: argocd
data:
service.slack: |
token: $slack-token
defaultTriggers: |
- on-deployed
trigger.on-deployed: |
- description: Application is synced and healthy. Triggered once per commit.
oncePer: app.status.operationState.syncResult.revision
send:
- app-deployed
when: app.status.operationState.phase in ['Succeeded'] and app.status.health.status == 'Healthy' and app.status.sync.status == 'Synced'
template.app-deployed: |
message: |
{{if eq .serviceType "slack"}}:white_check_mark:{{end}} Application {{.app.metadata.name}} is now running new version of deployments manifests.
slack:
attachments: |
[{
"title": "{{ .app.metadata.name}}",
"title_link":"{{.context.argocdUrl}}/applications/{{.app.metadata.name}}",
"color": "#18be52",
"fields": [
{
"title": "Sync Status",
"value": "{{.app.status.sync.status}}",
"short": true
},
{
"title": "Repository",
"value": "{{.app.spec.source.repoURL}}",
"short": true
},
{
"title": "Revision",
"value": "{{.app.status.sync.revision}}",
"short": true
}
{{range $index, $c := .app.status.conditions}}
{{if not $index}},{{end}}
{{if $index}},{{end}}
{
"title": "{{$c.type}}",
"value": "{{$c.message}}",
"short": true
}
{{end}}
]
}]
Save as argocd-notifications-cm.yaml. Ensure this ConfigMap is in the argocd namespace (add namespace: argocd under metadata if you’re creating it from scratch).
Apply and restart so ArgoCD loads the new config:
kubectl apply -f argocd-notifications-cm.yaml
kubectl rollout restart deploy argocd-server -n argocd
If you use a standalone notifications controller, restart that deployment too. The title_link in the template uses context.argocdUrl; set that in the argocd-cm ConfigMap (e.g. url: https://argocd.example.com) so Slack messages link to your ArgoCD UI.
Step 5: Subscribe applications or projects to Slack
You tell ArgoCD where to send notifications by adding annotations to an Application or an AppProject. The annotation format is:
notifications.argoproj.io/subscribe.<trigger>.<service>: <recipients>
- <trigger> — e.g.
on-sync-succeeded,on-deployed,on-sync-failed,on-health-degraded - <service> —
slack - <recipients> — one or more Slack channel names, separated by semicolons (e.g.
my-channel1;my-channel2)
Per-application subscription
Add the annotation(s) to the Application’s metadata.annotations. Example: subscribe one channel to several events:
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: stage-citizixapp
namespace: argocd
annotations:
notifications.argoproj.io/subscribe.on-deployed.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-health-degraded.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-sync-succeeded.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-sync-failed.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-sync-status-unknown.slack: argocd-notifications
spec:
destination:
name: in-cluster
namespace: stage
project: main-cluster-apps
source:
path: citizixapp/stage/main-957c4ac
repoURL: https://github.com/etowett/argocd-releases
targetRevision: main
syncPolicy:
automated:
prune: true
Per-project subscription
To send notifications for every application in a project, add the same annotations to the AppProject instead of each Application. Any app in that project will inherit the subscription. Full example:
apiVersion: argoproj.io/v1alpha1
kind: AppProject
metadata:
name: main-cluster-apps
namespace: argocd
# Finalizer that ensures that project is not deleted until it is not referenced by any application
finalizers:
- resources-finalizer.argocd.argoproj.io
annotations:
notifications.argoproj.io/subscribe.on-deployed.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-health-degraded.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-sync-succeeded.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-sync-failed.slack: argocd-notifications
notifications.argoproj.io/subscribe.on-sync-status-unknown.slack: argocd-notifications
spec:
description: Project for argocd local cluster citizix-releases related resources
# Allow manifests to deploy from kubernetes Git repo
sourceRepos:
- "https://github.com/etowett/citizix-releases.git"
# Permit applications to deploy to any namespace in local argocd cluster
destinations:
- namespace: "*"
server: "https://kubernetes.default.svc"
# Allow to deploy any resource
clusterResourceWhitelist:
- group: "*"
kind: "*"
Apply the project (or patch the existing one), then trigger a sync or health change for an app in that project to confirm Slack receives the notification.
Testing
- Ensure the Slack bot is in the channel and the Secret + ConfigMap are applied in
argocdand the server has been restarted. - Add the subscription annotations to an Application or AppProject (as above).
- Trigger an event — e.g. sync an application, or cause a sync failure — and check the channel for the message.
If nothing appears, verify the token in the Secret, that the bot is in the channel, and that the trigger name in your template (e.g. on-deployed) matches the annotation (e.g. subscribe.on-deployed.slack).
Frequently Asked Questions (FAQ)
Where do I get the Slack token for ArgoCD notifications?
Create a Slack app at api.slack.com/apps, add Bot Token Scopes chat:write (and optionally chat:write.customize), install the app to your workspace, then copy the Bot User OAuth Token (starts with xoxb-). Store it in the argocd-notifications-secret Secret under the key slack-token.
Why am I not receiving Slack notifications?
Common causes: (1) the bot is not invited to the channel (/invite @YourBot); (2) the Secret or ConfigMap is missing or in the wrong namespace (argocd); (3) you didn’t restart the ArgoCD server after changing the ConfigMap; (4) the Application or AppProject doesn’t have the notifications.argoproj.io/subscribe.<trigger>.slack annotation; (5) the trigger name in the annotation doesn’t match a trigger defined in argocd-notifications-cm.
Can I subscribe multiple Slack channels?
Yes. Use a semicolon-separated list in the annotation value, e.g. notifications.argoproj.io/subscribe.on-sync-succeeded.slack: channel1;channel2. The bot must be a member of each channel.
Per-application vs per-project subscriptions?
Add annotations to an Application to notify only for that app. Add the same annotations to an AppProject to notify for all applications in that project. Project-level annotations apply to every app in the project.
Conclusion
You’ve set up ArgoCD Slack notifications: created a Slack app and bot, stored the token in a Secret, configured triggers and a message template in argocd-notifications-cm, and subscribed applications or projects to Slack channels via annotations. For installing and configuring ArgoCD itself, see how to deploy and configure ArgoCD in Kubernetes. For a full CI/CD flow that pushes manifests to a GitOps repo consumed by ArgoCD, see deploy with ArgoCD, GitHub Actions, and Helm.