R.Ax
unread,May 25, 2022, 5:40:02 PM5/25/22Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to RestSharp
I am attempting to rework an existing program using RestSharp previous to the 107 changes. I'm looking at the documentation specfically for adding data to the body - either AddJsonBody or AddStringBody, but these methods do not appear to exist. The code looks something like:
var request = new RestSharp.RestRequest($"XX", RestSharp.Method.Patch);
request = RestSharp.RestRequestExtensions.AddHeader(request, "Authorization", $"XX");
request.AddJsonBody(Newtonsoft.Json.JsonConvert.SerializeObject(d));
And I receive a "RestRequest does not contain a definition for 'AddJsonBody'..."
With that being said, it seems most items in the docs aren't applicable for me, for some reason - AddQueryParameter, AddStringBody, AddHeader, etc.
Am I missing something important with the changes in 107?
Thank you.