{"id":15018795,"url":"https://github.com/c-klinger/node-raspi-rcswitch-api","last_synced_at":"2026-03-09T03:31:16.648Z","repository":{"id":119179122,"uuid":"96692363","full_name":"c-klinger/node-raspi-rcswitch-api","owner":"c-klinger","description":"RESTful API for the node-rcswitch binding based on Node.js/restify. ","archived":false,"fork":false,"pushed_at":"2020-01-07T14:04:13.000Z","size":11,"stargazers_count":7,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-08-09T14:16:20.145Z","etag":null,"topics":["433","433mhz","api","homeautomation","outlet","power","raspberrypi","rcswitch","rest","restful","rf","rpi","wireless"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/c-klinger.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-07-09T15:13:56.000Z","updated_at":"2020-08-17T03:19:01.000Z","dependencies_parsed_at":"2024-01-13T06:53:51.938Z","dependency_job_id":"9037ffbf-3d88-4b9c-9317-ab9a3ba08518","html_url":"https://github.com/c-klinger/node-raspi-rcswitch-api","commit_stats":{"total_commits":15,"total_committers":3,"mean_commits":5.0,"dds":"0.19999999999999996","last_synced_commit":"e4014b790b13dbec66bad1ace132248c77d06d59"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/c-klinger/node-raspi-rcswitch-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/c-klinger%2Fnode-raspi-rcswitch-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/c-klinger%2Fnode-raspi-rcswitch-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/c-klinger%2Fnode-raspi-rcswitch-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/c-klinger%2Fnode-raspi-rcswitch-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/c-klinger","download_url":"https://codeload.github.com/c-klinger/node-raspi-rcswitch-api/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/c-klinger%2Fnode-raspi-rcswitch-api/sbom","scorecard":{"id":260746,"data":{"date":"2025-08-11","repo":{"name":"github.com/c-klinger/node-raspi-rcswitch-api","commit":"e4014b790b13dbec66bad1ace132248c77d06d59"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.1,"checks":[{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Code-Review","score":1,"reason":"Found 2/14 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":9,"reason":"license file detected","details":["Info: project has a license file: LICENSE.md:0","Warn: project license file does not contain an FSF or OSI license."],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 5 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-17T10:47:04.323Z","repository_id":119179122,"created_at":"2025-08-17T10:47:04.324Z","updated_at":"2025-08-17T10:47:04.324Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30281485,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-09T02:57:19.223Z","status":"ssl_error","status_checked_at":"2026-03-09T02:56:26.373Z","response_time":61,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["433","433mhz","api","homeautomation","outlet","power","raspberrypi","rcswitch","rest","restful","rf","rpi","wireless"],"created_at":"2024-09-24T19:52:28.337Z","updated_at":"2026-03-09T03:31:16.163Z","avatar_url":"https://github.com/c-klinger.png","language":"JavaScript","readme":"node-raspi-rcswitch-api\n=======================\n[![npm version](https://badge.fury.io/js/raspi-rcswitch-api.svg)](https://badge.fury.io/js/raspi-rcswitch-api)\n\nRESTful API for the [node-rcswitch](https://github.com/marvinroger/node-rcswitch) binding based on Node.js/restify.\nAllows controlling of 433Mhz RC remote controlled power sockets with the raspberry-pi using HTTP Protocol.\nThere is a [german post](https://chrisklinger.de/2017/07/433-mhz-funksteckdosen-mit-raspberry-pi-ueber-rest-api-schalten/) on my blog describing the hardware requirements and schematics.\n\n## Requirements\n\n* To use node-rcswitch, [WiringPi](https://projects.drogon.net/raspberry-pi/wiringpi/download-and-install/) must be installed in order to compile.\n* Tthe data and power Pins of the transmitter must be connected to the Raspberry Pi.\n\n## Installation\n```bash\n$ npm install raspi-rcswitch-api\n```\n\n## Configuration\n\n* `transmitter_pin` defines the GIPO pin on which the transmitter is connected to the Raspberry Pi. Note the number of the WiringPi data Pin. (see http://wiringpi.com/pins/)\n* `retries` number of times the signal is send (optional)\n\n## Usage\n### Starting\n```bash\n$ npm start\n\n\u003e node-raspi-rcswitch-api@0.1.0 start /home/pi/node-raspi-rcswitch-api\n\u003e node daemon.js start\n\nraspi-rcswitch-api Server started. PID: 9082\nraspi-rcswitch-api listening at port 3000\n```\n\nThe server is running as deamon using [daemonize2](https://github.com/niegowski/node-daemonize2/) by default. As alternative you can start with\n```bash\n$ node server.js\n```\n\n### Stopping\n```bash\n$ npm stop\n```\n\n### Direct device access\nhttp://host:port/api/v1/switch/systemCode/unitCode/state\n\n* `systemCode` five character long binary system code identifying the rc switch system.\n* `unitCode` integer number between 1 and 4 identifying the power socket number in the system.\n* `state` can be either `on` or `off` for the target state of the power socket.\n\nFor example a GET call to `http://host:port/api/v1/switch/10101/2/on` will switch on the second power socket of the system `10101`.\n\n### Mapped device access\nYou can specify named devices in the `device_config.json` file to gain quick access to them.\n\nThe following example provides access the power socket with the system code `01001` and the unit code `1` under the name `Living_Room_Ambient_Light`.\n```json\n{\n  \"Living_Room_Ambient_Light\": {\n    \"systemCode\": \"01001\",\n    \"unitCode\": 1\n  }\n}\n```\n\nNow you can quickly access the power plug using http://host:port/api/v1/switch/Living_Room_Ambient_Light/state. For the `state` and the config values the same restrictions as mentioned in 'Direct device access' section apply.\n\n## License\nCopyright (c) 2017 Chris Klinger. Licensed under MIT license, see  [LICENSE](https://github.com/c-klinger/node-raspi-rcswitch-api/blob/master/LICENSE.md) for the full license.\n\n## Bugs\nSee \u003chttps://github.com/c-klinger/node-raspi-rcswitch-api/issues\u003e.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fc-klinger%2Fnode-raspi-rcswitch-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fc-klinger%2Fnode-raspi-rcswitch-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fc-klinger%2Fnode-raspi-rcswitch-api/lists"}