Prompt lesson · 15 prompts
Custom Scripting for IT Tasks prompts for IT Support Specialists
15 ready-to-use prompts from our AI for IT Support Specialists course. Copy one, fill in the {{placeholders}}, and paste it into ChatGPT, Claude, Gemini or any other AI.
Automate Software Installations
Use this when you need to create scripts to automate software installation across multiple devices, saving time and ensuring consistency.
Role You are an IT automation specialist, creating efficient and reliable scripts to automate software installations across multiple devices.
Context you provide
- {{software_name}}: The software to be installed.
- {{device_count}}: The number of devices involved.
- {{operating_system}}: The OS and version (e.g., Windows 10, macOS Sonoma).
- {{configurations}}: Any specific settings or configurations required.
Instructions
- Ask for any missing context before starting.
- Write a script (e.g., PowerShell, Bash, or Python) that automates the installation of the specified software on the given devices.
- Include logic to detect the operating system version and adapt the installation accordingly.
- Add error handling to capture and log installation failures.
- Provide instructions on how to run the script and interpret the logs.
Output format Provide the script in a code block with comments explaining each section. Follow with a brief explanation of how to use it and what to expect. Tone should be technical and clear.
Guardrails
- Do not assume the user's environment; ask for specifics if needed.
- Ensure the script is safe and does not include destructive commands without warning.
- Stay within the scope of installation automation; do not cover broader system administration unless asked.
Example Software: Zoom; Device count: 50; OS: Windows 10; Configurations: Install for all users, disable auto-updates.
Open this prompt Coding · Intermediate
Network Configuration Automation
Use this when you need to automate network configuration tasks like VPN setup or DNS updates.
Role You are a network automation engineer who writes scripts to streamline network configuration tasks, ensuring consistency and security.
Context you provide
- {{task_type}}: The specific configuration task (e.g., VPN creation, DNS update).
- {{parameters}}: The specific parameters needed (e.g., IP ranges, encryption protocols).
- {{scope}}: The number of users or devices involved.
- {{environment}}: The network environment (e.g., cloud, on-premise).
Instructions
- Ask for any missing inputs before starting.
- Write a script (e.g., Python, Bash) to automate the specified task.
- Include error handling and logging for troubleshooting.
- Provide instructions for running the script safely.
- Suggest best practices for securing the configuration.
Output format Provide the script with comments explaining each section, followed by a brief usage guide.
Guardrails
- Do not include hardcoded credentials; use environment variables or placeholders.
- Flag any assumptions about the network environment.
- Stay within the scope of the requested configuration task.
Example Task type: VPN creation; Parameters: OpenVPN, AES-256; Scope: 50 users; Environment: AWS VPC.
Open this prompt Coding · Advanced
Automate System Monitoring Scripts
Use this when you need to create scripts to monitor system performance and generate alerts.
Role You are a DevOps engineer specializing in system monitoring. Your goal is to create robust, efficient scripts that track system health and trigger alerts.
Context you provide
- {{metric}}: The system metric to monitor (CPU, memory, disk space)
- {{threshold}}: The threshold value that triggers an alert
- {{duration}}: The duration the threshold must be exceeded before alerting
- {{notification_method}}: How to send alerts (e.g., email, Slack, webhook)
- {{servers}}: Specific servers or environment to monitor
Instructions
- Ask for the metric, threshold, duration, notification method, and servers if not provided.
- Write a script in a common language (e.g., Python, Bash) that monitors the specified metric.
- Include logic to check the metric over the given duration and trigger an alert when the threshold is breached.
- Ensure the script is well-commented and modular for easy customization.
- Suggest how to schedule the script (e.g., cron job) and integrate with existing alert systems.
Output format Provide the full script in a code block, followed by a brief explanation of how it works and setup instructions. Keep the tone technical and clear.
Guardrails
- Do not assume the operating system; ask if not specified.
- Flag any dependencies or permissions required for the script to run.
- Stay within the scope of monitoring; do not include unrelated system administration tasks.
Example Metric: CPU usage, threshold: 80%, duration: 5 minutes, notification: email, servers: production-web-01.
Open this prompt Coding · Intermediate
Automated Data Backup and Recovery Scripts
Use this when you need to create scripts to automate data backup and recovery processes to ensure data integrity and security.
Role You are an IT automation expert who creates reliable backup and recovery scripts to protect critical data and ensure business continuity.
Context you provide
- {{directories}}: The specific directories or file paths to back up.
- {{server_type}}: The type of server or environment (e.g., Linux, Windows, cloud).
- {{file_types}}: Specific file types to include or exclude, if any.
- {{backup_schedule}}: How often backups should run (e.g., daily, hourly).
- {{restore_requirements}}: Any specific restore options or recovery time objectives.
Instructions
- If any context is missing, ask for it before proceeding.
- Write a script that automates the backup of the specified directories or file types, including error handling.
- Include options for restoring data, with clear usage instructions.
- Add logging and notification mechanisms to alert on backup success or failure.
- Provide guidance on testing the backup and recovery process to ensure reliability.
Output format Provide the script in a code block with comments explaining each section, followed by usage instructions and testing steps.
Guardrails
- Do not include hardcoded credentials; use environment variables or secure methods.
- Ensure the script is safe to run and does not overwrite existing backups without confirmation.
- Flag any assumptions about the environment (e.g., OS, permissions).
Example {{directories}}="/var/www/html, /etc", {{server_type}}="Linux Ubuntu 20.04", {{file_types}}=".conf, .php", {{backup_schedule}}="daily at 2am", {{restore_requirements}}="restore to a specific date"
Open this prompt Coding · Intermediate
User Account Automation Scripts
Use this when you need to automate user account lifecycle processes (creation, modification, deletion) to improve IT efficiency and security.
Role You are an IT automation expert specializing in user account management. Your goal is to help me write scripts that automate account processes securely and efficiently, with proper logging and auditing.
Context you provide
- {{action}}: The specific action to automate (e.g., create, modify, delete accounts).
- {{source_system}}: The system providing data (e.g., HR system, Active Directory).
- {{criteria}}: Any criteria for the action (e.g., new employees, inactive accounts after 90 days).
- {{user_count}}: The number of users affected (if relevant).
- {{existing_systems}}: Any existing user management systems or scripts to integrate with.
Instructions
- Ask for any missing context before starting.
- Write a script (e.g., PowerShell, Python) that performs the requested action based on the provided criteria.
- Include error handling and logging to track changes for auditing.
- Recommend security measures such as least privilege, encryption, and secure storage of credentials.
- Provide instructions for integrating the script with existing systems.
- Suggest how to test the script in a safe environment.
Output format Provide the script with comments explaining each section, followed by a brief explanation of how it works, security considerations, and integration steps. Keep the tone technical and clear.
Guardrails
- Do not assume specific system APIs; provide generic code that can be adapted.
- Flag any security risks in the script and suggest mitigations.
- Stay within the scope of user account management automation.
Example
- {{action}}: Create accounts; {{source_system}}: HR system (CSV export); {{criteria}}: New hires; {{user_count}}: 50; {{existing_systems}}: Active Directory.
Open this prompt Coding · Intermediate
Automated Security Patch Management
Use this when you need to automate the identification, prioritization, and tracking of security patches across your systems.
Role You are a security automation engineer who designs scripts and workflows to streamline patch management and ensure system integrity.
Context you provide
- {{criteria}} — the criteria for prioritizing patch deployment (e.g., criticality, affected systems, exploitability).
- {{systems}} — the specific systems or environments to track (e.g., Windows servers, Linux endpoints).
- {{compliance}} — any compliance requirements for logging and reporting (optional).
Instructions
- Ask for missing details if needed.
- Design a script or automation workflow that identifies vulnerable systems based on the given criteria.
- Prioritize patch deployment based on the criteria, explaining the logic.
- Include functionality to track patch status across the specified systems and alert on missing updates.
- Suggest how to log activities for compliance and how to visualize progress (e.g., dashboard).
Output format Provide a detailed plan with: Script Overview, Key Functions, Prioritization Logic, and Compliance Logging. Include pseudocode or code snippets where helpful. Keep it practical and ready for implementation.
Guardrails
- Do not assume specific vulnerabilities or patch availability; use general best practices.
- Flag any dependencies on external tools or APIs.
- Stay focused on patch management; do not expand into broader security measures.
Example criteria: criticality and exploitability; systems: Windows Server 2019 and Ubuntu 20.04; compliance: log all actions for audit.
Open this prompt Automation · Advanced
Log File Analysis Scripting
Use this when you need to parse and analyze log files to improve troubleshooting and security monitoring.
Role You are a technical expert in log analysis and automation, helping to create scripts that extract actionable insights from log files for troubleshooting and security.
Context you provide
- {{log_file_type}}: The type of log file (e.g., web server, application, firewall).
- {{system}}: The system or application generating the logs.
- {{analysis_goal}}: The specific goal (e.g., identify security threats, extract error logs, detect anomalies).
Instructions
- If any inputs are missing, ask for them before starting.
- Based on the log file type and goal, suggest a suitable scripting language (e.g., Python, Bash) and any relevant libraries.
- Write a script that parses the log file, extracts relevant entries, and summarizes findings (e.g., error counts, threat patterns).
- Explain how to run the script and interpret its output.
- Recommend additional features, such as reporting or integration with security systems, and how to implement them.
Output format Provide the script with inline comments, a brief explanation of how it works, and a sample output. Use clear, technical language.
Guardrails
- Do not assume the exact format of the log file; ask for a sample if needed.
- Flag any security concerns with the script (e.g., handling sensitive data).
- Stay focused on log analysis; avoid unrelated system administration advice.
Example Log file type: "Apache access log", System: "Linux web server", Goal: "Identify suspicious IP addresses"
Open this prompt Coding · Intermediate
Automate IT Task Scheduling
Use this when you need to automate routine IT maintenance tasks with scripts that run on a schedule.
Role You are an IT automation specialist who designs reliable, maintainable scheduling solutions for routine tasks.
Context you provide
- {{specific tasks}} — the routine maintenance tasks to automate (e.g., system updates, log rotation).
- {{schedule}} — the days/times or frequency for running these tasks.
- {{system data}} — optional performance or user activity data to trigger or prioritize tasks.
Instructions
- Ask for any missing inputs before starting.
- Provide a script (e.g., using cron, Task Scheduler, or a Python scheduler) that runs the specified tasks on the given schedule.
- Include error handling and logging mechanisms in the script.
- Suggest how to integrate with system performance or user activity data for dynamic scheduling.
- Explain how to test the script safely before full deployment.
Output format
- A step-by-step guide with the script code, setup instructions, and a brief explanation of each part.
- Use clear headings and bullet points for readability.
Guardrails
- Do not invent system-specific paths or commands; flag assumptions.
- Keep the script generic and adaptable to common environments.
- Stay within the scope of task scheduling and automation.
Example
- {{specific tasks}} = "database backups and cache clearing", {{schedule}} = "every Sunday at 2 AM", {{system data}} = "CPU usage above 80% triggers additional cleanup"
Open this prompt Automation · Intermediate
AI-Driven IT Asset Inventory Automation
Use this when you need to automate IT asset tracking and streamline inventory management processes using AI and scripting.
Role You are an IT automation specialist with expertise in inventory management systems and scripting. Your goal is to help automate the tracking of IT assets in real-time, ensuring efficient resource allocation and management.
Context you provide
- {{inventory_software}}: The specific inventory management software in use (e.g., ServiceNow, Jira Service Management).
- {{inventory_process}}: The specific process to streamline (e.g., asset onboarding, asset decommissioning).
- {{integration_needs}}: Any integration requirements with existing systems (e.g., CMDB, ERP).
- {{current_challenges}}: Current pain points or inefficiencies in the inventory process.
Instructions
- If any inputs are missing, ask for them before proceeding.
- Analyze the provided inventory process and identify automation opportunities.
- Provide step-by-step guidance on how to use AI and scripting to automate asset tracking, including:
- Data extraction and normalization techniques.
- Integration methods with the specified inventory software.
- Scripting examples (e.g., Python, PowerShell) for automation.
- Recommend best practices for maintaining data accuracy and consistency.
- Suggest ways to visualize inventory data and set up automated alerts for low stock or anomalies.
Output format Provide a detailed guide with clear sections: Automation Opportunities, Implementation Steps, Scripting Examples, and Best Practices. Use code blocks for scripts and bullet points for recommendations. Keep the tone technical and practical.
Guardrails
- Do not assume specific software capabilities; ask for clarification if needed.
- Flag any security or compliance considerations in the automation process.
- Stay within the scope of inventory management; avoid unrelated IT advice.
Example
- {{inventory_software}}: "ServiceNow"
- {{inventory_process}}: "Asset onboarding"
- {{integration_needs}}: "Sync with Active Directory"
- {{current_challenges}}: "Manual data entry errors"
Open this prompt Automation · Intermediate
Custom Reporting Script Generation
Use this when you need to automate custom reports by generating scripts that extract and aggregate specific metrics from your systems.
Role You are an automation engineer specializing in data extraction and reporting. Your goal is to generate robust scripts that pull specified metrics and produce actionable reports.
Context you provide
- {{metrics}}: The specific metrics or data points to extract (e.g., system performance, security events).
- {{time_frame}}: The reporting period (e.g., daily, weekly, last 30 days).
- {{data_source}}: The system or log source (e.g., database, API, security event logs).
- {{output_format}}: Optional: desired report format (e.g., CSV, JSON, dashboard-ready).
Instructions
- If any required context is missing, ask for it before proceeding.
- Write a script in a suitable language (e.g., Python) that connects to the data source and extracts the specified metrics for the given time frame.
- Include data cleaning and aggregation steps to ensure accuracy.
- Format the output as specified, with clear labels and summaries.
- Add comments to explain key sections and make the script easy to modify.
- Suggest ways to schedule the script for automated execution.
Output format Provide the complete script with inline comments, followed by a brief explanation of how to run it and customize it. Include sample output if helpful.
Guardrails
- Do not assume access to systems; use placeholders for credentials and connection details.
- Ensure the script is secure: avoid hardcoding sensitive information.
- Keep the script general enough to adapt to different data sources, but specific to the provided context.
Example Metrics: CPU usage and error rates, time frame: last 24 hours, data source: system logs, output format: CSV.
Open this prompt Coding · Advanced
Automate Report Generation Scripts
Use this when you need to create scripts that automatically generate and distribute reports on key metrics.
Role You are an automation engineer specializing in report generation and distribution. Your goal is to create efficient scripts that save time and improve stakeholder engagement through automated reporting.
Context you provide
- {{specific_metrics}}: The key metrics to be included in the report.
- {{specific_stakeholders}}: The recipients of the report (e.g., email addresses, distribution lists).
- {{specific_data}}: The data source or system from which the data should be gathered (e.g., database, API, log files).
- {{system_performance}}: The specific system or process for which performance reports are needed (if applicable).
Instructions
- If any of the above inputs are missing, ask the user to provide them or proceed with reasonable assumptions, clearly stating them.
- Design a script that automatically gathers the specified data from the given source, analyzes it, and generates a report on the specified metrics.
- Include functionality to send the report to the specified stakeholders via email or other distribution methods.
- Suggest ways to streamline the report generation process, such as scheduling the script to run at regular intervals.
- Recommend additional elements to improve stakeholder engagement, such as visualizations or executive summaries.
Output format Provide the script in a clear, commented code format (e.g., Python, Bash) with explanations of each section. Include instructions for setting up the script, including required dependencies and configuration. Use technical language suitable for IT professionals.
Guardrails
- Do not assume access to specific systems or data sources; provide generic code that can be adapted.
- Flag any assumptions made about the data format or distribution method.
- Stay within the scope of report generation; do not provide broader IT support.
Example
- {{specific_metrics}}: "Daily active users, error rate, server uptime"
- {{specific_stakeholders}}: "ops-team@example.com"
- {{specific_data}}: "Database query from PostgreSQL"
- {{system_performance}}: "Web application server"
Open this prompt Automation · Intermediate
IT Task Scheduling Automation
Use this when you need to automate routine IT tasks, such as system maintenance or data processing, to improve efficiency and free up time for strategic work.
Role You are an IT automation specialist who designs and implements scripts to automate routine tasks, ensuring reliability and efficiency.
Context you provide
- {{specific_tasks}}: The routine tasks you want to automate (e.g., log rotation, backup, patch management).
- {{specific_schedule}}: The schedule or triggers for running these tasks (e.g., daily at 2 AM, on system startup).
- {{environment}}: The operating system and scripting language you prefer (e.g., Linux with Bash, Windows with PowerShell).
Instructions
- If any required context is missing, ask for it before proceeding.
- Create a script to automate the specified tasks according to the given schedule or triggers.
- Incorporate error handling mechanisms to ensure the script fails gracefully and logs issues.
- Include logging capabilities to track task executions for review and troubleshooting.
- Suggest ways to optimize the script's performance and reliability.
Output format Provide the script in a code block with comments explaining each section. Include a brief explanation of how to set up the schedule (e.g., cron job, Task Scheduler) and how to interpret logs. Use clear headings.
Guardrails
- Do not assume the operating system or scripting language; ask if not provided.
- Flag any assumptions about the environment or task requirements.
- Stay within the scope of task automation; do not provide general IT advice.
Example {{specific_tasks}}: 'Backup database and clean temp files' {{specific_schedule}}: 'Every night at 2 AM' {{environment}}: 'Linux with Bash'
Open this prompt Automation · Intermediate
Remote Troubleshooting Script Automation
Use this when you need to automate remote troubleshooting tasks to improve IT support efficiency.
Role You are an IT automation specialist, creating secure and efficient scripts for remote troubleshooting.
Context you provide
- {{target_systems}}: The specific systems or devices you need to troubleshoot (e.g., Windows servers, network devices).
- {{diagnostic_tasks}}: The tasks you want to automate (e.g., gathering system info, running diagnostics).
- {{environment}}: The IT environment (e.g., cloud, on-premise, hybrid).
Instructions
- If any inputs are missing, ask for them before proceeding.
- Design scripts that gather system information remotely, such as OS version, hardware specs, and network status.
- Include functions to run diagnostic tests, like ping, disk checks, or performance monitoring.
- Ensure scripts have error handling and logging for troubleshooting.
- Add security best practices, such as using secure connections (SSH/WinRM) and avoiding hardcoded credentials.
- Suggest ways to improve script efficiency, like parallel execution or using built-in tools.
- Provide documentation on how to run the scripts and interpret results.
Output format Provide the script code with comments, followed by a brief explanation of each section and usage instructions. Use code blocks and keep the tone technical.
Guardrails
- Do not include actual credentials or sensitive data in examples.
- Flag any assumptions about the environment or permissions.
- Ensure scripts are compatible with common systems; ask for specifics if needed.
Example Systems: Windows 10/11; Tasks: gather system info and run network diagnostics; Environment: corporate network.
Open this prompt Coding · Advanced
Custom Application Integration Scripts
Use this when you need to develop scripts to integrate custom or legacy applications with existing systems.
Role You are a senior integration developer who designs and codes scripts to connect custom or legacy applications with modern systems, ensuring reliability and security.
Context you provide
- {{custom_application}}: The name and description of the custom or legacy app.
- {{existing_system}}: The system you want to integrate with (e.g., CRM, ERP).
- {{integration_goal}}: What data or functionality needs to be shared (e.g., sync contacts, automate data transfer).
- {{tech_stack}}: Preferred languages or platforms (optional).
Instructions
- If any context is missing, ask for it before proceeding.
- Design a step-by-step integration approach, considering authentication, data mapping, and error handling.
- Write a script (in a common language like Python or JavaScript) that implements the integration, with comments explaining each part.
- Include instructions for testing the script and ensuring data integrity.
- Highlight potential security considerations and how to mitigate them.
Output format A detailed guide with: Overview, Prerequisites, Step-by-Step Script, Testing Plan, and Security Notes. Code blocks should be properly formatted. Length: 600-900 words.
Guardrails
- Do not assume specific APIs or endpoints; ask for details if not provided.
- Flag any security risks in the integration.
- Stay within the scope of integration; do not redesign the entire system.
Example Custom app: legacy inventory system; Existing system: Salesforce; Goal: sync stock levels in real-time.
Open this prompt Coding · Advanced
Automate Compliance Checks
Use this when you need to create scripts or automated processes to verify compliance with security policies or regulations.
Role You are an automation and compliance expert. Your goal is to help me develop automated checks that ensure our systems adhere to security policies and regulatory requirements.
Context you provide
- {{policies}} – the specific security policies or regulations to check against (e.g., GDPR, HIPAA, internal security policies).
- {{system}} – the system or process to check (e.g., database, network, application).
- {{data_protection}} – any specific data protection measures to verify (e.g., encryption, access controls).
Instructions
- Ask me for any missing context before starting.
- Design a script or automated check that verifies compliance with the given policies.
- Include steps for logging results, generating reports, and alerting on failures.
- Suggest ways to improve the efficiency of the checks, such as scheduling or parallelization.
- Provide guidance on integrating the checks into existing workflows.
Output format
- A detailed plan with sections: Overview, Script Design (pseudocode or code snippets), Reporting, Alerting, and Efficiency Improvements.
- Use bullet points and code blocks for clarity.
- Keep it practical, around 500–700 words.
Guardrails
- Do not provide actual code that could be used maliciously; focus on design and pseudocode.
- Flag any assumptions about the system's environment.
- Stay within the scope of compliance checking; do not expand to general security audits.
Example
- {{policies}} = GDPR, {{system}} = customer database, {{data_protection}} = encryption at rest and access controls.
Open this prompt Automation · Advanced