Skip to content

nooschain v0.1.0


nooschain / observability/observability-service / ObservabilityService

Class: ObservabilityService

Defined in: observability/observability-service.ts:136

Facade around DB reads and runtime callbacks used by /node/observability/*. Expensive live scans are kept in explicit *Realtime methods; normal storage and payload endpoints use cached counter tables maintained by triggers.

Constructors

Constructor

new ObservabilityService(db, deps): ObservabilityService

Defined in: observability/observability-service.ts:137

Parameters

db

Kysely<Database>

deps

ObservabilityServiceDeps

Returns

ObservabilityService

Methods

bucketAccessRules()

bucketAccessRules(args?): Promise<{ rules: object[]; summary: { bucketsCovered: number; filters: { bucketId: string | null; organizationId: string | null; userId: string | null; }; hasMore: boolean; limit: number; offset: number; organizationRuleCount: number; totalReturnedRules: number; userRuleCount: number; }; }>

Defined in: observability/observability-service.ts:996

Returns a bounded page of bucket access rules, optionally filtered by one bucket or one principal. This is a read-only permission inspection endpoint.

Parameters

args?

BucketAccessRuleObservabilityFilters = {}

Returns

Promise<{ rules: object[]; summary: { bucketsCovered: number; filters: { bucketId: string | null; organizationId: string | null; userId: string | null; }; hasMore: boolean; limit: number; offset: number; organizationRuleCount: number; totalReturnedRules: number; userRuleCount: number; }; }>


buckets()

buckets(): Promise<{ buckets: object[]; summary: { encryptionModeCounts: Record<string, number>; policyCounts: Record<string, number>; totalAvailablePayloads: number; totalBuckets: number; totalMissingPayloads: number; totalRecords: number; }; }>

Defined in: observability/observability-service.ts:734

Returns bucket metadata plus cached per-bucket record/access/key counters.

Returns

Promise<{ buckets: object[]; summary: { encryptionModeCounts: Record<string, number>; policyCounts: Record<string, number>; totalAvailablePayloads: number; totalBuckets: number; totalMissingPayloads: number; totalRecords: number; }; }>


chain()

chain(args?): Promise<{ checkpoints: object[]; genesis: { createdAt: string; genesisHash: string; id: string; } | null; head: ChainHeadDto; protocol: ProtocolInfo; snapshots: object[]; verification: { replayVerification: string; status: unknown; }; }>

Defined in: observability/observability-service.ts:445

Returns chain-head, protocol, checkpoint, snapshot, and cached verification status. runVerify starts chain verification only; replay verification is intentionally not run from this endpoint.

Parameters

args?

ChainObservabilityOptions = {}

Returns

Promise<{ checkpoints: object[]; genesis: { createdAt: string; genesisHash: string; id: string; } | null; head: ChainHeadDto; protocol: ProtocolInfo; snapshots: object[]; verification: { replayVerification: string; status: unknown; }; }>


consensus()

consensus(): Promise<{ governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }>

Defined in: observability/observability-service.ts:337

Returns the full consensus observability payload.

Returns

Promise<{ governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }>


contract()

contract(contractId): Promise<{ contractId: string; recentCalls: object[]; summary: { callCount: number; contractId: string; encryptedRecordWriteCount: number; eventCount: number; failureCount: number; failureRate: number; fuelUsed: number; hostCalls: number; lastCallAt: string | null; methodCount: number; stateChangeCount: number; storageWriteCount: number; topFailureCodes: object[]; } | null; }>

Defined in: observability/observability-service.ts:913

Returns aggregate metrics and recent calls for one contract.

Parameters

contractId

string

Returns

Promise<{ contractId: string; recentCalls: object[]; summary: { callCount: number; contractId: string; encryptedRecordWriteCount: number; eventCount: number; failureCount: number; failureRate: number; fuelUsed: number; hostCalls: number; lastCallAt: string | null; methodCount: number; stateChangeCount: number; storageWriteCount: number; topFailureCodes: object[]; } | null; }>


contractCalls()

contractCalls(contractId, args?): Promise<{ calls: object[]; contractId: string; hasMore: boolean; limit: number; offset: number; }>

Defined in: observability/observability-service.ts:927

Returns a bounded page of per-call contract metrics.

Parameters

contractId

string

args?

ContractCallMetricFilters = {}

Returns

Promise<{ calls: object[]; contractId: string; hasMore: boolean; limit: number; offset: number; }>


contracts()

contracts(): Promise<{ contracts: object[]; summary: { totalCalls: number; totalContracts: number; totalEvents: number; totalFailures: number; totalFuelUsed: number; totalHostCalls: number; totalWrites: number; }; }>

Defined in: observability/observability-service.ts:824

Returns per-contract execution metrics derived from local call telemetry.

Returns

Promise<{ contracts: object[]; summary: { totalCalls: number; totalContracts: number; totalEvents: number; totalFailures: number; totalFuelUsed: number; totalHostCalls: number; totalWrites: number; }; }>


health()

health(): Promise<{ chain: { chainId: JsonValue | undefined; genesisHash: string | null; initialized: boolean; latestBlockHash: string | null; latestHeight: string | null; latestStateRoot: string | null; protocolVersion: number; }; consensus: ConsensusStatus; consensusDetails: { governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }; db: { connected: boolean; }; health: { activeIncident: boolean; issues: string[]; status: ObservabilityHealthStatus; }; migrations: { readable: boolean; }; ok: boolean; peerScoring: { banned: number; degraded: number; healthy: number; quarantined: number; total: number; }; process: { memoryUsage: MemoryUsage; uptimeMs: number; }; sync: unknown; tls: { } | null; verification: unknown; }>

Defined in: observability/observability-service.ts:354

Returns poll-safe operational health details across DB, sync, peers, and process state.

Returns

Promise<{ chain: { chainId: JsonValue | undefined; genesisHash: string | null; initialized: boolean; latestBlockHash: string | null; latestHeight: string | null; latestStateRoot: string | null; protocolVersion: number; }; consensus: ConsensusStatus; consensusDetails: { governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }; db: { connected: boolean; }; health: { activeIncident: boolean; issues: string[]; status: ObservabilityHealthStatus; }; migrations: { readable: boolean; }; ok: boolean; peerScoring: { banned: number; degraded: number; healthy: number; quarantined: number; total: number; }; process: { memoryUsage: MemoryUsage; uptimeMs: number; }; sync: unknown; tls: { } | null; verification: unknown; }>


incidents()

incidents(): Promise<{ activeIncident: { conflictId: string | null; details: JsonValue; id: string; reason: string; resolvedAt: string | null; startedAt: string; status: string; } | null; openConflicts: object[]; quarantinedPeers: object[]; recentIncidents: object[]; }>

Defined in: observability/observability-service.ts:611

Lists active/recent incidents and open conflicts for operator triage.

Returns

Promise<{ activeIncident: { conflictId: string | null; details: JsonValue; id: string; reason: string; resolvedAt: string | null; startedAt: string; status: string; } | null; openConflicts: object[]; quarantinedPeers: object[]; recentIncidents: object[]; }>


mempool()

mempool(includePayload?): Promise<{ newestPendingAgeMs: number | null; oldestPendingAgeMs: number | null; pendingByType: Record<string, number>; pendingCount: number; recent: object[]; }>

Defined in: observability/observability-service.ts:515

Returns local pending transaction metadata. Payloads are omitted by default so the GUI can inspect mempool health without rendering sensitive content.

Parameters

includePayload?

boolean = false

Returns

Promise<{ newestPendingAgeMs: number | null; oldestPendingAgeMs: number | null; pendingByType: Record<string, number>; pendingCount: number; recent: object[]; }>


metrics()

metrics(): Promise<{ blocks: { latestHeight: string | null; total: number; }; buckets: { total: number; }; consensus: { governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }; memory: MemoryUsage; peers: { banned: number; degraded: number; healthy: number; quarantined: number; total: number; }; process: { uptimeMs: number; }; records: { encrypted: number; }; rowCounts: Record<string, number>; tls: { } | null; transactions: { failed: number; pending: number; total: number; }; }>

Defined in: observability/observability-service.ts:391

Returns JSON metrics for dashboards without exposing Prometheus format yet.

Returns

Promise<{ blocks: { latestHeight: string | null; total: number; }; buckets: { total: number; }; consensus: { governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }; memory: MemoryUsage; peers: { banned: number; degraded: number; healthy: number; quarantined: number; total: number; }; process: { uptimeMs: number; }; records: { encrypted: number; }; rowCounts: Record<string, number>; tls: { } | null; transactions: { failed: number; pending: number; total: number; }; }>


organizations()

organizations(): Promise<{ organizations: object[]; summary: { totalAvailablePayloads: number; totalBuckets: number; totalMissingPayloads: number; totalNodes: number; totalOrganizations: number; totalRecords: number; totalUsers: number; totalValidators: number; }; }>

Defined in: observability/observability-service.ts:1100

Returns organization identity metadata and trigger-maintained ownership counters.

Returns

Promise<{ organizations: object[]; summary: { totalAvailablePayloads: number; totalBuckets: number; totalMissingPayloads: number; totalNodes: number; totalOrganizations: number; totalRecords: number; totalUsers: number; totalValidators: number; }; }>


overview()

overview(): Promise<{ chain: { chainId: JsonValue | undefined; genesisHash: string | null; initialized: boolean; latestBlockHash: string | null; latestHeight: string | null; latestStateRoot: string | null; protocolVersion: number; }; consensus: { governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }; health: { activeIncident: boolean; issues: string[]; status: ObservabilityHealthStatus; }; node: ObservabilityRuntimeInfo; tls: { } | null; }>

Defined in: observability/observability-service.ts:342

Returns the lightweight landing-page summary used for frequent polling.

Returns

Promise<{ chain: { chainId: JsonValue | undefined; genesisHash: string | null; initialized: boolean; latestBlockHash: string | null; latestHeight: string | null; latestStateRoot: string | null; protocolVersion: number; }; consensus: { governance: { activeValidatorCount: number; activeValidatorNodeIds: string[]; activeValidatorSetHash: string; currentNodeValidatorStatus: string | null; membership: { endpointMismatches: EndpointMismatch[]; governanceValidatorSetHash: string; membershipInSync: boolean; missingRuntimeValidators: object[]; reconciliationWarnings: string[]; runtimeValidatorSetHash: string; unexpectedRuntimeValidators: UnexpectedRuntimeValidator[]; }; retiredValidatorCount: number; runtimeGovernanceMismatch: boolean; runtimeRaftMembership: { lastMembershipChange: { completedAt: string | null; nodeId: string; operationType: string; status: string; } | null; leaderId: string | null; nonVoters: RuntimeRaftMember[]; reconciliationWarnings: string[]; runtimeMatchesGovernance: boolean; voters: RuntimeRaftMember[]; }; runtimeRaftVoterNodeIds: string[]; suspendedValidatorCount: number; warnings: string[]; }; mode: ConsensusMode; raft: { appliedIndex: number | null; clusterId: null; commitIndex: number | null; lastLogIndex: number | null; lastLogTerm: number | null; leaderId: string | null; nodeId: string; numPeers: number; state: "leader" | "follower" | "candidate" | "validator" | "observer" | "unknown" | null; term: number | null; } | null; raftEngine: string | null; raftTcpTls: { caConfigured: boolean; certConfigured: boolean; enabled: boolean; mtlsRequired: boolean; } | null; sidecar: { lastError: string | null; lastExitAt: string | null; lastExitCode: number | null; lastExitSignal: string | null; nextRestartAt: string | null; pid: number | null; restartCount: number; running: boolean; status: "stopped" | "starting" | "running" | "restarting" | "dead" | null; uptimeMs: number | null; } | null; stateRootEngine: { activeActivation: StateRootEngineActivationSchedule | null; appliesAtNextHeight: string; checkpoint: { configuredDirectory: string; latestVerified: null; } | { configuredDirectory: string; latestVerified: { blockHash: string; checkpointFormatVersion: number; checkpointHash: string; createdAt: string; engineVersion: "iden3-v1" | "nervos-smt-v2"; height: string; sidecarProtocolVersion: number; stateRoot: string; }; }; current: "iden3-v1" | "nervos-smt-v2"; nextActivation: StateRootEngineActivationSchedule | null; readiness: StateRootActivationReadiness; sidecar: PersistentStateRootSidecarStatus | null; source: "governance" | "env"; supervisor: StateRootSidecarSupervisorStatus | null; }; status: ConsensusBackendStatus; transportMode: string | null; }; health: { activeIncident: boolean; issues: string[]; status: ObservabilityHealthStatus; }; node: ObservabilityRuntimeInfo; tls: { } | null; }>


payloads()

payloads(): Promise<{ availablePayloadCount: number; byReplicationPolicy: Record<string, { available: number; missing: number; total: number; }>; missingPayloadCount: number; missingPayloadsByBucket: Record<string, number>; totalEncryptedRecords: number; }>

Defined in: observability/observability-service.ts:688

Returns trigger-maintained payload availability counters by policy and bucket.

Returns

Promise<{ availablePayloadCount: number; byReplicationPolicy: Record<string, { available: number; missing: number; total: number; }>; missingPayloadCount: number; missingPayloadsByBucket: Record<string, number>; totalEncryptedRecords: number; }>


payloadsRealtime()

payloadsRealtime(): Promise<{ availablePayloadCount: number; byReplicationPolicy: Record<string, { available: number; missing: number; total: number; }>; missingPayloadCount: number; missingPayloadsByBucket: Record<string, number>; totalEncryptedRecords: number; }>

Defined in: observability/observability-service.ts:1283

Performs a live encrypted-record scan for payload counter diagnostics.

Returns

Promise<{ availablePayloadCount: number; byReplicationPolicy: Record<string, { available: number; missing: number; total: number; }>; missingPayloadCount: number; missingPayloadsByBucket: Record<string, number>; totalEncryptedRecords: number; }>


peers()

peers(): Promise<{ peers: object[]; }>

Defined in: observability/observability-service.ts:551

Returns trusted-peer transport state plus local scoring/sync diagnostics.

Returns

Promise<{ peers: object[]; }>


storage()

storage(): Promise<{ availablePayloadCount: number; estimatedDbSize: null; latestSnapshot: { createdAt: string; height: string; id: string; snapshotHash: string; status: string; } | null; missingPayloadCount: number; rowCounts: Record<string, number>; snapshotCount: number; }>

Defined in: observability/observability-service.ts:729

Returns normal storage observability using cached counters, not live scans.

Returns

Promise<{ availablePayloadCount: number; estimatedDbSize: null; latestSnapshot: { createdAt: string; height: string; id: string; snapshotHash: string; status: string; } | null; missingPayloadCount: number; rowCounts: Record<string, number>; snapshotCount: number; }>


storageRealtime()

storageRealtime(): Promise<{ availablePayloadCount: number; estimatedDbSize: null; latestSnapshot: { createdAt: string; height: string; id: string; snapshotHash: string; status: string; } | null; missingPayloadCount: number; rowCounts: Record<string, number>; snapshotCount: number; }>

Defined in: observability/observability-service.ts:1329

Returns storage observability using live scans for troubleshooting counters.

Returns

Promise<{ availablePayloadCount: number; estimatedDbSize: null; latestSnapshot: { createdAt: string; height: string; id: string; snapshotHash: string; status: string; } | null; missingPayloadCount: number; rowCounts: Record<string, number>; snapshotCount: number; }>


sync()

sync(): Promise<{ head: ChainHeadDto; manager: unknown; peers: { peers: object[]; }; }>

Defined in: observability/observability-service.ts:602

Combines sync-manager state with local head and peer details.

Returns

Promise<{ head: ChainHeadDto; manager: unknown; peers: { peers: object[]; }; }>


users()

users(args?): Promise<{ summary: { filteredOrganizationId: string | null; totalAvailablePayloads: number; totalBuckets: number; totalMissingPayloads: number; totalRecords: number; totalSignedTransactions: number; totalUsers: number; usersByOrganization: Record<string, number>; }; users: object[]; }>

Defined in: observability/observability-service.ts:1193

Returns user identity metadata and counters, optionally scoped to one organization.

Parameters

args?

UserObservabilityFilters = {}

Returns

Promise<{ summary: { filteredOrganizationId: string | null; totalAvailablePayloads: number; totalBuckets: number; totalMissingPayloads: number; totalRecords: number; totalSignedTransactions: number; totalUsers: number; usersByOrganization: Record<string, number>; }; users: object[]; }>

Audience-first NOOSChain documentation.