Recent searches
No recent searches
API Endpoint to trigger GitHub-linked theme update?
Posted Mar 03, 2022
Is there an API for instructing Zendesk to update a GitHub-linked Guide Theme from GitHub?
1
7
Recent searches
No recent searches
Posted Mar 03, 2022
Is there an API for instructing Zendesk to update a GitHub-linked Guide Theme from GitHub?
1
7 comments
Eric Nelson
I'm not sure I fully follow. Are you wanting to create a CD pipeline so when you push against your repo it updates your Zendesk Theme in Guide?
0
Timothy
Hi Eric Nelson, yes that is the idea. I am trying to create a pipeline (on GitHub Actions) that would automatically increment the version and make Zendesk update the theme to the latest version.
0
Eric Nelson
Hey Timothy,
Thanks for clarifying, I think I misread your message the first time. You can do this by using this endpoint. We walk through the workflow a bit here.
Hope this helps!
1
Timothy
Hi Eric Nelson, I've read the link but it doesn't tell me how to trigger the Update from GitHub action available in the Theme settings page.
0
Eric Nelson
Hey Timothy,
This endpoint hooks into the backend endpoint that handles the upload. There isn't an endpoint that hooks into that frontend controller. Though the concept is the same:
Have your action create the update theme job on push to main, then you'll receive the endpoint to upload to. Zip the repo, add it to the payload and create the update request.
If you'd like my team can put this on our backlog of things to make a tutorial for.
0
Timothy
Eric Nelson so how does Zendesk manage to hide the manual zip-file uploading step from the user when they press "Update from GitHub"? Shouldn't the API also be able to bypass this step?
0
Eric Nelson
I'll need to check with the corresponding dev team to confirm. Though if I'm not mistaken, the "Update from Github" hooks into the Github OAuth flow to access your repository and perform this process. Though this isn't something that is possible from the API as the relationship between the services isn't the same (i.e. we can control the full OAuth flow from the UI, while we can't via API) from a security perspective. Due to that we aren't able to handle the cloning, zipping and uploading ourselves if it were to be initiated from API.
If I hear from the dev team that the reason is something else, I'll touch base here.
0