import { c as isOperatorUiClient } from "./message-channel-B5ay7uNh.js";
//#region src/gateway/session-input-participant.ts
/** Only the live authenticated profile establishes a person; client metadata stays unresolved. */
function resolveGatewayInputParticipant(client, provenance) {
	if (!client || client.internal?.syntheticClient || provenance && provenance.kind !== "external_user") return;
	const profileId = client.authenticatedUserProfile?.profileId;
	if (profileId) return {
		type: "profile",
		id: profileId
	};
	const clientInfo = client.connect?.client;
	return !clientInfo || isOperatorUiClient(clientInfo) ? void 0 : {
		type: "observation",
		pluginId: null,
		accountId: null,
		senderKind: "unknown",
		id: clientInfo.id
	};
}
//#endregion
export { resolveGatewayInputParticipant as t };
