Impact 2024: The Industrial Data and AI Conference for and by Users | Nominate Speakers Now for a Ch...
Hi there,I am trying to authenticate the CogniteClient in bluefield using our Azure B2C: response = requests.request("POST", "https://oceandataplatform.b2clogin.com/oceandataplatform.onmicrosoft.com/B2C_1A_ROPC_Auth/oauth2/v2.0/token", headers={ 'Content-Type': 'application/x-www-form-urlencoded'}, data={ "grant_type": 'password', "client_id": client_id, "scope": 'openid https://westeurope-1.cognitedata.com/user_impersonation', "username": username, "password": password,})creds = response.json()client = CogniteClient( token=creds["access_token"], project="oceandata", base_url='https://westeurope-1.cognitedata.com', client_name="cognite-python-dev", debug=True,)This works perfectly :) Edit: I initially asked how to get this working before spotting a typo in the code. Everything works fine now. Leaving the post here so that others may use it for reference.
Already have an account? Login
Enter your username or e-mail address. We'll send you an e-mail with instructions to reset your password.
Sorry, we're still checking this file's contents to make sure it's safe to download. Please try again in a few minutes.
Sorry, our virus scanner detected that this file isn't safe to download.