Wallet API
Query Broadcast Strategies

Query Broadcast Strategies#

Retrieve the set broadcast strategies.

Request Path#

GET https://www.okx.com/api/v5/wallet/pre-transaction/strategies

Request Parameters#

ParameterTypeRequiredDescription
chainIndexStringNoUnique identifier for the chain
limitStringNoNumber of items to query per request, default is 50, max 100
cursorStringNoCursor position, defaults to the first one

Response Parameters#

ParameterTypeDescription
cursorStringCursor
strategiesArrayBroadcast strategies
> chainIndexStringUnique identifier for the chain, empty if the strategy is set globally for all chains
> broadcastStrategyString0: Direct broadcast
1: Strict nonce order broadcast
Default is direct broadcast
> retryStrategyString0: No retry
1: Few retries, suitable for scenarios like web3 needing quick user response
2: Multiple timed retries, suitable for scenarios like single transactions in exchanges
Default is few retries

Request Example#

shell
curl --location --request GET 'https://www.okx.com/api/v5/wallet/pre-transaction/strategies' \
--header 'Content-Type: application/json' \
--header 'OK-ACCESS-PROJECT: 86af********d1bc' \
--header 'OK-ACCESS-KEY: 37c541a1-****-****-****-10fe7a038418' \
--header 'OK-ACCESS-SIGN: leaV********3uw=' \
--header 'OK-ACCESS-PASSPHRASE: 1****6' \
--header 'OK-ACCESS-TIMESTAMP: 2023-10-18T12:21:41.274Z'

Response Example#

200
{
 "code": "0",
    "msg": "success",
    "data": [
        {
            "cursor": "",
            "strategies": [
                {
                    "chainIndex": "",
                    "broadcastStrategy": "0",
                    "retryStrategy": "1"
                },
                {
                    "chainIndex": "1",
                    "broadcastStrategy": "1",
                    "retryStrategy": "0"
                }
            ]
        }
    ]
}