> For the complete documentation index, see [llms.txt](https://www.pionex.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.pionex.com/docs/api-docs/institution-api/asset.md).

# Asset

On-chain currencies, withdrawals, and deposit/withdrawal history.

## List currencies and chains

> List supported currencies and their chains. This is a public/self endpoint\
> and does not take \`userId\`, but still requires a valid signature and the\
> \`read\` scope.<br>

```json
{"openapi":"3.0.3","info":{"title":"Pionex Institution Open API (v2)","version":"2.0.0"},"tags":[{"name":"Asset","description":"On-chain currencies, withdrawals, and deposit/withdrawal history."}],"servers":[{"url":"https://api.pionex.com","description":"Production"}],"security":[{"ApiKey":[],"Signature":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","in":"header","name":"X-APIKEY","description":"Your institution API Key, in the form `webot_xxxxxxxx`. Used to look up\nyour registered public key. Must be accompanied by the `X-Signature`\nheader. See the Authentication section for the full signing algorithm\n(RSA-PSS over SHA-256, or Ed25519) and the canonical-string construction.\n"}},"parameters":{"Timestamp":{"name":"timestamp","in":"query","required":true,"description":"Current time in **seconds** (Unix). Required on every signed request and\nparticipates in the signature. Must be within +/-5 seconds of server time.\n","schema":{"type":"integer","format":"int64"}}},"schemas":{"BaseResponse":{"type":"object","properties":{"result":{"type":"boolean","description":"Success indicator."},"timestamp":{"type":"integer","format":"int64","description":"Response timestamp in milliseconds."},"code":{"type":"string","description":"Error code (present only on failure)."},"message":{"type":"string","description":"Error message (present only on failure)."}}},"Currency":{"type":"object","properties":{"currency":{"type":"string"},"displayName":{"type":"string"},"fullName":{"type":"string"},"chainList":{"type":"array","items":{"$ref":"#/components/schemas/Chain"}}}},"Chain":{"type":"object","properties":{"chain":{"type":"string"},"txType":{"type":"string"},"depositEnable":{"type":"boolean"},"withdrawEnable":{"type":"boolean"},"depositMin":{"type":"string"},"withdrawMin":{"type":"string"},"withdrawMax":{"type":"string"},"withdrawFee":{"type":"string"},"hasTag":{"type":"boolean"},"confirm":{"type":"integer"},"withdrawPrecision":{"type":"integer"},"contractAddress":{"type":"string"},"walletType":{"type":"string"},"preConfirm":{"type":"integer"}}}},"responses":{"BadRequest":{"description":"Bad Request - the request body could not be read.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"Unauthorized":{"description":"Unauthorized - authentication failed (missing key, bad signature, etc.).","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"InternalError":{"description":"Internal or business error. Note that most business failures are returned\nas HTTP `200` with `result: false` and a `code`; this `500` covers\nserver-side internal errors.\n","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}}}},"paths":{"/api/v2/institution/asset/currencies":{"get":{"tags":["Asset"],"summary":"List currencies and chains","description":"List supported currencies and their chains. This is a public/self endpoint\nand does not take `userId`, but still requires a valid signature and the\n`read` scope.\n","operationId":"institutionAssetCurrencies","parameters":[{"$ref":"#/components/parameters/Timestamp"},{"name":"currency","in":"query","required":false,"description":"Filter by currency, max 60.","schema":{"type":"string","maxLength":60}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"},{"type":"object","properties":{"data":{"type":"object","properties":{"currencies":{"type":"array","items":{"$ref":"#/components/schemas/Currency"}}}}}}]}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/InternalError"}}}}}}
```

## Query a single on-chain withdrawal

> Query a single on-chain withdrawal by \`id\` or \`clientId\` (at least one\
> required).<br>

```json
{"openapi":"3.0.3","info":{"title":"Pionex Institution Open API (v2)","version":"2.0.0"},"tags":[{"name":"Asset","description":"On-chain currencies, withdrawals, and deposit/withdrawal history."}],"servers":[{"url":"https://api.pionex.com","description":"Production"}],"security":[{"ApiKey":[],"Signature":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","in":"header","name":"X-APIKEY","description":"Your institution API Key, in the form `webot_xxxxxxxx`. Used to look up\nyour registered public key. Must be accompanied by the `X-Signature`\nheader. See the Authentication section for the full signing algorithm\n(RSA-PSS over SHA-256, or Ed25519) and the canonical-string construction.\n"}},"parameters":{"Timestamp":{"name":"timestamp","in":"query","required":true,"description":"Current time in **seconds** (Unix). Required on every signed request and\nparticipates in the signature. Must be within +/-5 seconds of server time.\n","schema":{"type":"integer","format":"int64"}},"UserIdQueryRequired":{"name":"userId","in":"query","required":true,"description":"Target sub-account UUID. Participates in the signature.","schema":{"type":"string"}}},"schemas":{"BaseResponse":{"type":"object","properties":{"result":{"type":"boolean","description":"Success indicator."},"timestamp":{"type":"integer","format":"int64","description":"Response timestamp in milliseconds."},"code":{"type":"string","description":"Error code (present only on failure)."},"message":{"type":"string","description":"Error message (present only on failure)."}}},"AssetRecord":{"type":"object","properties":{"id":{"type":"string"},"clientId":{"type":"string"},"currency":{"type":"string"},"chain":{"type":"string"},"type":{"type":"string","enum":["deposit","withdraw"]},"internal":{"type":"boolean"},"address":{"type":"string"},"tag":{"type":"string"},"addressFrom":{"type":"string"},"tagFrom":{"type":"string"},"amount":{"type":"string"},"fee":{"type":"string"},"status":{"type":"string"},"hash":{"type":"string"},"confirmations":{"type":"integer"},"note":{"type":"string"},"approvalReason":{"type":"string"},"createTime":{"type":"integer","format":"int64"},"updateTime":{"type":"integer","format":"int64"}}}},"responses":{"BadRequest":{"description":"Bad Request - the request body could not be read.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"Unauthorized":{"description":"Unauthorized - authentication failed (missing key, bad signature, etc.).","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"InternalError":{"description":"Internal or business error. Note that most business failures are returned\nas HTTP `200` with `result: false` and a `code`; this `500` covers\nserver-side internal errors.\n","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}}}},"paths":{"/api/v2/institution/asset/withdraw":{"get":{"tags":["Asset"],"summary":"Query a single on-chain withdrawal","description":"Query a single on-chain withdrawal by `id` or `clientId` (at least one\nrequired).\n","operationId":"institutionAssetWithdrawGet","parameters":[{"$ref":"#/components/parameters/Timestamp"},{"$ref":"#/components/parameters/UserIdQueryRequired"},{"name":"id","in":"query","required":false,"description":"Withdrawal id, max 64. Provide `id` or `clientId`.","schema":{"type":"string","maxLength":64}},{"name":"clientId","in":"query","required":false,"description":"Client idempotency key, max 64. Provide `id` or `clientId`.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"},{"type":"object","properties":{"data":{"$ref":"#/components/schemas/AssetRecord"}}}]}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/InternalError"}}}}}}
```

## Create an on-chain withdrawal

> Create an on-chain withdrawal. The address whitelist must be enabled and\
> the address must be whitelisted (or in the address book, for sub-accounts).\
> \
> \*\*Errors:\*\*\
> \
> \| Error Code | Description |\
> \|------------|-------------|\
> \| \`P\_PAY\_OPEN\_API\_ACCOUNT\_FROZEN\` | Deposits/withdrawals frozen for this account. |\
> \| \`P\_PAY\_OPEN\_API\_KYC\_REQUIRED\` | KYC not completed or insufficient level. |\
> \| \`P\_PAY\_OPEN\_API\_REGION\_RESTRICTED\` | The operation is restricted in your region. |\
> \| \`P\_PAY\_OPEN\_API\_SIGN\_REJECTED\` | Security signature check failed. |\
> \| \`P\_PAY\_OPEN\_API\_OPERATION\_FORBIDDEN\` | Blocked after high-risk behavior; \`data\` contains \`restrict\_expired\_on\`, \`restrict\_ttl\`. |\
> \| \`P\_PAY\_OPEN\_API\_UNSUPPORTED\_CURRENCY\` | \`currency\` + \`chain\` combination unsupported. |\
> \| \`P\_PAY\_OPEN\_API\_WITHDRAW\_WHITELIST\_CLOSED\` | Address whitelist not enabled (mandatory for Open API). |\
> \| \`P\_PAY\_OPEN\_API\_WITHDRAW\_ADDRESS\_NOT\_WHITELISTED\` | Address not on the whitelist. |\
> \| \`P\_PAY\_OPEN\_API\_WITHDRAW\_ADDRESS\_NOT\_ALLOWED\` | Address not on the configured allow list. |\
> \| \`P\_PAY\_OPEN\_API\_WITHDRAW\_ADDRESS\_NOT\_IN\_ADDRESS\_BOOK\` | Sub-account address not in the address book. |<br>

```json
{"openapi":"3.0.3","info":{"title":"Pionex Institution Open API (v2)","version":"2.0.0"},"tags":[{"name":"Asset","description":"On-chain currencies, withdrawals, and deposit/withdrawal history."}],"servers":[{"url":"https://api.pionex.com","description":"Production"}],"security":[{"ApiKey":[],"Signature":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","in":"header","name":"X-APIKEY","description":"Your institution API Key, in the form `webot_xxxxxxxx`. Used to look up\nyour registered public key. Must be accompanied by the `X-Signature`\nheader. See the Authentication section for the full signing algorithm\n(RSA-PSS over SHA-256, or Ed25519) and the canonical-string construction.\n"}},"parameters":{"Timestamp":{"name":"timestamp","in":"query","required":true,"description":"Current time in **seconds** (Unix). Required on every signed request and\nparticipates in the signature. Must be within +/-5 seconds of server time.\n","schema":{"type":"integer","format":"int64"}}},"schemas":{"BaseResponse":{"type":"object","properties":{"result":{"type":"boolean","description":"Success indicator."},"timestamp":{"type":"integer","format":"int64","description":"Response timestamp in milliseconds."},"code":{"type":"string","description":"Error code (present only on failure)."},"message":{"type":"string","description":"Error message (present only on failure)."}}}},"responses":{"BadRequest":{"description":"Bad Request - the request body could not be read.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"Unauthorized":{"description":"Unauthorized - authentication failed (missing key, bad signature, etc.).","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"InternalError":{"description":"Internal or business error. Note that most business failures are returned\nas HTTP `200` with `result: false` and a `code`; this `500` covers\nserver-side internal errors.\n","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}}}},"paths":{"/api/v2/institution/asset/withdraw":{"post":{"tags":["Asset"],"summary":"Create an on-chain withdrawal","description":"Create an on-chain withdrawal. The address whitelist must be enabled and\nthe address must be whitelisted (or in the address book, for sub-accounts).\n\n**Errors:**\n\n| Error Code | Description |\n|------------|-------------|\n| `P_PAY_OPEN_API_ACCOUNT_FROZEN` | Deposits/withdrawals frozen for this account. |\n| `P_PAY_OPEN_API_KYC_REQUIRED` | KYC not completed or insufficient level. |\n| `P_PAY_OPEN_API_REGION_RESTRICTED` | The operation is restricted in your region. |\n| `P_PAY_OPEN_API_SIGN_REJECTED` | Security signature check failed. |\n| `P_PAY_OPEN_API_OPERATION_FORBIDDEN` | Blocked after high-risk behavior; `data` contains `restrict_expired_on`, `restrict_ttl`. |\n| `P_PAY_OPEN_API_UNSUPPORTED_CURRENCY` | `currency` + `chain` combination unsupported. |\n| `P_PAY_OPEN_API_WITHDRAW_WHITELIST_CLOSED` | Address whitelist not enabled (mandatory for Open API). |\n| `P_PAY_OPEN_API_WITHDRAW_ADDRESS_NOT_WHITELISTED` | Address not on the whitelist. |\n| `P_PAY_OPEN_API_WITHDRAW_ADDRESS_NOT_ALLOWED` | Address not on the configured allow list. |\n| `P_PAY_OPEN_API_WITHDRAW_ADDRESS_NOT_IN_ADDRESS_BOOK` | Sub-account address not in the address book. |\n","operationId":"institutionAssetWithdrawCreate","parameters":[{"$ref":"#/components/parameters/Timestamp"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["userId","clientId","currency","chain","address","amount"],"properties":{"userId":{"type":"string","description":"Sub-account UUID."},"clientId":{"type":"string","description":"Idempotency key, globally unique, max 64. Retries must reuse the original value.","maxLength":64},"currency":{"type":"string","description":"e.g. `USDT`, max 60.","maxLength":60},"chain":{"type":"string","description":"A withdraw-enabled chain from List Currencies, max 60.","maxLength":60},"address":{"type":"string","description":"Destination address, max 300.","maxLength":300},"tag":{"type":"string","description":"Tag/Memo, required for currencies where `hasTag=true`, max 100.","maxLength":100},"amount":{"type":"string","description":"Amount, max 60.","maxLength":60},"note":{"type":"string","description":"Note, max 100.","maxLength":100}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"},{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"string"},"clientId":{"type":"string"}}}}}]}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/InternalError"}}}}}}
```

## Query deposit/withdrawal history

> Query on-chain deposit/withdrawal history for a \`userId\`.<br>

```json
{"openapi":"3.0.3","info":{"title":"Pionex Institution Open API (v2)","version":"2.0.0"},"tags":[{"name":"Asset","description":"On-chain currencies, withdrawals, and deposit/withdrawal history."}],"servers":[{"url":"https://api.pionex.com","description":"Production"}],"security":[{"ApiKey":[],"Signature":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"apiKey","in":"header","name":"X-APIKEY","description":"Your institution API Key, in the form `webot_xxxxxxxx`. Used to look up\nyour registered public key. Must be accompanied by the `X-Signature`\nheader. See the Authentication section for the full signing algorithm\n(RSA-PSS over SHA-256, or Ed25519) and the canonical-string construction.\n"}},"parameters":{"Timestamp":{"name":"timestamp","in":"query","required":true,"description":"Current time in **seconds** (Unix). Required on every signed request and\nparticipates in the signature. Must be within +/-5 seconds of server time.\n","schema":{"type":"integer","format":"int64"}},"UserIdQueryRequired":{"name":"userId","in":"query","required":true,"description":"Target sub-account UUID. Participates in the signature.","schema":{"type":"string"}},"StartTime":{"name":"startTime","in":"query","required":false,"description":"Start time, millisecond Unix timestamp.","schema":{"type":"integer","format":"int64"}},"EndTime":{"name":"endTime","in":"query","required":false,"description":"End time, millisecond Unix timestamp.","schema":{"type":"integer","format":"int64"}}},"schemas":{"BaseResponse":{"type":"object","properties":{"result":{"type":"boolean","description":"Success indicator."},"timestamp":{"type":"integer","format":"int64","description":"Response timestamp in milliseconds."},"code":{"type":"string","description":"Error code (present only on failure)."},"message":{"type":"string","description":"Error message (present only on failure)."}}},"AssetRecord":{"type":"object","properties":{"id":{"type":"string"},"clientId":{"type":"string"},"currency":{"type":"string"},"chain":{"type":"string"},"type":{"type":"string","enum":["deposit","withdraw"]},"internal":{"type":"boolean"},"address":{"type":"string"},"tag":{"type":"string"},"addressFrom":{"type":"string"},"tagFrom":{"type":"string"},"amount":{"type":"string"},"fee":{"type":"string"},"status":{"type":"string"},"hash":{"type":"string"},"confirmations":{"type":"integer"},"note":{"type":"string"},"approvalReason":{"type":"string"},"createTime":{"type":"integer","format":"int64"},"updateTime":{"type":"integer","format":"int64"}}}},"responses":{"BadRequest":{"description":"Bad Request - the request body could not be read.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"Unauthorized":{"description":"Unauthorized - authentication failed (missing key, bad signature, etc.).","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}},"InternalError":{"description":"Internal or business error. Note that most business failures are returned\nas HTTP `200` with `result: false` and a `code`; this `500` covers\nserver-side internal errors.\n","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"}]}}}}}},"paths":{"/api/v2/institution/asset/records":{"get":{"tags":["Asset"],"summary":"Query deposit/withdrawal history","description":"Query on-chain deposit/withdrawal history for a `userId`.\n","operationId":"institutionAssetRecords","parameters":[{"$ref":"#/components/parameters/Timestamp"},{"$ref":"#/components/parameters/UserIdQueryRequired"},{"name":"type","in":"query","required":false,"description":"`DEPOSIT` / `WITHDRAW`.","schema":{"type":"string","enum":["DEPOSIT","WITHDRAW"]}},{"name":"currency","in":"query","required":false,"schema":{"type":"string"}},{"$ref":"#/components/parameters/StartTime"},{"$ref":"#/components/parameters/EndTime"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/BaseResponse"},{"type":"object","properties":{"data":{"type":"object","properties":{"records":{"type":"array","items":{"$ref":"#/components/schemas/AssetRecord"}}}}}}]}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/InternalError"}}}}}}
```
