Wallet¶
充值配置 / 地址 / 历史(只读)与提现申请 / 历史。
提现(POST …/withdraw/apply)为写操作(需 Wallet 权限)。
Pepperstone Crypto Public OpenAPI — Wallet 1.0.0¶
Pepperstone Crypto 公开 REST API。
需鉴权的接口使用 HMAC。签名规则见开发者文档「鉴权」章节。WebSocket 行情与私有流另见 WebSocket 文档。除另行说明外,时间均为 UTC 毫秒。
Servers¶
| Description | URL |
|---|---|
| Production | https://api.pcrypto.com |
Wallet¶
GET /openapi/wallet/v1/config/getall¶
获取钱包资产配置
Description
所需类型:钱包(GET 亦接受 Read only)
输入参数
| 参数 | 位置 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|---|
x-ptrader-apikey |
header | string | 是 | API Key。 | |
recvWindow |
query | integer | 否 | 5000 |
请求有效时间窗(毫秒),范围 1–60000。 |
signature |
query | string | 是 | HMAC-SHA256 签名(十六进制)。见「鉴权 → HMAC 签名」。 | |
timestamp |
query | integer | 是 | 请求时间戳(Unix 毫秒)。 |
GET /openapi/wallet/v1/config/getallcurl -sS -X GET 'https://api.pcrypto.com/openapi/wallet/v1/config/getall?recvWindow=5000&signature={signature}×tamp={ts}' \
-H 'x-ptrader-apikey: {apiKey}'[
{
"coin": "BTC",
"name": "Bitcoin",
"depositAllEnable": true,
"withdrawAllEnable": true,
"free": "0",
"locked": "0",
"legalMoney": false,
"transferPrecision": 8,
"transferMinQuantity": "0.00001",
"networkList": [
{
"addressRegex": "^(bc1|[13])[a-zA-HJ-NP-Z0-9]{25,39}$",
"memoRegex": "",
"isNeedMemo": false,
"network": "BTC",
"name": "Bitcoin",
"depositEnable": true,
"minConfirm": 1,
"unLockConfirm": 2,
"withdrawDesc": "",
"withdrawEnable": true,
"withdrawFee": "0.0005",
"withdrawIntegerMultiple": "0.00000001",
"withdrawMax": "100",
"withdrawMin": "0.001",
"minDepositAmount": "0.0001",
"sameAddress": false,
"displayName": "Bitcoin",
"defaultFlag": true,
"logoUrl": ""
}
]
}
]Responses
Success
Response fields
Array of WalletAssetConfig:
Wallet asset configuration. The boolean field name is legalMoney.
| Name | Type | Description |
|---|---|---|
coin |
string | |
depositAllEnable |
boolean | |
free |
string | Decimal string. |
legalMoney |
boolean | |
locked |
string | Decimal string. |
name |
string | |
networkList |
Array<TokenNetworkInfo> | |
transferMinQuantity |
string | Decimal string. |
transferPrecision |
integer | |
withdrawAllEnable |
boolean |
rate_limited
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
GET /openapi/wallet/v1/deposit/address¶
获取充值地址
Description
所需类型:钱包(GET 亦接受 Read only)
输入参数
| 参数 | 位置 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|---|
x-ptrader-apikey |
header | string | 是 | API Key。 | |
coin |
query | string | 是 | ||
network |
query | string | 是 | ||
recvWindow |
query | integer | 否 | 5000 |
请求有效时间窗(毫秒),范围 1–60000。 |
signature |
query | string | 是 | HMAC-SHA256 签名(十六进制)。见「鉴权 → HMAC 签名」。 | |
timestamp |
query | integer | 是 | 请求时间戳(Unix 毫秒)。 |
GET /openapi/wallet/v1/deposit/addresscurl -sS -X GET 'https://api.pcrypto.com/openapi/wallet/v1/deposit/address?coin=USDT&network=TRC20&recvWindow=5000&signature={signature}×tamp={ts}' \
-H 'x-ptrader-apikey: {apiKey}'{
"coin": "USDT",
"address": "0x1a2b3c4d5e6f7890abcdef1234567890abcdef12",
"addressTag": ""
}Responses
Success
Response fields
Deposit address for a coin/network.
| Name | Type | Description |
|---|---|---|
address |
string | |
addressTag |
string | |
coin |
string |
missing_parameter
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
rate_limited
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
GET /openapi/wallet/v1/deposit/addresses¶
列出充值地址
Description
所需类型:钱包(GET 亦接受 Read only)
Returns every deposit address this account has generated, one row per (coin, network), keeping the earliest open address for each pair. Unlike GET /openapi/wallet/v1/deposit/address, this endpoint does not allocate a new address and takes no coin / network query parameters.
输入参数
| 参数 | 位置 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|---|
x-ptrader-apikey |
header | string | 是 | API Key。 | |
recvWindow |
query | integer | 否 | 5000 |
请求有效时间窗(毫秒),范围 1–60000。 |
signature |
query | string | 是 | HMAC-SHA256 签名(十六进制)。见「鉴权 → HMAC 签名」。 | |
timestamp |
query | integer | 是 | 请求时间戳(Unix 毫秒)。 |
GET /openapi/wallet/v1/deposit/addressescurl -sS -X GET 'https://api.pcrypto.com/openapi/wallet/v1/deposit/addresses?recvWindow=5000&signature={signature}×tamp={ts}' \
-H 'x-ptrader-apikey: {apiKey}'[
{
"address": "0x1a2b3c4d5e6f7890abcdef1234567890abcdef12",
"assetName": "ETH",
"network": "ETH",
"networkName": "Ethereum",
"tag": "",
"minDeposit": "0.01"
},
{
"address": "rXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"assetName": "XRP",
"network": "XRP",
"networkName": "Ripple",
"tag": "12345",
"minDeposit": "1"
}
]Responses
Success
Response fields
Array of ListAllAddresses:
Deposit addresses (one row per coin+network).
| Name | Type | Description |
|---|---|---|
address |
string | |
assetName |
string | Coin / asset symbol (e.g. ETH, USDT). |
minDeposit |
number | Minimum deposit for this coin+network as a JSON number; 0 when unset. |
network |
string | Network code (e.g. ETH, TRC20). |
networkName |
string | Display name from network config when available; otherwise the network code. |
tag |
string | Memo / destination tag when the network requires one; may be null or empty. |
rate_limited
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
GET /openapi/wallet/v1/deposit/history¶
查询充值历史
Description
所需类型:钱包(GET 亦接受 Read only)
输入参数
| 参数 | 位置 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|---|
x-ptrader-apikey |
header | string | 是 | API Key。 | |
coin |
query | string | 否 | ||
limit |
query | integer | 否 | 1000 |
返回条数,范围 1–1000。 |
recvWindow |
query | integer | 否 | 5000 |
请求有效时间窗(毫秒),范围 1–60000。 |
signature |
query | string | 是 | HMAC-SHA256 签名(十六进制)。见「鉴权 → HMAC 签名」。 | |
timestamp |
query | integer | 是 | 请求时间戳(Unix 毫秒)。 |
GET /openapi/wallet/v1/deposit/historycurl -sS -X GET 'https://api.pcrypto.com/openapi/wallet/v1/deposit/history?coin=USDT&limit=20&recvWindow=5000&signature={signature}×tamp={ts}' \
-H 'x-ptrader-apikey: {apiKey}'[
{
"id": "dep-1001",
"coin": "USDT",
"network": "ETH",
"address": "0x1a2b3c4d5e6f7890abcdef1234567890abcdef12",
"addressTag": "",
"txId": "0xabc123",
"amount": "100",
"status": 1,
"insertTime": 1713100000000,
"confirmNo": 12
}
]Responses
Success
Response fields
Array of DepositRecord:
| Name | Type | Description |
|---|---|---|
address |
string | |
addressTag |
string | |
amount |
number | Decimal amount as a JSON number (BigDecimal on the wire). |
coin |
string | |
confirmNo |
integer | |
id |
string | |
insertTime |
integer(int64) | |
network |
string | |
status |
integer | |
txId |
string |
invalid_parameter
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
rate_limited
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
POST /openapi/wallet/v1/withdraw/apply¶
申请提现
Description
所需类型:钱包
提交提现申请。JSON body 必填:coin、network、address、amount;可选:addressTag、withdrawOrderId。HMAC 签名覆盖 query 的 timestamp/signature 与紧凑 JSON body。
输入参数
| 参数 | 位置 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|---|
x-ptrader-apikey |
header | string | 是 | API Key。 | |
recvWindow |
query | integer | 否 | 5000 |
请求有效时间窗(毫秒),范围 1–60000。 |
signature |
query | string | 是 | HMAC-SHA256 签名(十六进制)。见「鉴权 → HMAC 签名」。 | |
timestamp |
query | integer | 是 | 请求时间戳(Unix 毫秒)。 |
Request body
| Name | Type | Description |
|---|---|---|
address |
string | Destination address. |
addressTag |
string | Optional memo / destination tag when the network requires one. |
amount |
string | Withdraw amount as a decimal string (must be greater than 0). |
coin |
string | Asset symbol to withdraw (e.g. `USDT`). |
network |
string | Network code (e.g. `TRC20`, `ETH`). |
withdrawOrderId |
string | Optional client-side withdraw id for idempotency (max 64 chars). |
POST /openapi/wallet/v1/withdraw/applycurl -sS -X POST 'https://api.pcrypto.com/openapi/wallet/v1/withdraw/apply?recvWindow=5000&signature={signature}×tamp={ts}' \
-H 'x-ptrader-apikey: {apiKey}'{
"id": "wd-1001"
}Responses
Success
Response fields
| Name | Type | Description |
|---|---|---|
id |
string |
missing_parameter
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
rate_limited
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
GET /openapi/wallet/v1/withdraw/history¶
查询提现历史
Description
所需类型:钱包(GET 亦接受 Read only)
输入参数
| 参数 | 位置 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|---|
x-ptrader-apikey |
header | string | 是 | API Key。 | |
coin |
query | string | 否 | ||
limit |
query | integer | 否 | 1000 |
返回条数,范围 1–1000。 |
recvWindow |
query | integer | 否 | 5000 |
请求有效时间窗(毫秒),范围 1–60000。 |
signature |
query | string | 是 | HMAC-SHA256 签名(十六进制)。见「鉴权 → HMAC 签名」。 | |
timestamp |
query | integer | 是 | 请求时间戳(Unix 毫秒)。 |
GET /openapi/wallet/v1/withdraw/historycurl -sS -X GET 'https://api.pcrypto.com/openapi/wallet/v1/withdraw/history?coin=USDT&limit=20&recvWindow=5000&signature={signature}×tamp={ts}' \
-H 'x-ptrader-apikey: {apiKey}'[
{
"id": "wd-1001",
"coin": "USDT",
"address": "0x1a2b3c4d5e6f7890abcdef1234567890abcdef12",
"addressTag": "",
"txId": "0xdef456",
"network": "ETH",
"withdrawOrderId": "client-wd-1",
"info": "",
"amount": "50",
"transactionFee": "1",
"status": 6,
"confirmNo": 12,
"applyTime": 1713100000000
}
]Responses
Success
Response fields
Array of WithdrawRecord:
| Name | Type | Description |
|---|---|---|
address |
string | |
addressTag |
string | |
amount |
number | Decimal amount as a JSON number (BigDecimal on the wire). |
applyTime |
integer(int64) | |
coin |
string | |
confirmNo |
integer | |
id |
string | |
info |
string | |
network |
string | |
status |
integer | |
transactionFee |
number | Decimal amount as a JSON number (BigDecimal on the wire). |
txId |
string | |
withdrawOrderId |
string |
invalid_parameter
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
rate_limited
Response fields
Error payload. Most API errors (including auth failures such as -1002) return HTTP 200 — see Error codes → HTTP status mapping. HTTP 400 for missing or invalid request parameters. HTTP 429 when rate limited.
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
Schemas¶
DepositAddress¶
| Name | Type | Description |
|---|---|---|
address |
string | |
addressTag |
string | |
coin |
string |
DepositRecord¶
| Name | Type | Description |
|---|---|---|
address |
string | |
addressTag |
string | |
amount |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
coin |
string | |
confirmNo |
integer | |
id |
string | |
insertTime |
integer(int64) | |
network |
string | |
status |
integer | |
txId |
string |
ErrorBody¶
| Name | Type | Description |
|---|---|---|
code |
integer | |
msg |
string |
ListAllAddresses¶
| Name | Type | Description |
|---|---|---|
address |
string | |
assetName |
string | Coin / asset symbol (e.g. ETH, USDT). |
minDeposit |
number | Minimum deposit for this coin+network as a JSON number; `0` when unset. |
network |
string | Network code (e.g. ETH, TRC20). |
networkName |
string | Display name from network config when available; otherwise the network code. |
tag |
string | Memo / destination tag when the network requires one; may be null or empty. |
TokenNetworkInfo¶
| Name | Type | Description |
|---|---|---|
addressRegex |
string | |
defaultFlag |
boolean | |
depositEnable |
boolean | |
displayName |
string | |
isNeedMemo |
boolean | |
logoUrl |
string | |
memoRegex |
string | |
minConfirm |
integer | |
minDepositAmount |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
name |
string | |
network |
string | |
sameAddress |
boolean | |
unLockConfirm |
integer | |
withdrawDesc |
string | |
withdrawEnable |
boolean | |
withdrawFee |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
withdrawIntegerMultiple |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
withdrawMax |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
withdrawMin |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
WalletAssetConfig¶
| Name | Type | Description |
|---|---|---|
coin |
string | |
depositAllEnable |
boolean | |
free |
string | Decimal string. |
legalMoney |
boolean | |
locked |
string | Decimal string. |
name |
string | |
networkList |
Array<TokenNetworkInfo> | |
transferMinQuantity |
string | Decimal string. |
transferPrecision |
integer | |
withdrawAllEnable |
boolean |
WithdrawApply¶
| Name | Type | Description |
|---|---|---|
id |
string |
WithdrawApplyRequest¶
| Name | Type | Description |
|---|---|---|
address |
string | Destination address. |
addressTag |
string | Optional memo / destination tag when the network requires one. |
amount |
string | Withdraw amount as a decimal string (must be greater than 0). |
coin |
string | Asset symbol to withdraw (e.g. `USDT`). |
network |
string | Network code (e.g. `TRC20`, `ETH`). |
withdrawOrderId |
string | Optional client-side withdraw id for idempotency (max 64 chars). |
WithdrawRecord¶
| Name | Type | Description |
|---|---|---|
address |
string | |
addressTag |
string | |
amount |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
applyTime |
integer(int64) | |
coin |
string | |
confirmNo |
integer | |
id |
string | |
info |
string | |
network |
string | |
status |
integer | |
transactionFee |
number | Decimal amount as a JSON number (`BigDecimal` on the wire). |
txId |
string | |
withdrawOrderId |
string |
Security schemes¶
| Name | Type | Scheme | Description |
|---|---|---|---|
| ApiKeyHmac | apiKey | 需要请求头 `x-ptrader-apikey`,以及 `timestamp` 与 `signature`。签名规则见「鉴权」文档。 | |
| ApiKeyOnly | apiKey | 仅需 API Key 请求头(无需 HMAC)。用于 listenKey 的创建、续期与关闭。 |
Tags¶
| Name | Description |
|---|---|
| Wallet |