# Mongo

`class` in `plugins` · v0.6.1

<https://docs.seedcord.org/packages/plugins/0.6.1/classes/mongo>

MongoDB integration plugin for Seedcord.

Manages MongoDB connections, service loading, and provides type-safe access to database services through service registration decorators.

```ts
class Mongo extends Plugin
```

## Constructors

### constructor

```ts
Mongo(core: Core, options: MongoOptions)
```

Constructs a new instance of the `Mongo` class

## Properties

### connection

```ts
public connection: Mongoose
```

Exposed Mongoose instance once `init` completes.

### core

```ts
public readonly core: Core
```

### logger

```ts
public readonly logger: Logger
```

### services

```ts
public get services(): MongoServices
```

Map of all loaded services. Keys come from `@RegisterMongoService('key')`.

## Methods

### init

```ts
public async init(): Promise<void>
```

### stop

```ts
public async stop(): Promise<void>
```
