SDKPlatform API v1

TypeScript SDK

Use typed resources, safe transport recovery, streaming uploads, polling helpers, and webhook verification from one ESM-first package.

Install and authenticate

Node.js 20+
shell
npm install autocontentapi
Client
ts
import AutoContent from 'autocontentapi'

const client = new AutoContent({
  apiKey: process.env.AUTOCONTENT_API_KEY,
})

Complete resource surface

The client exposes projects, collections, sources, assetTypes, models, voices, avatars, generations, assets, contentLoops, account, apiKeys, billing, and webhooks. Request and response fields intentionally preserve the API’s snake_case.

For one-off files, create a file Source with keep_as_project_asset: false, wait until it is ready, then pass its ID in attachment_source_ids to preview and create. Request-only Sources expire after 24 hours unless claimed by a Generation. Text files can ground any Asset; images are optional guidance for Lead Magnets and Product Demo Videos and still need text evidence.

Transport and upload safety

Mutation methods generate an idempotency key when omitted and keep it through safe retries. Ambiguous transport errors expose the recovery key. Blob/File and factory uploads are replayable; a consumed one-shot stream is never silently resent.