Problems creating an app using variations endpoint

I’m new here, so this is my first post. I’m also an artist, a painter, albeit one with a little more coding knowledge than some of my peer group.
I have a few problems that I hope the community can help me resolve.
Like many artists, I have been playing around with DALL-E. I have even created my own, highly limited, desktop app that uses the generations endpoint. It’s just a form with a text area and a submit button.
That’s all well and good. Works perfectly.
However I wish to take things further. So I have toiled to create a second app, which is where my problems arise.
I should add that I have had endless conversations with openai chat. But finally, it has passed me across to you, because it cannot resolve the problems.
So, a brief outline:
I am building a node.js app to use dall-e 2 /variations endpoint.
My html form allows me to select a file. I have prepared square png images, of less than 4 mb. These have transparent regions that will permit DALL-E to modify according to my text prompt.
The DALL-E endpoint will, hopefully, return a JSON object containing the generated variation(s). Once returned, I can then process the response and display the results in my app.
So, I have two main files, server.js, running on my laptop, and index.html
I have all the modules and dependencies installed.
My server runs successfully.
The html form opens in the browser. The form is all present and correct.
But when I submit my input the trouble begins. As I say, chat has not been able to resolve this, and needless to say neither have I.
So how do I best go about asking this community for help? In other words, can I post code here? Am I even in the right forum?
Your help would be greatly appreciated.