# Logger

`class` in `services` · v0.7.1

<https://docs.seedcord.org/packages/services/0.7.1/classes/logger>

Public logging service with channel-aware transports and per-run file output.

- Channel separation (e.g., bot, cli, hmr) - Production-safe JSON logs with ANSI stripping - Unique log files per run via filename templates

```ts
class Logger implements ILogger
```

## Constructors

### constructor

```ts
Logger(label: string, options?: LoggerOptions)
```

Creates a new Logger instance.

## Properties

### utils

```ts
public readonly utils: LoggerUtilities
```

## Methods

### configure

```ts
public static configure(
    config: Partial<LoggerConfiguration>
): void
```

Configures global logger settings.

Applies configuration to all channels and clears instance cache.

### debug

```ts
public debug(
    msg: string,
    args: unknown[]
): void
```

Logs a debug message with optional additional data.

### error

```ts
public error(
    msg: string,
    args: unknown[]
): void
```

Logs an error message with optional additional data.

### http

```ts
public http(
    msg: string,
    args: unknown[]
): void
```

Logs an HTTP-related message with optional additional data.

### inChannel

```ts
public inChannel(channel: string): Logger
```

Returns a new Logger instance configured for the specified channel. Loggers are cached per (label, channel) pair.

### info

```ts
public info(
    msg: string,
    args: unknown[]
): void
```

Logs an informational message with optional additional data.

### setChannel

```ts
public setChannel(channel: string): void
```

Switches this logger to a different channel.

### silly

```ts
public silly(
    msg: string,
    args: unknown[]
): void
```

Logs a silly/trace level message with optional additional data.

### verbose

```ts
public verbose(
    msg: string,
    args: unknown[]
): void
```

Logs a verbose message with optional additional data.

### warn

```ts
public warn(
    msg: string,
    args: unknown[]
): void
```

Logs a warning message with optional additional data.
