Created
May 22, 2015 10:10
-
-
Save jeznag/62f22aa9b7a54d7ed107 to your computer and use it in GitHub Desktop.
Get profile details for Zoho CRM user using deluge script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//get details for this user | |
userResp = getUrl(("https://crm.zoho.com/crm/private/xml/Users/getUsers?authtoken=AUTHTOKEN&scope=crmapi&type=ActiveUsers")); | |
info userResp; | |
users = userResp.executeXPath("/users/user"); | |
if ((users != null) && (users != "")) { | |
userList = users.toList("-|-"); | |
for each user in userList { | |
idNode = user.executeXPath("/user/@id"); | |
id = idNode.executeXPath("/id/text()"); | |
if (id == ownerId) { | |
emailNode = user.executeXPath("/user/@email"); | |
owner_email = emailNode.executeXPath("/email/text()"); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment