{"id":19977344,"url":"https://github.com/allar/nodecg-beam-service","last_synced_at":"2025-06-13T04:32:43.314Z","repository":{"id":147564893,"uuid":"72726830","full_name":"Allar/nodecg-beam-service","owner":"Allar","description":"Hooks into Beam events for a channel and user","archived":false,"fork":false,"pushed_at":"2017-05-17T00:30:37.000Z","size":10,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-29T23:32:04.957Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://gamemak.in","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/Allar.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}},"created_at":"2016-11-03T08:59:56.000Z","updated_at":"2017-03-15T04:03:38.000Z","dependencies_parsed_at":"2023-04-14T04:07:57.345Z","dependency_job_id":null,"html_url":"https://github.com/Allar/nodecg-beam-service","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Allar/nodecg-beam-service","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Allar%2Fnodecg-beam-service","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Allar%2Fnodecg-beam-service/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Allar%2Fnodecg-beam-service/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Allar%2Fnodecg-beam-service/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Allar","download_url":"https://codeload.github.com/Allar/nodecg-beam-service/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Allar%2Fnodecg-beam-service/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259580943,"owners_count":22879752,"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":[],"created_at":"2024-11-13T03:27:46.994Z","updated_at":"2025-06-13T04:32:43.295Z","avatar_url":"https://github.com/Allar.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# nodecg-beam-service\n\nThis is a [nodecg](https://github.com/nodecg/nodecg) bundle that provides access to [Beam.pro](http://beam.pro) channel and user data.\n\nThis doesn't provide any graphical elements itself, but allows other bundles to easily grab Beam info and catch Beam events.\n\n# Installation\n\nNavigate to your `bundles` folder of your nodecg site, and run:\n\n```\nnodecg install Allar/nodecg-beam-service\n```\n\nYou must configure the bundle before it can be loaded.\n\n# Configuration\n\nCreate file named `cfg/nodecg-beam-service.json` inside your nodecg site. You must provide both a channel and user id.\n\nExample config file:\n\n```\n{\n  \"channel\": 329582,\n  \"user\": 468820\n}\n```\n\n## Getting User and Channel IDs\n\nThe easiest way to get your user id is to:\n\n1. Log into Beam.pro\n1. Navigate your browser to [http://beam.pro/api/v1/channels/AwesomeAllar]\n\nReplace 'AwesomeAllar' in the url above with your channel's name. You should get a nice piece of JSON data back. The first two fields of this data are what we are interested in.\n\nExample JSON:\n\n```\n{\n\t\"id\":329582,\n\t\"userId\":468820,\n\t\"token\":\"AwesomeAllar\",\n\t...\n}\n```\n\nThe first field `id` is your channel id.\n\nThe second field `userId` is your user id.\n\n# Accessing Beam Data\n\nThis service provides Beam data in two ways. Replicants and messages.\n\n## Replicants\n\n### User\n\n* `UserSparks`: Integer, sparks user currently has.\n* `UserExp`: Integer, experience user currently has.\n\n### Channel\n\n* `ChannelOnline`: Boolean, whether channel is currently streaming.\n* `ChannelName`: String, title of the channel.\n* `ChannelAudience`: String, audience of the channel (family, teen, 18+).\n* `ChannelViewersTotal`: Number, the number of views the channel has.\n* `ChannelViewersCurrent`: Number, the number of viewers currently watching the channel.\n* `ChannelFollowers`: Number, the number of users following the channel.\n* `ChannelDescription`: String, description for the channel.\n* `ChannelTypeId`: Number, id of the channel type.\n* `ChannelInteractive`: Boolean, whether channel is interactive.\n* `ChannelInteractiveGameId`: Number, id of the interactive game channel is running.\n\n## Messages\n\n### Dashboard\n\n* `dashboard-update-request`: If this bundle receives this message, it will trigger a force update of the channel data using Beam's REST API.\n\n### Channel\n\n* `channel-followed`: Sent when a user follows this channel. Sends Beam [User](https://dev.beam.pro/rest.html#User) of follower.\n* `channel-unfollowed`: Sent when a user unfollows this channel. Sends Beam [User](https://dev.beam.pro/rest.html#User) of unfollower.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fallar%2Fnodecg-beam-service","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fallar%2Fnodecg-beam-service","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fallar%2Fnodecg-beam-service/lists"}