Skip to content

[API Proposal]: Add minimal QUERY verb support to HttpClient #114489

Closed

Description

@rokonec

Background and motivation

With the new C reaching the Proposed Standard maturity level, now might be the right time to add it to HttpClient.

At this moment we want to implement only minimal support for QUERY verb.
As QUERY verb become adopted by users and its full support requested, we will consider to implement it in whole scope as defined in #113522

Alternative Designs

No response

Risks

No response

API Proposal

A new static HttpMethod member called Query:

public partial class HttpMethod
{
    public static HttpMethod Query { get; }
}

API Usage

using var client = new HttpClient();
var response = await client.SendAsync(new HttpRequestMessage(HttpMethod.Query, "https://api.example.com/resource"));

Alternative Designs

No response

Risks

No response

Activity

  1. added
    api-suggestion
    on Apr 10, 2025
  2. self-assigned this
    on Apr 10, 2025
  3. added
    untriaged
    on Apr 10, 2025
  4. dotnet-policy-service commented on Apr 10, 2025

    @dotnet-policy-service
    Contributor

    Tagging subscribers to this area: @dotnet/ncl
    See info in area-owners.md if you want to be subscribed.

  5. added
    api-ready-for-review
    and removed
    untriaged
    on Apr 10, 2025
  6. added this to the 10.0.0 milestone on Apr 10, 2025
  7. removed
    api-suggestion
    on Apr 10, 2025
  8. bartonjs commented on Apr 15, 2025

    @bartonjs
    Member

    Video

    • Looks good as proposed
    namespace System.Net.Http;
    
    public partial class HttpMethod
    {
        public static HttpMethod Query { get; }
    }
  9. added
    api-approved
    and removed
    api-ready-for-review
    on Apr 15, 2025
  10. locked and limited conversation to collaborators on Jun 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

api-approvedarea-System.Net.Http

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions