HubSpot.NET icon indicating copy to clipboard operation
HubSpot.NET copied to clipboard

nuget package dependencies - RestSharp

Open arcbus opened this issue 5 years ago • 2 comments

This is mostly just feedback to make this api wrapper easier to use.

I.e. I followed the example under HubSpot.NET/HubSpot.NET.Examples/Deals.cs

and this code:

var deals = api.Deal.List(false,
       new ListRequestOptions(250) { PropertiesToInclude = new List<string> { "dealname", "amount" } });

Doesn't compile. Looks like it needs to this instead:

var deals = api.Deal.List<DealHubSpotModel>(false,
       new ListRequestOptions(250) { PropertiesToInclude = new List<string> { "dealname", "amount" } });

Also, would be nice if adding this nuget package would include all dependencies, but it doesn't. Worse still, i added the dependencies with latest stable versions, and it throws an obtuse error. Turns out RestSharp breaks something unless you are using the specific version in HubSpot.NET/HubSpot.NET/packages.config

arcbus avatar Jun 29 '20 21:06 arcbus

What dependencies did you add to the latest stable versions? I am getting the same error as well but this time is just when I call var api = new HubSpotApi(<API_KEY>);

TimFung93 avatar Aug 27 '20 16:08 TimFung93

I gave up trying to use this package and reverted to using RestClient directly myself, essentially calling URL's, setting headers, posting request manually :(

arcbus avatar Aug 27 '20 16:08 arcbus