Welcome to Portal

?Unknown\pull-down

Welcome to Zoho Cares

Bienvenido a Soporte de Zoho

Search our knowledge base, ask the community or submit a request.

I'm trying to fetch a lookup field data from desk to our creator application and it doesn't work.
I'm guessing that my search parameter is wrong?

On my trial function fetch if I use these:
tickets = invokeurl
[
type :GET
headers:{"featureFlags":"lookUp"}
connection:"deskconnect"
];
I can get the result in json:
customFields": {
"Bill To": {
      "accountName": "xxxxxxxxxxx",
      "id": "351081000013982683"
    },
or
cf": {
"cf_client": {
      "accountName": "xxxxxxxxxx",
      "id": "351081000013982683"
    },

however, on my workflow
zoho.desk.searchRecords("orgID","Tickets",searchValue,0,5,"deskconnect");
for each  Ticket_Rec in PM_TicketRecord.get("data")
{
if(Ticket_Rec.get("departmentId") == "deptID" && Ticket_Rec.get("category") == "Scheduled Maintenance")
    {
            input.Bill_To = Ticket_Rec.get("customFields").get("Bill To").get("accountName");  -always an error
   }
}

Any idea on this?

1 user has this question.
8 Replies
Reply

Hi
,

Currently, Deluge integration tasks don’t return lookup data. The lookup data will only be available if the following is added to the API header:

headers:{"featureFlags":"lookUp"}

Shoot us your complete use case via email at support@zohodesk.com so we can explore further feasibility.

Regards,
Shivani | Zoho Desk



@shivani,

When will then be implemented.  Do we have a timeline?

I'll connect with our product team to check for updates on this feature and ensure this post stays updated with any further information.

Thanks,
Shivani | Zoho Desk


@shivani,

Thanks but I was able to find a way to get the data from lookup field from Zoho Desk and reflect the data to the input field on the Creator.

I'm still using 
headers:{"featureFlags":"lookUp"}

Good to know that,

! Feel free to share it with the community if you’re interested.

Regards,
Shivani | Zoho Desk


I've been reading some of the previous queries back many years ago and I found out that the trick to do it is very simple.
* First, create an input field that stores the result.

* Second, instead of using zoho.desk.searchRecords - which only results an error try the invokeurl:
   > my method is this
     url : "https://desk.zoho.com/api/v1/tickets/" + {input field}
     headers:{"featureFlags":"lookUp"}

 * In this method I'm not using any for loop as the data has already been fetch above.
    > I'm using this [this however, depends on what's the name the lookup field was declared on zDesk]
            (try fetching the entire ticket details first to get the json result) - as mentioned on my first query I'm using a function as I'm trying to get the result first rather than incorporating the code back to workflow
      input.Bill_To = tickets.get("customFields").get("Bill To").get("accountName")

 *Trigger workflow is User Input of a field -> [input of ticket number] - what I'm doing is simultaneous search method correlated to the ticket details that was being search. 

 * Under a single workflow I have 2 search method.
     * zoho.desk.searchRecords (to get the ticket ID) 
                          
     * followed by the invokeurl - "https://desk.zoho.com/api/v1/tickets/" + input.TicketID
     

 
   
   Please do let me know once the integration task been implemented, so I can also change the code :)

Thanks a ton for sharing this with the Community! I’ll be sure to drop an update here as soon as we hear back from the development team on this functionality

.

Cheers,
Shivani | Zoho Desk


Reply to Israel NotarioA
/* */
  • 12
  • Insert
  • Plain text
Add Comment
(Up to 20 MB )