Please paste this code into a scenario and you should get two modules.
Shows different ways to play with map() and get() functions depending on your needs.
Code
{
“subflows”: [
{
“flow”: [
{
“id”: 1,
“module”: “json:ParseJSON”,
“version”: 1,
“parameters”: {
“type”: “”
},
“mapper”: {
“json”: “[\n\t{\n\t\t"gid": "1208132855637098",\n\t\t"assignee": null,\n\t\t"assignee_status": "upcoming",\n\t\t"completed": false,\n\t\t"completed_at": null,\n\t\t"created_at": "2024-08-23T08:53:42.849Z",\n\t\t"custom_fields": [\n\t\t\t{\n\t\t\t\t"gid": "1208132855637112",\n\t\t\t\t"enabled": true,\n\t\t\t\t"name": "Post Copy",\n\t\t\t\t"description": "",\n\t\t\t\t"created_by": {\n\t\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t\t"name": "",\n\t\t\t\t\t"resource_type": "user"\n\t\t\t\t},\n\t\t\t\t"display_value": "i is launching a new Cup. Eco-friendly paper cups. Plastic-free, PLA-free. For hot/cold drinks. Ideal for cafés, restaurants.",\n\t\t\t\t"resource_subtype": "text",\n\t\t\t\t"resource_type": "custom_field",\n\t\t\t\t"text_value": "is launching a new Cup. Eco-friendly paper cups. Plastic-free, PLA-free. For hot/cold drinks. Ideal for cafés, restaurants.",\n\t\t\t\t"type": "text"\n\t\t\t},\n\t\t\t{\n\t\t\t\t"gid": "1208132855637116",\n\t\t\t\t"enabled": true,\n\t\t\t\t"name": "Image URL",\n\t\t\t\t"description": "",\n\t\t\t\t"created_by": {\n\t\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t\t"name": "",\n\t\t\t\t\t"resource_type": "user"\n\t\t\t\t},\n\t\t\t\t"display_value": "Assorted garbage bottles on sandy surface photo – Free Plastic Image on Unsplash",\n\t\t\t\t"resource_subtype": "text",\n\t\t\t\t"resource_type": "custom_field",\n\t\t\t\t"text_value": "Assorted garbage bottles on sandy surface photo – Free Plastic Image on Unsplash",\n\t\t\t\t"type": "text"\n\t\t\t},\n\t\t\t{\n\t\t\t\t"gid": "1208132855637125",\n\t\t\t\t"enabled": true,\n\t\t\t\t"enum_options": [\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637126",\n\t\t\t\t\t\t"color": "blue",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "LinkedIn",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637127",\n\t\t\t\t\t\t"color": "aqua",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Facebook",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637128",\n\t\t\t\t\t\t"color": "pink",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Instagram",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637129",\n\t\t\t\t\t\t"color": "cool-gray",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "X/Twitter",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t}\n\t\t\t\t],\n\t\t\t\t"multi_enum_values": [\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637126",\n\t\t\t\t\t\t"color": "blue",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "LinkedIn",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637127",\n\t\t\t\t\t\t"color": "aqua",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Facebook",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637128",\n\t\t\t\t\t\t"color": "pink",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Instagram",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637129",\n\t\t\t\t\t\t"color": "cool-gray",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "X/Twitter",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t}\n\t\t\t\t],\n\t\t\t\t"name": "Platform(s)",\n\t\t\t\t"description": "",\n\t\t\t\t"created_by": {\n\t\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t\t"name": "",\n\t\t\t\t\t"resource_type": "user"\n\t\t\t\t},\n\t\t\t\t"display_value": "LinkedIn, Facebook, Instagram, X/Twitter",\n\t\t\t\t"resource_subtype": "multi_enum",\n\t\t\t\t"resource_type": "custom_field",\n\t\t\t\t"type": "multi_enum"\n\t\t\t}\n\t\t],\n\t\t"due_at": null,\n\t\t"due_on": "2024-08-24",\n\t\t"followers": [\n\t\t\t{\n\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t"name": "",\n\t\t\t\t"resource_type": "user"\n\t\t\t}\n\t\t],\n\t\t"hearted": false,\n\t\t"hearts": null,\n\t\t"html_notes": "",\n\t\t"liked": false,\n\t\t"likes": null,\n\t\t"memberships": [\n\t\t\t{\n\t\t\t\t"project": {\n\t\t\t\t\t"gid": "1208132854725061",\n\t\t\t\t\t"name": "TEST Content Generator",\n\t\t\t\t\t"resource_type": "project"\n\t\t\t\t},\n\t\t\t\t"section": {\n\t\t\t\t\t"gid": "1208132855637109",\n\t\t\t\t\t"name": "Ideation",\n\t\t\t\t\t"resource_type": "section"\n\t\t\t\t}\n\t\t\t}\n\t\t],\n\t\t"modified_at": "2024-08-23T12:08:26.528Z",\n\t\t"name": "TEST PROJECT TITLE",\n\t\t"notes": "",\n\t\t"num_hearts": 0,\n\t\t"num_likes": 0,\n\t\t"parent": null,\n\t\t"permalink_url": "https://app.asana.com/0/1208132854725061/1208132855637098\",\n\t\t\"projects\”: [\n\t\t\t{\n\t\t\t\t"gid": "1208132854725061",\n\t\t\t\t"name": "TEST Content Generator",\n\t\t\t\t"resource_type": "project"\n\t\t\t}\n\t\t],\n\t\t"resource_type": "task",\n\t\t"start_at": null,\n\t\t"start_on": null,\n\t\t"tags": null,\n\t\t"resource_subtype": "default_task",\n\t\t"workspace": {\n\t\t\t"gid": "1204214711554278",\n\t\t\t"name": "",\n\t\t\t"resource_type": "workspace"\n\t\t},\n\t\t"custom_fields_collection": {\n\t\t\t"1208132855637112": {\n\t\t\t\t"gid": "1208132855637112",\n\t\t\t\t"enabled": true,\n\t\t\t\t"name": "Post Copy",\n\t\t\t\t"description": "",\n\t\t\t\t"created_by": {\n\t\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t\t"name": "",\n\t\t\t\t\t"resource_type": "user"\n\t\t\t\t},\n\t\t\t\t"display_value": " is launching a new Cup. Eco-friendly paper cups. Plastic-free, PLA-free. For hot/cold drinks. Ideal for cafés, restaurants.",\n\t\t\t\t"resource_subtype": "text",\n\t\t\t\t"resource_type": "custom_field",\n\t\t\t\t"text_value": "s launching a new Cup. Eco-friendly paper cups. Plastic-free, PLA-free. For hot/cold drinks. Ideal for cafés, restaurants.",\n\t\t\t\t"type": "text"\n\t\t\t},\n\t\t\t"1208132855637116": {\n\t\t\t\t"gid": "1208132855637116",\n\t\t\t\t"enabled": true,\n\t\t\t\t"name": "Image URL",\n\t\t\t\t"description": "",\n\t\t\t\t"created_by": {\n\t\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t\t"name": "",\n\t\t\t\t\t"resource_type": "user"\n\t\t\t\t},\n\t\t\t\t"display_value": "Assorted garbage bottles on sandy surface photo – Free Plastic Image on Unsplash",\n\t\t\t\t"resource_subtype": "text",\n\t\t\t\t"resource_type": "custom_field",\n\t\t\t\t"text_value": "Assorted garbage bottles on sandy surface photo – Free Plastic Image on Unsplash",\n\t\t\t\t"type": "text"\n\t\t\t},\n\t\t\t"1208132855637125": {\n\t\t\t\t"gid": "1208132855637125",\n\t\t\t\t"enabled": true,\n\t\t\t\t"enum_options": [\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637126",\n\t\t\t\t\t\t"color": "blue",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "LinkedIn",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637127",\n\t\t\t\t\t\t"color": "aqua",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Facebook",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637128",\n\t\t\t\t\t\t"color": "pink",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Instagram",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637129",\n\t\t\t\t\t\t"color": "cool-gray",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "X/Twitter",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t}\n\t\t\t\t],\n\t\t\t\t"multi_enum_values": [\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637126",\n\t\t\t\t\t\t"color": "blue",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "LinkedIn",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637127",\n\t\t\t\t\t\t"color": "aqua",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Facebook",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637128",\n\t\t\t\t\t\t"color": "pink",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "Instagram",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\t"gid": "1208132855637129",\n\t\t\t\t\t\t"color": "cool-gray",\n\t\t\t\t\t\t"enabled": true,\n\t\t\t\t\t\t"name": "X/Twitter",\n\t\t\t\t\t\t"resource_type": "enum_option"\n\t\t\t\t\t}\n\t\t\t\t],\n\t\t\t\t"name": "Platform(s)",\n\t\t\t\t"description": "",\n\t\t\t\t"created_by": {\n\t\t\t\t\t"gid": "1207619797048797",\n\t\t\t\t\t"name": "",\n\t\t\t\t\t"resource_type": "user"\n\t\t\t\t},\n\t\t\t\t"display_value": "LinkedIn, Facebook, Instagram, X/Twitter",\n\t\t\t\t"resource_subtype": "multi_enum",\n\t\t\t\t"resource_type": "custom_field",\n\t\t\t\t"type": "multi_enum"\n\t\t\t}\n\t\t}\n\t}\n]"
},
“metadata”: {
“designer”: {
“x”: 0,
“y”: 0
},
“restore”: {
“parameters”: {
“type”: {
“label”: “Choose a data structure”
}
}
},
“parameters”: [
{
“name”: “type”,
“type”: “udt”,
“label”: “Data structure”
}
],
“expect”: [
{
“name”: “json”,
“type”: “text”,
“label”: “JSON string”,
“required”: true
}
]
}
},
{
“id”: 2,
“module”: “util:SetVariables”,
“version”: 1,
“parameters”: {},
“filter”: {
“name”: “LinkedIn Only”,
“conditions”: [
[
{
“a”: “{{first(map(1.custom_fields; "display_value"; "name"; "Platform(s)"))}}”,
“o”: “text:contain:ci”,
“b”: “linkedin”
}
]
]
},
“mapper”: {
“variables”: [
{
“name”: “Display Value”,
“value”: “{{map(1.custom_fields; "display_value")}}”
},
{
“name”: “Any Display Value has linkedin? (ci)”,
“value”: “{{contains(split(lower(join(map(1.custom_fields; "display_value"); ",")) + ","); "linkedin")}}”
},
{
“name”: “Item 3”,
“value”: “{{get(1.custom_fields; 3)}}”
},
{
“name”: “Display Value 3”,
“value”: “{{get(1.custom_fields; "3.display_value")}}”
},
{
“name”: “Display Value 3 (lower)”,
“value”: “{{lower(get(1.custom_fields; "3.display_value"))}}”
},
{
“name”: “Display Value 3 Has LinkedIn?”,
“value”: “{{contains(split(get(1.custom_fields; "3.display_value"); ","); "LinkedIn")}}”
},
{
“name”: “Display Value 3 Has linkedin? (ci)”,
“value”: “{{contains(split(lower(get(1.custom_fields; "3.display_value")); ","); "linkedin")}}”
},
{
“name”: “Display Value 3 Has linkedin?”,
“value”: “{{contains(split(get(1.custom_fields; "3.display_value"); ","); "linkedin")}}”
},
{
“name”: “Platforms”,
“value”: “{{first(map(1.custom_fields; "display_value"; "name"; "Platform(s)"))}}”
}
],
“scope”: “roundtrip”
},
“metadata”: {
“designer”: {
“x”: 429,
“y”: 11
},
“restore”: {
“expect”: {
“variables”: {
“items”: [
null,
null,
null,
null,
null,
null,
null,
null,
null
]
},
“scope”: {
“label”: “One cycle”
}
}
},
“expect”: [
{
“name”: “variables”,
“type”: “array”,
“label”: “Variables”,
“spec”: [
{
“name”: “name”,
“label”: “Variable name”,
“type”: “text”,
“required”: true
},
{
“name”: “value”,
“label”: “Variable value”,
“type”: “any”
}
]
},
{
“name”: “scope”,
“type”: “select”,
“label”: “Variable lifetime”,
“required”: true,
“validate”: {
“enum”: [
“roundtrip”,
“execution”
]
}
}
],
“interface”: [
{
“name”: “Display Value”,
“label”: “Display Value”,
“type”: “any”
},
{
“name”: “Any Display Value has linkedin? (ci)”,
“label”: “Any Display Value has linkedin? (ci)”,
“type”: “any”
},
{
“name”: “Item 3”,
“label”: “Item 3”,
“type”: “any”
},
{
“name”: “Display Value 3”,
“label”: “Display Value 3”,
“type”: “any”
},
{
“name”: “Display Value 3 (lower)”,
“label”: “Display Value 3 (lower)”,
“type”: “any”
},
{
“name”: “Display Value 3 Has LinkedIn?”,
“label”: “Display Value 3 Has LinkedIn?”,
“type”: “any”
},
{
“name”: “Display Value 3 Has linkedin? (ci)”,
“label”: “Display Value 3 Has linkedin? (ci)”,
“type”: “any”
},
{
“name”: “Display Value 3 Has linkedin?”,
“label”: “Display Value 3 Has linkedin?”,
“type”: “any”
},
{
“name”: “Platforms”,
“label”: “Platforms”,
“type”: “any”
}
]
}
}
]
}
],
“metadata”: {
“version”: 1
}
}
Basically one version checks if Display Value in ANY of the Custom Fields contains “linkedin”.
Another checks if Display Value of ONLY the third Custom Field has LinkedIn, and there are both case-sensitive an case-insensitive versions.
You can learn how these functions works then apply them in your filter.