xxjs17xx
xxjs17xx
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
I really apprecaite you taking the time.
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
i defeinatly started without the await, so maybe im a tad bit impatient
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
well thank you so much Chaika
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
i swear I did this test earlier.
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
ah.. .ok it loolks like it is fireing now !!
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
just a side note this is the new Email workers vs regular workers not sure if there are a differeerence
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
export default { async email(message, env, ctx) { await fetch('https://<redacted>.zendesk.com/api/v2/tickets.json', { method: 'POST', headers: { 'Content-Type': 'application/json', 'Accept':'application/json', 'Authorization': 'Basic ' + btoa('<redacted>/token:<redacted>') }, body: JSON.stringify({ ticket: { subject: 'Test ticket jon sammut', comment: { body: 'This is a test ticket jon sammut' } } }) }) .then(response => response.json()) .then(data => console.log(data)) .catch(error => console.error(error)); } }
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
the streamed logs say OK but I do get a bunch of fecth handler erros
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
I have tried it with await..
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
Also note url username and password have been redacted
18 replies
CDCloudflare Developers
Created by xxjs17xx on 11/8/2023 in #workers-help
Email workers
Note this is wrapped in the export default { async email(message, env, ctx) { } }
18 replies