Prometheus Entity Management API
    Preparing search index...
    useGraphStore: Omit<
        Omit<zustand_vanilla.StoreApi<GraphState>, "subscribe"> & {
            subscribe: {
                (
                    listener: (
                        selectedState: GraphState,
                        previousSelectedState: GraphState,
                    ) => void,
                ): () => void;
                <U>(
                    selector: (state: GraphState) => U,
                    listener: (selectedState: U, previousSelectedState: U) => void,
                    options?: {
                        equalityFn?: (a: U, b: U) => boolean;
                        fireImmediately?: boolean;
                    },
                ): () => void;
            };
        },
        "setState",
    > & {
        setState(
            nextStateOrUpdater:
                | GraphState
                | Partial<GraphState>
                | (
                    (
                        state: {
                            appendListResult: (
                                key: QueryKey,
                                ids: EntityId[],
                                meta: Partial<
                                    Omit<
                                        ListState,
                                        "ids"
                                        | "isFetching"
                                        | "isFetchingMore"
                                        | "error"
                                        | "stale",
                                    >,
                                >,
                            ) => void;
                            clearEntitySyncMetadata: (type: EntityType, id: EntityId) => void;
                            clearPatch: (type: EntityType, id: EntityId) => void;
                            entities: { [x: string]: { [x: string]: { [x: string]: unknown } } };
                            entityStates: {
                                [x: string]: {
                                    error: string | null;
                                    isFetching: boolean;
                                    lastFetched: number | null;
                                    stale: boolean;
                                };
                            };
                            ingestFetchedList: (
                                type: EntityType,
                                entries: { data: Record<string, unknown>; id: EntityId }[],
                                options?: IngestFetchedListOptions,
                            ) => void;
                            insertIdInList: (
                                key: QueryKey,
                                id: EntityId,
                                position: "start" | "end" | number,
                            ) => void;
                            invalidateEntity: (type: EntityType, id?: EntityId) => void;
                            invalidateLists: (
                                matcher: string | ((key: QueryKey) => boolean),
                            ) => void;
                            invalidateType: (type: EntityType) => void;
                            lists: {
                                [x: string]: {
                                    currentPage: number | null;
                                    error: string | null;
                                    hasNextPage: boolean;
                                    hasPrevPage: boolean;
                                    ids: string[];
                                    isFetching: boolean;
                                    isFetchingMore: boolean;
                                    lastError:
                                        | {
                                            cause?: unknown;
                                            kind: "terminal";
                                            message: string;
                                            name: string;
                                            stack?: string;
                                            status?: number;
                                        }
                                        | {
                                            cause?: unknown;
                                            kind: "transient";
                                            message: string;
                                            name: string;
                                            stack?: string;
                                            status?: number;
                                        }
                                        | null;
                                    lastFetched: number
                                    | null;
                                    nextCursor: string | null;
                                    pageSize: number | null;
                                    prevCursor: string | null;
                                    stale: boolean;
                                    total: number | null;
                                };
                            };
                            patchEntity: (
                                type: EntityType,
                                id: EntityId,
                                patch: Record<string, unknown>,
                            ) => void;
                            patches: { [x: string]: { [x: string]: { [x: string]: unknown } } };
                            prependListResult: (
                                key: QueryKey,
                                ids: EntityId[],
                                meta?: Partial<ListState>,
                            ) => void;
                            readEntity: <T = Record<string, unknown>>(
                                type: EntityType,
                                id: EntityId,
                            ) => T | null;
                            readEntitySnapshot: <T = Record<string, unknown>>(
                                type: EntityType,
                                id: EntityId,
                            ) => EntitySnapshot<T & Record<string, unknown>> | null;
                            removeEntity: (type: EntityType, id: EntityId) => void;
                            removeIdFromAllLists: (type: EntityType, id: EntityId) => void;
                            replaceEntity: (
                                type: EntityType,
                                id: EntityId,
                                data: Record<string, unknown>,
                            ) => void;
                            setEntityError: (
                                type: EntityType,
                                id: EntityId,
                                error: string | null,
                            ) => void;
                            setEntityFetched: (type: EntityType, id: EntityId) => void;
                            setEntityFetching: (
                                type: EntityType,
                                id: EntityId,
                                fetching: boolean,
                            ) => void;
                            setEntityStale: (
                                type: EntityType,
                                id: EntityId,
                                stale: boolean,
                            ) => void;
                            setEntitySyncMetadata: (
                                type: EntityType,
                                id: EntityId,
                                metadata: Partial<EntitySyncMetadata>,
                            ) => void;
                            setListError: (
                                key: QueryKey,
                                error: string | null,
                                typed?: EntityError | null,
                            ) => void;
                            setListFetching: (key: QueryKey, fetching: boolean) => void;
                            setListFetchingMore: (key: QueryKey, fetchingMore: boolean) => void;
                            setListResult: (
                                key: QueryKey,
                                ids: EntityId[],
                                meta: Partial<
                                    Omit<
                                        ListState,
                                        "ids"
                                        | "isFetching"
                                        | "isFetchingMore"
                                        | "error"
                                        | "stale",
                                    >,
                                >,
                            ) => void;
                            setListStale: (key: QueryKey, stale: boolean) => void;
                            syncMetadata: {
                                [x: string]: {
                                    origin: SyncOrigin;
                                    synced: boolean;
                                    updatedAt: number | null;
                                };
                            };
                            unpatchEntity: (
                                type: EntityType,
                                id: EntityId,
                                keys: string[],
                            ) => void;
                            upsertEntities: (
                                type: EntityType,
                                entries: { data: Record<string, unknown>; id: EntityId }[],
                            ) => void;
                            upsertEntity: (
                                type: EntityType,
                                id: EntityId,
                                data: Record<string, unknown>,
                            ) => void;
                        },
                    ) => void
                ),
            shouldReplace?: false,
        ): void;
        setState(
            nextStateOrUpdater:
                | GraphState
                | (
                    (
                        state: {
                            appendListResult: (
                                key: QueryKey,
                                ids: EntityId[],
                                meta: Partial<
                                    Omit<
                                        ListState,
                                        "ids"
                                        | "isFetching"
                                        | "isFetchingMore"
                                        | "error"
                                        | "stale",
                                    >,
                                >,
                            ) => void;
                            clearEntitySyncMetadata: (type: EntityType, id: EntityId) => void;
                            clearPatch: (type: EntityType, id: EntityId) => void;
                            entities: { [x: string]: { [x: string]: { [x: string]: unknown } } };
                            entityStates: {
                                [x: string]: {
                                    error: string | null;
                                    isFetching: boolean;
                                    lastFetched: number | null;
                                    stale: boolean;
                                };
                            };
                            ingestFetchedList: (
                                type: EntityType,
                                entries: { data: Record<string, unknown>; id: EntityId }[],
                                options?: IngestFetchedListOptions,
                            ) => void;
                            insertIdInList: (
                                key: QueryKey,
                                id: EntityId,
                                position: "start" | "end" | number,
                            ) => void;
                            invalidateEntity: (type: EntityType, id?: EntityId) => void;
                            invalidateLists: (
                                matcher: string | ((key: QueryKey) => boolean),
                            ) => void;
                            invalidateType: (type: EntityType) => void;
                            lists: {
                                [x: string]: {
                                    currentPage: number | null;
                                    error: string | null;
                                    hasNextPage: boolean;
                                    hasPrevPage: boolean;
                                    ids: string[];
                                    isFetching: boolean;
                                    isFetchingMore: boolean;
                                    lastError:
                                        | {
                                            cause?: unknown;
                                            kind: "terminal";
                                            message: string;
                                            name: string;
                                            stack?: string;
                                            status?: number;
                                        }
                                        | {
                                            cause?: unknown;
                                            kind: "transient";
                                            message: string;
                                            name: string;
                                            stack?: string;
                                            status?: number;
                                        }
                                        | null;
                                    lastFetched: number
                                    | null;
                                    nextCursor: string | null;
                                    pageSize: number | null;
                                    prevCursor: string | null;
                                    stale: boolean;
                                    total: number | null;
                                };
                            };
                            patchEntity: (
                                type: EntityType,
                                id: EntityId,
                                patch: Record<string, unknown>,
                            ) => void;
                            patches: { [x: string]: { [x: string]: { [x: string]: unknown } } };
                            prependListResult: (
                                key: QueryKey,
                                ids: EntityId[],
                                meta?: Partial<ListState>,
                            ) => void;
                            readEntity: <T = Record<string, unknown>>(
                                type: EntityType,
                                id: EntityId,
                            ) => T | null;
                            readEntitySnapshot: <T = Record<string, unknown>>(
                                type: EntityType,
                                id: EntityId,
                            ) => EntitySnapshot<T & Record<string, unknown>> | null;
                            removeEntity: (type: EntityType, id: EntityId) => void;
                            removeIdFromAllLists: (type: EntityType, id: EntityId) => void;
                            replaceEntity: (
                                type: EntityType,
                                id: EntityId,
                                data: Record<string, unknown>,
                            ) => void;
                            setEntityError: (
                                type: EntityType,
                                id: EntityId,
                                error: string | null,
                            ) => void;
                            setEntityFetched: (type: EntityType, id: EntityId) => void;
                            setEntityFetching: (
                                type: EntityType,
                                id: EntityId,
                                fetching: boolean,
                            ) => void;
                            setEntityStale: (
                                type: EntityType,
                                id: EntityId,
                                stale: boolean,
                            ) => void;
                            setEntitySyncMetadata: (
                                type: EntityType,
                                id: EntityId,
                                metadata: Partial<EntitySyncMetadata>,
                            ) => void;
                            setListError: (
                                key: QueryKey,
                                error: string | null,
                                typed?: EntityError | null,
                            ) => void;
                            setListFetching: (key: QueryKey, fetching: boolean) => void;
                            setListFetchingMore: (key: QueryKey, fetchingMore: boolean) => void;
                            setListResult: (
                                key: QueryKey,
                                ids: EntityId[],
                                meta: Partial<
                                    Omit<
                                        ListState,
                                        "ids"
                                        | "isFetching"
                                        | "isFetchingMore"
                                        | "error"
                                        | "stale",
                                    >,
                                >,
                            ) => void;
                            setListStale: (key: QueryKey, stale: boolean) => void;
                            syncMetadata: {
                                [x: string]: {
                                    origin: SyncOrigin;
                                    synced: boolean;
                                    updatedAt: number | null;
                                };
                            };
                            unpatchEntity: (
                                type: EntityType,
                                id: EntityId,
                                keys: string[],
                            ) => void;
                            upsertEntities: (
                                type: EntityType,
                                entries: { data: Record<string, unknown>; id: EntityId }[],
                            ) => void;
                            upsertEntity: (
                                type: EntityType,
                                id: EntityId,
                                data: Record<string, unknown>,
                            ) => void;
                        },
                    ) => void
                ),
            shouldReplace: true,
        ): void;
    }

    Import graphStore from core, or useGraphStore from the React binding. This StoreApi-shaped alias remains for non-React 2.x migrations.