RocketChat/Rocket.Chat · error · Error

apps-engine-not-configured-correctly

apps-engine-not-configured-correctly

Error message

apps-engine-not-configured-correctly

What it means

Apps.self is loaded but getManager()?.getOutboundCommunicationProviderManager() returns nothing: the running apps-engine build does not expose the outbound communication manager. Unlike 'apps-engine-not-loaded' this is not transient — retrying will not fix it; the runtime itself lacks the manager.

Solutions

  1. Bring the apps-engine / @rocket.chat/apps packages to the version matching this server release
  2. Restart so the manager registers after the upgrade
  3. Verify which apps runtime actually serves the server (in-process vs apps microservice) and align its version
Defensive patterns

Strategy: try-catch

Validate before calling

import { Apps } from '@rocket.chat/apps';

const manager = Apps.self?.isLoaded()
  ? Apps.self?.getManager()?.getOutboundCommunicationProviderManager()
  : undefined;
if (!manager) {
  throw new Error('apps-engine runtime does not expose the outbound manager - version mismatch, upgrade @rocket.chat/apps');
}

Try / catch

try {
  return await outboundMessageProvider.sendMessage(providerId, message);
} catch (error) {
  if (error instanceof Error && error.message === 'apps-engine-not-configured-correctly') {
    // configuration defect, not transient: do NOT retry; surface an ops-facing error
    throw new ConfigurationError('apps-engine lacks the outbound communication manager; align apps-engine version with the server');
  }
  throw error;
}

Prevention

When it happens

Trigger: Version skew between the Rocket.Chat server and its @rocket.chat/apps packages after a partial upgrade; an apps microservice build that does not implement the outbound communication provider manager.

Common situations: Upgrade scripts updating the server but not the bundled apps-engine; custom builds; EE outbound features enabled against an older apps runtime.

Related errors


AI-assisted analysis of RocketChat/Rocket.Chat@b2c16d5842 (2026-08-18). Data as JSON: /api/errors/d92b24c17e78f96f. Report an issue: GitHub.

Appendix: source

Thrown at apps/meteor/ee/server/api/v1/omnichannel/lib/outbound.ts:53

	}

	public getProviderMetadata(providerId: string): Promise<IOutboundProviderMetadata> {
		const provider = this.provider.findOneByProviderId(providerId);
		if (!provider) {
			throw new Error('error-invalid-provider');
		}

		return this.getProviderManager().getProviderMetadata(provider.appId, provider.type);
	}

	private getProviderManager() {
		if (!Apps.self?.isLoaded()) {
			throw new Error('apps-engine-not-loaded');
		}

		const manager = Apps.self?.getManager()?.getOutboundCommunicationProviderManager();
		if (!manager) {
			throw new Error('apps-engine-not-configured-correctly');
		}

		return manager;
	}

	public sendMessage(providerId: string, message: IOutboundMessage) {
		const provider = this.provider.findOneByProviderId(providerId);
		if (!provider) {
			throw new Error('error-invalid-provider');
		}

		return this.getProviderManager().sendOutboundMessage(provider.appId, provider.type, message);
	}
}

export const outboundMessageProvider = new OutboundMessageProviderService();

getOutboundService.patch(() => {

View on GitHub (pinned to b2c16d5842)