'How to update the ticket field using API
Can someday jump on this and help me to update the ticket field (ticket is already submitted), the targeted field is a custom-field which I need to update it using the Zendesk API,
Can this is possible using Zendesk API?
Thank You
Solution 1:[1]
Update - Using Zendesk Api Endpoint
Zendesk Api Update Ticket is what you need to hit with the payload as described here:
{
ticket: {
custom_fields: [{ "id": 25356371, "value": "something"}]
}
}
Old Answer (using zafClient)
If you're trying this from Sidebar app and utilizing zafClient then its pretty straightforward. Example here and below
client.set('ticket.customField:fieldName', value)
If you're trying this with Zendesk rest api then you can utilize this Update Ticket endpoint to update the value of any Custom-Field present in that ticket.
Steps to update:
- get custom-field's id
- get ticket id
- Hit update ticket api with following JSON payload
{
ticket: {
custom_fields: [{id: <custom_field_id>, value: 'hurray!'}]
},
}
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 |
