buzzle-sdk

Official SDK for Buzzle Platform APIs

Usage no npm install needed!

<script type="module">
  import buzzleSdk from 'https://cdn.skypack.dev/buzzle-sdk';
</script>

README

Usage

const { apiClient, progressListener } = require("buzzle-sdk");

const API_URL = "http://localhost:5000";

const pl = progressListener(API_URL);
const { Job } = apiClient({ baseUrl: API_URL });

async function main() {
  try {
    const { id } = await Job.create({
      idVideoTemplate: "FU_Sg-ygG9",
      idVersion: "XJy4MpE0M",
    });

    pl.on(id, (data) => console.log(data));
  } catch (e) {
    console.error(`Error:${e.message}`);
  }
}

main();