Interface: NonJsonResponseDiagnostics
Diagnostic payload carried in StorefrontError.cause when code === ErrorCodes.NON_JSON_RESPONSE.
StorefrontErrorOptions.cause is unknown by design (it wraps arbitrary thrown values), so a
consumer narrows with err.cause as NonJsonResponseDiagnostics after checking err.code.
Properties
bodySnippet
bodySnippet:
string
The first ~200 characters of the response body, trimmed — enough to spot an HTML challenge/error page in a log without the full payload.
cfRay
cfRay:
string|null
The Cloudflare cf-ray response header, when present — useful for support correlation.
contentType
contentType:
string|null
The response's Content-Type header, or null when absent.