# Mongoose

`class` in `plugin-mongoose` · v0.1.4

<https://docs.seedcord.org/packages/plugin-mongoose/0.1.4/classes/mongoose>

MongoDB integration plugin for Seedcord.

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

```ts
class Mongoose extends Plugin<{
    transport: "any";
    runtime: "server";
}>
```

## Constructors

### constructor

```ts
Mongoose(host: CoreBase, options: MongooseOptions)
```

Constructs a new instance of the `Mongoose` class

## Properties

### connection

```ts
public connection: Mongoose
```

Exposed Mongoose instance once `init` completes.

### runtime

```ts
public runtime: 'server'
```

### services

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

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

### transport

```ts
public transport: 'any'
```

## Methods

### dispose

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

### init

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