---
title: "Unassign a managed OpenCode config"
method: POST
path: "/v1/org/opencode-config-assignments/remove"
tags: ["Agent Permissions"]
---

# Unassign a managed OpenCode config

`POST /v1/org/opencode-config-assignments/remove`

## Request

- Base URL: `https://api.openworklabs.com`
- URL: `https://api.openworklabs.com/v1/org/opencode-config-assignments/remove`
- Auth: one of:
  - API key in header `x-api-key`
  - HTTP bearer

Removes the config assigned to everyone, one team or one member. Members it no longer reaches go back to Agent permissions in full the next time their desktop app checks in. Removing an assignment that is not there answers not_assigned. Requires Managed OpenCode config and agent_permissions.manage with a recent sign-in.

## Request body

- ManagedOpencodeConfigUnassignRequest
  - `target` union, required
    - object
      - `everyone` true, required
    - object
      - `teamId` string, typeid, required: Den TypeID with 'tem_' prefix and a 26-character base32 suffix.
    - object
      - `memberId` string, typeid, required: Den TypeID with 'om_' prefix and a 26-character base32 suffix.

## Response `200`

Unassigned, or nothing was assigned.

- ManagedOpencodeConfigUnassignResponse
  - `result` 'unassigned' | 'not_assigned', required
  - `config` string, nullable, required

## Other responses

- `401`: Sign in required.
- `403`: The caller needs the agent_permissions.manage permission and a recent sign-in.
- `404`: Managed OpenCode config is off, or the config, team or member is not in this organization.

## Changes

- **2026-12-01** `418545ae8367`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/openworklabs/apis/den-api/changes/v1/org/opencode-config-assignments/remove/post.md)

---

[API](https://skmtc.dev/openworklabs/apis/den-api.md) - [All operations](https://skmtc.dev/openworklabs/apis/den-api/llms.txt) - [OpenAPI document](https://skmtc.dev/openworklabs/apis/den-api/revisions/84fb0f99fb95?raw)
