Skip to content

Commit c022b03

Browse files
committed
feat: add support for the HTTP QUERY verb (RFC 10008)
1 parent 8712aa7 commit c022b03

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

‎components/abstractions/src/main/java/com/microsoft/kiota/HttpMethod.java‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,7 @@ public enum HttpMethod {
2121
/** The HTTP TRACE method */
2222
TRACE,
2323
/** The HTTP HEAD method */
24-
HEAD
24+
HEAD,
25+
/** The HTTP QUERY method */
26+
QUERY
2527
}

‎components/http/okHttp/src/main/java/com/microsoft/kiota/http/OkHttpRequestAdapter.java‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -965,7 +965,8 @@ public void writeTo(@Nonnull BufferedSink sink) throws IOException {
965965
if (body == null
966966
&& (requestInfo.httpMethod.equals(HttpMethod.POST)
967967
|| requestInfo.httpMethod.equals(HttpMethod.PATCH)
968-
|| requestInfo.httpMethod.equals(HttpMethod.PUT))) {
968+
|| requestInfo.httpMethod.equals(HttpMethod.PUT)
969+
|| requestInfo.httpMethod.equals(HttpMethod.QUERY))) {
969970
body = RequestBody.create(new byte[0]);
970971
}
971972
final Request.Builder requestBuilder =

0 commit comments

Comments
 (0)