Optimized for: Gemini / ChatGPT / Claude
Advanced AI Prompt for Time-Bound IAM Policy Conditions
Use this engineered prompt to drastically optimize your workflow and output.
Required Variables
- ✦
[START_TIME] - ✦
[END_TIME] - ✦
[USER_ARN] - ✦
[RESOURCE_ARN]
advanced-ai-prompt-time-bound-iam-access.txt
Create an AWS IAM policy for [USER_ARN] that grants temporary 'AdministratorAccess' to [RESOURCE_ARN] but only between the hours of [START_TIME] and [END_TIME] (ISO 8601 format). Use the 'DateGreaterThan' and 'DateLessThan' conditions. Also, include a global condition that requires the user to be logged in with MFA. The output should be a JSON policy document.
Example Output
"The AI outputs a policy featuring 'aws:CurrentTime' conditions that automatically expire the access after the specified window."