InsionInsion
TypeScript

Ingest a record

Persist a record for asynchronous moderation

Call ingestARecord to create or update content and receive moderation results through webhooks.

const result = await client.ingestARecord({
  clientId: "post-123",
  name: "A post",
  entity: "post",
  content: { text: "Hello world", imageUrls: ["https://example.com/image.jpg"] },
});

The required fields are clientId, name, entity, and content. You can also provide clientUrl, metadata, and a user object. The response is IngestRecordResponse, which contains the Insion record ID and, when queued, a moderation ID.

When to ingest

Choose ingestion for feeds, imports, and other workflows where the user does not need an immediate decision. Configure a webhook to receive moderation results once processing completes. If you must block publication until moderation finishes, use Moderate a record instead.

The same clientId updates an existing record, which makes retrying or synchronizing content safe.

On this page