{"id":25949811,"url":"https://github.com/benmelz/omniauth-passthrough","last_synced_at":"2025-03-04T12:29:16.086Z","repository":{"id":275654496,"uuid":"926753466","full_name":"benmelz/omniauth-passthrough","owner":"benmelz","description":"An OmniAuth strategy that passes request params straight through the middleware.","archived":false,"fork":false,"pushed_at":"2025-02-06T14:43:48.000Z","size":38,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-11T16:02:31.842Z","etag":null,"topics":["omniauth","omniauth-strategy","ruby"],"latest_commit_sha":null,"homepage":"https://rubygems.org/gems/omniauth-strategies-passthrough","language":"Ruby","has_issues":false,"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/benmelz.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-02-03T19:55:46.000Z","updated_at":"2025-02-06T14:43:51.000Z","dependencies_parsed_at":"2025-02-03T21:31:52.260Z","dependency_job_id":"c88d5eab-1bed-45d9-bedd-9a005ec9ed56","html_url":"https://github.com/benmelz/omniauth-passthrough","commit_stats":null,"previous_names":["benmelz/omniauth-passthrough"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benmelz%2Fomniauth-passthrough","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benmelz%2Fomniauth-passthrough/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benmelz%2Fomniauth-passthrough/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benmelz%2Fomniauth-passthrough/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/benmelz","download_url":"https://codeload.github.com/benmelz/omniauth-passthrough/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241847479,"owners_count":20030262,"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":["omniauth","omniauth-strategy","ruby"],"created_at":"2025-03-04T12:29:15.180Z","updated_at":"2025-03-04T12:29:16.063Z","avatar_url":"https://github.com/benmelz.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# omniauth-passthrough\n\nAn OmniAuth strategy that passes request params straight through the middleware.\n\nThis strategy allows you to pass auth hash values directly to an auth endpoint and forwards them directly to your\ncallback(s). The end goal of this is to provide more flexibility when writing login helpers in development/test\nenvironments while still utilizing your OmniAuth callback(s).\n\n## Installation\n\nInstall the gem and add to the application's Gemfile by executing:\n\n```bash\nbundle add omniauth-passthrough\n```\n\nIf bundler is not being used to manage dependencies, install the gem by executing:\n\n```bash\ngem install omniauth-passthrough\n```\n\n## Usage\n\nInclude the passthrough strategy in development/test environments as you would with any other OmniAuth\nstrategy. *NEVER* use it in a production environment.\n\nOnce included, any POST request to `/auth/passthrough` will pass through any `uid`, `info`, `credentials` and `extra`\nparams to your omniauth callback.\n\n```ruby \n# request\npost '/auth/passthrough', params: { uid: 'my-uid',\n                                    info: { email: 'my-email@example.com', first_name: 'My', last_name: 'Name' } }\n\n# callback\nrequest.env['omniauth.auth'].uid # =\u003e 'my-uid'\nrequest.env['omniauth.auth'].info.email # =\u003e 'my-email@example.com'\nrequest.env['omniauth.auth'].info.first_name # =\u003e 'My'\nrequest.env['omniauth.auth'].info.last_name # =\u003e 'Name'\n```\n\n### Test Environments\n\nA number of test helpers are provided to help with using the strategy for test login helpers.\n\n```ruby\n# including one of the following helpers in your test\ninclude Omniauth::Passthrough::RackHelper # if using Rack::Test\ninclude Omniauth::Passthrough::ActionDispatchHelper # if using ActionDispatch (Rails)\ninclude Omniauth::Passthrough::CapybaraHelper # if using Capybara\n\n# will make the following login helper available\nomniauth_passthrough(uid: 'my-uid', info: { email: 'my-email@example.com', first_name: 'My', last_name: 'Name' })\n```\n\n## Development\n\n* Run `bin/setup` to install dependencies.\n* Run `bin/rake appraisal spec` to run the tests.\n* Run `bin/rake rubocop` to run the linter.\n* Run `bin/console` for an interactive prompt that will allow you to experiment.\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/omniauth-passthrough.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenmelz%2Fomniauth-passthrough","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbenmelz%2Fomniauth-passthrough","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenmelz%2Fomniauth-passthrough/lists"}