List object versions
Authorizations
ApiKeyAuthApiKeyAuthapi-key string
NOWNodes API key passed in the api-key header.
Returns an object history, including live, deleted and wrapped versions. The default order is ascending. Version and checkpoint bounds intersect with the cursor interval. A successful stream ends with an end marker; pruning can limit the available history.
An empty result terminates with QueryEnd, not NOT_FOUND. Historical ranges and continuation cursors are limited by retained history. When endCheckpoint is set, LEDGER_TIP means the indexed tip was reached before the bound.
gRPC method: sui.rpc.v2.LedgerService.ListObjectVersions (server-streaming).
This is a gRPC method (HTTP/2, Protocol Buffers), not a REST endpoint. The request and response bodies below are shown in the proto3 JSON form that tools such as grpcurl and Postman accept and print. Pass your NOWNodes API key as the api-key gRPC metadata header. Proto files: sui/rpc/v2/ledger_service.proto.
This is a server-streaming method: the server sends a sequence of response messages. The response schema below describes one message, not a JSON array. Use the last cursor as options.after for ascending reads or options.before for descending reads.
Use proto files that include the Sui v1.85.2 API changes (MystenLabs/sui-apis commit 680d19c).
Example grpcurl request:
grpcurl \
-H 'api-key: YOUR_API_KEY' \
-emit-defaults \
-proto './sui-apis-grpc/proto/sui/rpc/v2/ledger_service.proto' \
-import-path './sui-apis-grpc/proto' \
-d '{"objectId": "0x5", "options": {"limit": 10, "ordering": "ORDERING_DESCENDING"}}' \
'sui-grpc.nownodes.io:443' \
sui.rpc.v2.LedgerService.ListObjectVersionsBody
objectIdstringrequiredRequired. ID of the object whose history is requested.
readMaskstringComma-separated protobuf FieldMask in lowerCamelCase, e.g. objectId,version,digest. Nested paths use dots. Fields for live objects. Defaults to object_id,version,digest.
optionsQueryOptionsCursor-based listing options. Cursors are opaque and specific to the object.
startVersionstring<uint64>Inclusive lower version bound.
endVersionstring<uint64>Exclusive upper version bound; must not be less than startVersion.
removalReadMaskstringComma-separated protobuf FieldMask in lowerCamelCase, e.g. objectId,version,digest. Nested paths use dots. Fields for removal entries. Defaults to version,kind; may also select transaction.
startCheckpointstring<uint64>Inclusive lower checkpoint bound for writes. If omitted, starts from the oldest available version.
endCheckpointstring<uint64>Exclusive upper checkpoint bound for writes. If omitted, uses the indexed tip.
Response
Successful response. Each streamed message has this schema.
gRPC error. The status code (e.g. UNAUTHENTICATED, INVALID_ARGUMENT, NOT_FOUND) is returned in the grpc-status trailer, details in grpc-message. INVALID_ARGUMENT: invalid bounds or cursor; OUT_OF_RANGE: unavailable history or a cursor beyond the indexed tip; UNIMPLEMENTED (NOT_SERVED_HERE): required indexes are disabled; UNAVAILABLE (NOT_READY): indexes are not ready. A node that does not support the requested operation returns UNIMPLEMENTED (NOT_SERVED_HERE); a node not ready to serve it returns UNAVAILABLE (NOT_READY). Historical data outside the retained range can return OUT_OF_RANGE (BELOW_EARLIEST_AVAILABLE); requests beyond the indexed tip can return OUT_OF_RANGE (ABOVE_LATEST_AVAILABLE) where applicable.