最近搜索


没有最近搜索

Akshay Joshi's Avatar

Akshay Joshi

已加入2024年12月08日

·

最后活动2024年12月09日

关注

0

关注者

0

活动总数

3

投票

0

订阅

1

活动概览

的最新活动 Akshay Joshi

Akshay Joshi 进行了评论,

社区评论 Developer - Zendesk Apps Framework (ZAF)

I also tried using `ticket.latest_public_comment`

 

I get the error InvalidPathError: Path 'latest_public_comment' doesn't exist on node 'ticket'

 

查看评论 · 已于 2024年12月09日 发布 · Akshay Joshi

0

关注者

0

投票

0

评论


Akshay Joshi 创建了一个帖子,

帖子 Developer - Zendesk Apps Framework (ZAF)

I am trying to fetch the contents of the comments on a zendesk ticket using ZAF client in js but it keeps giving me “undefined”.

eg code -

```

const ticketData = await client.get(['ticket.status', 'currentUser.name',  'ticket.comments']);

const comments = ticketData['ticket.comments'];

const commentContent=comments[0].body;

```

I also tried fetching the comments using the API - GET /api/v2/tickets/{ticket_id}/comments, and then using .body on one of the comments and still the same issue.

 

When I do a curl i do see the JSON response but when using 

commentContent=comments[0].body I get undefined.

Could you please help me understand how to fetch the contents of the comments?

已于 2024年12月08日 发布 · Akshay Joshi

0

关注者

2

投票

2

评论