aws_refresh_if_expiring_soon
Checks cached AWS SSO token expiry and automatically refreshes if fewer than thresholdMinutes remain, returning verification URL and code to avoid mid-session expiry.
Instructions
Proactive SSO token check. If the cached token has fewer than thresholdMinutes left (default 10), this kicks off aws_login_start and returns the verification URL + code in one round-trip. If plenty of time remains, returns status: 'ok' with the minutes left. Use at the start of a multi-step AWS workflow to avoid mid-session expiry.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| thresholdMinutes | No | Trigger refresh when the token has fewer than this many minutes left. Default 10. | |
| profile | No | AWS profile configured for SSO. Defaults to $AWS_PROFILE or 'default'. |