Zendesk and Corona

I use Zendesk for customer feedback. I have the cheapest plan $5.00 a month. Just sharing my implementation in case anybody wants to use it:

local json = require "json"; local requestBody = {} requestBody.request = {} requestBody.request.requester = {} requestBody.request.subject = "feedback" -- My form doesn't have a subject line. I default to this. requestBody.request.comment = {} requestBody.request.comment.body = message -- String of the message. if not (email:match("^[%w.]+@%w+%.%w+$")) then -- Didn't provide an e-mail. So send anon feedback. requestBody.request.requester.name = "Anonymous customer" else -- Email provided. requestBody.request.requester.name = email -- My form does not have a name line. I use the e-mail again. requestBody.request.requester.email = email end local url = "https://\<youraccount\>.zendesk.com/api/v2/requests.json" -- Use your zendesk url. local headers = {} headers["Content-Type"] = "application/json" local params = {} params.body = json.encode (requestBody) params.headers = headers network.request( url, "POST", networkListener, params ) -- networklistener replies back the response.