codingSW
codingSW
CDCloudflare Developers
Created by codingSW on 9/25/2023 in #workers-help
Worker and temp picture for Twitter
Hello, 'workers' is a fantastic thing, but I have a problem that has been bothering me for days, and I haven’t been able to solve it. I have a function that needs to send a tweet to a certain network. First, I need to send a picture in the standard way and it should return a mediaID. Since the picture is at a URL, I've been taking it into a buffer but the Twitter API 1.1 simply refuses to send it. What’s even worse, when I try the function on a system where I have the possibility to have the picture on the filesystem, it works without a problem. In desperation, I also sent it to R2 and tried from there, but without success. Does anyone have any solution to at least transfer it to some temporary place on the filesystem before sending??? Thanks
6 replies