First time using this API today.
I have an existing custom field dropdown in my Tasks table, in ASANA. When my program runs, I want to be able to update the value of that dropdown to a new value. Any advice on how to approach this?
Here is my custom field object: "custom_fields":[ { "gid":"xxx", "enabled":true, "enum_options":[ { "gid":"xxx", "color":"yellow", "enabled":true, "name":"READY", "resource_type":"enum_option" }, { "gid":"xxx", "color":"red", "enabled":true, "name":"ON HOLD", "resource_type":"enum_option" }, { "gid":"xxx", "color":"orange", "enabled":true, "name":"DATA ISSUE", "resource_type":"enum_option" }, { "gid":"229014069447456", "color":"yellow-green", "enabled":true, "name":"WAITING ON FC", "resource_type":"enum_option" }, { "gid":"xxx", "color":"hot-pink", "enabled":true, "name":"WAITING ON CLIENT", "resource_type":"enum_option" }, { "gid":"xxx", "color":"purple", "enabled":true, "name":"In Progress", "resource_type":"enum_option" }, { "gid":"xxx", "color":"red", "enabled":true, "name":"Forfeited", "resource_type":"enum_option" }, { "gid":"1199952868879785", "color":"yellow-orange", "enabled":true, "name":"SOW Clarification", "resource_type":"enum_option" }, { "gid":"xxx", "color":"green", "enabled":true, "name":"Waiting on Final Proof", "resource_type":"enum_option" } ], "enum_value":{ "gid":"xxx", "color":"yellow", "enabled":true, "name":"READY", "resource_type":"enum_option" }, "name":"Status", "created_by":{ "gid":"xxx", "name":"xxx", "resource_type":"user" }, "display_value":"READY", "resource_subtype":"enum", "resource_type":"custom_field", "type":"enum" } ]
In my program, I parse out the option I want to set it to from the enum_options
area and with that data, update enum_value
object to those values. I also update display_value
to the appropriate name from my parsed out enum_options
.
While the object looks correct, once I PUT it through the ASANA API, I get a success status but no change.
I have been following this “Update a task” page to build this process out. I hope someone can help me! Update a task
Thanks in advanced
ps. I changed all gid to xxx