# PgPubSub.isActive() method · @imqueue/pg-pubsub

Source: https://imqueue.org/api/pg-pubsub/latest/pg-pubsub.pgpubsub.isactive/
Published: 2026-08-01
Author: @imqueue maintainers (https://github.com/imqueue)
Package: @imqueue/pg-pubsub 3.0.5 — generated reference, not hand-written

If channel argument passed will return true if channel is in active state (listening by this pub/sub), false - otherwise. If channel is not specified - will return true if there is at least one active channel listened by this pub/sub, false - otherwise.

**Signature:**

```typescript
isActive(channel?: string): boolean;
```

## Parameters


| Parameter | Type | Description |
| --- | --- | --- |
| channel | string | _(Optional)_ channel to test; omit to test the connection as a whole |


**Returns:**

boolean

