sui_tryGetPastObject
POST
Note there is no software-level guarantee/SLA that objects with past versions can be retrieved by this API, even if the object and version exists/existed. The result may vary across nodes depending on their pruning policies. Return the object information for a specified version
param[0]
objectIdstringrequired
The ID of the queried objectparam[1]
versionstringrequired
The version of the queried object. If None, default to the latest known versionparam[2]
optionsobjectrequired
Options for specifying the content to be returnedshowBcsboolean
Whether to show the content in BCS format. Default to be FalseshowContentboolean
Whether to show the content(i.e., package content or Move struct content) of the object. Default to be FalseshowDisplayboolean
Whether to show the Display metadata of the object for frontend rendering. Default to be FalseshowOwnerboolean
Whether to show the owner of the object. Default to be FalseshowPreviousTransactionboolean
Whether to show the previous transaction digest of the object. Default to be FalseshowStorageRebateboolean
Whether to show the storage rebate of the object. Default to be FalseshowTypeboolean
Whether to show the type of the object. Default to be FalseResponses
jsonrpcstring
idinteger
resultoneOf
bcsoneOf
Move object content or package content in BCS, default to be None unless SuiObjectDataOptions.showBcs is set to truebcsBytesstringrequired
Base64 encodingdataTypestringrequired
hasPublicTransferbooleanrequired
typestringrequired
versionstringrequired
contentoneOf
Move object content or package content, default to be None unless SuiObjectDataOptions.showContent is set to truedataTypestringrequired
fieldsstringrequired
hasPublicTransferbooleanrequired
typestringrequired
digestobjectrequired
The Display metadata for frontend UI rendering, default to be None unless SuiObjectDataOptions.showContent is set to true This can also be None if the struct type does not have Display defined See more details in <https://forums.sui.io/t/nft-object-display-proposal/4872>
dataobject
erroroneOf
codestringrequired
object_idobjectrequired
objectIdobjectrequired
owneroneOf
The owner of this object. Default to be None unless SuiObjectDataOptions.showOwner is set to trueAddressOwnerobjectrequired
previousTransactionobject
storageRebatestring
The amount of SUI we would rebate if this object gets deleted. This number is re-calculated each time the object is mutated based on the present storage gas price.typestring
The type of the object. Default to be None unless SuiObjectDataOptions.showType is set to trueversionobjectrequired
statusstringrequired
codestringrequired
Code identifying the cause of the failed request.messagestringrequired
Detailed message including the name and value of the invalid parameter.{"code": "ERROR_CODE","message": "Bad Request"}
cURL
curl -X POST 'https://sui-mainnet.nodit.io' \-H 'Content-Type: application/json' \-H 'X-API-KEY: nodit-demo' \-d '{"jsonrpc": "2.0","id": 1,"method": "sui_tryGetPastObject","params": ["0x11af4b844ff94b3fbef6e36b518da3ad4c5856fa686464524a876b463d129760",4,{"showBcs": false,"showContent": true,"showDisplay": false,"showOwner": true,"showPreviousTransaction": true,"showStorageRebate": true,"showType": true}]}'