최근 검색


최근 검색 없음

Attaching custom objects to a profile and then displaying that information via Zendesk app

답변함


2021년 6월 16일에 게시됨

Hello,

I was wondering if anyone could help me put everything that I have learned together.

I have created an object called "Kit" (a kit that we sell) with the property of "serial" (serial number). I have then created a user profile and am able to grab the user ID. I also know how to create a Zendesk app (using HTML and javascript). I am able to add the serial number via API. However, I am getting stuck here.

What I would like to do is figure out how to attach the "Kit" object to a user profile and then display the "serial number" via the Zendesk app in the user profile if this is possible. The more simple the app the better. 

TL;DR I just want to be able to see how to tie object data to a user profile and then display it via app in zendesk. 

Does anyone have any example code of how to do this?


1

2

댓글 2개

Hey Jon, 

Do you already have the object associated to the User object with a relationship? If so you'd just need to use the List Related Object Records endpoint with the User ID. 

  function userKits(client, id) {
var kits = {
url: '/api/sunshine/objects/records/zen:user:' + id + '/related/{relationship_type}',
type:'GET',
dataType: 'json',

};

From there you just parse and display the data in the object record you want to show. 

If you don't yet have the user associated to an object record, then you'd need to set up your relationship type, and then have a mechanism to associate the two

Matt

2


This was very helpful! Thank you @...!

1


댓글을 남기려면 로그인하세요.

원하는 정보를 못 찾으셨나요?

새 게시물