We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 09606c0 commit 76fe4ddCopy full SHA for 76fe4dd
docs/models/google.md
@@ -80,7 +80,10 @@ from pydantic_ai import Agent
80
from pydantic_ai.models.google import GoogleModel
81
from pydantic_ai.providers.google import GoogleProvider
82
83
-credentials = service_account.Credentials.from_service_account_file('path/to/service-account.json')
+credentials = service_account.Credentials.from_service_account_file(
84
+ 'path/to/service-account.json',
85
+ scopes=['https://www.googleapis.com/auth/cloud-platform'],
86
+)
87
provider = GoogleProvider(credentials=credentials)
88
model = GoogleModel('gemini-1.5-flash', provider=provider)
89
agent = Agent(model)
0 commit comments