Search Order

Search an order by orderId

It's recommended to query the latest status every 10 seconds.

amount = outputValue*count + minerFee + serviceFee + devFee

GEThttps://open-api.unisat.io/v2/inscribe/order/{orderId}
Path parameters
orderId*string
Response

Successful operation

Body
codeinteger (int32)
msgstring
Example: "OK"
dataOrder (object)
Request
const response = await fetch('https://open-api.unisat.io/v2/inscribe/order/{orderId}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "msg": "OK",
  "data": {
    "orderId": "",
    "status": "pending",
    "payAddress": "",
    "receiveAddress": "",
    "amount": 3000,
    "feeRate": 0,
    "minerFee": 0,
    "serviceFee": 0,
    "devFee": 0,
    "files": [
      {
        "filename": "10000.sats",
        "inscriptionId": "",
        "status": "pending"
      }
    ],
    "count": 1,
    "pendingCount": 1,
    "unconfirmedCount": 0,
    "confirmedCount": 0,
    "createTime": 1693439128100,
    "refundTxid": "",
    "refundFeeRate": 0
  }
}


enum OrderStatus {
    // when create order
    pending = 'pending',
    
    // pay not enough, need pay more
    payment_notenough = 'payment_notenough',
    
    // pay over, need choose continue or refund
    payment_overpay = 'payment_overpay',
    
    // there is an inscription in payment transaction, need refund
    payment_withinscription = 'payment_withinscription',
    
    // in some case, payment transaction need be confirmed
    payment_waitconfirmed = 'payment_waitconfirmed',
    
    // payment success
    payment_success = 'payment_success',
    
    // ready to inscribe
    ready = 'ready',
    inscribing = 'inscribing',
    minted = 'minted',
    closed = 'closed',
    refunded = 'refunded',
    cancel = 'cancel',
}


enum InscriptionStatus {
  pending = 'pending',
  unconfirmed = 'unconfirmed',
  confirmed = 'confirmed'
}

Last updated