ChatResponse class
Chat response.
Constructors
-
ChatResponse.fromJson(Map<
String, dynamic> json, {bool isStream = false}) -
Parse a json response to a ChatResponse object.
factory
Properties
-
choices
→ List<
ResponseChoice> -
List of completion choices
final
- createdAt → DateTime
-
Date when the response was created.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Unique completion identifier.
final
- metadata → OpenRouterMetadata?
-
final
- model → String
-
Slug of the model used for the completion.
final
- object → String
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- serviceTier → ServiceTier
-
The service tier used by the upstream provider for this request.
final
- systemFingerprint → String?
-
final
- usage → ChatResponseUsage?
-
Token usage statistics.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited