Flurl.Http 4.0.0

Flurl

build NuGet Version NuGet Downloads

Flurl is a modern, fluent, asynchronous, testable, portable, buzzword-laden URL builder and HTTP client library.

var result = await "https://api.mysite.com"
    .AppendPathSegment("person")
    .SetQueryParams(new { api_key = "xyz" })
    .WithOAuthBearerToken("my_oauth_token")
    .PostJsonAsync(new { first_name = firstName, last_name = lastName })
    .ReceiveJson<T>();

[Test]
public void Can_Create_Person() {
    // fake & record all http calls in the test subject
    using var httpTest = new HttpTest();

    // arrange
    httpTest.RespondWith("OK", 200);

    // act
    await sut.CreatePersonAsync("Frank", "Reynolds");
        
    // assert
    httpTest.ShouldHaveCalled("http://api.mysite.com/*")
        .WithVerb(HttpMethod.Post)
        .WithContentType("application/json");
}

Get it on NuGet:

PM> Install-Package Flurl.Http

Or get just the stand-alone URL builder without the HTTP features:

PM> Install-Package Flurl

For updates and announcements, follow @FlurlHttp on Twitter.

For detailed documentation, please visit the main site.

No packages depend on Flurl.Http.

https://github.com/tmenier/Flurl/releases

.NET Framework 4.6.1

.NET 6.0

.NET Standard 2.0

Version Downloads Last updated
4.0.2 8 01/27/2024
4.0.1 5 01/25/2024
4.0.0 7 03/02/2024
4.0.0-pre7 7 03/25/2024
4.0.0-pre6 7 03/02/2024
4.0.0-pre5 7 03/20/2024
4.0.0-pre4 6 03/20/2024
4.0.0-pre3 8 08/19/2023
4.0.0-pre2 8 03/03/2024
4.0.0-pre1 7 03/20/2024
3.2.4 20 09/26/2023
3.2.4-pre2 7 03/12/2024
3.2.4-pre1 6 03/13/2024
3.2.3 6 03/02/2024
3.2.2 7 03/03/2024
3.2.1 6 03/03/2024
3.2.0 6 03/03/2024
3.0.1 7 03/03/2024
3.0.0 8 03/25/2024
3.0.0-pre6 7 03/03/2024
3.0.0-pre5 6 03/19/2024
3.0.0-pre4 5 03/19/2024
3.0.0-pre3 7 03/19/2024
3.0.0-pre2 7 03/18/2024
3.0.0-pre1 6 03/13/2024
2.4.2 8 03/02/2024
2.4.1 7 03/03/2024
2.4.0 7 03/03/2024
2.4.0-pre 5 03/13/2024
2.3.2 6 01/05/2024
2.3.1 6 03/02/2024
2.3.0 7 03/02/2024
2.3.0-pre1 6 01/28/2024
2.2.1 6 03/03/2024
2.2.0 7 03/01/2024
2.2.0-pre2 6 03/12/2024
2.2.0-pre1 6 03/13/2024
2.1.1 6 03/12/2024
2.1.0 6 03/02/2024
2.1.0-pre 5 03/13/2024
2.0.1 8 03/02/2024
2.0.0 6 03/01/2024
2.0.0-pre4 6 03/17/2024
2.0.0-pre3 6 03/17/2024
2.0.0-pre2 7 03/17/2024
2.0.0-pre1 6 03/18/2024
1.2.0 7 03/01/2024
1.2.0-pre 5 03/13/2024
1.1.3 6 03/02/2024
1.1.2 5 03/13/2024
1.1.1 6 03/02/2024
1.1.1-pre 6 03/13/2024
1.1.0-pre 6 03/15/2024
1.0.3 6 01/09/2024
1.0.2 6 01/08/2024
1.0.1 6 03/13/2024
1.0.0 6 03/02/2024
1.0.0-beta9 5 02/28/2025
1.0.0-beta8 7 03/17/2024
1.0.0-beta7 8 03/22/2024
0.10.1 7 03/02/2024
0.10.0 8 03/03/2024
0.10.0-pre2 7 03/13/2024
0.10.0-pre 6 03/13/2024
0.9.0 5 03/13/2024
0.9.0-pre 5 03/13/2024
0.8.0 7 03/16/2024
0.8.0-pre 8 03/16/2024
0.7.0 6 03/03/2024
0.6.4 6 03/17/2024
0.6.3 6 03/16/2024
0.6.2 6 01/07/2024
0.6.1 6 03/13/2024
0.6.0 6 03/02/2024
0.5.3 7 03/24/2024
0.5.2 6 03/03/2024
0.5.1 5 01/25/2024
0.5.0 5 03/25/2024
0.4.2 6 03/02/2024
0.4.1 6 01/15/2024
0.4.0 5 03/15/2024
0.4.0-pre2 6 03/17/2024
0.4.0-pre 5 03/15/2024
0.3.0-pre 5 03/13/2024
0.2.5 5 03/13/2024
0.2.4 7 03/01/2024
0.2.3 6 03/02/2024
0.2.2 6 03/01/2024
0.2.1 6 01/24/2024
0.2.0 6 03/12/2024
0.2.0-pre 5 03/12/2024
0.1.3 6 03/14/2024
0.1.2 0 05/12/2014
0.1.1 0 05/05/2014
0.1.0 6 01/05/2024