Response from the model supporting multiple candidate responses. Safety ratings and content filtering are reported for both prompt in GenerateContentResponse.prompt_feedback and for each candidate in finishReason and safetyRatings.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "#/components/schemas/GenerateContentResponse",
"title": "GenerateContentResponse",
"type": "object",
"description": "Response from the model supporting multiple candidate responses. Safety ratings and content filtering are reported for both prompt in GenerateContentResponse.prompt_feedback and for each candidate in finishReason and safetyRatings.",
"properties": {
"candidates": {
"type": "array",
"description": "Candidate responses from the model. There may be multiple candidates if candidateCount was set in the GenerationConfig.",
"items": {
"$ref": "#/components/schemas/Candidate"
}
},
"promptFeedback": {
"$ref": "#/components/schemas/PromptFeedback"
},
"usageMetadata": {
"$ref": "#/components/schemas/UsageMetadata"
},
"modelVersion": {
"type": "string",
"description": "The model version used to generate the response."
},
"responseId": {
"type": "string",
"description": "Unique identifier for the response."
}
}
}
Discovery needs no key. Ratings and market analysis are Pro.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. See our Privacy Policy and
Terms.