---
# System prepended metadata

title: Flow blast message lp down

---

```plantuml

participant "api" as ap
participant "n8n" as n8
participant "api user" as us
participant "redis" as re
participant "evercrm" as ev
participant "slack" as sl

n8 -> ap: hit landing page & hit page builder
note right
n8n as a cron will hit per 1 min
end note

alt response code 500+
ap -> n8: return http code 500+
n8 -> re: get data to redis

alt return error mode is false
n8 <- re: return error mode is false

n8 -> re: get retry count
alt if not max retry
n8 -> sl: send error notif
n8 -> re: set max retry +1
n8 <-- re: return 
note right: max retry is 3

else reach max retry
n8 -> re: \ndelete retry state, udpate error mode to true
n8 -> us: get user data
n8 <- us: return user data\n(phone number)
n8 -> ev: get available device

loop send requset per batch
n8 -> n8: \nbuild request,\nbatch per 20 phone number
n8 -> ev: send request blast message; server is down
end
end

else return error mode is true
n8 <- re: return error mode is true
n8 -> n8: igonre
end

else response code 200
ap -> n8: return http code 200
n8 -> re: get data to redis

alt return error mode is false
n8 <- re: \nerror mode is false
n8 -> n8: ignore

else return error mode is true
n8 <- re: \nerror mode is true
n8 -> sl: send notif server back to normal
n8 -> re: udpate error mode to false
n8 -> us: \n\nget user data
n8 <- us: return user data\n(phone number)
n8 -> ev: get available device

loop send requset per batch
n8 -> n8: \nbuild request,\nbatch per 20 phone number
n8 -> ev: send request blast message; server is normal
end
end
end