> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nemu.cc/llms.txt
> Use this file to discover all available pages before exploring further.

# Configs

> Store routing and workflow configs for a workspace

A config holds a workflow that decides how requests are handled inside a workspace. Configs
belong to a workspace, so pass `workspace_id` on reads and writes. Reads need `models:read`
and writes need `models:write`.

## List configs

```
GET /api/v1/configs?workspace_id=ws_1
```

<RequestExample>
  ```bash cURL theme={null}
  curl 'https://platform.nemu.cc/api/v1/configs?workspace_id=ws_1' \
    -H 'Authorization: Bearer <access_token>'
  ```

  ```ts SDK theme={null}
  const configs = await workspace.configs.list();
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "data": [
      {
        "id": "cfg_1",
        "workspace_id": "ws_1",
        "name": "default",
        "description": null,
        "enabled": true,
        "is_default": true,
        "workflow": {},
        "created_at": "2026-01-04T10:22:00.000Z",
        "updated_at": "2026-01-04T10:22:00.000Z"
      }
    ]
  }
  ```
</ResponseExample>

## Get a config

```
GET /api/v1/configs/{id}?workspace_id=ws_1
```

## Create a config

```
POST /api/v1/configs
```

<ParamField body="workspace_id" type="string" required>
  The workspace the config belongs to.
</ParamField>

<ParamField body="name" type="string" required>
  A name for the config.
</ParamField>

<ParamField body="description" type="string">
  A short description.
</ParamField>

<ParamField body="enabled" type="boolean">
  Whether the config is active.
</ParamField>

<ParamField body="is_default" type="boolean">
  Use this config when none is named.
</ParamField>

<ParamField body="workflow" type="object">
  The workflow graph. Defaults to an empty object.
</ParamField>

<RequestExample>
  ```ts SDK theme={null}
  const config = await workspace.configs.create({ name: "default" });
  ```
</RequestExample>

## Delete a config

```
DELETE /api/v1/configs/{id}
```

Edit a config's workflow in the console. The API supports listing, reading, creating, and
deleting configs.
