Ich bin eine URL wie das Abrufen:holen Post mit mehrteiliger Formulardaten
fetch(url, {
mode: 'no-cors',
method: method || null,
headers: {
'Accept': 'application/json, application/xml, text/plain, text/html, *.*',
'Content-Type': 'multipart/form-data'
},
body: JSON.stringify(data) || null,
}).then(function(response) {
console.log(response.status)
console.log("response");
console.log(response)
})
Meine API die Daten so sein, von multipart/form-data
erwartet ich content-type
dieser Art bin mit ... Aber es gibt mir eine Antwort mit Statuscode 400.
Was ist falsch an meinem Code?