{"id":16073693,"url":"https://github.com/phstc/support-roulette","last_synced_at":"2025-03-22T08:44:26.620Z","repository":{"id":5992787,"uuid":"7215348","full_name":"phstc/support-roulette","owner":"phstc","description":"Redirects telephone calls to support agents cellphone. Support roulette will rotate your support agents weekly.","archived":false,"fork":false,"pushed_at":"2013-10-05T14:14:05.000Z","size":3592,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-27T08:45:22.061Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/phstc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-12-18T01:09:24.000Z","updated_at":"2015-01-14T13:22:47.000Z","dependencies_parsed_at":"2022-08-19T09:01:22.679Z","dependency_job_id":null,"html_url":"https://github.com/phstc/support-roulette","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/phstc%2Fsupport-roulette","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phstc%2Fsupport-roulette/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phstc%2Fsupport-roulette/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phstc%2Fsupport-roulette/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/phstc","download_url":"https://codeload.github.com/phstc/support-roulette/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244931585,"owners_count":20534009,"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-10-09T08:22:20.060Z","updated_at":"2025-03-22T08:44:26.597Z","avatar_url":"https://github.com/phstc.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Welcome to Support Roulette, wait a minute while we transfer your call…\n\nDo you need a support phone number in your company? What do you think about a phone number that rotates between your team members?\n\nA long time ago, in a galaxy far, far away, we decided to have a support developer per week, a guy who will carry a support cellphone at night, weekend etc in case of any emergency in the company's website.\n\nEverybody has already a cellphone, carrying another isn't a good idea. That's the motivation of Support Roulette.\n\n## How it works\n\nBasically, create a [Twilio](http://www.twilio.com) account, get a phone number, configure the `application.yml` and nothing more, that's it. :smile:\n\n**config/application.yml.sample**\n\n```yaml\nagents:\n  - {name: \"Batman\", phone: \"+5511111111111\"}\n  - {name: \"Homer\", phone: \"+5511111111111\"}\ntwilio:\n  account_sid: \"abc123\"\n  auth_token: \"abc123\"\n  from_call: \"+5511111111111\"\n  from_sms: \"+5511111111111\"\n```\n\nYou can add as many support agents as you want. They will rotate weekly.\n\n**models/agent.rb**\n\n```ruby\n  def self.current\n    all[(Date.today.cweek % all.size) - 1]\n  end\n```\n\n\n### Notifying the current support agent\n\nYou can notify the current support agent by calling:\n\n```shell\n$ bundle exec rake scheduler:notify_current_agent\n```\n\nLooking for something more automated? You can configure [Heroku Scheduler](https://addons.heroku.com/scheduler) (for free) to notify the current support agent automatically.\n\nThe current support agent will by notified by SMS.\n\n`Congratulations you are the current support agent!`\n\nCongratulations??? :trollface:\n\n#### Note\n\nThere is an explicit `if Date.today.sunday?` on `scheduler:notify_current_agent`, it exists to guarantee that the current support agent will be notified only when it was rotated (on Sundays).\n\n## To start\n\n```shell\nforeman start\nopen http://localhost:5000\n```\n\nThe available urls: `/voice_request` and `/notify_current_agent`.\n\n## To run the test suite\n\n```shell\nrake spec\n```\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphstc%2Fsupport-roulette","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphstc%2Fsupport-roulette","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphstc%2Fsupport-roulette/lists"}