Skip to content

Instantly share code, notes, and snippets.

@rahulbanerjee26
Created May 26, 2022 23:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rahulbanerjee26/a26285c4bc07f693e9c34319bb8b80dc to your computer and use it in GitHub Desktop.
Save rahulbanerjee26/a26285c4bc07f693e9c34319bb8b80dc to your computer and use it in GitHub Desktop.
createLiveStream()
.then((res) => {
console.log(
"Created a live stream resource successfully. Below is the Livestream resource"
);
console.log(res);
const liveStreamID = res["liveStreamId"];
const filePath = "thumbnailImage.jpg";
addThumbnail(liveStreamID, filePath)
.then((res) => console.log("Added Thumbnail"))
.catch((err) =>
console.log(
`Encountered following error ${err} while adding thumbnail to live stream`
)
);
})
.catch((err) =>
console.log(
`Encountered following error ${err} while creating live stream resource`
)
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment