> For the complete documentation index, see [llms.txt](https://docs.validationcloud.io/v1/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.validationcloud.io/v1/berachain/execution-api/eth_unsubscribe.md).

# eth\_unsubscribe

Cancels an existing subscription so that no further events are sent.

This method will use `10` [Compute Units](/v1/about/billing.md).

***

## **Parameters**

`subscription name` - **string, same as previously returned from an** [eth\_subscribe](/v1/ethereum/execution-api/eth_subscribe.md) **call**

```json
params: [
  "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
]
```

## Returns

`true` if a subscription was successfully cancelled, or `false` if no subscription existed with the given ID.

```json
// Result
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": true
}
```

{% tabs %}
{% tab title="mainnet" %}

```bash
wscat -c wss:///mainnet.berachain.validationcloud.io/v1/wss/<YOUR_API_KEY_HERE>
# wait for connection

# example request
{"jsonrpc":  "2.0",  "id":  1,  "method":"eth_subscribe","params":["newHeads"]}
# example result
{"jsonrpc":"2.0","result":"0x4327e562d202d98983a2ee341409f09e","id":1}

## subscription data
{"id": 1, "jsonrpc":  "2.0", "method": "eth_unsubscribe", "params": ["0x4327e562d202d98983a2ee341409f09e"]}
{"jsonrpc":"2.0","result":true,"id":1}
```

{% endtab %}

{% tab title="testnet" %}

```bash
wscat -c wss:///bepolia.berachain.validationcloud.io/v1/wss/<YOUR_API_KEY_HERE>
# wait for connection

# example request
{"jsonrpc":  "2.0",  "id":  1,  "method":"eth_subscribe","params":["newHeads"]}
# example result
{"jsonrpc":"2.0","result":"0x4327e562d202d98983a2ee341409f09e","id":1}

## subscription data
{"id": 1, "jsonrpc":  "2.0", "method": "eth_unsubscribe", "params": ["0x4327e562d202d98983a2ee341409f09e"]}
{"jsonrpc":"2.0","result":true,"id":1}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.validationcloud.io/v1/berachain/execution-api/eth_unsubscribe.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
