---
updatedAt: 2026-09-30T03:41:03.000Z
agentTools:
  projectIndex: https://cn.developers.tron.network/llms.txt
---

# CancelAllUnfreezeV2

一次性取消所有进行中的 Stake 2.0 解质押——未到期的回滚为质押，已到期的自动提取到账户。

> 📘 **两类资金的不同结局**
>
> * **仍在等待期内的解质押资金** → **重新质押**，获得的资源与原先完全一致（不能取消已到期资金）
> * **已经到期的解质押资金** → **无法取消，自动提取到账户余额**
>
> 可通过 [GetTransactionInfoById](https://cn.developers.tron.network/reference/gettransactioninfobyid) 查询本次交易的 `cancel_unfreezeV2_amount`（取消量）和 `withdraw_expire_amount`（自动提取量）。

> ⚠️ **链参数 `#77` 激活要求**
>
> 本接口受链参数 `#77 getAllowCancelAllUnfreezeV2` 控制，需主网通过提案启用后才可用。以 `wallet/getchainparameters` 查询实时状态。

***

## 相关资源

* [UnfreezeBalanceV2](https://cn.developers.tron.network/reference/unfreezebalancev2-1) —— 发起单笔解质押（本接口的反向）
* [WithdrawExpireUnfreeze](https://cn.developers.tron.network/reference/withdrawexpireunfreeze) —— 主动提取已到期解质押资金
* [GetAvailableUnfreezeCount](https://cn.developers.tron.network/reference/getavailableunfreezecount-1) —— 查询取消前的进行中解质押数
* [解质押](https://cn.developers.tron.network/docs/unstaking) —— 取消机制的详细语义

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "全节点 HTTP API",
    "version": "4.8.0"
  },
  "servers": [
    {
      "url": "https://api.shasta.trongrid.io",
      "description": "Shasta 测试网"
    },
    {
      "url": "https://nile.trongrid.io",
      "description": "Nile 测试网"
    },
    {
      "url": "https://api.trongrid.io",
      "description": "TRON 主网（真实资产）"
    }
  ],
  "components": {
    "schemas": {
      "NodeHttpBusinessError": {
        "title": "错误信息",
        "type": "object",
        "description": "请求处理发生异常时，java-tron 可能随 HTTP 200 返回此格式；具体错误信息位于 `Error` 字段。",
        "required": [
          "Error"
        ],
        "properties": {
          "Error": {
            "type": "string",
            "description": "java-tron 返回的错误信息。"
          }
        },
        "examples": [
          {
            "Error": "Invalid request parameters."
          }
        ],
        "additionalProperties": false
      }
    }
  },
  "security": [
    {}
  ],
  "paths": {
    "/wallet/cancelallunfreezev2": {
      "post": {
        "summary": "CancelAllUnfreezeV2",
        "description": "取消解质押操作，仍处于等待期的全部解质押资金将重新质押；已经到期的解质押资金将自动提取至账户所有者的账户。等待期由链参数 #70 `getUnfreezeDelayDays` 决定。",
        "operationId": "cancelallunfreezev2",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "owner_address": {
                    "type": "string",
                    "description": "交易发起方地址。（格式：Base58 或十六进制）",
                    "default": ""
                  },
                  "Permission_id": {
                    "type": "integer",
                    "description": "可选。用于多签账户操作的权限 ID，未指定时默认使用 owner 权限（0）。",
                    "format": "int32"
                  },
                  "visible": {
                    "type": "boolean",
                    "description": "可选。设为 `true` 时地址以 Base58 格式返回；设为 `false` 时以十六进制格式返回。（默认值：`false`）",
                    "default": "false"
                  }
                },
                "required": [
                  "owner_address"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "请求正常完成时，响应体为接口返回结果；请求处理发生异常时，HTTP 状态仍可能为 200，此时仅返回包含 `Error` 字段的错误信息。",
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "title": "返回结果",
                      "not": {
                        "type": "object",
                        "required": [
                          "Error"
                        ]
                      },
                      "type": "object",
                      "properties": {
                        "owner_address": {
                          "type": "string",
                          "description": "交易发起方地址。（格式：Base58 或十六进制）"
                        }
                      }
                    },
                    {
                      "$ref": "#/components/schemas/NodeHttpBusinessError"
                    }
                  ]
                },
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        },
        "deprecated": false,
        "security": []
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```