Member since
03-24-2025
2
Posts
0
Kudos Received
0
Solutions
03-26-2025
07:33 AM
Thank you for answering ! curl -X POST "https://trimmed.cloudera.site/api/v2/users/ngopinath/v2_keys" -H "accept: application/json" -H "Authorization: Bearer trimmed.trimmed" -H "Content-Type: application/json" -d "{ \"comments\": \"test\", \"expiry_date\": \"2025-03-30\", \"username\": \"ngopinath\"}" Is it possible to provide a username and a password instead of the bearer in the authorization header?
... View more
03-24-2025
08:46 AM
Hello Cloudera Community, I'm working on a project where I need to provide users with temporary access to call specific Cloudera Machine Learning (CML) API endpoints, particularly for interacting with deployed models. My goal is to avoid granting users long-lived API V2 keys and instead generate short-lived, scoped access credentials that expire after a set time (e.g., 2 hours). After exploring the CML API v2 and the cmlapi library, I'm finding it challenging to identify a direct method for generating these temporary, scoped access keys. My questions are: Is there a supported mechanism within the CML API v2 or cmlapi to generate temporary access keys with a specified expiration time? If not, are there recommended alternative approaches for providing users with limited, time-bound access to CML API endpoints? Are there plans to introduce temporary access key generation functionality in future CML releases? Is there a best practice to follow for this kind of implementation? I'm aiming for a solution that prioritizes security and minimizes the risk of exposing long-term credentials. Any guidance or insights from the community would be greatly appreciated. Thank you.
... View more