500 Error Creating Ticket with attribute_value_ids



Publication le 20 oct. 2022

Receiving 500 error when trying to create ticket with form with attribute_value_ids from ruby library: 

https://github.com/zendesk/zendesk_api_client_rb/tree/v1.37.0

 

 response = client.tickets.create!(description: 'a', ticket_form_id: 9580526189331, attribute_value_ids: [9580974989331.to_s])

 

INFO - post https://applyboard1620149335.zendesk.com/api/v2/tickets [{}]
DEBUG -   Accept: "application/json"
  Accept-Encoding: "gzip;q=1.0,deflate;q=0.6,identity;q=0.3"
  User-Agent: "ZendeskAPI Ruby 1.37.0"
{:ticket=>#<ZendeskAPI::SilentMash attribute_value_ids=#<Hashie::Array ["9580974989331"]> comment=nil description="a" ticket_form_id=9580526189331>} [{}]
INFO - Status 500 [{}]
DEBUG -   date: "Thu, 20 Oct 2022 20:51:53 GMT"
  content-type: "application/json; charset=UTF-8"
  content-length: "46"
  connection: "close"
  x-request-id: "75d4a2511ae054af-IAD, 75d4a2511ae054af-IAD"
  x-runtime: "0.477588"
  x-zendesk-zorg: "yes"
  cf-cache-status: "DYNAMIC"
  server: "cloudflare"
  cf-ray: "75d4a2511ae054af-YYZ"
{"status"=>500, "error"=>"Internal Server Error"} [{}]
ZendeskAPI::Error::NetworkError:


0

6

6 commentaire

Agreed, I'm still going to open up a bug report with the team who owns this endpoint to provide them with this feedback.
 
Have a great weekend,

Eric

0


Ah perfect. It is probably best to not throw a 500 error with invalid input and instead return a useful message! 

Thanks for the help Eric Nelson!!

0


Hey Allen,

That attribute is to be used for setting the attribute values for skills based routing. If you're wanting to set some of the form fields you'd want to set custom field values.

0


Eric Nelson I am trying to supply the form_id for a ticket & pre-populate some of the attributes for the form fields. According to what I could figure out from the API documentation, this is how to accomplish this?

https://developer.zendesk.com/api-reference/ticketing/tickets/tickets/#json-format

0


Hey Allen,

Upon a closer look, that id that you've put in the attribute_value_ids array doesn't look to be valid. To confirm you're trying to set a skill attribute on the ticket correct?

0


Hey Allen,

I've been able to replicate your issue and will be opening up a bug report with the team who owns the client. As soon as I have an update, I'll let you know. 

1


Se connecter pour laisser un commentaire.

Vous ne trouvez pas ce que vous cherchez ?

Nouvelle publication