TypedResults.Ok Method

Definition

Overloads

Ok()

Produces a Status200OK response.

Ok<TValue>(TValue)

Produces a Status200OK response.

Ok()

Produces a Status200OK response.

public static Microsoft.AspNetCore.Http.HttpResults.Ok Ok ();
static member Ok : unit -> Microsoft.AspNetCore.Http.HttpResults.Ok
Public Shared Function Ok () As Ok

Returns

Ok

The created Ok for the response.

Applies to

Ok<TValue>(TValue)

Produces a Status200OK response.

public static Microsoft.AspNetCore.Http.HttpResults.Ok<TValue> Ok<TValue> (TValue? value);
static member Ok : 'Value -> Microsoft.AspNetCore.Http.HttpResults.Ok<'Value>
Public Shared Function Ok(Of TValue) (value As TValue) As Ok(Of TValue)

Type Parameters

TValue

The type of object that will be JSON serialized to the response body.

Parameters

value
TValue

The value to be included in the HTTP response body.

Returns

The created Ok<TValue> for the response.

Applies to