'C# Add body parameters to Request of a GET method
So I'm being forced to use an API Endpoint that is get but also requires data in the body. I've tried various methods in c# but each time I keep getting the same result. Body Content is not allowed for the GET method.
Does anyone have an idea on how I can create an HTTPClient Request or WebRequest or anything that will allow me to hit their GET method with body parameters?
Solution 1:[1]
Technically, you're able to use GET request with a body. But in practice, it's VERY note recommended to do that. On this site there is a detailed explanation of what I'm saying. Also, take a look at this stack overflow topic. I don't want to copy good replies that's why I'm just attaching links to good and comprehensive results.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Michael Samoilenko |
