Back to Software Deployment Workflow

Integration and API Spec

The reference during the build: every tool connection, auth scope, field mapping, and error-handling rule.

4 pagesPDF · Technical
FS-DOC-05Technical

Integration and API Spec

Software Deployment Workflow

[YourCompany.com] · IT Department · Prepared by FullSpec · [Today's Date]

This document is the authoritative technical reference for every integration point in the Software Deployment Workflow automation. It covers authentication requirements, exact API scopes, webhook and trigger configuration, field mappings between tools, orchestration architecture, credential store contents, and defined error handling behaviour for each integration. The FullSpec team uses this specification during build and testing. Treat it as a living reference throughout the engagement and update it whenever credentials rotate or configuration changes.

01Tool inventory

Tool
Role in automation
Auth method
Min plan required
Used by agents
Orchestration layer
Hosts all workflows, manages credential store, routes inter-agent data
Internal service account
Self-hosted or cloud subscription
All agents
GitHub
Webhook trigger on PR merge, CI check query via API, deployment pipeline trigger via Actions API
Personal Access Token (PAT) or GitHub App
Free (public); Team plan for private repos with Actions minutes
Agent 1, Agent 2
Jira
Create deployment ticket, update ticket status and timestamp on completion
API token + Basic Auth (base64 email:token)
Free tier (up to 10 users); Standard for larger teams
Agent 1, Agent 3
Slack
Send Block Kit approval request, receive interactive button callback, post deployment result to channel
OAuth 2.0 Bot Token (xoxb-)
Pro plan required for Workflow interactivity at volume
Agent 1, Agent 2, Agent 3
Confluence
Read environment config table from known page, serve values to Environment and Deploy Agent
API token + Basic Auth (base64 email:token)
Standard (same Atlassian org as Jira)
Agent 2
GitHub Actions
Receive programmatic workflow dispatch trigger, apply environment variables, run deployment job
PAT or GitHub App installation token with workflow scope
Team plan (private repos); Actions minutes included
Agent 2
Datadog
Polled every 5 minutes post-deploy for monitor states and metric thresholds
API key + Application key
Pro plan (monitor alerting and API access)
Agent 3
PagerDuty
Fire incident alert via Events API v2 when Datadog health check breaches threshold
Integration key (Events API v2 routing key)
Professional plan (API and incident management)
Agent 3
Before you connect anything: sandbox-test every integration using non-production credentials in a staging environment before any production secrets are stored in the credential store. Confirm each tool responds with the expected HTTP 200 or 201 before advancing to the next connection. Never store plaintext secrets in workflow node configuration fields.
Integration and API SpecPage 1 of 4
FS-DOC-05Technical

02Per-tool integration detail

GitHub

Used by Agent 1 (webhook trigger and CI check query) and Agent 2 (workflow dispatch trigger). A GitHub App is preferred over a PAT for production because it provides scoped installation tokens that expire and can be rotated without tying access to an individual user account.

Auth method
GitHub App with installation access token (preferred) or PAT stored in credential store. Token exchanged per request using JWT signed with app private key (RS256).
Required scopes (PAT)
repo, workflow, checks:read, pull_requests:read, actions:write
Required permissions (GitHub App)
Contents: Read; Actions: Write; Checks: Read; Pull requests: Read; Webhooks: Admin (to register the push/merge event)
Webhook setup
Register a webhook on the target repository pointing to the orchestration layer inbound URL. Event: pull_request with action: closed and merged: true. Set a shared HMAC-SHA256 secret (stored in credential store as GITHUB_WEBHOOK_SECRET). Validate the X-Hub-Signature-256 header on every inbound request before processing.
CI check query
GET /repos/{owner}/{repo}/commits/{ref}/check-runs — filter where status=completed and evaluate all conclusion values. If any conclusion != success, branch to failure path.
Workflow dispatch trigger
POST /repos/{owner}/{repo}/actions/workflows/{workflow_id}/dispatches — body: {ref: target branch, inputs: {environment: string, jira_ticket_id: string, deploy_run_id: string}}. workflow_id stored in credential store as GITHUB_DEPLOY_WORKFLOW_ID.
Rate limits
REST API: 5,000 requests/hour per authenticated user or app installation. At ~12 deployments/month (approx. 6 API calls per deployment), peak usage is under 100 calls/hour. No throttling needed at current volume.
Constraints
Webhook deliveries are retried by GitHub up to 3 times on non-200 responses. The orchestration layer must respond with HTTP 200 within 10 seconds. Workflow dispatch requires the target workflow file to exist on the specified ref and have workflow_dispatch as a trigger event.
// Inbound webhook payload (truncated)
{
  "action": "closed",
  "pull_request": {
    "merged": true,
    "merge_commit_sha": "<sha>",
    "base": { "ref": "main" },
    "head": { "ref": "feature/DEPLOY-42" },
    "user": { "login": "priya-nair" }
  },
  "repository": { "full_name": "yourcompany/app" }
}
// Output to Agent 1 context
{ commit_sha, pr_number, pr_author, repo_full_name, target_branch }
Jira

Used by Agent 1 (ticket creation) and Agent 3 (status update and timestamp write-back). The Jira project key and deployment issue type ID must be stored in the credential store. No hardcoded values in workflow node fields.

Auth method
HTTP Basic Auth. Encode email:api_token in base64. Header: Authorization: Basic <encoded>. API token generated from id.atlassian.net/manage-profile/security/api-tokens.
Required scopes
Classic API tokens do not use OAuth scopes. The Atlassian account must have project-level permissions: Create Issues, Edit Issues, Transition Issues, Add Comments on the target project.
Ticket creation endpoint
POST https://{org}.atlassian.net/rest/api/3/issue — Content-Type: application/json. Fields: project.key, summary, issuetype.id, description (Atlassian Document Format), labels, customfield for environment and deploy_run_id.
Status transition endpoint
POST https://{org}.atlassian.net/rest/api/3/issue/{issueIdOrKey}/transitions — body: {transition: {id: "<transition_id>"}}. Transition IDs must be retrieved once at setup via GET /rest/api/3/issue/{key}/transitions and stored in credential store as JIRA_TRANSITION_DONE_ID and JIRA_TRANSITION_FAILED_ID.
Required configuration
JIRA_BASE_URL, JIRA_PROJECT_KEY, JIRA_ISSUE_TYPE_ID (for deployment ticket type), JIRA_TRANSITION_DONE_ID, JIRA_TRANSITION_FAILED_ID — all stored in credential store, never hardcoded.
Rate limits
Jira Cloud REST API: no hard published rate limit for Standard/Premium plans but applies a 429 with Retry-After when bursts exceed ~100 requests/10 seconds. At 12 deployments/month, usage is negligible. No throttling needed.
Constraints
Atlassian Document Format (ADF) is required for the description field in API v3. Plain text strings are rejected. The orchestration layer must construct a valid ADF JSON object for the ticket body.
// Ticket creation request body (ADF description, truncated)
{
  "fields": {
    "project": { "key": "{{JIRA_PROJECT_KEY}}" },
    "summary": "Deploy: {{repo_name}} v{{version}} -> {{environment}}",
    "issuetype": { "id": "{{JIRA_ISSUE_TYPE_ID}}" },
    "labels": ["deployment", "automated"],
    "description": { "type": "doc", "version": 1, "content": [...] }
  }
}
// Output: jira_ticket_key (e.g. DEPLOY-142) passed to Agent 1 Slack message and Agent 3
Slack

Used by all three agents. Agent 1 sends an interactive Block Kit approval message. Agent 2 listens for the button callback on the interactivity request URL. Agent 3 posts the deployment result to the team channel. A single Slack App with a Bot Token serves all three agents.

Auth method
OAuth 2.0. Bot Token (xoxb-) stored in credential store as SLACK_BOT_TOKEN. The Slack App must be installed to the workspace with bot scopes granted.
Required scopes
chat:write, chat:write.public, channels:read, im:write, users:read, users:read.email, incoming-webhook (optional fallback)
Interactive components
Enable Interactivity in the Slack App settings. Set the Request URL to the orchestration layer endpoint that handles button callbacks (e.g. https://automation.yourcompany.com/hooks/slack/interactive). Slack signs each callback with HMAC-SHA256 using the Signing Secret. Validate X-Slack-Signature and X-Slack-Request-Timestamp on every inbound callback before processing.
Block Kit approval message
POST https://slack.com/api/chat.postMessage — channel: IT lead user ID (stored as SLACK_IT_LEAD_USER_ID), blocks: Block Kit JSON containing PR details, Jira ticket link, approve button (value: approve::{jira_ticket_key}::{deploy_run_id}), reject button (value: reject::{jira_ticket_key}::{deploy_run_id}).
Result post
POST https://slack.com/api/chat.postMessage — channel: SLACK_DEPLOY_CHANNEL_ID. Message contains deploy status (success/failure), environment, timestamp, Jira ticket link, and Datadog dashboard link.
Rate limits
Tier 3 methods (chat.postMessage): 1 request/second per channel. At 12 deployments/month, burst risk is zero. No throttling logic needed at current volume.
Constraints
Block Kit interactive messages expire after 30 minutes by default. If no approval or rejection is received within 29 minutes, the orchestration layer must send a reminder and log the timeout. Button action payloads must be URL-decoded before JSON parsing.
// Inbound interactive callback payload (key fields)
{
  "type": "block_actions",
  "user": { "id": "U012AB3CD", "name": "marcus.reid" },
  "actions": [{
    "action_id": "deploy_approve",
    "value": "approve::DEPLOY-142::run-789"
  }],
  "message": { "ts": "1718000000.000100" }
}
// Output parsed by Agent 2
{ decision: "approve", jira_ticket_key: "DEPLOY-142", deploy_run_id: "run-789", approved_by: "marcus.reid", approved_at: <timestamp> }
Confluence

Used by Agent 2 only. The Environment and Deploy Agent reads a structured config table from a known Confluence page to obtain environment variables for the target deployment environment. The page ID must be stored in the credential store. If config is not in a single structured table, a mapping exercise is required before build.

Auth method
HTTP Basic Auth using Atlassian API token. Same token as Jira if the same Atlassian account has Confluence access. Header: Authorization: Basic <base64(email:token)>.
Required scopes
Atlassian API tokens are not scope-limited by OAuth grant. The account must have Read permission on the target Confluence space and View permission on the specific config page.
Config page read
GET https://{org}.atlassian.net/wiki/rest/api/content/{pageId}?expand=body.storage — parse the storage format HTML to extract the environment variable table. The table must follow the fixed structure: Column 1: variable_name, Column 2: production_value, Column 3: staging_value. Page ID stored as CONFLUENCE_CONFIG_PAGE_ID.
Required configuration
CONFLUENCE_BASE_URL, CONFLUENCE_CONFIG_PAGE_ID — both stored in credential store. The target environment label (production or staging) is passed from Agent 2 context to determine which column to read.
Rate limits
Confluence Cloud REST API: no published hard rate limit. Fair-use throttling at approximately 100 requests/10 seconds. One read per deployment event. No throttling needed.
Constraints
The config page must not be nested inside a restricted space that the API token cannot access. If the page is updated between the read and the deployment trigger, the automation uses the values read at the time of the API call. A page version number is logged with each deployment for audit purposes.
// API response (storage format excerpt)
<table><tr><th>variable_name</th><th>production_value</th><th>staging_value</th></tr>
<tr><td>DB_HOST</td><td>prod-db.internal</td><td>staging-db.internal</td></tr>
<tr><td>API_BASE_URL</td><td>https://api.yourcompany.com</td><td>https://api-staging.yourcompany.com</td></tr>
...
// Output to Agent 2 context (after parsing for target environment)
{ env_vars: { DB_HOST: "prod-db.internal", API_BASE_URL: "https://api.yourcompany.com", ... }, page_version: 47 }
Integration and API SpecPage 2 of 4
FS-DOC-05Technical
Datadog

Used by Agent 3 (Post-Deploy Monitor Agent). The agent polls Datadog monitor states on a 5-minute interval after deployment completion. Monitor IDs and threshold definitions must be agreed with the team and stored in the credential store before build.

Auth method
API key + Application key pair. Header: DD-API-KEY: <api_key> and DD-APPLICATION-KEY: <app_key>. Both stored in credential store as DATADOG_API_KEY and DATADOG_APP_KEY.
Required scopes
Application key must belong to a Datadog user with at minimum the Read Monitors permission. No write access required for the polling use case. If the team wants Agent 3 to mute monitors during deployment, the Manage Monitors permission is also required.
Monitor poll endpoint
GET https://api.datadoghq.com/api/v1/monitor/{monitor_id} — evaluate overall_state field. States: OK, Warn, Alert, No Data. Alert state triggers PagerDuty incident. Monitor IDs stored as DATADOG_MONITOR_IDS (comma-delimited list).
Poll schedule
Agent 3 polls at T+0, T+5, and T+10 minutes post-deployment. If all monitors return OK at any poll, the deployment is marked healthy and the Jira ticket is closed. If Alert persists at T+10, PagerDuty is fired regardless of subsequent recovery.
Rate limits
Datadog API: 300 requests/hour for the monitor endpoint on Pro plan. Three polls per deployment across a maximum of 5 monitor IDs equals 15 requests per deployment. At 12 deployments/month, total monthly usage is 180 requests. No throttling needed.
Constraints
Monitor IDs must be confirmed with the IT ops team before build. Generic names like api_error_rate_monitor must be resolved to numeric IDs via GET /api/v1/monitor?name={name}. The Datadog site region (US1, EU1, US3, etc.) affects the base URL and must match the account region stored as DATADOG_SITE.
// Monitor state poll response (key fields)
{
  "id": 12345678,
  "name": "API Error Rate Post-Deploy",
  "overall_state": "OK",
  "query": "avg(last_5m):sum:trace.web.request.errors{env:production} / sum:trace.web.request.hits{env:production} > 0.05"
}
// Agent 3 decision logic
if overall_state == "Alert" -> trigger PagerDuty, flag Jira ticket
if overall_state == "OK" at any poll -> mark deployment healthy, close Jira
PagerDuty

Used by Agent 3 only. A PagerDuty incident is fired via the Events API v2 when Datadog health checks breach threshold. The integration key (routing key) is service-specific and must match the deployment monitoring service configured in PagerDuty.

Auth method
Events API v2 uses an integration routing key (32-character string), not an OAuth token. Stored in credential store as PAGERDUTY_ROUTING_KEY. No user credentials required.
Required scopes
Events API v2 does not use OAuth scopes. The routing key is tied to a specific PagerDuty service. The service must have at least one escalation policy configured before testing.
Event trigger endpoint
POST https://events.pagerduty.com/v2/enqueue — Content-Type: application/json. Body: routing_key, event_action: trigger, payload: {summary, severity: critical, source: deployment-automation, component: deploy-pipeline, custom_details: {jira_ticket, environment, commit_sha, datadog_monitor_id}}.
Required configuration
PAGERDUTY_ROUTING_KEY, PAGERDUTY_SERVICE_ID (for deduplication key construction). Dedup key format: deploy-{jira_ticket_key}-{deploy_run_id} to prevent duplicate incidents for the same deployment event.
Rate limits
PagerDuty Events API v2: no published rate limit for inbound events on Professional plan. At 12 deployments/month with a minority triggering health check breaches, volume is minimal. No throttling needed.
Constraints
If the PagerDuty service is in maintenance mode, the event is accepted (HTTP 202) but may not page anyone. The orchestration layer must not assume a 202 response means an on-call engineer has been notified. Log all PagerDuty event responses for audit. Auto-resolve is not implemented in this build; the on-call engineer resolves the incident manually after reviewing Datadog.
// Events API v2 trigger payload
{
  "routing_key": "{{PAGERDUTY_ROUTING_KEY}}",
  "event_action": "trigger",
  "dedup_key": "deploy-DEPLOY-142-run-789",
  "payload": {
    "summary": "Post-deploy health check ALERT: API Error Rate exceeded threshold (env: production)",
    "severity": "critical",
    "source": "deployment-automation",
    "component": "deploy-pipeline",
    "custom_details": {
      "jira_ticket": "DEPLOY-142",
      "environment": "production",
      "commit_sha": "a1b2c3d",
      "datadog_monitor_id": "12345678"
    }
  }
}

03Field mappings between tools

The following tables define the exact field mappings for each agent handoff. Use these as the definitive reference when building data transformation nodes in the orchestration layer. Field names in monospace represent the exact key paths used in API payloads or extracted context variables.

Agent 1 handoff: GitHub webhook to Jira ticket creation

Source tool
Source field
Destination tool
Destination field
GitHub
pull_request.merge_commit_sha
Jira
fields.customfield_deploy_commit_sha
GitHub
pull_request.number
Jira
fields.customfield_pr_number
GitHub
pull_request.user.login
Jira
fields.customfield_deploy_author
GitHub
pull_request.base.ref
Jira
fields.customfield_target_environment
GitHub
repository.full_name
Jira
fields.customfield_repo_name
GitHub
pull_request.html_url
Jira
fields.description (ADF link node)
Computed
ISO8601 timestamp at trigger
Jira
fields.customfield_deploy_requested_at
Config store
JIRA_PROJECT_KEY
Jira
fields.project.key
Config store
JIRA_ISSUE_TYPE_ID
Jira
fields.issuetype.id

Agent 1 handoff: Jira ticket key and PR details to Slack approval message

Source tool
Source field
Destination tool
Destination field
Jira
key (e.g. DEPLOY-142)
Slack
blocks[].text.text (ticket reference)
Jira
self (issue URL)
Slack
blocks[].accessory.url (Jira link button)
GitHub
pull_request.merge_commit_sha
Slack
blocks[].text.text (commit SHA display)
GitHub
pull_request.user.login
Slack
blocks[].text.text (requested by field)
GitHub
pull_request.base.ref
Slack
blocks[].text.text (target environment display)
Computed
ISO8601 timestamp at trigger
Slack
blocks[].text.text (requested at display)
Config store
SLACK_IT_LEAD_USER_ID
Slack
channel (DM recipient)
Computed
approve::{jira_key}::{deploy_run_id}
Slack
blocks[].elements[].value (approve button)
Computed
reject::{jira_key}::{deploy_run_id}
Slack
blocks[].elements[].value (reject button)

Agent 2 handoff: Confluence config page to GitHub Actions workflow dispatch

Source tool
Source field
Destination tool
Destination field
Confluence
table.row[n].variable_name / production_value or staging_value
GitHub Actions
inputs.env_vars (JSON stringified key-value map)
Confluence
page version number
GitHub Actions
inputs.config_version (logged for audit)
Slack callback
actions[0].value -> jira_ticket_key
GitHub Actions
inputs.jira_ticket_id
Slack callback
actions[0].value -> deploy_run_id
GitHub Actions
inputs.deploy_run_id
Slack callback
user.name (approver)
GitHub Actions
inputs.approved_by
Config store
GITHUB_DEPLOY_WORKFLOW_ID
GitHub Actions
workflow_id (URL parameter)

Agent 3 handoff: Datadog poll result to Jira status update and Slack result post

Source tool
Source field
Destination tool
Destination field
Datadog
overall_state (OK / Alert)
Jira
transition.id -> JIRA_TRANSITION_DONE_ID or JIRA_TRANSITION_FAILED_ID
Datadog
overall_state
Jira
fields.comment (ADF: health check outcome + timestamp)
Datadog
name (monitor display name)
Slack
blocks[].text.text (health check summary)
Datadog
overall_state
Slack
blocks[].text.text (status: healthy / alert)
GitHub Actions
run.html_url (pipeline run URL)
Slack
blocks[].accessory.url (pipeline link)
Jira context
key (DEPLOY-142)
Slack
blocks[].text.text (ticket reference in result post)
Computed
ISO8601 timestamp at poll completion
Jira
fields.customfield_deploy_completed_at
Computed
ISO8601 timestamp at poll completion
Slack
blocks[].text.text (completed at display)
Integration and API SpecPage 3 of 4
FS-DOC-05Technical

04Build stack and orchestration

Orchestration layout
One workflow per agent: Deployment Gate Agent Workflow, Environment and Deploy Agent Workflow, Post-Deploy Monitor Agent Workflow. All three share a single credential store. Inter-agent data is passed via a shared context object written and read from the orchestration layer's internal state store, keyed by deploy_run_id.
Agent 1 trigger mechanism
Webhook (push). The orchestration layer exposes a public HTTPS inbound endpoint registered as a GitHub repository webhook. Payload validated via HMAC-SHA256 signature check against GITHUB_WEBHOOK_SECRET before any workflow execution begins.
Agent 2 trigger mechanism
Webhook (interactive callback). The Slack App posts the IT lead's button click to the orchestration layer interactivity URL. Payload validated via Slack signing secret (HMAC-SHA256 of X-Slack-Signature against the raw request body + X-Slack-Request-Timestamp). Timestamp staleness check: reject callbacks older than 5 minutes.
Agent 3 trigger mechanism
Poll (scheduled). Agent 3 is triggered by Agent 2 upon successful GitHub Actions workflow dispatch. The orchestration layer schedules a poll at T+0, T+5, and T+10 minutes. No external webhook from GitHub Actions; poll interval is internal to the orchestration layer.
Shared credential store
All secrets are stored in the orchestration layer's encrypted credential store. No secret is written into a workflow node configuration field, environment file, or source control repository. Secret reference syntax varies by platform; use the platform's native secret interpolation.
Context state store
Each deployment event is assigned a unique deploy_run_id (UUID v4) at Agent 1 trigger time. All three agents read and write to a shared state record keyed by deploy_run_id: {commit_sha, pr_number, jira_ticket_key, environment, approved_by, approved_at, config_version, pipeline_run_url, health_check_results, deploy_status}.
Approval timeout handling
If Agent 2 does not receive a Slack callback within 29 minutes of the approval message being sent, Agent 1 posts a reminder DM to SLACK_IT_LEAD_USER_ID and logs a timeout_warning event. If no response arrives within 59 minutes, the deploy_run_id is marked expired and a timeout_expired event is logged. No automatic deployment occurs on timeout.
Logging
All inbound webhooks, API calls (request + response status), state transitions, and error events are written to the orchestration layer's execution log with ISO8601 timestamps and deploy_run_id as the correlation key. Logs must be retained for a minimum of 90 days.
Credential store reference — all names are case-sensitive. Store values using the platform's native secret management. Never log secret values.
// Credential store contents (reference names only — values are never stored in this document)

// GitHub
GITHUB_WEBHOOK_SECRET          // HMAC-SHA256 secret for inbound webhook validation
GITHUB_APP_PRIVATE_KEY         // PEM-encoded private key for GitHub App JWT signing
GITHUB_APP_ID                  // GitHub App numeric ID
GITHUB_APP_INSTALLATION_ID     // Installation ID for the target repository
GITHUB_DEPLOY_WORKFLOW_ID      // Numeric or filename ID of the deployment workflow
GITHUB_REPO_FULL_NAME          // e.g. yourcompany/app
GITHUB_TARGET_BRANCH           // e.g. main

// Jira
JIRA_BASE_URL                  // e.g. https://yourcompany.atlassian.net
JIRA_EMAIL                     // Atlassian account email for Basic Auth
JIRA_API_TOKEN                 // API token from id.atlassian.net
JIRA_PROJECT_KEY               // e.g. DEPLOY
JIRA_ISSUE_TYPE_ID             // Numeric ID for deployment ticket issue type
JIRA_TRANSITION_DONE_ID        // Numeric transition ID for Done/Deployed status
JIRA_TRANSITION_FAILED_ID      // Numeric transition ID for Failed status

// Slack
SLACK_BOT_TOKEN                // xoxb- token for the Slack App
SLACK_SIGNING_SECRET           // Used to validate interactive callback signatures
SLACK_IT_LEAD_USER_ID          // Slack user ID for the IT lead (e.g. U012AB3CD)
SLACK_DEPLOY_CHANNEL_ID        // Channel ID for deployment result posts

// Confluence
CONFLUENCE_BASE_URL            // e.g. https://yourcompany.atlassian.net/wiki
CONFLUENCE_EMAIL               // Same Atlassian account email as Jira (if shared)
CONFLUENCE_API_TOKEN           // API token (can be same as JIRA_API_TOKEN if same account)
CONFLUENCE_CONFIG_PAGE_ID      // Numeric page ID of the environment config page

// Datadog
DATADOG_API_KEY                // 32-character API key
DATADOG_APP_KEY                // Application key for monitor read access
DATADOG_SITE                   // e.g. datadoghq.com (US1) or datadoghq.eu (EU1)
DATADOG_MONITOR_IDS            // Comma-delimited list of monitor IDs to poll

// PagerDuty
PAGERDUTY_ROUTING_KEY          // 32-character Events API v2 integration routing key
PAGERDUTY_SERVICE_ID           // PagerDuty service ID for dedup key construction

// Orchestration
DEPLOY_STATE_STORE_TTL_HOURS   // How long deploy_run_id state records are retained (default: 48)

05Error handling and retry logic

Unhandled exceptions must never fail silently. Every integration point has a defined failure behaviour. If a scenario is not covered by the table below and the workflow reaches an unexpected state, the orchestration layer must log the full exception with the deploy_run_id, post an alert to SLACK_DEPLOY_CHANNEL_ID, and halt the current workflow execution. Do not allow partial or silent progression.
Integration
Scenario
Required behaviour
GitHub webhook inbound
X-Hub-Signature-256 validation fails
Reject with HTTP 401. Log the invalid request with source IP and timestamp. Do not execute any workflow step. No retry.
GitHub API: CI check query
GitHub API returns 5xx or times out
Retry up to 3 times with exponential backoff: 10s, 30s, 90s. If all retries fail, post alert to SLACK_DEPLOY_CHANNEL_ID with deploy_run_id and mark the run as stalled. Do not proceed to Jira ticket creation.
GitHub API: CI check query
One or more CI checks return conclusion: failure
Branch to failure path. Post Slack DM to PR author (use pull_request.user.login resolved via SLACK_BOT_TOKEN users.lookupByEmail) with failing check names. Do not create Jira ticket. Mark deploy_run_id as ci_failed and stop.
Jira API: ticket creation
POST returns 4xx (e.g. invalid ADF, missing field)
Log full response body. Post alert to SLACK_DEPLOY_CHANNEL_ID. Do not proceed to Slack approval message. Retry once after 15 seconds for transient 429 (rate limit). For 400 or 422, escalate immediately without retry.
Slack API: approval message send
chat.postMessage returns error (e.g. channel_not_found, not_in_channel)
Log error. Retry once after 10 seconds. If second attempt fails, post to SLACK_DEPLOY_CHANNEL_ID as fallback with the Jira ticket link and a note that direct DM failed. Mark deploy_run_id as approval_notify_failed.
Slack interactive callback
Callback arrives with stale timestamp (older than 5 minutes)
Reject with HTTP 400. Do not process the action. Log the stale callback. The existing approval message remains active.
Slack interactive callback
No callback received within 29 minutes of approval message send
Post reminder DM to SLACK_IT_LEAD_USER_ID. Log timeout_warning. If still no callback at 59 minutes, mark deploy_run_id as expired, post to SLACK_DEPLOY_CHANNEL_ID, and stop the workflow.
Confluence API: config page read
GET returns 404 (page not found or access denied)
Do not proceed to GitHub Actions trigger. Log the error with CONFLUENCE_CONFIG_PAGE_ID. Post alert to SLACK_DEPLOY_CHANNEL_ID stating config read failed. Manual fallback: IT Ops applies config and triggers deployment manually. Mark deploy_run_id as config_read_failed.
GitHub Actions: workflow dispatch
POST returns 4xx or 5xx
Retry up to 2 times with 30-second backoff. If all retries fail, post alert to SLACK_DEPLOY_CHANNEL_ID and SLACK_IT_LEAD_USER_ID. Mark deploy_run_id as dispatch_failed. Manual fallback: Developer triggers the workflow from the GitHub Actions UI.
Datadog API: monitor poll
GET returns 401 (invalid API or app key)
Halt polling immediately. Post critical alert to SLACK_DEPLOY_CHANNEL_ID and SLACK_IT_LEAD_USER_ID: health checks cannot be verified. Fire PagerDuty incident with severity: critical and summary indicating Datadog auth failure, not a deployment metric breach. Mark deploy_run_id as monitor_auth_failed.
Datadog API: monitor poll
overall_state returns No Data for all three poll intervals
Treat No Data as inconclusive, not healthy. Post alert to SLACK_DEPLOY_CHANNEL_ID stating health check data unavailable. Fire PagerDuty incident with severity: warning. Do not close the Jira ticket as Done; transition to a manual review status using JIRA_TRANSITION_FAILED_ID. Log as monitor_no_data.
PagerDuty Events API: incident trigger
POST returns non-202 or network timeout
Retry up to 3 times with exponential backoff: 15s, 45s, 135s. If all retries fail, post critical alert directly to SLACK_DEPLOY_CHANNEL_ID and SLACK_IT_LEAD_USER_ID with the Datadog monitor state and deploy_run_id. Log as pagerduty_dispatch_failed. Do not allow health check breach to go unreported.
Jira API: status transition (Agent 3)
Transition ID not found or transition not valid for current status
Log the Jira error response. Post warning to SLACK_DEPLOY_CHANNEL_ID with the Jira ticket key and a note that status update failed. Do not retry automatically. Flag for manual resolution by the developer. Mark deploy_run_id as jira_close_failed.
Integration and API SpecPage 4 of 4

More documents for this process

Every document generated for Software Deployment Workflow.

Launch Plan
Operations · Owner
View
ROI and Business Case
Finance · Owner
View
Process Runbook / SOP
Operations · Owner
View
Developer Handover Pack
Technical · Developer
View
Test and QA Plan
Quality · Developer
View