Zapier Integration - Get IDs for custom field

Hi. I’m connecting Google Sheets and Asana, using Zapier. In both the Asana projec and the Google Sheet I have a mult-select field for “Assets”. I get the following error, how do I get the custom field values ID? I’m a project manager, not a developer.
Thanks!

Failed to create a task in Asana

The app returned “multi_enum_values: [0]: Not a recognized ID: Asset example”.

The error message “multi_enum_values: [0]: Not a recognized ID: Asset example” indicates that the value “Asset examples” is not a valid ID for the custom field you are trying to update in Asana. This typically happens when the custom field expects a specific set of predefined options (IDs) and the provided value does not match any of these options.

To resolve this issue, you need to ensure that the value you are passing to the custom field is a valid ID recognized by Asana. You can do this by fetching the list of valid IDs for the custom field from Asana and then using one of these IDs in your Zap. Here’s how you can do it:

  1. Fetch Valid IDs: Use Asana’s API to get the list of valid IDs for the custom field. You can do this by making a GET request to the custom field endpoint.
  2. Update Zap: Once you have the valid IDs, update your Zap to use one of these IDs instead of “CIAM for Dummies”. You can use a Lookup Table in Zapier to map the human-readable values to the corresponding IDs.

For example, if you have a custom field with options like “Option A” (ID: 12345) and “Option B” (ID: 67890), you would replace “Asset example” with the appropriate ID (e.g., 12345). This ensures that the value you are passing is recognized by Asana.

1 Like

@Vanesa_Socolovsky - Does the pre-built integration with Google Sheets not offer you enough? If not, to get this info, follow these steps (this assumes your field is either a single- or multi-select field):

  1. Create an Asana project with only your Assets custom field.
  2. Follow these steps to create a personal access token. This is how you will validate your connection to the API. Copy the long randomized code.
  3. Go to this API reference. Paste your PAT (the long code from last step) on the right side in the box for a bearer token.
  4. Go to your project (from step 2) and copy the first long number in the URL after app.asana.com/0/{get this number}/{do not include this second number}. Do not get the leading or trailing /. Paste this in the Path Params section in the project_gid box.
  5. Click “Try it”. You should get a bunch of code in the response box. As long as your project only had your Asset field, you should only have to worry about the field GID (identifies the field) and the enum_values GID(s) (identify the specific options in your dropdown). I attached an example photo below (second photo). The first red box is the field GID, the other 2 red boxes are the enum_values GIDs (you may have more than 2).


1 Like

Many thanks, Stephen!

Hi @Stephen_Li sorry, one thing to clarify the screenshot you provided. the black box (first gid, in my example below the XXXXXXXX) is not used. The one that follows (in my example YYYYYYY) would be the custom field ID and the one after that (in my example ZZZZZZZZ and OOOOOO) is the gid for the enum_value in the dropdown, right?

{
“data”: [
{
“gid”: “XXXXXXXXXXX”,
“custom_field”: {
“gid”: “YYYYYYYYYY”,
“enum_options”: [
{
“gid”: “ZZZZZZZZZZZZZZ”,
“color”: “green”,
“enabled”: true,
“name”: “AMER”,
“resource_type”: “enum_option”
},
{
“gid”: “00000000000”,
“color”: “orange”,
“enabled”: true,
“name”: “EMEA”,
“resource_type”: “enum_option”
},
{

@Vanesa_Socolovsky - yes, that’s exactly correct.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.