Alokai

ModuleOptions

Options for the SDK module.

interface ModuleOptions {
	dataPrefix?: string;
	defaultTimeToLive?: number;
	enabled?: boolean;
	id?: string;
	ioredis?: RedisOptions;
	mock?: boolean;
	tagPrefix?: string;
}

Properties

NameRequiredTypeDescription
dataPrefixOptionalstringPrefix for all data keys stored in Redis. "data:"
defaultTimeToLiveOptionalnumberThe time in seconds after which data records saved in redis using the setCache method will be deleted. Can be overridden by the timeout property of the setCache method.
enabledOptionalbooleanDisables caching globally by inactivating certain SDK methods when set to false.
idOptionalstringUnique identifier of a module instance.
ioredisOptionalRedisOptionsioredis client options.
mockOptionalbooleanUses in-memory key-value store instead of redis.
tagPrefixOptionalstringPrefix for all tag keys stored in Redis. "tag:"

Referenced Types

  • RedisOptions

On this page