Serializing objects to URL encoded form data

added by DotNetKicks
4/23/2019 4:59:21 AM

1 Kicks, 247 Views

While messing with dictionaries to create form data for FormUrlEncodedContent so I can send data to server using HTTP client, I started thinking about easier and cleaner way to do it. I was writing integration tests and I wanted to re-use some model classes instead of dictionaries. Here's how to do it.