{"id":13878032,"url":"https://github.com/waiting-for-dev/web_pipe","last_synced_at":"2025-04-05T03:07:46.917Z","repository":{"id":45367648,"uuid":"173350441","full_name":"waiting-for-dev/web_pipe","owner":"waiting-for-dev","description":"One-way pipe, composable, rack application builder","archived":false,"fork":false,"pushed_at":"2025-01-05T14:51:43.000Z","size":491,"stargazers_count":63,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-29T02:04:19.870Z","etag":null,"topics":["controller","pipe","rack","ruby"],"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/waiting-for-dev.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null},"funding":{"github":"waiting-for-dev"}},"created_at":"2019-03-01T18:34:17.000Z","updated_at":"2024-12-02T10:37:47.000Z","dependencies_parsed_at":"2023-11-14T11:43:36.020Z","dependency_job_id":null,"html_url":"https://github.com/waiting-for-dev/web_pipe","commit_stats":{"total_commits":321,"total_committers":1,"mean_commits":321.0,"dds":0.0,"last_synced_commit":"eb2c4ddca883941f77226f23ed84775327101cfb"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waiting-for-dev%2Fweb_pipe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waiting-for-dev%2Fweb_pipe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waiting-for-dev%2Fweb_pipe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/waiting-for-dev%2Fweb_pipe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/waiting-for-dev","download_url":"https://codeload.github.com/waiting-for-dev/web_pipe/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247280264,"owners_count":20912967,"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":["controller","pipe","rack","ruby"],"created_at":"2024-08-06T08:01:38.017Z","updated_at":"2025-04-05T03:07:46.885Z","avatar_url":"https://github.com/waiting-for-dev.png","language":"Ruby","readme":"[![Gem Version](https://badge.fury.io/rb/web_pipe.svg)](https://badge.fury.io/rb/web_pipe)\n[![Build Status](https://travis-ci.com/waiting-for-dev/web_pipe.svg?branch=master)](https://travis-ci.com/waiting-for-dev/web_pipe)\n\n# WebPipe\n\n`web_pipe` is a builder of composable rack applications through a pipe of\nfunctions on an immutable struct.\n\n\u003e `web_pipe` plays incredibly well with `hanami 2`. If you want to create a\n\u003e `hanami 2` app with `web_pipe`, you can take inspiration from this sample todo\n\u003e application:\n\u003e\n\u003e https://github.com/waiting-for-dev/hanami_2_web_pipe_todo_app\n\n1. [Introduction](docs/introduction.md)\n1. [Design model](docs/design_model.md)\n1. [Building a rack application](docs/building_a_rack_application.md)\n1. [Plugging operations](docs/plugging_operations.md)\n   1. [Resolving operations](docs/plugging_operations/resolving_operations.md)\n   1. [Injecting operations](docs/plugging_operations/injecting_operations.md)\n   1. [Composing operations](docs/plugging_operations/composing_operations.md)\n   1. [Inspecting operations](docs/plugging_operations/inspecting_operations.md)\n1. [Using rack middlewares](docs/using_rack_middlewares.md)\n   1. [Injecting middlewares](docs/using_rack_middlewares/injecting_middlewares.md)\n   1. [Composing middlewares](docs/using_rack_middlewares/composing_middlewares.md)\n   1. [Inspecting middlewares](docs/using_rack_middlewares/inspecting_middlewares.md)\n1. [Composing applications](docs/composing_applications.md)\n1. [Connection struct](docs/connection_struct.md)\n   1. [Sharing data downstream](docs/connection_struct/sharing_data_downstream.md)\n   1. [Halting the pipe](docs/connection_struct/halting_the_pipe.md)\n   1. [Configuring the connection struct](docs/connection_struct/configuring_the_connection_struct.md)\n1. [Overriding instance methods](docs/overriding_instance_methods.md)\n1. [DSL free usage](docs/dsl_free_usage.md)\n1. [Plugs](docs/plugs.md)\n   1. [Config](docs/plugs/config.md)\n   1. [ContentType](docs/plugs/content_type.md)\n1. [Testing](docs/testing.md)\n1. [Extensions](docs/extensions.md)\n   1. [Container](docs/extensions/container.md)\n   1. [Cookies](docs/extensions/cookies.md)\n   1. [Flash](docs/extensions/flash.md)\n   1. [Dry Schema](docs/extensions/dry_schema.md)\n   1. [Hanami View](docs/extensions/hanami_view.md)\n   1. [Not found](docs/extensions/not_found.md)\n   1. [Params](docs/extensions/params.md)\n   1. [Rails](docs/extensions/rails.md)\n   1. [Redirect](docs/extensions/redirect.md)\n   1. [Router params](docs/extensions/router_params.md)\n   1. [Session](docs/extensions/session.md)\n   1. [URL](docs/extensions/url.md)\n1. Recipes\n   1. [hanami 2 \u0026 dry-rb integration](docs/recipes/hanami_2_and_dry_rb_integration.md)\n   1. [Injecting dependencies through dry-auto_inject](docs/recipes/injecting_dependencies_through_dry_auto_inject.md)\n   1. [hanami-router integration](docs/recipes/hanami_router_integration.md)\n   1. [Using all RESTful methods](docs/recipes/using_all_restful_methods.md)\n\n```ruby\n# config.ru\nrequire 'web_pipe'\n\nWebPipe.load_extensions(:params)\n\nclass HelloApp\n  include WebPipe\n  \n  AUTHORIZED_USERS = %w[Alice Joe]\n  \n  plug :html\n  plug :authorize\n  plug :greet\n  \n  private\n  \n  def html(conn)\n    conn.add_response_header('Content-Type', 'text/html')\n  end\n  \n  def authorize(conn)\n    user = conn.params['user']\n    if AUTHORIZED_USERS.include?(user)\n      conn.add(:user, user)\n    else\n      conn.\n        set_status(401).\n        set_response_body('\u003ch1\u003eNot authorized\u003c/h1\u003e').\n        halt\n    end\n  end\n  \n  def greet(conn)\n    conn.set_response_body(\"\u003ch1\u003eHello #{conn.fetch(:user)}\u003c/h1\u003e\")\n  end\nend\n\nrun HelloApp.new\n```\n\n## Current status\n\n`web_pipe` is in active development but ready to be used in any environment.\nEveryday needs are covered, and while you can expect some API changes,\nthey won't be essential, and we'll document everything appropriately.\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at\nhttps://github.com/waiting-for-dev/web_pipe.\n\n## Release Policy\n\n`web_pipe` follows the principles of [semantic versioning](http://semver.org/).\n","funding_links":["https://github.com/sponsors/waiting-for-dev"],"categories":["Ruby"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaiting-for-dev%2Fweb_pipe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwaiting-for-dev%2Fweb_pipe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwaiting-for-dev%2Fweb_pipe/lists"}