Hi everyone
I am creating a video in webm format in the program code, I download the file created from mediaRecorder without any problems and it is played. The problem occurs when I send the same blob to Jira Cloud using the rest api, the file is attached to the issue, but the video file downloaded from the Jira panel is not previously played, while Jira can not create a preview of the file and display it. Give.
Webm file creation code:
blobs = [];
rec = new MediaRecorder(stream, {mimeType: 'video/webm; codecs=vp8,opus'});
rec.ondataavailable = (e) => blobs.push(e.data);
rec.onstop = async () => {
blob = new Blob(blobs, {type: 'video/webm'});
c.attachAPI(blob);
};
And attach the file code to the issue:
const form = new FormData();
form.append('file', blob, 'attach.webm');
const responseFile = await requestJira('/rest/api/3/issue/'+issueKey+'/attachments', {
method:'POST',
body: form,
headers:{
'Accept': 'application/json',
'X-Atlassian-Token': 'no-check',
'Content-Type':'application/json'
}
});
let res = await responseFile.json();
Thank you for your help
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.