Skip to content

JsonStreams.JsonBody

Namespace: Vercel.AI.ProviderUtils

public sealed class JsonStreams.JsonBody

A parsed JSON body and the headers that came with it.

Inheritance: object

View source

JsonBody(JsonElement, JsonElement, IReadOnlyDictionary<string, string>)

Section titled “JsonBody(JsonElement, JsonElement, IReadOnlyDictionary<string, string>)”
public JsonBody(JsonElement value, JsonElement rawValue, IReadOnlyDictionary<string, string> headers)

Creates a body.

Parameters

Name Type Description
value JsonElement
rawValue JsonElement
headers IReadOnlyDictionary<string, string>

View source

public IReadOnlyDictionary<string, string> Headers { get; }

Response headers.

Value: IReadOnlyDictionary<string, string>

View source

public JsonElement RawValue { get; }

Parsed JSON before projection.

Value: JsonElement

View source

public JsonElement Value { get; }

Value after the schema projection.

Value: JsonElement

View source

Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product