Share via


HttpRequestData Class

Definition

A representation of the HTTP request sent by the host.

public abstract class HttpRequestData
type HttpRequestData = class
Public MustInherit Class HttpRequestData
Inheritance
HttpRequestData

Constructors

Name Description
HttpRequestData(FunctionContext)

Initializes a new instance of the HttpRequestData class.

Properties

Name Description
Body

A Stream containing the HTTP body data.

Cookies

Gets an IReadOnlyCollection<T> containing the request cookies.

FunctionContext

Gets the FunctionContext for this request.

Headers

Gets a HttpHeadersCollection containing the request headers.

Identities

Gets an IEnumerable<T> containing the request identities.

Method

Gets the HTTP method for this request.

Query

Gets the NameValueCollection containing the request query.

Url

Gets the Uri for this request.

Methods

Name Description
CreateResponse()

Creates a response for this request.

Extension Methods

Name Description
CreateResponse(HttpRequestData, HttpStatusCode)

Creates a response for the the provided HttpRequestData.

ReadAsString(HttpRequestData, Encoding)

Reads the body payload as a string.

ReadAsStringAsync(HttpRequestData, Encoding)

Reads the body payload as a string.

ReadFromJsonAsync<T>(HttpRequestData, ObjectSerializer, CancellationToken)

Reads the request using the provided ObjectSerializer.

ReadFromJsonAsync<T>(HttpRequestData, CancellationToken)

Reads the request using the default ObjectSerializer configured for this worker.

Applies to