Dopamine AI Prompt Library
Open search
Menu
Submitted by
hana_t34 prompts

API Key and Credential Rotation Runbook (JSON)

Added Nov 26, 2026

Prompt

api-key-and-credential-rotation-runbook-json.mdMarkdown · 82 lines · about 960 tokens
You are a senior platform security engineer. Using the schema below, produce a complete credential rotation runbook as one valid JSON object for the secret I describe (an API key, database password, OAuth client secret, signing key, webhook secret, cloud access key, SSH key or TLS certificate). Ask me up to 5 short questions first if the inputs are missing, then output ONLY the JSON, with no comments and no trailing commas.
My inputs:
- Secret type and provider:
- Where it is stored (vault, cloud secret manager, CI variables, .env files, Kubernetes secrets):
- Every service, job, device or partner that uses it:
- Reason for rotation (scheduled, employee offboarding, suspected leak, confirmed leak, compliance):
- Can the provider keep two valid credentials at once (yes / no / unknown):
- Allowed downtime and team size:
Schema:
```json
{
"rotation_runbook": {
"summary": {
"secret_name": "",
"secret_type": "",
"provider": "",
"reason": "",
"severity": "routine | elevated | incident",
"owner": "",
"approver": "",
"target_completion": "",
"rotation_strategy": "dual_credential_overlap | blue_green_secret | hard_cutover"
},
"blast_radius": {
"consumers": [
{ "name": "", "type": "service | job | ci | device | partner | human", "how_it_loads_secret": "", "reload_method": "restart | hot_reload | redeploy | manual", "owner": "", "risk_if_broken": "" }
],
"unknown_consumers_check": ["provider access logs for the old key", "secret scanning in repos and CI logs", "search config and IaC for the secret name"]
},
"preparation": [
{ "step": "", "command_or_location": "", "verify": "" }
],
"rotation_steps": [
{ "order": 1, "action": "", "who": "", "command_or_location": "", "expected_result": "", "verify": "", "rollback": "" }
],
"verification": {
"health_checks": [],
"old_credential_usage_must_be_zero_for": "",
"metrics_and_logs_to_watch": []
},
"revocation": {
"revoke_old_after": "",
"steps": [],
"confirm_revoked_by": ""
},
"rollback_plan": {
"trigger_conditions": [],
"steps": [],
"point_of_no_return": ""
},
"incident_extras": {
"applies": false,
"scope_review": "",
"audit_log_queries": [],
"notify": [],
"evidence_to_keep": []
},
"communication": [
{ "audience": "", "when": "", "channel": "", "message": "" }
],
"prevention": {
"next_rotation_date": "",
"automation_opportunities": [],
"secret_hygiene_fixes": []
},
"open_questions": []
}
}
```
Rules:
1. Prefer a dual-credential overlap: create the new secret, roll it out to every consumer, verify, and only then revoke the old one. If the provider allows only one valid credential, use hard_cutover and plan a short maintenance window.
2. Order rotation_steps so nothing breaks: store the new secret, update consumers from least to most critical, reload each one, verify, then revoke.
3. Every step must have a concrete verify and, before the point of no return, a rollback.
4. Never print, invent or echo real secret values; use placeholders like <NEW_SECRET_REF>.
5. For a suspected or confirmed leak, set severity to incident, fill incident_extras, revoke as fast as safely possible, and review audit logs for misuse since the exposure window began.
6. Include CI/CD variables, local .env files, cached build artifacts, mobile or desktop apps and partner integrations in the consumer search, because they are the usual misses.
7. In prevention, suggest moving to short-lived or workload identity credentials where the provider supports them, and a realistic rotation interval.
8. Put anything you had to assume into open_questions instead of guessing silently.

About this prompt

Content type
Code
Industries
Software Development
Models
GPT
Languages
English
Length
82 lines, about 960 tokens
Added
Nov 26, 2026
License
CC0
Request takedown
hana_t34 prompts
Profile

More from hana_t

View all

Tell Your Story

Write a personal story about why I started contributing to open source, what drives me, and how sponsorship helps me continue this journey in [field/technology].

Event Seating Chart Planner

--- name: event-seating-chart-planner description: Builds a seating chart for weddings, dinners and team events from your tables and guest list - keeps couples and families together, honours sit-with and keep-apart requests and head-table seats, puts mobility needs at accessible tables, seats nobody among strangers and fills tables by group. Flags misspelled names, duplicates, conflicting requests

How to Obtain a Radio and TV License in Nigeria

Act as a Broadcasting License Consultant. You are an expert in Nigerian broadcasting regulations with extensive knowledge of the licensing process for radio and TV stations. Your task is to guide users through the process of obtaining a broadcasting license in Nigeria. Responsibilities: - Provide a step-by-step process for application. - List necessary documents and requirements. - Explain the re

Comprehensive Repository Audit & Remediation Prompt

## Objective Conduct a thorough analysis of the entire repository to identify, prioritize, fix, and document ALL verifiable bugs, security vulnerabilities, and critical issues across any programming language, framework, or technology stack. ## Phase 1: Initial Repository Assessment ### 1.1 Architecture Mapping - Map complete project structure (src/, lib/, tests/, docs/, config/, scripts/, etc.)