{"id":15022495,"url":"https://github.com/elmarti/meteor-video-chat","last_synced_at":"2025-05-02T07:32:38.374Z","repository":{"id":57295921,"uuid":"53943920","full_name":"elmarti/meteor-video-chat","owner":"elmarti","description":"Simple id based video calling in meteor","archived":false,"fork":false,"pushed_at":"2023-05-25T08:45:39.000Z","size":602,"stargazers_count":33,"open_issues_count":9,"forks_count":8,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-10-29T23:07:18.187Z","etag":null,"topics":["angular","blaze","meteor","meteor-video-chat","peer-to-peer","react","tdd","video","webrtc"],"latest_commit_sha":null,"homepage":"https://atmospherejs.com/elmarti/video-chat","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/elmarti.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2016-03-15T12:46:38.000Z","updated_at":"2023-05-25T08:45:31.000Z","dependencies_parsed_at":"2022-08-26T21:54:45.627Z","dependency_job_id":null,"html_url":"https://github.com/elmarti/meteor-video-chat","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elmarti%2Fmeteor-video-chat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elmarti%2Fmeteor-video-chat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elmarti%2Fmeteor-video-chat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elmarti%2Fmeteor-video-chat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elmarti","download_url":"https://codeload.github.com/elmarti/meteor-video-chat/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224260680,"owners_count":17282250,"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":["angular","blaze","meteor","meteor-video-chat","peer-to-peer","react","tdd","video","webrtc"],"created_at":"2024-09-24T19:58:01.890Z","updated_at":"2024-11-12T16:04:41.107Z","avatar_url":"https://github.com/elmarti.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# UNMAINTAINED - i can review PRs, but I don't work with Meteor anymore and would not recommend this solution\n\n# Meteor Video Chat\nThis extension allows you to implement user-to-user video calling in React, Angular and Blaze.\nThis package now uses [RTCFly](https://github.com/rtcfly/rtcfly)\n\n\n[Example with React](https://meteorvideochat.herokuapp.com)\n\n[Click here for the React example source code.](https://github.com/elmarti/meteor-video-chat-example)\n\n\n[Example with Blaze](https://blazevideochat.herokuapp.com)\n\n[Click here for the Blaze example source code.](https://github.com/elmarti/blaze-video-chat)\n\n[![Stories in Ready](https://badge.waffle.io/elmarti/meteor-video-chat.svg?label=ready\u0026title=Ready)](http://waffle.io/elmarti/meteor-video-chat)\n[![Travis CI](https://travis-ci.org/elmarti/meteor-video-chat.svg?branch=master)](https://travis-ci.org/elmarti/meteor-video-chat)\n[![Maintainability](https://api.codeclimate.com/v1/badges/1ac37840becd7f729338/maintainability)](https://codeclimate.com/github/elmarti/meteor-video-chat/maintainability)\n\n## A note on previous versions\nMeteor Video Chat used to use `Meteor.VideoCallServices`, however we have moved to a more modular system, opting for ES6 imports like so: \n\n`import { VideoCallServices } from 'meteor/elmarti:video-chat';`\nOld style code will be supported for the forseeable future, but we suggest moving over to the new format.\n\n## Usage with asteroid\nThe Meteor Video Chat client can be used by first running `npm install meteor-video-chat`, and then using the following mixin import\n```\n\nimport { AsteroidVideoChatMixin } from 'meteor-video-chat';\n\n```\nAfter including this as an Asteroid mixin, as per the Asteroid page, you can access it like so:\n```\n    Asteroid.VideoCallServices;\n\n```\n\n## init\nHere you can set the [RTCConfiguration](https://developer.mozilla.org/en-US/docs/Web/API/RTCConfiguration). If you are testing outside of a LAN, you'll need to procure some [STUN \u0026 TURN](https://gist.github.com/yetithefoot/7592580) servers.\n\n```\nVideoCallServices.init({'iceServers': [{\n    'urls': 'stun:stun.example.org'\n  }]\n});\n```\n#### Calling a user\nTo call a user, use the following method. \n```\nVideoCallServices.call(ICallParams);\n\n```\nThese are the parameters that can be used: \n```\ninterface ICallParams {\n    id:string; //ID of the callee\n    localElement: IHTMLMediaElement; //local HTMLElement\n    remoteElement: IHTMLMediaElement; //remote HTMLElement\n    video:boolean; //Do you want to show video?\n    audio:boolean; //Do you want to show audio?\n}\n```\n\n\n#### Deciding who can connect to whom\nThe follow method can be overridden on the server side to implement some kind of filtering. Returning `false` will cancel the call, and `true` will allow it to go ahead.\n\n```\nVideoCallServices.checkConnect = function(caller, target){\nreturn *can caller and target call each other\"\n};\n```\n\n\n\n#### Answering a call\nThe first step is to handle the onReceiveCall callback and then to accept the call. The answerCall method accepts the ICallParams interfaces, just like the \"call\" method above\n```\n VideoCallServices.onReceiveCall = (userId) =\u003e {\n        VideoCallServices.answerCall(ICallParams);\n };\n\n```\n\n\n#### Muting local or remote videos\n```\nVideoCallServices.toggleLocalAudio();\nVideoCallServices.toggleRemoteAudio();\n```\n\n\n#### Application state\nThe following values are stored in a reactive var \n```\nlocalMuted:boolean, \nremoteMuted:boolean, \nringing:boolean,\ninProgress:boolean\n\n```\n#### Getting the state \n```\nVideoCallServices.getState(\"localMuted\");\n\n```\n#### Accessing the video (HTMLMediaElement) elements\n\n```\nconst localVideo = VideoCallServices.getLocalVideo();\nconst remoteVideo = VideoCallServices.getRemoteVideo();\n\n```\n\n#### Ending call\nSimply call\n```\nVideoCallServices.endCall();\n```\n#### Other events\nThe following method is invoked when the callee accepts the call.\n```\nVideoCallServices.onTargetAccept = () =\u003e {\n}\n```\nThe following method is invoked when either user ends the call\n```\nVideoCallServices.onTerminateCall = () =\u003e {\n}\n```\nThe following method invoked when the RTCPeerConnection instance has been created, making it possible to consitently mutate it or add a data channel\n```\nVideoCallServices.onPeerConnectionCreated = () =\u003e {\n}\n\n``` \nThe following method is invoked on the caller browser when the callee rejects the call \n```\nVideoCallServices.onCallRejected = () =\u003e {\n    \n}\n\n```\n\n\nThe following method is invoked on both the client and server whenever an error is caught.\nUser is only passed on the server\n\n```\nVideoCallServices.setOnError(callback);\n```\nThe onError section can also be used for handling errors thrown when obtaining the user media (Webcam/audio).\n[See here for more info](https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia#Exceptions), or checkout the example.\n\n\nThis project is sponsored by the following:\n\n[![BrowserStack](https://www.browserstack.com/images/layout/browserstack-logo-600x315.png)](https://www.browserstack.com/)\n\n[![Sentry.io](https://sentry.io/_assets/branding/png/sentry-horizontal-black-6aaf82e66456a21249eb5bef3d3e65754cadfd498f31469002bc603d966d08ef.png)](https://sentry.io/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felmarti%2Fmeteor-video-chat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felmarti%2Fmeteor-video-chat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felmarti%2Fmeteor-video-chat/lists"}