Facebook Insights Module (Mapping)

:bullseye: What is your goal?

I’m looking to extract the data within the Arrays, but only the omni_purchase action type and it’s value.

:thinking: What is the problem & what have you tried?

I have tried for hours, using GET / MAP, aggregators.etc and I can’t get it extracted and it’s driving me crazy.

:clipboard: Error messages or input/output bundles

It’s just returning blank.

This is the output bundle;

[
  {
    "action_values": [
      {
        "action_type": "onsite_web_app_purchase",
        "value": "90455.11"
      },
      {
        "action_type": "onsite_web_app_add_to_cart",
        "value": "280406.93"
      },
      {
        "action_type": "onsite_web_initiate_checkout",
        "value": "46306.05"
      },
      {
        "action_type": "add_payment_info",
        "value": "68124.88"
      },
      {
        "action_type": "omni_initiated_checkout",
        "value": "46306.05"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_view_content",
        "value": "3713007.4"
      },
      {
        "action_type": "web_app_in_store_purchase",
        "value": "9.05"
      },
      {
        "action_type": "omni_view_content",
        "value": "3713007.4"
      },
      {
        "action_type": "add_to_cart",
        "value": "280406.93"
      },
      {
        "action_type": "onsite_web_purchase",
        "value": "90455.11"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_add_to_cart",
        "value": "280406.93"
      },
      {
        "action_type": "purchase",
        "value": "90455.11"
      },
      {
        "action_type": "view_content",
        "value": "3713007.4"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_initiate_checkout",
        "value": "46306.05"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_add_payment_info",
        "value": "68124.88"
      },
      {
        "action_type": "onsite_web_view_content",
        "value": "3713007.4"
      },
      {
        "action_type": "onsite_web_app_view_content",
        "value": "3713007.4"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_purchase",
        "value": "90455.11"
      },
      {
        "action_type": "initiate_checkout",
        "value": "46306.05"
      },
      {
        "action_type": "omni_add_to_cart",
        "value": "280406.93"
      },
      {
        "action_type": "omni_purchase",
        "value": "90455.11"
      },
      {
        "action_type": "web_in_store_purchase",
        "value": "90455.11"
      },
      {
        "action_type": "onsite_web_add_to_cart",
        "value": "280406.93"
      }
    ],
    "actions": [
      {
        "action_type": "onsite_conversion.add_to_wishlist",
        "value": "10"
      },
      {
        "action_type": "web_in_store_purchase",
        "value": "517"
      },
      {
        "action_type": "omni_search",
        "value": "534"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_search",
        "value": "534"
      },
      {
        "action_type": "omni_purchase",
        "value": "517"
      },
      {
        "action_type": "link_click",
        "value": "11748"
      },
      {
        "action_type": "omni_add_to_wishlist",
        "value": "10"
      },
      {
        "action_type": "omni_add_to_cart",
        "value": "2467"
      },
      {
        "action_type": "omni_initiated_checkout",
        "value": "962"
      },
      {
        "action_type": "page_engagement",
        "value": "82615"
      },
      {
        "action_type": "purchase",
        "value": "517"
      },
      {
        "action_type": "landing_page_view",
        "value": "7872"
      },
      {
        "action_type": "add_to_cart",
        "value": "2467"
      },
      {
        "action_type": "onsite_conversion.view_content",
        "value": "427"
      },
      {
        "action_type": "omni_landing_page_view",
        "value": "7872"
      },
      {
        "action_type": "onsite_app_view_content",
        "value": "427"
      },
      {
        "action_type": "onsite_web_app_add_to_cart",
        "value": "2467"
      },
      {
        "action_type": "onsite_web_view_content",
        "value": "29603"
      },
      {
        "action_type": "onsite_web_add_to_cart",
        "value": "2467"
      },
      {
        "action_type": "onsite_conversion.post_unlike",
        "value": "70"
      },
      {
        "action_type": "post_engagement",
        "value": "82609"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_add_payment_info",
        "value": "361"
      },
      {
        "action_type": "comment",
        "value": "6"
      },
      {
        "action_type": "onsite_web_app_purchase",
        "value": "517"
      },
      {
        "action_type": "like",
        "value": "6"
      },
      {
        "action_type": "post_interaction_gross",
        "value": "1061"
      },
      {
        "action_type": "view_content",
        "value": "29176"
      },
      {
        "action_type": "web_app_in_store_purchase",
        "value": "517"
      },
      {
        "action_type": "offsite_search_add_meta_leads",
        "value": "534"
      },
      {
        "action_type": "onsite_conversion.post_unsave",
        "value": "10"
      },
      {
        "action_type": "onsite_conversion.post_save",
        "value": "137"
      },
      {
        "action_type": "onsite_conversion.post_net_like",
        "value": "848"
      },
      {
        "action_type": "onsite_web_initiate_checkout",
        "value": "962"
      },
      {
        "action_type": "onsite_conversion.post_net_save",
        "value": "127"
      },
      {
        "action_type": "onsite_web_app_view_content",
        "value": "29603"
      },
      {
        "action_type": "offsite_content_view_add_meta_leads",
        "value": "29176"
      },
      {
        "action_type": "onsite_web_purchase",
        "value": "517"
      },
      {
        "action_type": "add_payment_info",
        "value": "361"
      },
      {
        "action_type": "search",
        "value": "534"
      },
      {
        "action_type": "video_view",
        "value": "69800"
      },
      {
        "action_type": "omni_view_content",
        "value": "29603"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_view_content",
        "value": "29176"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_add_to_cart",
        "value": "2467"
      },
      {
        "action_type": "post_reaction",
        "value": "918"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_initiate_checkout",
        "value": "962"
      },
      {
        "action_type": "offsite_conversion.fb_pixel_purchase",
        "value": "517"
      },
      {
        "action_type": "initiate_checkout",
        "value": "962"
      }
    ],
    "spend": "6946.37",
    "date_start": "2025-11-01T00:00:00.000Z",
    "date_stop": "2025-11-30T00:00:00.000Z",
    "account_id": "100406093450210",
    "__IMTLENGTH__": 1,
    "__IMTINDEX__": 1
  }
]

:camera_with_flash: Screenshots (scenario flow, module settings, errors)

1 Like

Hey Dean,

your ifempty() is wrong. Looks like it has one too many closing brackets and this is breaking the rest of the formula.

{{first(map(1.actions; "value"; "action_type"; "omni_purchase"))}}
2 Likes

SOLVED! Thank you so much, can’t tell you how much that’s been bugging me.