Check RefreshToken Authentication - auto-refresh token for refresh token
In M25 preship testing, when using RefreshToken Auth and populate random RefreshToken
The current workflow will be utilizing the password flow which fails currently and we can simulate the error in postman.
So, we will exclude the scope of the M25 preship testing
Issue: osdu/platform/data-flow/ingestion/osdu-airflow-lib!375 (comment 368269)
Workaround:
- Always update the refresh token manually when the refresh token expired or failed
Airflow Logs
[2025-03-19, 04:26:35 UTC] {oauth_refresh_token.py:66} INFO - Refresh Token in secret Vault is expired --- Generating new Refresh token
[2025-03-19, 04:26:35 UTC] {generate_refresh_token.py:59} INFO - Auto Generate Refresh Token --- Start
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:41} INFO - In SecrectService --Start
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:59} INFO - In SecrectService --End
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:41} INFO - In SecrectService --Start
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:59} INFO - In SecrectService --End
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:41} INFO - In SecrectService --Start
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:59} INFO - In SecrectService --End
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:41} INFO - In SecrectService --Start
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:59} INFO - In SecrectService --End
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:41} INFO - In SecrectService --Start
[2025-03-19, 04:26:35 UTC] {secret_service_client.py:59} INFO - In SecrectService --End
[2025-03-19, 04:26:36 UTC] {airflow_logger.py:266} ERROR -
--------------------------Error Occured----------------------------
Function Name : auto_generate_refresh_token
Exception Details: {"error":"unsupported_grant_type"}
Exception Details: 400: Bad Request - The server cannot process the request due to a client error (e.g., malformed request syntax, invalid request message framing).
-----------------------
Postman auth for AWS Preship to get refresh token - authorization_code instead of password
Edited by Teo Sheng Pu
