Teradata Package for Python Function Reference | 20.00 - authenticate - Teradata Package for Python - Look here for syntax, methods and examples for the functions included in the Teradata Package for Python.
Teradata® Package for Python Function Reference - 20.00
- Deployment
- VantageCloud
- VantageCore
- Edition
- VMware
- Enterprise
- IntelliFlex
- Product
- Teradata Package for Python
- Release Number
- 20.00.00.11
- Published
- August 2026
- ft:locale
- en-US
- ft:lastEdition
- 2026-08-13
- dita:id
- TeradataPython_FxRef_Enterprise_2000
- Product Category
- Teradata Vantage
- teradataml.sdk.DeviceCodeAuth.authenticate = authenticate(self, token_cache_file_path=None)
- DESCRIPTION:
Authenticates using device code flow and fetches the access token.
PARAMETERS:
token_cache_file_path:
Optional Argument.
Specifies the file path to load and/or cache the token data.
Types: str
RETURNS:
requests.Session: Authenticated session with the access token.
RAISES:
None
EXAMPLES:
>>> from teradataml.sdk import DeviceCodeAuth
>>> auth = DeviceCodeAuth(
auth_token_url="https://example.com/token",
auth_device_auth_url="https://example.com/device_auth",
auth_client_id="your_client_id",
auth_client_secret="your_client_secret"
)
>>> session = auth.authenticate(token_cache_file_path="/path/to/token_cache.json")