{"id":27386155,"url":"https://github.com/monksoul/httpagent","last_synced_at":"2025-04-13T17:14:00.825Z","repository":{"id":257916477,"uuid":"870967418","full_name":"monksoul/HttpAgent","owner":"monksoul","description":"HttpAgent 是一个高性能、灵活且易用的开源库，提供了全面的 HTTP 功能支持，包括文件传输、轮询、测试工具、实时通信、请求管理、Media 类型处理、MessagePack 支持、声明式请求等，并具有低资源消耗和高测试覆盖率的特点。","archived":false,"fork":false,"pushed_at":"2025-04-12T17:52:02.000Z","size":50399,"stargazers_count":8,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-13T17:13:56.648Z","etag":null,"topics":["curl","forward","http","httpclient","proxy"],"latest_commit_sha":null,"homepage":"https://furion.net/docs/http-agent","language":"C#","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/monksoul.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-10-11T02:18:20.000Z","updated_at":"2025-04-12T17:52:05.000Z","dependencies_parsed_at":"2024-10-26T15:37:39.051Z","dependency_job_id":null,"html_url":"https://github.com/monksoul/HttpAgent","commit_stats":null,"previous_names":["monksoul/httpagent"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monksoul%2FHttpAgent","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monksoul%2FHttpAgent/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monksoul%2FHttpAgent/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/monksoul%2FHttpAgent/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/monksoul","download_url":"https://codeload.github.com/monksoul/HttpAgent/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248750128,"owners_count":21155687,"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":["curl","forward","http","httpclient","proxy"],"created_at":"2025-04-13T17:14:00.123Z","updated_at":"2025-04-13T17:14:00.816Z","avatar_url":"https://github.com/monksoul.png","language":"C#","readme":"# HttpAgent\n\n[![license](https://img.shields.io/badge/license-MIT-orange?cacheSeconds=10800)](https://gitee.com/dotnetchina/HttpAgent/blob/master/LICENSE) [![nuget](https://img.shields.io/nuget/v/HttpAgent.svg?cacheSeconds=10800)](https://www.nuget.org/packages/HttpAgent) [![dotNET China](https://img.shields.io/badge/organization-dotNET%20China-yellow?cacheSeconds=10800)](https://gitee.com/dotnetchina)\n\nHttpAgent is a high-performance, flexible, and user-friendly open-source library that provides comprehensive support for\nHTTP functionalities, including file transfer, polling, testing tools, real-time communication, request management,\nmedia type handling, MessagePack support, Declarative Requests, and more. It is characterized by low resource\nconsumption and high test coverage.\n\n![HttpAgent.drawio](https://gitee.com/dotnetchina/HttpAgent/raw/master/drawio/HttpAgent.drawio.jpg \"HttpAgent.drawio.jpg\")\n\n[**View High-Definition Architecture Diagram**](https://diagram-viewer.giteeusercontent.com?repo=dotnetchina/HttpAgent\u0026ref=master\u0026file=drawio/HttpAgent.drawio)\n\n## Features\n\n- **Comprehensive `HTTP` Method Support**: Covers `GET`, `POST`, `PUT`, `DELETE`, `PATCH`, `HEAD`, `TRACE`, and\n  `OPTIONS` methods.\n- **File Transfer Functionality**: Supports file upload and download with real-time transfer progress monitoring.\n- **Polling Mechanism**: Supports standard polling and long polling with customizable polling intervals.\n- **Testing Toolkit**: Capable of stress testing, performance testing, and simulation testing with the ability to\n  generate detailed test reports; supports configuration of the number of requests, concurrency levels, and test\n  iteration counts.\n- **`HTTP` Proxy and Microservice Integration**: Supports `HTTP` proxy and request forwarding, suitable for integration\n  development in microservice architectures.\n- **Real-Time Communication Capability**: Implements real-time data push via `Server-Sent Events (SSE)` and is\n  compatible with `WebSocket` protocol.\n- **Request Management and Log Auditing**: Includes built-in request interception mechanisms and `HTTP` request log\n  auditing functions.\n- **Media Type Handling**: Provides predefined handling mechanisms for mainstream `MediaTypes` and offers an open\n  interface for custom handling.\n- **Declarative Requests**: Specifying the behavior of requests through simple attribute annotations or interface\n  definitions.\n- **`MessagePack` Support**: Integrates `MessagePack` serialization and deserialization capabilities to enhance data\n  exchange efficiency.\n- **`WebService` Support**: Comprehensive support for `SOAP` and `RESTful WebService`, including automatic client proxy\n  generation, `WSDL` parsing, `XML/JSON` data binding, simplifying integration and interaction.\n- **Flexible Response Transformation**: Provides common `HTTP` response transformers and supports custom transformation\n  logic.\n- **High Performance and Resource Management**: Employs memory optimization techniques and connection pool management to\n  ensure low resource consumption and high performance.\n- **Architecture Design**: Flexible architecture design that is easy to use and extend.\n- **Cross-Platform Independence**: Supports cross-platform operation without external dependencies.\n- **High-Quality Code Assurance**: Adheres to high-standard coding practices, with unit and integration test coverage as\n  high as `98%`.\n- **`.NET 8+` Compatibility**: Can be deployed and used in environments running `.NET 8` and higher versions.\n\n## Installation\n\n```powershell\ndotnet add package HttpAgent\n```\n\n## Getting Started\n\nWe have many examples on our [homepage](https://furion.net/docs/http-agent/). Here's your first one to get you started:\n\n1. Register `HttpRemote` service:\n\n```cs\nservices.AddHttpRemote();\n```\n\n2. Retrieve internet data:\n\n```cs\npublic class YourService(IHttpRemoteService httpRemoteService)\n{\n    public async Task\u003cstring?\u003e GetContent()\n    {\n        return await httpRemoteService.GetAsStringAsync(\"https://furion.net/\");\n    }\n}\n```\n\n[More Documentation](https://furion.net/docs/http-agent/)\n\n## Documentation\n\nYou can find the HttpAgent documentation on our [homepage](https://furion.net/docs/http-agent/).\n\n## Contributing\n\nThe main purpose of this repository is to continue developing the core of HttpAgent, making it faster and easier to use.\nThe development of HttpAgent is publicly hosted on [Gitee](https://gitee.com/dotnetchina/HttpAgent), and we appreciate\ncommunity contributions for bug fixes and improvements.\n\n## License\n\nHttpAgent is released under the [MIT](./LICENSE) open source license.\n\n[![](./assets/baiqian.svg)](https://baiqian.com)","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmonksoul%2Fhttpagent","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmonksoul%2Fhttpagent","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmonksoul%2Fhttpagent/lists"}