Disapproved ads
27 mins to complete
In this tutorial, you will learn how to send Slack notifications to one of your channels if ads get disapproved.
Facebook uses JSON to work with data. If you are not familiar with JSON, refer to the tutorial.
Video Tutorial
Instructions
- Add Fetch Facebook Ads Node.
- Add Fetch Facebook Ad Ids. In the
effective_status
socket, select “disapproved”. Connectad_ids
sockets.
- Add Select Facebook Ad Account Ids. Select a Facebook account. Connect
ad_account_ids
sockets.
- Add Slack Notifier Node.
- Add Select Slack Conversation Node. Select a channel in which you would want the message to be sent. Connect
conversation_id
sockets. If you want your message to go into the thread under another message, inputthread_ts
socket.
- Add For Each node. We will send 1 Slack message for one disapproved ad. Connect
ads
toitems
- Add Patch JSON node. Connect
item
tovalue
- Copy or create blocks JSON into the
data
socket of the Patch JSON node. Then, refer to Slack block builder to find the correct format.
- Select “replace” operation inside of the patch node. Add a path. In our example it’s
/0/text/text
. The path consists of the index of an object in the list and the path to the element you wanna change.“
- In the value field, write down your message. You can insert the dynamic parameters by using
{{inputValue("/path_to_value")}}
. In our example it’s{{inputValue("/effective_status")}}
and{{inputValue("/id")}}
[Note that this is slightly different to the video. The Patch JSON nodes now support Tiny Kitchn Language (TiKiLa), which you can learn about here.]
- Connect
data
(Patch JSON) toblocks
(Slack Notifier).
- Add Extract node. Connect
item
(For Each) withdata
(Extract). In thepointer
socket, add/id
path.
- Connect
data
(Extract) toitem
(Append). Select Any schema.
- Add Extract list node. Connect
ad_ids
(Fetch Facebook Ad ids) todata_list
(Extract List). Add/id
pointer.
- Add Calculate Set operation node. Connect
data_list
(Extract list) to a, andlist
(Append) to b. Choose difference operator.
- Add Parse strings to ids node. Connect
data
(Calculate Set Operation) tovalues
. Select Facebookad_id
schema. Connect result toad_ids
(Fetch Facebook Ad ids).
- Add Delay or Delay to Node.
Did this answer your question?
😞
😐
🤩
Last updated on August 4, 2021