{"id":25824432,"url":"https://github.com/petitviolet/rreplay","last_synced_at":"2026-06-09T02:03:08.157Z","repository":{"id":36862499,"uuid":"230462794","full_name":"petitviolet/rreplay","owner":"petitviolet","description":"HTTP request/response recorder and replayer","archived":false,"fork":false,"pushed_at":"2023-03-16T06:10:34.000Z","size":1526,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-01T08:24:40.724Z","etag":null,"topics":["http-recording","rack","ruby","ruby-gem"],"latest_commit_sha":null,"homepage":"","language":"Ruby","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/petitviolet.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-12-27T14:58:32.000Z","updated_at":"2023-05-12T04:55:48.000Z","dependencies_parsed_at":"2023-02-10T18:15:32.586Z","dependency_job_id":null,"html_url":"https://github.com/petitviolet/rreplay","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/petitviolet%2Frreplay","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/petitviolet%2Frreplay/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/petitviolet%2Frreplay/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/petitviolet%2Frreplay/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/petitviolet","download_url":"https://codeload.github.com/petitviolet/rreplay/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241153592,"owners_count":19918831,"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":["http-recording","rack","ruby","ruby-gem"],"created_at":"2025-02-28T12:51:10.083Z","updated_at":"2026-06-09T02:03:08.131Z","avatar_url":"https://github.com/petitviolet.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Rreplay\n\n[![rreplay](https://badge.fury.io/rb/rreplay.svg)](https://badge.fury.io/rb/rreplay)\n[![Actions Status](https://github.com/petitviolet/rreplay/workflows/test/badge.svg)](https://github.com/petitviolet/rreplay/actions)\n\nReplay HTTP request and is able to assert if the response is expected.\n\n- Record HTTP request and response into file\n- Feed the recorded request and response\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'rreplay'\n```\n\nAnd then execute:\n\n    $ bundle install\n\nOr install it yourself as:\n\n    $ gem install rreplay\n\n## Usage\n\n### HTTP request/resopnse recording\n\nUse `Rack::Rreplay`.\n\nIn 'config.ru' file:\n\n```ruby\nrequire 'rack/rreplay'\nuse Rack::Rreplay.Middleware(directory: './rreplay_tmp', format: :json),\n    { sample: 5, extra_header_keys: %w[ACCESS_TOKEN], debug: true }\n```\n\nThis configuration enables rreplay to record HTTP request and response, and write records into `./rreplay_tmp` directory files with specified format(json or msgpack).\n\nPlease see the implementation of [rack/rreplay.rb](https://github.com/petitviolet/rreplay/blob/master/lib/rack/rreplay.rb).\n\n![demo](./rreplay-demo-record.gif)\n\n### HTTP request replay\n\nUse `bundle exec rreplay \u003cendpoint\u003e \u003ctarget\u003e` to send recorded HTTP request in \u003ctarget\u003e to \u003cendpoint\u003e.\n\n```console\n$ bundle exec rreplay 'http://localhost:4567' ./rreplay_tmp/ --format json --verbose\n$ bundle exec rreplay 'https://example.com' ./rreplay_tmp/rreplay.log.msgpack --format msgpack\n```\n\nPlease call `bundle exec rreplay --help` to see arguments and available options.\n\n![demo](./rreplay-demo-replay.gif)\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/petitviolet/rreplay. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/petitviolet/rreplay/blob/master/CODE_OF_CONDUCT.md).\n\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n\n## Code of Conduct\n\nEveryone interacting in the Rreplay project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/petitviolet/rreplay/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpetitviolet%2Frreplay","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpetitviolet%2Frreplay","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpetitviolet%2Frreplay/lists"}