Skip to content

EntitiesAPI

Defined in: namespaces-core-plugins.ts:426

Universal entity-resolution plane (fn-93). 6 v1 entity types plus plugin-attached fields.

NOTE: There is deliberately NO delete method (AD-FN93-50).

fn-93

getType(entityType): Promise<AnyJSONValue>

Defined in: namespaces-core-plugins.ts:428

Gets an entity type definition, or null. [entities.read]

string

Promise<AnyJSONValue>


listTypes(opts?): Promise<AnyJSONValue[]>

Defined in: namespaces-core-plugins.ts:430

Lists entity type definitions. [entities.read]

AnyJSONValue

Promise<AnyJSONValue[]>


get(entityType, entityId, opts?): Promise<EntityRecord | null>

Defined in: namespaces-core-plugins.ts:432

Gets a single entity record, or null. [entities.read]

string

string

AnyJSONValue

Promise<EntityRecord | null>


query(query): Promise<EntityQueryResult>

Defined in: namespaces-core-plugins.ts:434

Runs a v1 query envelope (operator-allowlisted, depth-capped). [entities.read]

AnyJSONValue

Promise<EntityQueryResult>


watch(entityType, handler, opts?): Promise<string>

Defined in: namespaces-core-plugins.ts:436

Watches an entity type. Returns a token. [entities.read]

string

(change) => void

AnyJSONValue

Promise<string>


unwatch(token): Promise<void>

Defined in: namespaces-core-plugins.ts:438

Cancels a watch.

string

Promise<void>


upsert(entityType, partialRecord): Promise<EntityRecord>

Defined in: namespaces-core-plugins.ts:440

Upserts an entity record. [entities.write]

string

Partial<EntityRecord>

Promise<EntityRecord>