API REFERENCE / 永续合约
Gate 永续条件单列表与结束方式:参数、响应与查询工具
按状态与合约查询永续条件单,区分 initial 委托配置、trigger 条件和 finish_as 结果。
需要官方 API 鉴权固定规格 v4.106.132资料核对:2026-09-10
GET /futures/{settle}/price_orders这条查询解决什么问题
succeeded 描述条件单流程结果,实际成交仍需核对触发后生成的订单,不能以条件单结束状态替代成交确认。
这是账户数据查询文档。真实调用需要在你自己的可信环境完成官方鉴权;此页没有登录、密钥输入或账户连接功能。
查看官方英文说明
Query auto order list
此操作没有额外说明。
请求参数逐项核对
字段名和数据类型保留官方拼写。必填标记来自规格;描述中的条件约束还需要一起检查。
| 参数与位置 | 类型与范围 | 官方字段说明 |
|---|---|---|
settlepath · 必填 | string枚举:btc / usdt / usd1 | Perpetual futures settlement currency |
statusquery · 必填 | string枚举:open / finished | Query order list based on status |
contractquery · 可选 | string | Futures contract, return related data only if specified |
limitquery · 可选 | integer默认:100;最小:1;最大:1000 | Maximum number of records returned in a single list |
offsetquery · 可选 | integer默认:0;最小:0 | List offset, starting from 0 |
在本页组装查询 URL
填写参数后生成一个 GET 地址,只在浏览器本地处理。留空的可选项不会发送。请勿填写密码、API Key 或 Secret。
尚未生成 URL。
不会向 Gate 或本站发送表单内容。
工具检查必填、枚举与简单数值范围,不代替服务端校验。复合参数、时间窗口、条件必填等请对照上方原文。
响应字段怎样阅读
以下展示的是规格中的类型定义,不是现场 API 响应,也不是行情样本。嵌套结构展开至三层;数组的 [] 表示其中一个元素。
HTTP 200 · List retrieved successfully
| 字段路径 | 数据类型 | 字段说明 |
|---|---|---|
$ | array<object> | 未提供字段注释 |
$[] | object | Futures price-triggered order details |
$[].initial | object | 未提供字段注释 |
$[].initial.contract | string | Futures contract |
$[].initial.size | integer格式:"int64" | Represents the number of contracts that need to be closed, full closing: size=0
Partial closing: plan-close-short-position size>0
Partial closing: plan-close-long-position size<0 |
$[].initial.amount | string | Same as `size`; used for decimal contract size. When both `size` and `amount` are provided, `amount` takes precedence. |
$[].initial.price | string | Order price. Set to 0 to use market price |
$[].initial.close | boolean默认:false | When fully closing a position in single-position mode, close must be set to true to execute the close operation.
When partially closing a position in single-position mode or in dual-position mode, close can be left unset or set to false. |
$[].initial.tif | string默认:"gtc";枚举:gtc / ioc | Time in force strategy, default is gtc, market orders currently only support ioc mode
- gtc: GoodTillCancelled
- ioc: ImmediateOrCancelled |
$[].initial.text | string | The source of the order, including:
- web: Web
- api: API call
- app: Mobile app |
$[].initial.reduce_only | boolean默认:false | When set to true, perform automatic position reduction operation. Set to true to ensure that the order will not open a new position, and is only used to close or reduce positions |
$[].initial.auto_size | string | One-way Mode: auto_size is not required
Hedge Mode full closing (size=0): auto_size must be set, close_long for closing long positions, close_short for closing short positions
Hedge Mode partial closing (size≠0): auto_size is not required |
$[].initial.is_reduce_only | boolean | Is the order reduce-only |
$[].initial.is_close | boolean | Is the order to close position |
$[].trigger | object | 未提供字段注释 |
$[].trigger.strategy_type | integer格式:"int32";枚举:0 / 1 | Trigger Strategy
- 0: Price trigger, triggered when price meets conditions
- 1: Price spread trigger, i.e. the difference between the latest price specified in `price_type` and the second-last price
Currently only supports 0 (latest transaction price) |
$[].trigger.price_type | integer格式:"int32";枚举:0 / 1 / 2 | Reference price type. 0 - Latest trade price, 1 - Mark price, 2 - Index price |
$[].trigger.price | string | Price value for price trigger, or spread value for spread trigger |
$[].trigger.rule | integer格式:"int32";枚举:1 / 2 | Price Condition Type
- 1: Trigger when the price calculated based on `strategy_type` and `price_type` is greater than or equal to `Trigger.Price`, while Trigger.Price must > last_price
- 2: Trigger when the price calculated based on `strategy_type` and `price_type` is less than or equal to `Trigger.Price`, and Trigger.Price must < last_price |
$[].trigger.expiration | integer | Maximum wait time for trigger condition (in seconds). Order will be cancelled if timeout |
$[].id | integer格式:"int64" | Auto order ID |
$[].id_string | string | String form of the auto order ID; the same order as numeric `id`, as the decimal string of `id` to avoid int64 precision loss in JavaScript and similar environments.
Prefer this field to display the order ID or when a string unique identifier is needed; one-to-one with `id`. Same meaning as the field of the same name in futures price-trigger REST APIs and in `futures.orders` / `futures.autoorders` WebSocket pushes. |
$[].user | integer | User ID |
$[].create_time | number格式:"double" | Created time |
$[].finish_time | number格式:"double" | End time |
$[].trade_id | integer格式:"int64" | ID of the order created after trigger |
$[].status | string枚举:open / finished / inactive / invalid | Order status
- `open`: Active
- `finished`: Finished
- `inactive`: Inactive, only applies to order take-profit/stop-loss
- `invalid`: Invalid, only applies to order take-profit/stop-loss |
$[].finish_as | string枚举:cancelled / succeeded / failed / expired | Finish status: cancelled - Cancelled; succeeded - Succeeded; failed - Failed; expired - Expired |
$[].reason | string | Additional description of how the order was completed |
$[].order_type | string | Types of take-profit and stop-loss orders, including:
- `close-long-order`: Order take-profit/stop-loss, close long position
- `close-short-order`: Order take-profit/stop-loss, close short position
- `close-long-position`: Position take-profit/stop-loss, used to close all long positions
- `close-short-position`: Position take-profit/stop-loss, used to close all short positions
- `plan-close-long-position`: Position plan take-profit/stop-loss, used to close all or partial long positions
- `plan-close-short-position`: Position plan take-profit/stop-loss, used to close all or partial short positions
The two types of order take-profit/stop-loss are read-only and cannot be passed in requests |
$[].me_order_id | integer格式:"int64" | Corresponding order ID for order take-profit/stop-loss orders |
$[].pos_margin_mode | string枚举:isolated / cross | Position margin mode: `isolated` (isolated margin) or `cross` (cross margin).
Returned by the server in simple split-position mode; when writing, use only the values below. |
来源、版本与使用说明
本站独立整理 Gate 技术资料,不代表 Gate,不提供账户、交易、充值或软件下载服务。
参数和字段改编自 Gate 官方 SDK 的 Apache 2.0 开放规格,固定版本为 v4.106.132。核对时官网文档已为 v4.106.136,后续变更须以官网为准;本页并未声称对该接口做过在线实测。
中文用途解释、字段阅读界面和本地 URL 组装器由本站整理。访问日志用于站点运维;页面没有第三方统计脚本,表单参数仅在当前页面内存中处理。