spad.site-deletion-init ​
Initialize site deletion - load site data and mark as deleting
Init step for site deletion DAG.
Loads site data from DB, sets status to "deleting", and returns all resource IDs needed by downstream steps.
Overview ​
| Property | Value |
|---|---|
| Workflow type | Linear |
| Library | App-spad |
| Version | 1.0 |
Input Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
site_uuid | string | Yes | — | UUID of the SPAD site to delete |
organization_uuid | string | No | — | Organization UUID |
delete_resources | boolean | No | True | Whether to delete cloud resources |
workflow_run_id | string | No | — | — |
workflow_run_uuid | string | No | — | Parent workflow run ID stamped by the DAG engine (legacy alias) |
Output Schema ​
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
site_uuid | string | Yes | — | UUID of the site marked as deleting |
organization_uuid | string | Yes | — | UUID of the organization that owns the site |
cloud_connection_uuid | string | Yes | — | CloudConnection UUID used to reach the site's resources |
cloudfront_distribution_ref | string | No | — | CloudFront distribution id to disable/delete (None when unset) |
cloudfront_oac_ref | string | No | — | CloudFront OAC id to delete (None when unset) |
s3_bucket_name | string | No | — | S3 bucket name to empty/delete (None when unset) |
delete_resources | boolean | Yes | — | Whether downstream steps should delete cloud resources |
cloud_provider | string | Yes | — | Provider identifier derived from the site's CloudConnection (e.g. 'aws', 'gcp') |
initiated_at | string | Yes | — | ISO8601 timestamp when deletion was initiated |
gcp_cdn_forwarding_rule_name | string | No | — | GCP HTTP forwarding-rule name (gcp_cdn resource, None for non-GCP) |
gcp_cdn_target_proxy_name | string | No | — | GCP HTTP target-proxy name (gcp_cdn resource, None for non-GCP) |
gcp_cdn_url_map_name | string | No | — | GCP URL-map name (gcp_cdn resource, None for non-GCP) |
gcp_cdn_backend_bucket_name | string | No | — | GCP backend-bucket name (gcp_cdn resource, None for non-GCP) |
gcp_https_proxy_name | string | No | — | GCP HTTPS target-proxy name (gcp_https_proxy resource, None when absent) |
gcp_https_forwarding_rule_name | string | No | — | GCP HTTPS forwarding-rule name (gcp_https_forwarding_rule resource, None when absent) |
gcp_managed_cert_name | string | No | — | GCP managed-cert name (gcp_managed_cert resource, None when absent) |
failure_reason | string | No | — | Reason recorded on the failure path |
workflow_run_id | string | No | — | — |
workflow_run_uuid | string | No | — | Parent workflow run ID stamped by the DAG engine (legacy alias) |
error | string | No | — | Engine-stamped failure metadata |
error_type | string | No | — | Engine-stamped failure metadata |
failed_at_state | json | No | — | Engine-stamped failure metadata |
failed_layer | json | No | — | Engine-stamped failure metadata |
failed_step | json | No | — | Engine-stamped failure metadata |
States ​
| State | Initial | Terminal | Success | Auto-advance | Description |
|---|---|---|---|---|---|
pending | Yes | No | — | run | Deletion init accepted |
run | No | No | — | complete | Loading site and preparing deletion context |
completed | No | Yes | Yes | — | Deletion init completed |
failed | No | Yes | No | — | Deletion init failed |
State Diagram ​
Transitions ​
| From | Action | To | Description |
|---|---|---|---|
pending | run | run | Start deletion init |
run | complete | completed | Mark init completed |
* (any state) | fail | failed | Mark init failed |
API Usage ​
bash
POST /api/workflows/start
Content-Type: application/json
{
"workflow_type": "spad.site-deletion-init",
"initial_data": {
"site_uuid": "value"
}
}