> ## Documentation Index
> Fetch the complete documentation index at: https://www.helius.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# accountUnsubscribe

> Dừng nhận thông báo thay đổi tài khoản Solana qua WebSocket. Hủy luồng accountSubscribe bằng cách truyền ID của luồng đó vào accountUnsubscribe.

## Endpoint

WebSocket khả dụng trên mainnet và devnet với các URL sau:

* **Mainnet** `wss://mainnet.helius-rpc.com/?api-key=<api-key>`
* **Devnet** `wss://devnet.helius-rpc.com/?api-key=<api-key>`

<Note>WebSocket có bộ hẹn giờ ngắt kết nối sau 10 phút không hoạt động. Bạn nên triển khai kiểm tra trạng thái và gửi ping mỗi phút để duy trì kết nối WebSocket.</Note>

## Xác thực

<ParamField query="api-key" type="string" required>
  Khóa API Helius của bạn. Bạn có thể nhận khóa miễn phí trong [bảng điều khiển](https://dashboard.helius.dev/api-keys).
</ParamField>

## Nội dung

<ParamField body="params" type="array" required>
  <Expandable title="properties" defaultOpen>
    <ParamField body="subscriptionId" type="integer" required>
      ID đăng ký cần hủy.
    </ParamField>
  </Expandable>
</ParamField>

## Phản hồi

<ResponseField name="result" type="boolean">
  Thông báo hủy đăng ký thành công.
</ResponseField>

<RequestExample>
  ```json Request theme={"system"}
  {
    "jsonrpc": "2.0",
    "id": 1,
    "method": "accountUnsubscribe",
    "params": [
      23784
    ]
  }
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={"system"}
  {
    "jsonrpc": "2.0",
    "result": true,
    "id": 1
  }
  ```
</ResponseExample>
