---
title: "Assign or release"
method: POST
path: "/conversations/{id}/assign"
tags: ["Inbox"]
---

# Assign or release

`POST /conversations/{id}/assign`

## Request

- Base URL: `https://rcs-templates-api-dot-msg2ai-server.ue.r.appspot.com/api/agent`
- URL: `https://rcs-templates-api-dot-msg2ai-server.ue.r.appspot.com/api/agent/conversations/{id}/assign`
- Auth: HTTP bearer

Give a thread an owner, or release it back to the pool by passing a null user id. The assignee is a bare user id and is not checked against the org roster, so a stale id degrades visibly to “assigned to someone who left” rather than failing the write.

## Path parameters

- `id` string, required

## Request body

- object
  - `userId` string, nullable, required: Clerk user id to hand the thread to; null releases it.

## Response `200`

Success.

- object

## Other responses

- `400`: Arguments failed validation.
- `401`: Missing or invalid agent key.
- `403`: Key does not hold the conversations:write scope.
- `429`: Rate limited.

---

[API](https://skmtc.dev/wa-campaigns/apis/whatsapp-campaigns-agent-gateway.md) · [All operations](https://skmtc.dev/wa-campaigns/apis/whatsapp-campaigns-agent-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/wa-campaigns/apis/whatsapp-campaigns-agent-gateway/revisions/24503d56cc7b?raw)
