Skip to content
Documentation

NotInTheContextOfAnHttpRequestException Class

This error occurs when no storage information is passed while deserializing a reference and the IDefaultStorageInformationProvider<TReference> registered for that type requires an HTTP context to determine the default storage information.

public sealed class NotInTheContextOfAnHttpRequestException : HAKOM.ErrorHandling.Core.Net.Api.HakomException

Inheritance System.Object 🡒 System.Exception 🡒 HakomException 🡒 NotInTheContextOfAnHttpRequestException

To avoid this issue, make sure all references of this type include a storage information property for deserialization or make sure this deserialization operation only occurs within an HTTP request.

This exception is identified by error code HK12047.

NotInTheContextOfAnHttpRequestException.EquivalentHttpStatusCode Property

Section titled “NotInTheContextOfAnHttpRequestException.EquivalentHttpStatusCode Property”

When unhandled within an HTTP request, this exception produces HTTP 400 (Bad Request).

protected override System.Net.HttpStatusCode EquivalentHttpStatusCode { protected get; }

System.Net.HttpStatusCode

NotInTheContextOfAnHttpRequestException.ReferenceTypeName Property

Section titled “NotInTheContextOfAnHttpRequestException.ReferenceTypeName Property”

The name of the type of reference for which deserialization failed.

public string ReferenceTypeName { get; }

System.String

© 2026 Volue.Version v0.6.38017 November 2026