title Account Update participant "" as f participant "\nOrganization Manager" as om participant "\nS3" as s3 participant "\naws-control-tower-\ncustomizations" as ctc participant "\nStep Functions" as sf participant "\nCloudFormation" as cf participant "\nEventBridge" as eb note over f, om 1) Update the account on Facade API (an async process) end note f -> om: "PATCH /organizatonalUnits//accounts/" activate om alt Account Update Successful om -> om : Update regions for the account &\nUpdate Account Status to PENDING om -> s3 : Update Manifest file activate s3 activate ctc om --> f : <202> Accepted s3 -> ctc : Trigger Control Tower Customization CodePipeline deactivate s3 ctc -> sf : Trigger StackSets Deployment\n StateMachine deactivate ctc activate sf sf -> cf : Deploy CDF Stacks activate cf note over sf, cf 2) Deploying CDF Services as CloudFormation StackSets to ACTIVE accounts end note alt CDF Deployment Successful cf -> sf : StackSets Deployment Successful sf -> eb : \nState Machine Execution\nstatus: success activate eb eb -> om : Invoke deactivate eb om -> om : Update Account Status to PROVISIONED else CDF Deployment Failed cf -> sf: StackSets Deployment Failed deactivate cf sf -> eb : \nState Machine Execution\nstatus: failed activate eb deactivate sf eb -> om : Invoke deactivate eb om -> om : Update Account Status to FAILED end else Account Is Not In Provisioned State om --> f : <409> Conflict else Account Does Not Exist om --> f : <404> Not Found end else Bad Request om --> f : <400> Bad Request end deactivate om