---
title: "Create use case with agent"
method: POST
path: "/api/v1/public/usecases/with-agent"
tags: ["public"]
---

# Create use case with agent

`POST /api/v1/public/usecases/with-agent`

Atomically create a workspace-owned use case and its voice agent as one idempotent operation.

## Headers

- `Idempotency-Key` string, required

## Request body

- CompoundUseCaseRequest
  - `name` string, required
  - `description` string, nullable
  - `purpose` string, nullable
  - `direction` 'OUTBOUND' | 'INBOUND' | 'ONE_WAY'
  - `agentName` string, required
  - `agentGender` 'MALE' | 'FEMALE'
  - `voiceId` string, nullable
  - `knowledgeBaseId` string, nullable
  - `integrations` string[]
  - `scheduleEnabled` boolean

## Response `201`

Successful Response

- CompoundUseCaseResult
  - `useCaseId` string, required
  - `useCaseName` string, required
  - `agentId` string, required
  - `agentName` string, required
  - `appUrl` string, required

## Other responses

- `422` — Validation Error

## Changes

- **2026-08-21** `2a1adc380310` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/outcallerai/apis/fastapi/changes/api/v1/public/usecases/with-agent/post.md)

---

[API](https://skmtc.dev/outcallerai/apis/fastapi.md) · [All operations](https://skmtc.dev/outcallerai/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/outcallerai/fastapi/revisions/6155db644bab/schema)
