IotaObjectContext

Class in @sentio/sdk/iota

Defined in @sentio/sdk/iota

Extends

Constructors

Constructor

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

Parameters

ParameterType
networkSuiChainId
objectIdstring
objectVersionbigint
checkpointbigint
timestampDate
baseLabelsLabels | undefined

Returns

IotaObjectContext

Overrides

IotaAddressContext.constructor

Properties

PropertyTypeDefault valueOverridesInherited from
addressstringundefined-IotaAddressContext.address
baseLabelsLabelsundefined-IotaAddressContext.baseLabels
checkpointbigintundefined-IotaAddressContext.checkpoint
coderMoveCoderundefined-IotaAddressContext.coder
contractNamestring'object'IotaAddressContext.contractName-
eventLoggerEventLoggerBindingundefined-IotaAddressContext.eventLogger
meterMeterundefined-IotaAddressContext.meter
networkSuiChainIdundefined-IotaAddressContext.network
objectIdstringundefined--
objectVersionbigintundefined--
timestampDateundefined-IotaAddressContext.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

IotaAddressContext.cache


client

Get Signature

get client(): IotaClient;
Returns

IotaClient

Inherited from

IotaAddressContext.client


store

Get Signature

get store(): Store;
Returns

Store

Inherited from

IotaAddressContext.store

Methods

getChainId()

getChainId(): SuiChainId;

Returns

SuiChainId

Inherited from

IotaAddressContext.getChainId


getMetaData()

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

Parameters

ParameterType
namestring
labelsLabels

Returns

RecordMetaData

Inherited from

IotaAddressContext.getMetaData


getMetaDataInternal()

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

Parameters

ParameterType
namestring
labelsLabels

Returns

RecordMetaData

Inherited from

IotaAddressContext.getMetaDataInternal


getTimestamp()

getTimestamp(): number;

Returns

number

Inherited from

IotaAddressContext.getTimestamp


initStore()

initStore(): void;

Returns

void

Inherited from

IotaAddressContext.initStore


sendTemplateInstance()

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

Parameters

ParameterTypeDefault value
instanceTemplateInstanceundefined
unbindbooleanfalse

Returns

void

Inherited from

IotaAddressContext.sendTemplateInstance


stopAndGetResult()

stopAndGetResult(): ProcessResult;

Returns

ProcessResult

Inherited from

IotaAddressContext.stopAndGetResult


update()

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

Parameters

ParameterType
resMessageInit<ProcessResult>

Returns

void

Inherited from

IotaAddressContext.update

On this page