Detect when Jira/Confluence is unavailable and store operations locally for later sync. This ensures work can continue even when Atlassian services are temporarily down.
Stores Jira/Confluence operations locally when services are unavailable for later sync.
/plugin marketplace add marcel-Ngan/ai-dev-team/plugin install ai-dev-team@ai-dev-team-marketplaceThis skill inherits all available tools. When active, it can use any tool Claude has access to.
Detect when Jira/Confluence is unavailable and store operations locally for later sync. This ensures work can continue even when Atlassian services are temporarily down.
None - this skill handles local file operations only.
Pending items are stored in the active workflow directory:
workflow/active/{workflow-name}/pending/
| Error Type | Detection Patterns |
|---|---|
| Service Unavailable | HTTP 503, "service unavailable", "service temporarily unavailable" |
| Gateway Timeout | HTTP 504, "gateway timeout" |
| Authentication Failure | HTTP 401, "unauthorized", "token expired", "authentication failed" |
| Connection Failure | ECONNREFUSED, ETIMEDOUT, "connection refused", "connection timeout" |
| MCP Server Failure | "MCP server not running", "MCP connection failed", "server not available" |
| Error Type | Reason |
|---|---|
| 400 Bad Request | Invalid data - fix the request payload |
| 403 Forbidden | Permission issue - fix permissions |
| 404 Not Found | Target doesn't exist - handle differently |
Check if an error indicates service/auth unavailability:
function isUnavailabilityError(error) {
const errorString = String(error).toLowerCase();
const unavailabilityPatterns = [
// HTTP status codes
'503', 'service unavailable',
'504', 'gateway timeout',
'401', 'unauthorized', 'token expired', 'authentication failed',
// Connection errors
'econnrefused', 'etimedout', 'connection refused', 'connection timeout',
// MCP errors
'mcp server', 'server not available', 'mcp connection'
];
return unavailabilityPatterns.some(pattern => errorString.includes(pattern));
}
When unavailability is detected, store the operation locally:
mkdir -p workflow/active/{workflow-name}/pending/
Use sequential numbering with timestamp: 001-jira-comment.json, 002-confluence-page.json
File Format:
{
"id": "001",
"created_at": "2025-01-17T10:30:00Z",
"service": "jira",
"operation": "add_comment",
"original_error": "503 Service Unavailable",
"target": {
"issue_key": "PROJECT-45"
},
"payload": {
"cloudId": "abc123",
"issueIdOrKey": "PROJECT-45",
"commentBody": "..."
},
"context": {
"agent": "Senior Developer",
"step": "Code Review",
"workflow": "development-PROJECT-45"
}
}
| Service | Operation | Target Fields |
|---|---|---|
| jira | create_issue | project_key, issue_type |
| jira | edit_issue | issue_key |
| jira | add_comment | issue_key |
| jira | transition_issue | issue_key, transition_name |
| confluence | create_page | space_key, parent_page |
| confluence | update_page | page_id or page_title |
After storing locally, inform the user:
⚠️ **Jira/Confluence Unavailable**
The operation has been stored locally for later sync:
- Operation: Add comment to PROJECT-45
- Stored: workflow/active/development-PROJECT-45/pending/001-jira-comment.json
Run `/sync` when services are available to push pending changes.
Workflow will continue without blocking.
List pending items in a workflow:
ls workflow/active/{workflow-name}/pending/*.json 2>/dev/null | wc -l
Or read all pending files to get details:
for f in workflow/active/{workflow-name}/pending/*.json; do
cat "$f" | jq '{id, service, operation, target, created_at}'
done
When any Jira/Confluence skill encounters an unavailability error:
isUnavailabilityError()try {
// Attempt normal MCP call
await Atlassian:addCommentToJiraIssue({
cloudId: config.jira.cloudId,
issueIdOrKey: "PROJECT-45",
commentBody: commentText
});
} catch (error) {
if (isUnavailabilityError(error)) {
// Store locally for later sync
await storeOfflineFallback({
service: "jira",
operation: "add_comment",
original_error: error.message,
target: { issue_key: "PROJECT-45" },
payload: {
cloudId: config.jira.cloudId,
issueIdOrKey: "PROJECT-45",
commentBody: commentText
},
context: {
agent: currentAgent,
step: currentStep,
workflow: workflowId
}
});
// Notify user and continue
console.log("⚠️ Jira unavailable - comment stored locally");
} else {
// Re-throw other errors
throw error;
}
}
| Scenario | Action |
|---|---|
| Cannot create pending directory | Log error, notify user, may need to block |
| Cannot write pending file | Log error, notify user, may need to block |
| Disk full | Notify user, cannot store locally |
Activates when the user asks about AI prompts, needs prompt templates, wants to search for prompts, or mentions prompts.chat. Use for discovering, retrieving, and improving prompts.
Activates when the user asks about Agent Skills, wants to find reusable AI capabilities, needs to install skills, or mentions skills for Claude. Use for discovering, retrieving, and installing skills.
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.