@blitz-planner/sdk
v0.1.2
Published
TypeScript SDK for the Blitz Planner public API.
Readme
Blitz Planner SDK
TypeScript SDK for the Blitz Planner public API.
Full developer documentation lives in docs/DEVELOPER_PLATFORM.md in the Blitz Planner repository.
Install:
npm install @blitz-planner/sdkimport { BlitzPlanner } from "@blitz-planner/sdk";
const blitz = new BlitzPlanner({ apiKey: process.env.BLITZ_API_KEY! });
const links = await blitz.connections.createLinks({
platforms: ["TIKTOK", "INSTAGRAM"],
returnUrl: "https://your-app.example/connections/done",
});
const post = await blitz.publishNow({
content: "Launch day.",
accountIds: ["account_tiktok"],
mediaIds: ["media_123"],
mediaType: "VIDEO",
tiktok: {
privacyLevel: "PUBLIC_TO_EVERYONE",
disableComment: false,
},
});Node file uploads are exposed from the node entrypoint:
import { BlitzPlannerNode } from "@blitz-planner/sdk/node";
const blitz = new BlitzPlannerNode({ apiKey: process.env.BLITZ_API_KEY! });
const media = await blitz.uploadFile({
path: "./launch.mp4",
projectId: "project_123",
mimeType: "video/mp4",
});