---
title: "Bulk Create Agent Resources"
method: POST
path: "/voice/agent-resources/bulk"
tags: ["Voice Agent Intelligence"]
---

# Bulk Create Agent Resources

`POST /voice/agent-resources/bulk`

## Request

- Base URL: `https://api.speakai.co/v1`
- URL: `https://api.speakai.co/v1/voice/agent-resources/bulk`
- Auth: API key in header `x-speakai-key` and API key in header `x-access-token`

### Bulk Create Agent Resources

Requires the OWNER or ADMIN role. Adds up to 100 documents/links in one call; each is fetched and embedded independently in the background.

## Request body

- object
  - `agentId` string, required: Required.
  - `resources` object[], required: Required. 1 to 100 entries, each shaped like the Create Agent Resource request body minus agentId.
    - `agentId` string: Required.
    - `url` string, uri: Required.
    - `title` string: Required. Max 200 characters.
    - `description` string: Required. Max 1000 characters.
    - `action` 'link' | 'presentation': Required.
    - `contentType` 'video' | 'pdf' | 'image'

## Response `201`

Created

- object
  - `status` 'success'
  - `data` object
    - `resources` object[]
      - `_id` string: MongoDB document id, included because every document has one; use resourceId to identify it.
      - `resourceId` string: Server-generated UUID. Immutable -- sent in the body on create or update is silently dropped.
      - `agentId` string: Required on create. Immutable after create -- sent on update is silently dropped.
      - `companyId` string: Stamped from the caller's authenticated company. Sent in the body is silently dropped.
      - `userId` string: Id of the user who created this resource. Sent in the body is silently dropped.
      - `url` string, uri: Required on create.
      - `title` string: Required on create. Max 200 characters.
      - `description` string: Required on create. Max 1000 characters.
      - `action` 'link' | 'presentation': Required on create.
      - `contentType` 'video' | 'pdf' | 'image'
      - `status` 'pending' | 'uploading' | 'processing' | 'completed' | 'failed': Defaults to pending. Advances as the resource's content is fetched and embedded for the agent to search during calls. Not settable directly.
      - `isDeleted` boolean: Delete is a soft delete. Not settable directly.
      - `deletedAt` string, date-time, nullable
      - `createdAt` string, date-time
      - `updatedAt` string, date-time
    - `total` integer

## Other responses

- `400`: Validation failed
- `403`: Caller's role is not OWNER or ADMIN
- `404`: Agent not found

---

[API](https://skmtc.dev/speakai/apis/speak-ai-api.md) · [All operations](https://skmtc.dev/speakai/apis/speak-ai-api/llms.txt) · [OpenAPI document](https://skmtc.dev/speakai/apis/speak-ai-api/revisions/52d777e6d46e?raw)
