Support simple class with BodySerializationMethod.UrlEncoded
- Dominant language
- C#
- Stars
- 1.1k
- Forks
- 114
- PR merge metrics
- No merged PRs in 30d
Description
The param is required to implement IDictionary, https://github.com/canton7/RestEase#url-encoded-bodies e.g.
```c#
Task Collect([Body(BodySerializationMethod.UrlEncoded)] Dictionary data);
```
Refit can do this, see: https://github.com/paulcbetts/refit#form-posts e.g.
```c#
Task Collect([Body(BodySerializationMethod.UrlEncoded)] Measurement measurement);
// Serialized as: v=1&tid=UA-1234-5&cid=d1e9ea6b-2e8b-4699-93e0-0bcbd26c206c&t=event
```
Are there any reasons why RestEase doesn't support this or is this just not implemented yet?
Nevertheless, this is an awesome lib! Keep up the good work!
Contributor guide
No contributing guide indexed for this repository
Research direction
The issue names BodySerializationMethod.UrlEncoded and shows Dictionary and Measurement examples, but no repository files or tests. Start by tracing the existing UrlEncoded body handling and its IDictionary requirement. Done means a simple class such as Measurement can be serialized into the requested form fields while the existing dictionary example continues to work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- api
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100