Is there a clean way to generate a long-lived API token for a GitHub Actions CI/CD pipeline without hitting the standard OAuth refresh window?
The current workflow fails when the access token expires between the terraform plan and apply steps. I am using the POST /api/v2/oauth/token endpoint with client_credentials grant type, but the returned token only lasts an hour.
The API returns a 401 Unauthorized error during the apply phase. Is there a specific parameter or scope required to extend the token lifetime for automated service accounts?