A compile-time generated, reflection-free REST API client library for .NET Standard, focused on performance and type safety.
RestLess is a type-safe REST API client library for .NET Standard that generates client code at compile time, eliminating runtime reflection overhead for improved performance. It provides a clean, declarative interface for defining API endpoints using attributes, similar to Refit, but with a focus on speed and minimal dependencies.
.NET developers building high-performance applications, especially on resource-constrained devices like mobile or IoT, who need a fast, type-safe REST client with minimal runtime overhead.
Developers choose RestLess over alternatives like Refit for its compile-time code generation, which significantly improves startup and execution speed by avoiding runtime reflection, and for its minimal core dependencies, allowing for greater customization and lighter deployments.
The automatic type-safe-reflectionless REST API client library for .Net Standard
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Benchmarks show RestLess starts up 9 times faster than Refit on old Android devices, reducing startup time from over a second to 120ms by eliminating runtime reflection.
Full support for standards-compliant URI templates allows flexible URL construction with variables and expressions, as detailed in the attribute-based API definitions.
The core package has minimal third-party dependencies, reducing bloat and allowing pluggable formatters for JSON or custom serialization via separate NuGet packages.
Supports headers via constant attributes, runtime settings, or dynamic parameters with clear precedence rules, enabling flexible authentication and metadata management.
Explicitly does not support interface inheritance, limiting code reuse and organizational patterns for complex API hierarchies, as admitted in the README.
Visual Studio for Mac requires restarts after package installation for Intellisense to work correctly, disrupting developer workflow and increasing setup friction.
Code generation at compile time can increase build times and introduce hard-to-debug errors if attributes are misconfigured, adding complexity compared to runtime libraries.
Fewer community contributions and pre-built solutions than Refit, meaning developers may need to write custom formatters for niche serialization needs.
RestLess is an open-source alternative to the following products: