# Interface: community

> Reads and moderation, all checked by the host against the bot's grants and permissions.

Generated from `zaun:bot@0.2.0` (`wit/` in [zaun-bot](https://github.com/zaunchat/zaun-bot)). Do not edit.

Reads and moderation, all checked by the host against the bot's grants and permissions.

## Uses

- `use types.{id, host-error, member, channel, role, timestamp}`

## Functions

### `get-member`

```wit
get-member: func(member-id: id) -> result<member, host-error>;
```

Needs capability `members` for members the bot has not seen.

### `list-members`

```wit
list-members: func(after: option<id>, limit: u32) -> result<list<member>, host-error>;
```

### `get-channel`

```wit
get-channel: func(channel-id: id) -> result<channel, host-error>;
```

### `list-channels`

```wit
list-channels: func() -> result<list<channel>, host-error>;
```

### `get-role`

```wit
get-role: func(role-id: id) -> result<role, host-error>;
```

### `list-roles`

```wit
list-roles: func() -> result<list<role>, host-error>;
```

### `add-role`

```wit
add-role: func(member-id: id, role-id: id) -> result<_, host-error>;
```

`member.roles.update`.

### `remove-role`

```wit
remove-role: func(member-id: id, role-id: id) -> result<_, host-error>;
```

### `timeout`

```wit
timeout: func(member-id: id, until: option<timestamp>, reason: option<string>) -> result<_, host-error>;
```

`member.timeout`; `none` clears.

### `kick`

```wit
kick: func(member-id: id, reason: option<string>) -> result<_, host-error>;
```

`member.kick`.
