SuiObjectContext

Class in @sentio/sdk/sui

Defined in @sentio/sdk/sui

Extends

Constructors

Constructor

new SuiObjectContext(
   network: SuiChainId, 
   objectId: string, 
   objectVersion: bigint, 
   checkpoint: bigint, 
   timestamp: Date, 
   baseLabels: Labels | undefined
): SuiObjectContext;

Parameters

ParameterType
networkSuiChainId
objectIdstring
objectVersionbigint
checkpointbigint
timestampDate
baseLabelsLabels | undefined

Returns

SuiObjectContext

Overrides

SuiAddressContext.constructor

Properties

PropertyTypeDefault valueOverridesInherited from
addressstringundefined-SuiAddressContext.address
baseLabelsLabelsundefined-SuiAddressContext.baseLabels
checkpointbigintundefined-SuiAddressContext.checkpoint
coderMoveCoderundefined-SuiAddressContext.coder
contractNamestring'object'SuiAddressContext.contractName-
eventLoggerEventLoggerBindingundefined-SuiAddressContext.eventLogger
meterMeterundefined-SuiAddressContext.meter
networkSuiChainIdundefined-SuiAddressContext.network
objectIdstringundefined--
objectVersionbigintundefined--
timestampDateundefined-SuiAddressContext.timestamp

Accessors

cache

Get Signature

get cache(): MemoryCache;

Access the in-memory key-value cache.

The cache allows storing and retrieving JSON-serializable values that persist across handler invocations. Useful for caching computed results, tracking cumulative state, or storing intermediate processing data.

Example
// Store and retrieve values
await ctx.cache.set('totalVolume', volume)
const cached = await ctx.cache.get<number>('totalVolume')

// Block-scoped values (isolated per block)
await ctx.cache.setInBlock('blockCount', count)
See

MemoryCache for full API documentation

Returns

MemoryCache

The MemoryCache instance, or undefined if cache is not available

Inherited from

SuiAddressContext.cache


client

Get Signature

get client(): SuiGrpcClient;
Returns

SuiGrpcClient

Inherited from

SuiAddressContext.client


store

Get Signature

get store(): Store;
Returns

Store

Inherited from

SuiAddressContext.store

Methods

getChainId()

getChainId(): SuiChainId;

Returns

SuiChainId

Inherited from

SuiAddressContext.getChainId


getMetaData()

getMetaData(name: string, labels: Labels): RecordMetaData;

Parameters

ParameterType
namestring
labelsLabels

Returns

RecordMetaData

Inherited from

SuiAddressContext.getMetaData


getMetaDataInternal()

getMetaDataInternal(name: string, labels: Labels): RecordMetaData;

Parameters

ParameterType
namestring
labelsLabels

Returns

RecordMetaData

Inherited from

SuiAddressContext.getMetaDataInternal


getTimestamp()

getTimestamp(): number;

Returns

number

Inherited from

SuiAddressContext.getTimestamp


initStore()

initStore(): void;

Returns

void

Inherited from

SuiAddressContext.initStore


sendTemplateInstance()

sendTemplateInstance(instance: TemplateInstance, unbind?: boolean): void;

Parameters

ParameterTypeDefault value
instanceTemplateInstanceundefined
unbindbooleanfalse

Returns

void

Inherited from

SuiAddressContext.sendTemplateInstance


stopAndGetResult()

stopAndGetResult(): ProcessResult;

Returns

ProcessResult

Inherited from

SuiAddressContext.stopAndGetResult


update()

update(res: MessageInit<ProcessResult>): void;

Parameters

ParameterType
resMessageInit<ProcessResult>

Returns

void

Inherited from

SuiAddressContext.update

On this page