Firebase.AI.GenerateContentResponse

The model's response to a generate content request.

Summary

Properties

Candidates
IReadOnlyList<Candidate >
A list of candidate response content, ordered from best to worst.
FunctionCalls
Returns function calls found in anyParts of the first candidate of the response, if any.
PromptFeedback
A value containing the safety ratings for the response, or, if the request was blocked, a reason for blocking the request.
Text
string
The response's content as text, if it exists.
ThoughtSummary
string
A summary of the model's thinking process, if available.
UsageMetadata
Token usage metadata for processing the generate content request.

Properties

Candidates

IReadOnlyList<Candidate>Firebase::AI::GenerateContentResponse::Candidates

A list of candidate response content, ordered from best to worst.

FunctionCalls

IReadOnlyList<ModelContent.FunctionCallPart>Firebase::AI::GenerateContentResponse::FunctionCalls

Returns function calls found in anyParts of the first candidate of the response, if any.

PromptFeedback

PromptFeedbackFirebase::AI::GenerateContentResponse::PromptFeedback

A value containing the safety ratings for the response, or, if the request was blocked, a reason for blocking the request.

Text

stringFirebase::AI::GenerateContentResponse::Text

The response's content as text, if it exists.

ThoughtSummary

stringFirebase::AI::GenerateContentResponse::ThoughtSummary

A summary of the model's thinking process, if available.

Note that Thought Summaries are only available whenIncludeThoughts is enabled in theThinkingConfig. For more information, see theThinking documentation.

UsageMetadata

UsageMetadataFirebase::AI::GenerateContentResponse::UsageMetadata

Token usage metadata for processing the generate content request.

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-09-04 UTC.