{"id":18248219,"url":"https://github.com/serverless-components/dashboard-notification-handler","last_synced_at":"2025-07-27T10:05:39.143Z","repository":{"id":41767519,"uuid":"212838004","full_name":"serverless-components/dashboard-notification-handler","owner":"serverless-components","description":"Easily build custom integrations for Serverless Dashbaord Notifications using Serverless Components","archived":false,"fork":false,"pushed_at":"2022-12-04T14:38:21.000Z","size":1018,"stargazers_count":0,"open_issues_count":8,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-08T19:52:31.009Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/serverless-components.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-10-04T14:48:04.000Z","updated_at":"2019-10-04T19:29:00.000Z","dependencies_parsed_at":"2023-01-22T20:20:17.842Z","dependency_job_id":null,"html_url":"https://github.com/serverless-components/dashboard-notification-handler","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/serverless-components/dashboard-notification-handler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Fdashboard-notification-handler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Fdashboard-notification-handler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Fdashboard-notification-handler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Fdashboard-notification-handler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/serverless-components","download_url":"https://codeload.github.com/serverless-components/dashboard-notification-handler/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/serverless-components%2Fdashboard-notification-handler/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267340987,"owners_count":24071606,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-27T02:00:11.917Z","response_time":82,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T09:36:16.791Z","updated_at":"2025-07-27T10:05:39.121Z","avatar_url":"https://github.com/serverless-components.png","language":"JavaScript","readme":"# serverless-notification-handler\n\n\u0026nbsp;\n\nEasily deploy a NodeJS or Python function for handling Serverless Insight Alert Notifications.\n\n\u0026nbsp;\n\n1. [Install](#1-install)\n2. [Create](#2-create)\n3. [Configure](#3-configure)\n4. [Deploy](#4-deploy)\n\n\u0026nbsp;\n\n\n### 1. Install\n\n```console\n$ npm install -g serverless\n```\n\n### 2. Create\n\n```console\n$ mkdir notification-forwarder \u0026\u0026 cd notification-forwarder\n```\n\nThe directory should look something like this:\n\n\n```\n|- handler.js # OR handler.py\n|- serverless.yml\n|- .env         # your AWS api keys\n```\n\nthe `.env` file should look like this\n\n```\nAWS_ACCESS_KEY_ID=XXX\nAWS_SECRET_ACCESS_KEY=XXX\n```\n\nThe `handler.js` or `handler.py` file should contain a function to handle an alert notification event from\nServerless Insights.\n\n```python\nmodule.exports.alert = (notification) =\u003e {\n  console.log('got notification', notification);\n}\n```\n\n```python\ndef alert(notification):\n    print('got notification', notification)\n```\n\n### 3. Configure\n\nConfigure your `serverless.yml` as follows:\n\n```yml\n# serverless.yml\n\nname: notification-handler\nstage: dev\n\nnotificationHandler:\n  component: '@serverless/notification-handler'\n  inputs:\n    code: .\n    handler: handler.alert\n    env:\n      FOOBAR: ${env.FOOBAR} # Optional, set any env vars for your code\n```\n\n### 4. Deploy\n\n```console\n$ serverless\n```\n\n### 5. Configure the Serverless Dashboard\n\nPaste the ARN printed in the output of the previous step into the SNS notification configuration on\ndashboard.serverless.com for your app.\n\n\u0026nbsp;\n\n### New to Components?\n\nCheckout the [Serverless Components](https://github.com/serverless/components) repo for more information.\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fserverless-components%2Fdashboard-notification-handler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fserverless-components%2Fdashboard-notification-handler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fserverless-components%2Fdashboard-notification-handler/lists"}