Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add C# HttpClient target client #149

Merged
merged 2 commits into from
Jun 2, 2020
Merged

Add C# HttpClient target client #149

merged 2 commits into from
Jun 2, 2020

Conversation

Atvaark
Copy link
Contributor

@Atvaark Atvaark commented Oct 5, 2019

Adds a second C# target client, one that doesn't require an additional NuGet package to work.
This will generate a C# snippet which can be pasted into the body of an existing (async) method.
#141

Differences between this and PR #142:

  • this also generates working code for multipart/form-data requests
  • this supports custom HTTP methods
  • this enables automatic gzip, deflate (but no br) decompression if a compatible accept header is found
  • this generates code similar to the restsharp target client: no method declaration boilerplate is generated and the user has to add the required using statements on their own

@PavelStefanov
Copy link

PavelStefanov commented May 23, 2020

Hey guys! This PR looks nice and really useful, can we merge that? If you need any help feel free to ask me, I'd be happy to help.
I'd suggest make HttpClient the default target

This target uses the default HttpClient class
which doesn't require any additional NuGet Packages.
@Atvaark
Copy link
Contributor Author

Atvaark commented Jun 2, 2020

Would anyone mind taking a look at this? The CI and tests work again and there aren't any conflicts.
@reynolek @darrenjennings

@reynolek reynolek merged commit d266769 into Kong:master Jun 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants