Búsquedas recientes


No hay búsquedas recientes

Sort_by in Organization and Ticket Form



Publicado 08 feb 2023

Somehow, I cannot sort Organizations by updated_at desc or created_at desc

https://MyDomain.zendesk.com/api/v2/organizations?sort_by=updated_at&sort_order=desc

Also, how can we do the same for the ticket form api below?

https://MyDomain.zendesk.com/api/v2/search?query=ticket_form_id:8836099999499%20custom_field_8836999980539:i_test_at_an_teset_test_test_level

Since api gives 100 records in a page, I wanted to pull data updated in the last say 12 hours... Any suggestions? So if we can do this we can pull only the last updated Organizations and the form data every time our ETL pipeline runs...Thanks a lot for your assistance.


0

4

4 comentarios

image avatar

Eric Nelson

Zendesk Developer Advocacy

Hey Sujay,

If you don't see "sort" listed in the documentation it means that endpoint doesn't have a sort operator. This is best accomplished with the search api. 

/api/v2/search?query=type:organization&sort_by=updated_at&sort_order=desc

As for your second query, are you looking to pull tickets that have had that particular field updated? 

0


Thanks Eric for the response. For organizations and the ticket form data, I am looking for a way to pull those were either updated or created within the last so and so hours or day(s)... 

0


Eric I was trying to use something like these.. Is that right way? I did not get results. To change hours to days I guess we just change 12hours to 2days (as an example)?

/api/v2/search?query=type:organization%20updated>12hours

/api/v2/search?query=form:8836099999499 custom_field_8836999980539:i_test_at_an_teset_test_test_level updated>12hours

0


Eric I am good. Thanks for your help.

0


Iniciar sesión para dejar un comentario.

¿No encontró lo que buscaba?

Nueva publicación