# social.colibri.beta.channel.update

> Published by [colibri.social](https://lexicon.garden/identity/did:plc:mprdjqjluoswa7awzggaggj3)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.channel.update)
- [Documentation](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.channel.update/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.channel.update/examples)

## Definitions

### `social.colibri.beta.channel.update`

**Type**: `procedure`

Updates a channel's configuration. An absent field leaves the current value unchanged.

#### Input

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `name` | `string` | No | The channel's name. Absent leaves the current value unchanged. |
| `channel` | `string` (space-ref) | Yes | The channel to update. |
| `category` | `string` (record-key) | No | The category to move the channel to. Absent leaves the current value unchanged. |
| `ownerOnly` | `boolean` | No | Whether only community admins may post. Absent leaves the current value unchanged. |
| `linkEmbeds` | `boolean` | No | Whether link previews are shown here. Absent leaves the current value unchanged. |
| `description` | `string` | No | The channel's topic. Absent leaves the current value unchanged. |
| `allowedRoles` | `array` | No | Roles allowed to post here. Absent leaves the current value unchanged. |
| `allowedMembers` | `array` | No | Members allowed to post here in addition to allowedRoles. Absent leaves the current value unchanged. |
| `visibleToRoles` | `array` | No | Roles that may read this channel. Empty means every member may. |
| `visibleToMembers` | `array` | No | Members that may read this channel beyond visibleToRoles. |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `channel` | `ref` → `social.colibri.beta.community.defs#channelView` | Yes | The channel, after the update. |

#### Errors

- **AuthRequired**: The request has no valid service auth.
- **Forbidden**: The requesting user lacks the channel.update permission.
- **ChannelNotFound**: No channel matches the given space reference.
- **CategoryNotFound**: No category matches the given record key.
- **RoleHierarchy**: The requesting user cannot grant a role that outranks their own.
- **CredentialsUnavailable**: The AppView cannot act as the community because its stored credentials are missing or unusable.

## Raw Schema

```json
{
  "id": "social.colibri.beta.channel.update",
  "defs": {
    "main": {
      "type": "procedure",
      "input": {
        "schema": {
          "type": "object",
          "required": [
            "channel"
          ],
          "properties": {
            "name": {
              "type": "string",
              "maxLength": 32,
              "minLength": 1,
              "description": "The channel's name. Absent leaves the current value unchanged."
            },
            "channel": {
              "type": "string",
              "format": "space-ref",
              "description": "The channel to update."
            },
            "category": {
              "type": "string",
              "format": "record-key",
              "description": "The category to move the channel to. Absent leaves the current value unchanged."
            },
            "ownerOnly": {
              "type": "boolean",
              "description": "Whether only community admins may post. Absent leaves the current value unchanged."
            },
            "linkEmbeds": {
              "type": "boolean",
              "description": "Whether link previews are shown here. Absent leaves the current value unchanged."
            },
            "description": {
              "type": "string",
              "maxLength": 256,
              "description": "The channel's topic. Absent leaves the current value unchanged."
            },
            "allowedRoles": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "record-key",
                "description": "A role permitted to post."
              },
              "description": "Roles allowed to post here. Absent leaves the current value unchanged."
            },
            "allowedMembers": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "did",
                "description": "A member permitted to post."
              },
              "description": "Members allowed to post here in addition to allowedRoles. Absent leaves the current value unchanged."
            },
            "visibleToRoles": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "record-key",
                "description": "A role."
              },
              "description": "Roles that may read this channel. Empty means every member may."
            },
            "visibleToMembers": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "did",
                "description": "A member."
              },
              "description": "Members that may read this channel beyond visibleToRoles."
            }
          }
        },
        "encoding": "application/json"
      },
      "errors": [
        {
          "name": "AuthRequired",
          "description": "The request has no valid service auth."
        },
        {
          "name": "Forbidden",
          "description": "The requesting user lacks the channel.update permission."
        },
        {
          "name": "ChannelNotFound",
          "description": "No channel matches the given space reference."
        },
        {
          "name": "CategoryNotFound",
          "description": "No category matches the given record key."
        },
        {
          "name": "RoleHierarchy",
          "description": "The requesting user cannot grant a role that outranks their own."
        },
        {
          "name": "CredentialsUnavailable",
          "description": "The AppView cannot act as the community because its stored credentials are missing or unusable."
        }
      ],
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "channel"
          ],
          "properties": {
            "channel": {
              "ref": "social.colibri.beta.community.defs#channelView",
              "type": "ref",
              "description": "The channel, after the update."
            }
          }
        },
        "encoding": "application/json"
      },
      "description": "Updates a channel's configuration. An absent field leaves the current value unchanged."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
