{"id":23070803,"url":"https://github.com/PriyanshuPz/rust-server","last_synced_at":"2025-08-15T13:33:16.286Z","repository":{"id":252533129,"uuid":"840666065","full_name":"PriyanshuPz/rust-server","owner":"PriyanshuPz","description":"A simple web server with rust from scratch.","archived":false,"fork":false,"pushed_at":"2025-05-31T03:43:33.000Z","size":49,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-11T10:50:36.404Z","etag":null,"topics":["github","learn"],"latest_commit_sha":null,"homepage":null,"language":"Rust","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/PriyanshuPz.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-10T10:07:02.000Z","updated_at":"2025-07-04T13:41:46.000Z","dependencies_parsed_at":"2025-02-04T14:44:27.652Z","dependency_job_id":"1ee004f5-a7fc-44b8-ab13-cf7d114eeb86","html_url":"https://github.com/PriyanshuPz/rust-server","commit_stats":null,"previous_names":["priyanshuverma-dev/rust-server","priyanshupz/rust-server"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/PriyanshuPz/rust-server","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PriyanshuPz%2Frust-server","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PriyanshuPz%2Frust-server/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PriyanshuPz%2Frust-server/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PriyanshuPz%2Frust-server/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PriyanshuPz","download_url":"https://codeload.github.com/PriyanshuPz/rust-server/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PriyanshuPz%2Frust-server/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270578391,"owners_count":24610036,"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","status":"online","status_checked_at":"2025-08-15T02:00:12.559Z","response_time":110,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["github","learn"],"created_at":"2024-12-16T06:27:48.407Z","updated_at":"2025-08-15T13:33:16.252Z","avatar_url":"https://github.com/PriyanshuPz.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Rust HTTP Server from Scratch\n\nThis project is a complete implementation of a web server in Rust built from scratch, primarily using only the standard library (`std::net::TcpListener`). It serves as a learning exercise in systems programming and HTTP fundamentals, and includes a functional Todo application example.\n\n\u003e **Note:** This project is no longer under active development but remains available as a learning resource. Contributions are still welcome!\n\n## Features\n\n1. **Core HTTP Server:**\n   * Parses and handles HTTP requests using only `std::net::TcpListener`\n   * Custom request and response abstractions\n   * Thread pool for concurrent connection handling\n   * Basic routing system for API endpoints\n\n2. **API Capabilities:**\n   * Supports common HTTP methods: GET, POST, PUT, DELETE\n   * Query parameter parsing\n   * JSON request/response handling\n\n3. **Todo Application Example:**\n   * Manages a list of todos, each with an `id`, `title`, and `completed` status\n   * Provides CRUD (Create, Read, Update, Delete) operations\n   * Persists todo data to a local `data.json` file \n\n4. **Learning Benefits:**\n   * Demonstrates low-level HTTP protocol parsing\n   * Shows concurrent programming patterns in Rust\n   * Provides insights into web server architecture\n   * Illustrates Rust's ownership system and safety features\n\n## Getting Started\n\n```bash\n# Clone the repository\ngit clone https://github.com/PriyanshuPz/rust-server.git\ncd rust-server\n\n# Run the server\ncargo run\n```\n\nThen visit `http://localhost:5000` in your browser or use tools like `curl` to interact with the API.\n\n## Educational Resources\n\nIf you're learning from this project, check out these related resources:\n\n- [Rust Book - Building a Web Server](https://doc.rust-lang.org/book/ch20-00-final-project-a-web-server.html)\n- [HTTP/1.1 RFC](https://tools.ietf.org/html/rfc7230)\n- [Rust By Example](https://doc.rust-lang.org/rust-by-example/)\n\n## Contributing\n\nAlthough this project is no longer under active development, contributions are welcome! Feel free to:\n\n- Fork the repository\n- Make your changes\n- Submit a pull request\n\nThis is a fun project for learning purposes, so creative improvements are encouraged!\n\n## License\n\nMIT\n\n---\n\n*Built with ❤️ and a slightly masochistic desire to understand HTTP from the ground up*\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPriyanshuPz%2Frust-server","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FPriyanshuPz%2Frust-server","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPriyanshuPz%2Frust-server/lists"}