Marketplace API
Submit listing

Submit listing#

This interface is used submit ordinals listings to OKX platform. Listing including BRC-20 and BTC NFT are possible. Psbt would require UTXO of the inscription which you can obtain from this interface query UTXO.

Request address#


Request param#

nftIdStringYesThe unique identifier for the ordinal NFT that is listing
inscriptionIdStringYesInscription ID
orderTypeIntegerYesType of this order. Use 2 to create ordinal listing
unitPriceBigDecimalYesBRC-20 unit price/price of one NFT. Unit: satoshi
isBrc20BooleanNoIf the respective listing is BRC-20, then true otherwise false. Default to true
psbtStringYesPartially signed Bitcoin transaction. Only base64 encoded PSBT is accepted
totalPriceBigDecimalYesTotal Price to be listed on the platform. Unit: satoshi

Response param#

nftIdStringThe unique NFT ID for this request
successBooleanIf it is successful, it will be true otherwise it will be false
errorMsgStringDetail error message for the failure of the request

Code request example#

curl --location '' \
--header 'OK-ACCESS-KEY: your api key' \
--header 'OK-ACCESS-PASSPHRASE: your passphrase' \
--header 'Content-Type: application/json' \
--data '{
  "brc20": false,
  "items": [
      "inscriptionId": "02ecbe7ef5143...3f3de87a7c6e64409883f66f4e3036i0",
      "nftId": 20824...473273458, // get this data part 1 step 2 by mapping it to inscriptionId
      "orderType": 2,
      "totalPrice": 100000,  // this price should match part 3 step 1
      "unitPrice": 100000, // this price will varies for BRC20 or btc NFT.  Check out NOTE on unitPrice

Json response example#

      "result": [
              "nftID": 20824...473273458,
              "errorMsg": "",
              "success": true,