{"id":21335005,"url":"https://github.com/manasesjesus/c8y_microservice-nodejs","last_synced_at":"2026-05-17T12:32:10.686Z","repository":{"id":43358129,"uuid":"185349557","full_name":"manasesjesus/c8y_microservice-nodejs","owner":"manasesjesus","description":"Cumulocity IoT - Microservice developed using Node.js and Docker. It notifies a Slack channel when there are alarms in the subscribed tenants.","archived":false,"fork":false,"pushed_at":"2023-02-28T22:42:56.000Z","size":507,"stargazers_count":1,"open_issues_count":4,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-22T14:34:36.277Z","etag":null,"topics":["cumulocity-iot","iot-platform","microservices","monitoring","slack"],"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/manasesjesus.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-07T07:47:24.000Z","updated_at":"2022-04-21T18:52:29.000Z","dependencies_parsed_at":"2025-01-22T14:40:55.169Z","dependency_job_id":null,"html_url":"https://github.com/manasesjesus/c8y_microservice-nodejs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manasesjesus%2Fc8y_microservice-nodejs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manasesjesus%2Fc8y_microservice-nodejs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manasesjesus%2Fc8y_microservice-nodejs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manasesjesus%2Fc8y_microservice-nodejs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/manasesjesus","download_url":"https://codeload.github.com/manasesjesus/c8y_microservice-nodejs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243814854,"owners_count":20352037,"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","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":["cumulocity-iot","iot-platform","microservices","monitoring","slack"],"created_at":"2024-11-21T23:37:18.200Z","updated_at":"2026-05-17T12:32:05.666Z","avatar_url":"https://github.com/manasesjesus.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Cumulocity IoT Microservice \n\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/49064d3b224c4c9284cf965d3e45e619)](https://app.codacy.com/app/manasesjesus/c8y_microservice_nodejs?utm_source=github.com\u0026utm_medium=referral\u0026utm_content=manasesjesus/c8y_microservice_nodejs\u0026utm_campaign=Badge_Grade_Dashboard)\n\nCumulocity IoT microservice developed using Node.js and Docker. It notifies a Slack channel when there are alarms in the subscribed tenants.\n\n### Prerequisites\n\n*   Local Docker installation.\n*   A [Cumulocity IoT](https://cumulocity.com) account. Create a free trial to test this example.\n*   Slack channel to post messages to, [Slack app and OAuth token](https://slack.dev/node-slack-sdk/getting-started).\n*   A *.env* file in the root directory with the following content:\n\n```properties\nPORT=80\nSLACK_OAUTH_TOKEN=\u003cYOUR-TOKEN-GOES-HERE\u003e\nSLACK_CHANNEL_ID=\u003cYOUR-CHANNEL_ID-GOES-HERE\u003e\n```\n\n### Build\n\nExecute the following commands to build the Docker image and save it as *image.tar*:\n\n```shell\n$ docker build -t mynode-microservice .\n$ docker save mynode-microservice \u003e \"image.tar\"\n```\n\nThen pack *image.tar* together with the manifest *cumulocity.json* into a ZIP file.\n\n```shell\n$ zip mynode-microservice cumulocity.json image.tar\n```\n\nThe resulting *mynode-microservice.zip* file contains the microservice and it is ready to be uploaded to the Cumulocity IoT platform.\n\n### Deployment\n\nDeploy the microservice application (refer to [Adding own applications](https://cumulocity.com/guides/users-guide/administration/#a-name-adding-applications-a-adding-own-applications) in the Cumulocity IoT's User guide) and subscribe it afterwards. It may take some minutes for the ZIP file to be uploaded. \n\n### Execution\n\nUse a web browser or a terminal command (e.g. cURL) to make a GET request to the microservice endpoints.\n\n```http\nGET \u003ctenant-domain\u003e.cumulocity.com/service/mynode-microservice/environment\n```\n\nThe Slack channel will get the posted messages every time a new alarm is raised on the subscribed tenants.\n\n![Slack app posting alarms](microservice-slack-alarms.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmanasesjesus%2Fc8y_microservice-nodejs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmanasesjesus%2Fc8y_microservice-nodejs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmanasesjesus%2Fc8y_microservice-nodejs/lists"}