Hi,
I was following this thread and I got pretty much most of it, but my call is not working as expected.
What I understood is that custom_fields come as arrays, so let’s say I want the first one of my custom fields I have to use custom_fields[1].enum_value.name
I did it, but it’s not working.
This is a section of my JSON that I slightly modified for privacy reasons
"gid":"1199598179279534",
"assignee":{
"gid":"1140123822819447",
"resource_type":"user"
},
"completed_at":null,
"created_at":"2021-01-17T18:22:42.423Z",
**"custom_fields"**:[
{
"gid":"1199597717454706",
"enabled":true,
"name":"Actual words",
"number_value":null,
"precision":0,
"created_by":{
"gid":"1199584947573930",
"name":"XXX",
"resource_type":"user"
},
"resource_subtype":"number",
"resource_type":"custom_field",
"type":"number"
},
{
"gid":"1199595541698569",
"enabled":true,
"name":"Words required",
**"number_value":**I WANT THIS**,**
"precision":0,
"created_by":{
"gid":"1199584947573930",
"name":"XXX",
"resource_type":"user"
},
"resource_subtype":"number",
"resource_type":"custom_field",
"type":"number"
},
{
"gid":"1199594765947252",
"enabled":true,
"enum_options":[
{
**ALL OPTIONS**
],
"enum_value":{
"gid":"1199594766288004",
"color":"yellow-orange",
"enabled":true,
"name":"**I WANT THIS**",
"resource_type":"enum_option"
},
"name":"Cliente",
"created_by":{
"gid":"1199584947573930",
"name":"XXX",
"resource_type":"user"
},
"resource_subtype":"enum",
"resource_type":"custom_field",
"type":"enum"
}> Blockquote
this is my call:
https://app.asana.com/api/1.0/projects/MY_PROJECT_ID/tasks?opt_fields=name,completed_at,name,assignee,due_on,notes,tags,custom_fields[2].number_value,custom_fields[3].enum_value.name
Can you please point me to the mistake?
Thank you!
Nina