# ImqueueInstrumentation.unpatch() method · @imqueue/opentelemetry

Source: https://imqueue.org/api/opentelemetry/latest/opentelemetry.imqueueinstrumentation.unpatch/
Published: 2026-08-01
Author: @imqueue maintainers (https://github.com/imqueue)
Package: @imqueue/opentelemetry 4.0.0 — generated reference, not hand-written

Removes the tracing hooks previously attached by [ImqueueInstrumentation.patch()](https://imqueue.org/api/opentelemetry/latest/opentelemetry.imqueueinstrumentation.patch/).

**Signature:**

```typescript
unpatch(rpc: RpcModule): RpcModule;
```

## Parameters


| Parameter | Type | Description |
| --- | --- | --- |
| rpc | [RpcModule](https://imqueue.org/api/opentelemetry/latest/opentelemetry.rpcmodule/) | module to remove the hooks from |


**Returns:**

[RpcModule](https://imqueue.org/api/opentelemetry/latest/opentelemetry.rpcmodule/)

the same object, hooks removed in place

## Remarks

Deletes the three hook properties outright rather than restoring whatever was there before, so a `beforeCall` the application had set itself is lost too. In practice the defaults are empty, but do not use this to toggle tracing on a module you also hook yourself.

