最近搜索


没有最近搜索

Adding a User to a New Org but still keeping them in all of their current orgs



已于 2024年5月17日 发布

I have a problem where I am trying to add an end user to an org that is new for that user based on a tag that appears on a ticket.

 

I have all of logic working to a degree from a webhook and then using a zendesk trigger to finish the job, but the problem I am having is that when I run this, it removes the end user from any org they were a member of and then adds the one I wanted to add.

 

I need to change this so that the user does not lose previous orgs but gains a new one.

 

Thoughts? I have tried PUT, PATCH, and POST but all 3 give the same reseult


0

1

1 条评论

image avatar

Charles Nadeau

Zendesk Documentation Team

Hi Matt, just today we made an update to the dev docs explaining this issue:

If you make a request to update the organization_id property, the organization_id of the request updates the default organization for that user and removes all other organizations currently associated with that user. Zendesk recommends using the Organization Memberships API to add or delete organizations for a user.

https://developer.zendesk.com/api-reference/ticketing/users/users/#organization-id

In other words, when updating the user, leave the organization_id blank and make a separate request with the Create Membership endpoint to assign the user to the new organization. 

0


请先登录再写评论。

找不到所需的内容?

新建帖子