openmeld 0.3.107 → 0.3.109

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/openmeld.js CHANGED
@@ -1,16 +1,17 @@
1
1
  #!/usr/bin/env node
2
2
 
3
3
  import { $ as runWithHeldLock, A as toSpaceContractUrl, At as openMeldBackupsDir, D as normalizeBaseUrl, E as updateConfiguredStartV1OnboardingState, F as toSpaceDispatchTraceUrl, Ft as openMeldRootDir, G as buildOpenMeldOrphanedLockAction, Gt as resolveOpenMeldRootDir, Ht as resolveOpenMeldCliEntryNameFromArgv, Jt as skillsDir, K as isOpenMeldLockError, Lt as organizationSkillReleaseDir, Mt as openMeldManagedBinaryPath, Nt as openMeldManagedVersionBinaryPath, Ot as normalizeAccountKey, P as toSpaceDispatchLookupUrl, Q as resolveOpenMeldOrphanedLockIssue, Rt as profileDir, S as setConfiguredSkillsConfig, St as accountsDir, Ut as resolveOpenMeldEnvPreset, V as toSpaceResultUrl, W as acquireLock, X as releaseLockSync, Xt as systemDir, Yt as spacesDir, Z as repairOrphanedLegacyLocks, Zt as formatLocalMachineIssueMessage, a as resolveBaseUrl, at as resolveCliContext, b as setConfiguredBaseUrl, bt as accountProfileViewPath, c as resolveExplicitGatewayUrlOrThrow, ct as formatLaneScopeSentence, ft as createActiveSetupConcurrencyIssue, g as getConfiguredSkillsConfig, gt as toRecognizedLocalMachineFailureError, ht as isLocalMachineFailureError, in as agentControllerConversationRefSchema, k as toSpaceBoardUrl, lt as resolveOpenMeldLaneDescriptor, m as getConfiguredOnboardingDisclaimerAcceptedAt, mt as createOrphanedSetupConcurrencyIssue, nt as OPENMELD_CLI_CONTEXT_ENV_KEY, o as resolveBaseUrlOrNull, q as isOpenMeldOrphanedLockError, tt as LEGACY_OPENMELD_AGENT_SESSION_ENV_KEY, u as alignRuntimeConfigStorage, ut as LocalMachineFailureError, w as updateConfiguredOnboardingConfig, yt as accountProfileSpaceCacheDir, zt as profileViewPath } from "./base-url-PkgATS5u.js";
4
- import { $ as runAgentsRepair, $a as installAgentActivityIntegrations, $i as readDaemonServiceJobCrashExitCode, $n as formatDaemonServiceMissingRecommendation, $r as resolveOpenClawLocalDiagnosticsValue, $t as readBundledOpenMeldCliSkillDocumentByPath, A as assertFullSignalIdArgument, Aa as updateOpenMeldProfile, Ai as resolveNativeAgentControllerPermissionModeForController, An as upsertSpaceConfig, Ao as setDefaultProjectConnection, Ar as DualViewGuideError, At as shouldEmitAgentOverview, B as persistAgentTransportSelection, Ba as resolveAuthenticationGuidanceFromMessage, Bi as assessServerRequiredVersion, Bn as promptSearchMultiselect, Bo as outJsonLine, Br as runPendingDaemonServiceUpdate, Bt as parseJsonResponse, C as toSpaceMetaUpsertInput, Ca as resolveOpenMeldProfileOrNull, Ci as getAgentControllerPermissionModeFieldLabel, Cn as submitRuntimeAgentControllerReport, Co as removeProjectOutbox, Cr as SPACE_ADD_MEMBERS_PROGRESS_HEARTBEAT_MS, Ct as runDaemonTeardownStrict, D as formatHumanReadTargetList, Da as listOpenMeldProfiles, Di as resolveAgentExecutionStatus, Dn as resolveLocalAgentControllerLaunchability, Do as migrateProjectBindingStore, Dr as registerAuthLoginRequestOptions, Dt as reconcileCliVersionView, E as buildHumanReplyContextSummary, Ea as deleteOpenMeldProfile, Ei as resolveAgentControllerPermissionModeForController, En as resolveLocalAgentControllerBlockerReasonCodes, Eo as listProjectConnectionsWithStatus, Er as registerDaemonControlTargetOptions, Et as buildProfileWorkspaceRows, F as emitSpaceAgentOverview, Fa as buildAgentAuthenticationGuide, Fi as buildDaemonServiceTargetSpec, Fn as buildSignalMessageReadProjection, Fo as renderInfoCard, Fr as SPACE_CONTRACT_ALLOWED_ACTION_ORDER, Ft as fetchSpaceMeta, G as runAgentsCustomList, Ga as LocalDaemonControlPlaneClientError, Gi as resetCurrentCommandCheckState, Gn as isCliUpdateCheckApplicable, Go as cliJsonSkillsLoadEnvelopeSchema, Gr as resolveServiceReadinessFromServiceStatus, Gt as runDaemonStartDecisionPrompt, H as runAgents, Ha as setProfileDefaultView, Hi as finishCurrentCommandCheckScope, Hn as isReturnKeypress, Ho as cliBinaryDeltaPatchSchema, Hr as ensureDaemonRuntimePaths, Ht as writeInstalledLocalComponentsSnapshot, I as emitSpaceCliAgentOverview, Ia as buildHumanAuthenticationCard, Ii as resolveDaemonServiceAlignmentDecision, In as buildSpaceRoundReadProjection, Io as renderTextInfoCard, Ir as areAllowedActionsEquivalent, It as updateSpaceMeta, J as runAgentsDetect, Ja as registerAgentActivityRoute, Ji as resolveVersionChangeDirection, Jn as readDispatchSpaceActionContextFromEnv, Jo as organizationJoinLinkErrorResponseSchema, Jr as formatAgentReplyReadinessLabel, Jt as runSkillsEnsure, K as runAgentsCustomRemove, Ka as requestLocalAgentActivitySync, Ki as startCurrentCommandCheckScope, Kn as assertDispatchOwnedRuntimePublicWriteAllowed, Ko as cliJsonSkillsShowEnvelopeSchema, Kr as resolveDaemonServiceFreshnessWarning, Kt as collectSkillsReadinessSnapshot, L as prepareLocalAgentReadiness, La as createAuthenticationError, Li as classifyDaemonServiceRunStartability, Ln as buildUpdatesReplyWorkflowProjection, Lo as sanitizeTerminalDisplayText, Lr as buildAgentFacingPublicationModeGuideLines, Lt as readGatewayJsonResponse, M as prepareAuthenticatedSpaceCommandContext, Ma as clearSelectedOpenMeldProfileId, Mi as buildDaemonRouteObservationPresentation$1, Mn as buildDispatchResultMessageReadProjection, Mo as canonicalizeLocalProjectPath, Mr as buildDualViewGuideMessage, Mt as readDaemonStartFailureLogTailLines, N as resolveOpenMeldProfileForSpaceCommand, Na as getSelectedOpenMeldProfileId, Ni as buildOnboardingPlan, Nn as buildDispatchResultReplyWorkflowProjection, No as enqueueControllerTaskLifecycleEventWhileLocked, Nr as formatAgentOverviewPayload, Nt as fetchSpaceUpdates, O as parseEnvelope, Oa as primeOpenMeldProfilesSessionCache, Oi as resolveAgentProfileEditCapabilities, On as resolveLocalAgentControllerReportDecision, Oo as removeProjectConnection, Or as registerBuiltinAgentSelectionOptions, Ot as emitDaemonAgentOverview, P as resolveSpaceAccessLabel, Pa as setSelectedOpenMeldProfileId, Pi as getSetupFlowCopy, Pn as buildSignalIndex, Po as readControllerTaskLifecycleOutboxHealth, Pr as OPENMELD_AGENT_MENTAL_MODEL_LINES, Pt as createCliSpaceApi, Q as runAgentsManage, Qa as defaultManagedIntegrationPaths, Qi as isDaemonServiceJobNeverSpawned, Qn as formatDaemonServiceDowngradeBlockedRecommendation, Qr as resolveGatewayChainReadiness, Qt as ensureLocalSkills, R as buildReplyReadinessGuidance, Ra as resolveAuthenticationGuidance, Ri as classifyDaemonServiceWakeability, Rn as createSpaceMemberIdentityIndex, Ro as emitCliJsonEnvelope, Rr as canonicalizeAllowedActions, Rt as readGatewayTextResponse, S as loadSpaceSignalIndexOrNull, Sa as requireOpenMeldProfile, Si as getAgentControllerPermissionModeDisplayMetadata, Sn as submitProfileRuntimeAgentControllerReport, So as readAgentActivityOutboxHealth, Sr as registerSpaceMemberSelectionOptions, St as runDaemonStop, T as buildFormalSignalReadPayload, Ta as createOpenMeldHumanProfile, Ti as parseAgentControllerRef, Tn as collectLocalAgentControllerInventory, To as listProjectBindings, Tr as getCliVersionInfo, Tt as buildProfileWorkspacePresentation, U as runAgentsConfig, Ua as LocalProjectConnectionError, Ui as getCurrentCommandCheckState, Un as runInteractivePrompt, Uo as cliJsonOutputEnvelopeSchema, Ur as resolveDaemonDeviceId, Ut as resolveDaemonServiceParticipationStatus, V as resolveAgentProfileSetup, Va as getProfileDefaultView, Vi as resolveOpenMeldEnvironmentTarget, Vn as promptSearchSelect, Vo as outLine, Vr as scheduleDaemonServiceUpdate, Vt as resolveLocalComponentsStatus, W as runAgentsCustomAdd, Wa as validateLocalProjectConnectionPath, Wi as isCurrentCommandCheckScopeActive, Wn as assessCliUpdate, Wo as cliJsonSkillsListEnvelopeSchema, Wr as formatDaemonFailureContextText, Wt as runDaemonServiceParticipationGate, X as runAgentsEnable, Xa as unregisterAgentActivityRoute, Xi as readCurrentObservedDaemonRuntimeStatus, Xn as formatElapsedTime, Xo as compareAgentControllerRefsForDisplay, Xr as formatHumanReplyReadinessReason$1, Xt as runSkillsUninstall, Y as runAgentsDisable, Ya as resolveAgentActivityRouteForPath, Yi as readCurrentDaemonRuntimeContext, Yn as writeDispatchSpaceActionRecord, Yo as revokeOrganizationJoinLinkResponseSchema, Yr as formatDeviceReplyReadinessLabel, Yt as runSkillsInstall, Z as runAgentsList, Zi as getDaemonSystemServiceLogPath, Zn as resolveElapsedTimeMs, Zo as package_default, Zr as mapAgentReplyReadinessToLegacyAutoReply, Zt as runSkillsUpdate, _ as runSpaceWriteWithPasswordRetry, _a as formatMessage, _i as listBuiltinAgentsRegistryEntries, _n as ensureAgentProfileRuntimeBinding, _o as resolveObservedAgentActivityBinding, _r as createStartAgentIdentityGuideError, _t as runDaemonInterrupt, a as runSpaceDelete, aa as ensureVersionStateReady, ai as normalizeCustomProfileWorkspacePath, an as evaluateCommandAuthentication, ao as formatOpenMeldCliCommands, ar as createResetConfirmationGuideError, at as printOpenMeldBanner, b as buildIdentityOnlyMembersSnapshotForReadProjection, ba as resolveViewProfileKey, bi as buildAgentControllerRef, bn as assessActionParticipationCandidate, bo as enqueueAgentActivityHookEvent, br as getCommandEntryContract, bt as runDaemonSnapshot, c as runSpaceLeave, ca as readVersionState, ci as setCustomProfileWorkspace, cn as runAuthMenu, co as formatProfileAwareOpenMeldCliCommands, cr as createSpaceContractSetGuideError, ct as renderOpenMeldLogo, d as runSpaceRemoveMembers, da as toStartBackgroundHelperExecutionCompatibility, di as describeProfileWorkspacePathValidationFailure, dn as buildAuthStatusSnapshot, do as syncLocalAgentActivity, dr as createSpacePublicationSetGuideError, dt as resolveSpaceSendText, ea as resolveDaemonServiceManager, ei as readRecentDaemonLifecycleEvents, en as readRuntimeReportingHealthState, eo as readAgentActivityIntegrationStatus, er as canUseInteractivePrompts, et as runAgentsShow, f as runSpaceSend, fa as resolveCurrentDaemonExpectedVersion, fi as syncDeviceRuntimeStateProjection, fn as formatActiveOrganizationLabel, fo as readDaemonServiceContract, fr as createSpaceRemoveMembersGuideError, ft as runDaemon, g as runSpaceReadWithPasswordRetry, ga as createPresenter, gi as reconcileNewRunnableBuiltinAgentsForSetup, gn as promptTextEntry, go as buildAgentActivityEvent, gr as createSpaceUpdatesGuideError, gt as runDaemonInstall, h as uploadPreparedSpaceFiles, ha as renderHumanTextErrorCard, hi as listAgentTargetStates, hn as resolveCreateProfileName, ho as removeAgentActivityContextCache, hr as createSpaceTargetGuideError, ht as runDaemonCancel, i as runSpaceCreate, ia as compareSemver, ii as ensureOpenMeldManagedProfileWorkspace, in as ensureCommandAuthenticationOrCancel, io as formatOpenMeldCliCommand, ir as createProfileMenuGuideError, it as colorizeDisplayProfileLabel, j as assertValidSpaceIdTarget, ja as alignSelectedOpenMeldProfileStorage, jn as assertNoRemovedCcSpaceAddressingSyntax, jo as unbindProject, jr as formatDualViewGuideForDisplay, jt as runDaemonStartupPreflight, k as isSpaceCommandOutputHandledError, ka as resolveOpenMeldProfile, ki as resolveEvidenceSyncHealth, kn as inspectSpaceCacheFile, ko as runIfAgentActivityBindingGenerationIsCurrent, kr as buildAgentOverviewFromContract, kt as createDelayedSpinner, l as runSpaceList, la as writeVersionState, li as setOpenMeldManagedProfileWorkspace, ln as runAuthStatus, lo as resolveSetupFollowUpCliEntryCommand, lr as createSpaceLeaveGuideError, lt as renderOpenMeldTagline, m as prepareRequestedSpaceSendFiles, ma as renderHumanErrorCard, mi as resolveAgentProfilePrimaryAgentControllerReport, mn as resolveCreateProfileKind, mo as readAgentActivityContextForPath, mr as createSpaceSubcommandTargetGuideError, mt as runDaemonBackgroundStartForDecision, n as promptAndConfirmSpacePassword, na as performManagedInstall, ni as createModelCatalogReadSession, nn as connectWebSocket, no as uninstallAgentActivityIntegrations, nr as createProfileActionGuideError, nt as postLocalParticipationMutationReconcile, o as runSpaceHistory, oa as fetchLatestCliBinaryRelease, oi as readProfileWorkspaceConfig, on as runAuthLogin, oo as formatOpenMeldCliLine, or as createSpaceAddMembersGuideError, ot as renderOpenMeldBrandBlockLines, p as runSpaceWatch, pa as buildHumanErrorCopy, pi as createPrimaryBindingReadSession, pn as createProfileByKind, po as upsertDaemonServiceContract, pr as createSpaceResultGuideError, pt as runDaemonAutostart, q as runAgentsCustomUpdate, qa as isAgentActivityRouteRegistered, qi as inspectDaemonServiceInventory, qn as readDispatchOwnedRuntimeGuard, qo as getOrganizationJoinLinkResponseSchema, qr as resolveCurrentReplyReadinessSnapshot, qt as runSkillsCheck$1, r as runSpaceAddMembers, ra as buildNextVersionState, ri as resolveProfileWorkspaceRuntime, rn as buildCommandAuthenticationPromptMessage, ro as formatInlineOpenMeldCliCommands, rr as createProfileCreateGuideError, rt as colorizeAgentLabel, s as runSpaceJoin, sa as fetchLatestPackageInfo, si as resolveConfiguredProfileWorkspacePath, sn as runAuthLogout, so as formatOpenMeldCliTextBlock, sr as createSpaceAliasTargetGuideError, st as renderOpenMeldHeader, t as buildCreateSpacePasswordPromptConfig, ta as buildInstallSelfJsonPayload, ti as syncProfileWorkspaceState, tn as readRecentDaemonDispatchJournalEvents, to as resolveAgentActivityDispatcherCommand, tr as createDoctorFailedGuideError, tt as formatTransportModeDisplay, u as runSpacePassword, ua as resolveDaemonRuntimeContractCompatibility, ui as validateCustomProfileWorkspacePath, un as buildAuthStatusRows, uo as resolveUserFacingCliEntryCommand, ur as createSpaceMenuGuideError, ut as resolveGatewayWebOrigin, v as buildHumanReadSignalsTranscriptItems, va as parseCliViewMode, vi as notifyDaemonRouteCatalogChanged, vn as formatServiceParticipationReadinessLabel, vo as normalizeSharedSessionTitle, vr as createStartAuthenticationGuideError, vt as runDaemonReinstall, w as buildFormalDispatchResultReadPayload, wa as createOpenMeldAgentProfile, wi as listAgentControllerPermissionModeOptions, wn as submitRuntimeAgentControllerReports, wo as bindProject, wr as registerSkillsTargetSelectionOptions, wt as runDaemonUninstall, x as loadSpaceIdentityDirectoryOrNull, xa as isSelectedOpenMeldProfileRequiredError, xi as createAgentExecutionStatusDisplayRows, xn as computeRetryDelayMs, xo as removeProjectInbox, xr as getCommandHintsFromContract, xt as runDaemonStatusFlow, y as emitHumanReadSignalsTextProjection, ya as resolveRuntimeContext, yi as resolveLocalRegistryAgentIdFromAgentControllerRef, yn as resolveServiceParticipationReadiness, yo as readCodexSessionTitles, yr as createUpgradeConfirmationGuideError, yt as runDaemonRunAfterEntryChecks, z as resolveHumanControllerDisplayName, za as resolveAuthenticationGuidanceFromError, zi as resolveServiceUpdateUrgency, zn as formatRemovedCcRelationMessage, zo as errLine, zr as readOpenMeldToolsUpdateContextFromEnv, zt as toStructuredGatewayFailure } from "./command-DmVde7c-.js";
5
- import { $ as ownerComputerDiagnosticsSchema, $t as agentActivityInventorySessionStatusSchema, B as sleep, Bt as agentActivityProviderSchema, Ct as authProfileKindSchema, D as toStructuredApiClientFailure, F as OPENMELD_HEADER_PROFILE_ID, G as projectSpaceDispatchTraceFinalVisibleOutcome, Ht as agentActivitySnapshotQuerySchema, J as spaceDispatchTraceDispatchStatusSchema, K as resolveSpaceDispatchTraceRootCause, Ot as submitFeedbackIssueRequestSchema, Qt as agentActivityInventorySessionOriginSchema, Vt as agentActivitySessionStatusSchema, W as SPACE_DISPATCH_TRACE_RESPONSE_CONTRACT_VERSION_HEADER, X as observabilityWakeTraceSelectorSchema, Y as spaceDispatchTraceResponseSchema, Z as projectObservabilityWakeCorrelation, _ as createOrganizationSkillsApi, b as createProjectsApi, c as createAgentProfileBindingApi, d as createCurrentDeviceApi, dn as START_BOUNDED_ID_SCHEMA, en as agentActivitySessionInventoryQuerySchema, et as projectOwnerComputerLocalRuntimes, f as createFeedbackApi, fn as START_BOUNDED_VERSION_SCHEMA, g as createOrganizationApi, gn as localAgentCatalogSchema, gt as organizationSkillBundleSchema, hn as startReplyReadinessSummarySchema, l as createCenterAgentApi, mn as START_TRIMMED_NON_EMPTY_STRING_SCHEMA, nn as localAgentSessionProviderSchema, nt as DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION, pn as START_ISO_DATE_TIME_SCHEMA, q as spaceDispatchTraceAttemptStatusSchema, rt as agentProfileCreationConfigurationSchema, s as createAgentActivityApi, tt as summarizeComputerFileAccessPolicy, u as createComputerFileAccessApi, v as createPrepareReadinessApi, wt as authProfileManagedRoleSchema, x as createRoutinesApi, yt as stringifyOrganizationSkillBundleCanonicalJson } from "./dist-Bypn86JC.js";
6
- import { Bt as resolveSpaceFileMimeType, Er as openMeldRuntimeProfileIdSchema, Fr as trimmedStringFromUnknown, Lt as isSpaceFileTextEditable, Mt as centerAgentInteractionSourceSchema, Nr as nonEmptyTrimmedStringFromUnknown, bn as messageEnvelopeSchema, cn as spaceContractSchema, er as clientMessageIdSchema, jt as spaceStatusSchema, nn as dispatchExecutionSchema, rn as spaceThreadContextSchema, sn as spaceContractFieldsSchema, xr as openMeldProfileIdSchema } from "./runtime-transport-CJRu8NiO.js";
4
+ import { $ as runAgentsRepair, $a as installAgentActivityIntegrations, $i as readDaemonServiceJobCrashExitCode, $n as formatDaemonServiceMissingRecommendation, $r as resolveOpenClawLocalDiagnosticsValue, $t as readBundledOpenMeldCliSkillDocumentByPath, A as assertFullSignalIdArgument, Aa as updateOpenMeldProfile, Ai as resolveNativeAgentControllerPermissionModeForController, An as upsertSpaceConfig, Ao as setDefaultProjectConnection, Ar as DualViewGuideError, At as shouldEmitAgentOverview, B as persistAgentTransportSelection, Ba as resolveAuthenticationGuidanceFromMessage, Bi as assessServerRequiredVersion, Bn as promptSearchMultiselect, Bo as outJsonLine, Br as runPendingDaemonServiceUpdate, Bt as parseJsonResponse, C as toSpaceMetaUpsertInput, Ca as resolveOpenMeldProfileOrNull, Ci as getAgentControllerPermissionModeFieldLabel, Cn as submitRuntimeAgentControllerReport, Co as removeProjectOutbox, Cr as SPACE_ADD_MEMBERS_PROGRESS_HEARTBEAT_MS, Ct as runDaemonTeardownStrict, D as formatHumanReadTargetList, Da as listOpenMeldProfiles, Di as resolveAgentExecutionStatus, Dn as resolveLocalAgentControllerLaunchability, Do as migrateProjectBindingStore, Dr as registerAuthLoginRequestOptions, Dt as reconcileCliVersionView, E as buildHumanReplyContextSummary, Ea as deleteOpenMeldProfile, Ei as resolveAgentControllerPermissionModeForController, En as resolveLocalAgentControllerBlockerReasonCodes, Eo as listProjectConnectionsWithStatus, Er as registerDaemonControlTargetOptions, Et as buildProfileWorkspaceRows, F as emitSpaceAgentOverview, Fa as buildAgentAuthenticationGuide, Fi as buildDaemonServiceTargetSpec, Fn as buildSignalMessageReadProjection, Fo as renderInfoCard, Fr as SPACE_CONTRACT_ALLOWED_ACTION_ORDER, Ft as fetchSpaceMeta, G as runAgentsCustomList, Ga as LocalDaemonControlPlaneClientError, Gi as resetCurrentCommandCheckState, Gn as isCliUpdateCheckApplicable, Go as cliJsonSkillsLoadEnvelopeSchema, Gr as resolveServiceReadinessFromServiceStatus, Gt as runDaemonStartDecisionPrompt, H as runAgents, Ha as setProfileDefaultView, Hi as finishCurrentCommandCheckScope, Hn as isReturnKeypress, Ho as cliBinaryDeltaPatchSchema, Hr as ensureDaemonRuntimePaths, Ht as writeInstalledLocalComponentsSnapshot, I as emitSpaceCliAgentOverview, Ia as buildHumanAuthenticationCard, Ii as resolveDaemonServiceAlignmentDecision, In as buildSpaceRoundReadProjection, Io as renderTextInfoCard, Ir as areAllowedActionsEquivalent, It as updateSpaceMeta, J as runAgentsDetect, Ja as registerAgentActivityRoute, Ji as resolveVersionChangeDirection, Jn as readDispatchSpaceActionContextFromEnv, Jo as organizationJoinLinkErrorResponseSchema, Jr as formatAgentReplyReadinessLabel, Jt as runSkillsEnsure, K as runAgentsCustomRemove, Ka as requestLocalAgentActivitySync, Ki as startCurrentCommandCheckScope, Kn as assertDispatchOwnedRuntimePublicWriteAllowed, Ko as cliJsonSkillsShowEnvelopeSchema, Kr as resolveDaemonServiceFreshnessWarning, Kt as collectSkillsReadinessSnapshot, L as prepareLocalAgentReadiness, La as createAuthenticationError, Li as classifyDaemonServiceRunStartability, Ln as buildUpdatesReplyWorkflowProjection, Lo as sanitizeTerminalDisplayText, Lr as buildAgentFacingPublicationModeGuideLines, Lt as readGatewayJsonResponse, M as prepareAuthenticatedSpaceCommandContext, Ma as clearSelectedOpenMeldProfileId, Mi as buildDaemonRouteObservationPresentation$1, Mn as buildDispatchResultMessageReadProjection, Mo as canonicalizeLocalProjectPath, Mr as buildDualViewGuideMessage, Mt as readDaemonStartFailureLogTailLines, N as resolveOpenMeldProfileForSpaceCommand, Na as getSelectedOpenMeldProfileId, Ni as buildOnboardingPlan, Nn as buildDispatchResultReplyWorkflowProjection, No as enqueueControllerTaskLifecycleEventWhileLocked, Nr as formatAgentOverviewPayload, Nt as fetchSpaceUpdates, O as parseEnvelope, Oa as primeOpenMeldProfilesSessionCache, Oi as resolveAgentProfileEditCapabilities, On as resolveLocalAgentControllerReportDecision, Oo as removeProjectConnection, Or as registerBuiltinAgentSelectionOptions, Ot as emitDaemonAgentOverview, P as resolveSpaceAccessLabel, Pa as setSelectedOpenMeldProfileId, Pi as getSetupFlowCopy, Pn as buildSignalIndex, Po as readControllerTaskLifecycleOutboxHealth, Pr as OPENMELD_AGENT_MENTAL_MODEL_LINES, Pt as createCliSpaceApi, Q as runAgentsManage, Qa as defaultManagedIntegrationPaths, Qi as isDaemonServiceJobNeverSpawned, Qn as formatDaemonServiceDowngradeBlockedRecommendation, Qr as resolveGatewayChainReadiness, Qt as ensureLocalSkills, R as buildReplyReadinessGuidance, Ra as resolveAuthenticationGuidance, Ri as classifyDaemonServiceWakeability, Rn as createSpaceMemberIdentityIndex, Ro as emitCliJsonEnvelope, Rr as canonicalizeAllowedActions, Rt as readGatewayTextResponse, S as loadSpaceSignalIndexOrNull, Sa as requireOpenMeldProfile, Si as getAgentControllerPermissionModeDisplayMetadata, Sn as submitProfileRuntimeAgentControllerReport, So as readAgentActivityOutboxHealth, Sr as registerSpaceMemberSelectionOptions, St as runDaemonStop, T as buildFormalSignalReadPayload, Ta as createOpenMeldHumanProfile, Ti as parseAgentControllerRef, Tn as collectLocalAgentControllerInventory, To as listProjectBindings, Tr as getCliVersionInfo, Tt as buildProfileWorkspacePresentation, U as runAgentsConfig, Ua as LocalProjectConnectionError, Ui as getCurrentCommandCheckState, Un as runInteractivePrompt, Uo as cliJsonOutputEnvelopeSchema, Ur as resolveDaemonDeviceId, Ut as resolveDaemonServiceParticipationStatus, V as resolveAgentProfileSetup, Va as getProfileDefaultView, Vi as resolveOpenMeldEnvironmentTarget, Vn as promptSearchSelect, Vo as outLine, Vr as scheduleDaemonServiceUpdate, Vt as resolveLocalComponentsStatus, W as runAgentsCustomAdd, Wa as validateLocalProjectConnectionPath, Wi as isCurrentCommandCheckScopeActive, Wn as assessCliUpdate, Wo as cliJsonSkillsListEnvelopeSchema, Wr as formatDaemonFailureContextText, Wt as runDaemonServiceParticipationGate, X as runAgentsEnable, Xa as unregisterAgentActivityRoute, Xi as readCurrentObservedDaemonRuntimeStatus, Xn as formatElapsedTime, Xo as compareAgentControllerRefsForDisplay, Xr as formatHumanReplyReadinessReason$1, Xt as runSkillsUninstall, Y as runAgentsDisable, Ya as resolveAgentActivityRouteForPath, Yi as readCurrentDaemonRuntimeContext, Yn as writeDispatchSpaceActionRecord, Yo as revokeOrganizationJoinLinkResponseSchema, Yr as formatDeviceReplyReadinessLabel, Yt as runSkillsInstall, Z as runAgentsList, Zi as getDaemonSystemServiceLogPath, Zn as resolveElapsedTimeMs, Zo as package_default, Zr as mapAgentReplyReadinessToLegacyAutoReply, Zt as runSkillsUpdate, _ as runSpaceWriteWithPasswordRetry, _a as formatMessage, _i as listBuiltinAgentsRegistryEntries, _n as ensureAgentProfileRuntimeBinding, _o as resolveObservedAgentActivityBinding, _r as createStartAgentIdentityGuideError, _t as runDaemonInterrupt, a as runSpaceDelete, aa as ensureVersionStateReady, ai as normalizeCustomProfileWorkspacePath, an as evaluateCommandAuthentication, ao as formatOpenMeldCliCommands, ar as createResetConfirmationGuideError, at as printOpenMeldBanner, b as buildIdentityOnlyMembersSnapshotForReadProjection, ba as resolveViewProfileKey, bi as buildAgentControllerRef, bn as assessActionParticipationCandidate, bo as enqueueAgentActivityHookEvent, br as getCommandEntryContract, bt as runDaemonSnapshot, c as runSpaceLeave, ca as readVersionState, ci as setCustomProfileWorkspace, cn as runAuthMenu, co as formatProfileAwareOpenMeldCliCommands, cr as createSpaceContractSetGuideError, ct as renderOpenMeldLogo, d as runSpaceRemoveMembers, da as toStartBackgroundHelperExecutionCompatibility, di as describeProfileWorkspacePathValidationFailure, dn as buildAuthStatusSnapshot, do as syncLocalAgentActivity, dr as createSpacePublicationSetGuideError, dt as resolveSpaceSendText, ea as resolveDaemonServiceManager, ei as readRecentDaemonLifecycleEvents, en as readRuntimeReportingHealthState, eo as readAgentActivityIntegrationStatus, er as canUseInteractivePrompts, et as runAgentsShow, f as runSpaceSend, fa as resolveCurrentDaemonExpectedVersion, fi as syncDeviceRuntimeStateProjection, fn as formatActiveOrganizationLabel, fo as readDaemonServiceContract, fr as createSpaceRemoveMembersGuideError, ft as runDaemon, g as runSpaceReadWithPasswordRetry, ga as createPresenter, gi as reconcileNewRunnableBuiltinAgentsForSetup, gn as promptTextEntry, go as buildAgentActivityEvent, gr as createSpaceUpdatesGuideError, gt as runDaemonInstall, h as uploadPreparedSpaceFiles, ha as renderHumanTextErrorCard, hi as listAgentTargetStates, hn as resolveCreateProfileName, ho as removeAgentActivityContextCache, hr as createSpaceTargetGuideError, ht as runDaemonCancel, i as runSpaceCreate, ia as compareSemver, ii as ensureOpenMeldManagedProfileWorkspace, in as ensureCommandAuthenticationOrCancel, io as formatOpenMeldCliCommand, ir as createProfileMenuGuideError, it as colorizeDisplayProfileLabel, j as assertValidSpaceIdTarget, ja as alignSelectedOpenMeldProfileStorage, jn as assertNoRemovedCcSpaceAddressingSyntax, jo as unbindProject, jr as formatDualViewGuideForDisplay, jt as runDaemonStartupPreflight, k as isSpaceCommandOutputHandledError, ka as resolveOpenMeldProfile, ki as resolveEvidenceSyncHealth, kn as inspectSpaceCacheFile, ko as runIfAgentActivityBindingGenerationIsCurrent, kr as buildAgentOverviewFromContract, kt as createDelayedSpinner, l as runSpaceList, la as writeVersionState, li as setOpenMeldManagedProfileWorkspace, ln as runAuthStatus, lo as resolveSetupFollowUpCliEntryCommand, lr as createSpaceLeaveGuideError, lt as renderOpenMeldTagline, m as prepareRequestedSpaceSendFiles, ma as renderHumanErrorCard, mi as resolveAgentProfilePrimaryAgentControllerReport, mn as resolveCreateProfileKind, mo as readAgentActivityContextForPath, mr as createSpaceSubcommandTargetGuideError, mt as runDaemonBackgroundStartForDecision, n as promptAndConfirmSpacePassword, na as performManagedInstall, ni as createModelCatalogReadSession, nn as connectWebSocket, no as uninstallAgentActivityIntegrations, nr as createProfileActionGuideError, nt as postLocalParticipationMutationReconcile, o as runSpaceHistory, oa as fetchLatestCliBinaryRelease, oi as readProfileWorkspaceConfig, on as runAuthLogin, oo as formatOpenMeldCliLine, or as createSpaceAddMembersGuideError, ot as renderOpenMeldBrandBlockLines, p as runSpaceWatch, pa as buildHumanErrorCopy, pi as createPrimaryBindingReadSession, pn as createProfileByKind, po as upsertDaemonServiceContract, pr as createSpaceResultGuideError, pt as runDaemonAutostart, q as runAgentsCustomUpdate, qa as isAgentActivityRouteRegistered, qi as inspectDaemonServiceInventory, qn as readDispatchOwnedRuntimeGuard, qo as getOrganizationJoinLinkResponseSchema, qr as resolveCurrentReplyReadinessSnapshot, qt as runSkillsCheck$1, r as runSpaceAddMembers, ra as buildNextVersionState, ri as resolveProfileWorkspaceRuntime, rn as buildCommandAuthenticationPromptMessage, ro as formatInlineOpenMeldCliCommands, rr as createProfileCreateGuideError, rt as colorizeAgentLabel, s as runSpaceJoin, sa as fetchLatestPackageInfo, si as resolveConfiguredProfileWorkspacePath, sn as runAuthLogout, so as formatOpenMeldCliTextBlock, sr as createSpaceAliasTargetGuideError, st as renderOpenMeldHeader, t as buildCreateSpacePasswordPromptConfig, ta as buildInstallSelfJsonPayload, ti as syncProfileWorkspaceState, tn as readRecentDaemonDispatchJournalEvents, to as resolveAgentActivityDispatcherCommand, tr as createDoctorFailedGuideError, tt as formatTransportModeDisplay, u as runSpacePassword, ua as resolveDaemonRuntimeContractCompatibility, ui as validateCustomProfileWorkspacePath, un as buildAuthStatusRows, uo as resolveUserFacingCliEntryCommand, ur as createSpaceMenuGuideError, ut as resolveGatewayWebOrigin, v as buildHumanReadSignalsTranscriptItems, va as parseCliViewMode, vi as notifyDaemonRouteCatalogChanged, vn as formatServiceParticipationReadinessLabel, vo as normalizeSharedSessionTitle, vr as createStartAuthenticationGuideError, vt as runDaemonReinstall, w as buildFormalDispatchResultReadPayload, wa as createOpenMeldAgentProfile, wi as listAgentControllerPermissionModeOptions, wn as submitRuntimeAgentControllerReports, wo as bindProject, wr as registerSkillsTargetSelectionOptions, wt as runDaemonUninstall, x as loadSpaceIdentityDirectoryOrNull, xa as isSelectedOpenMeldProfileRequiredError, xi as createAgentExecutionStatusDisplayRows, xn as computeRetryDelayMs, xo as removeProjectInbox, xr as getCommandHintsFromContract, xt as runDaemonStatusFlow, y as emitHumanReadSignalsTextProjection, ya as resolveRuntimeContext, yi as resolveLocalRegistryAgentIdFromAgentControllerRef, yn as resolveServiceParticipationReadiness, yo as readCodexSessionTitles, yr as createUpgradeConfirmationGuideError, yt as runDaemonRunAfterEntryChecks, z as resolveHumanControllerDisplayName, za as resolveAuthenticationGuidanceFromError, zi as resolveServiceUpdateUrgency, zn as formatRemovedCcRelationMessage, zo as errLine, zr as readOpenMeldToolsUpdateContextFromEnv, zt as toStructuredGatewayFailure } from "./command-BZRJ4QV_.js";
5
+ import { $ as ownerComputerDiagnosticsSchema, $t as agentActivityInventorySessionStatusSchema, B as sleep, Bt as agentActivityProviderSchema, Ct as authProfileKindSchema, D as toStructuredApiClientFailure, F as OPENMELD_HEADER_PROFILE_ID, G as projectSpaceDispatchTraceFinalVisibleOutcome, Ht as agentActivitySnapshotQuerySchema, J as spaceDispatchTraceDispatchStatusSchema, K as resolveSpaceDispatchTraceRootCause, Ot as submitFeedbackIssueRequestSchema, Qt as agentActivityInventorySessionOriginSchema, Vt as agentActivitySessionStatusSchema, W as SPACE_DISPATCH_TRACE_RESPONSE_CONTRACT_VERSION_HEADER, X as observabilityWakeTraceSelectorSchema, Y as spaceDispatchTraceResponseSchema, Z as projectObservabilityWakeCorrelation, _ as createOrganizationSkillsApi, b as createProjectsApi, c as createAgentProfileBindingApi, d as createCurrentDeviceApi, dn as START_BOUNDED_ID_SCHEMA, en as agentActivitySessionInventoryQuerySchema, et as projectOwnerComputerLocalRuntimes, f as createFeedbackApi, fn as START_BOUNDED_VERSION_SCHEMA, g as createOrganizationApi, gn as localAgentCatalogSchema, gt as organizationSkillBundleSchema, hn as startReplyReadinessSummarySchema, l as createCenterAgentApi, mn as START_TRIMMED_NON_EMPTY_STRING_SCHEMA, nn as localAgentSessionProviderSchema, nt as DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION, pn as START_ISO_DATE_TIME_SCHEMA, q as spaceDispatchTraceAttemptStatusSchema, rt as agentProfileCreationConfigurationSchema, s as createAgentActivityApi, tt as summarizeComputerFileAccessPolicy, u as createComputerFileAccessApi, v as createPrepareReadinessApi, wt as authProfileManagedRoleSchema, x as createRoutinesApi, yt as stringifyOrganizationSkillBundleCanonicalJson } from "./dist-C_v_J7PS.js";
6
+ import { Bt as resolveSpaceFileMimeType, Er as openMeldRuntimeProfileIdSchema, Fr as trimmedStringFromUnknown, Lt as isSpaceFileTextEditable, Mt as centerAgentInteractionSourceSchema, Nr as nonEmptyTrimmedStringFromUnknown, bn as messageEnvelopeSchema, cn as spaceContractSchema, er as clientMessageIdSchema, jt as spaceStatusSchema, nn as dispatchExecutionSchema, rn as spaceThreadContextSchema, sn as spaceContractFieldsSchema, xr as openMeldProfileIdSchema } from "./runtime-transport-C3tPSwZv.js";
7
7
  import { r as daemonServiceLaneSchema } from "./service-contract-CRyDcIIf.js";
8
8
  import { O as getDaemonStatus } from "./daemon-runtime-lease-Cath1v3w.js";
9
- import { a as getCurrentAuthOwnerUserId, c as updateAuthSessionActiveOrganization, d as resolveOpenMeldDistribution, i as getAuthSessionState, l as runMacOsNativeKeychainHelperIfRequested, n as clearAuthSession, o as normalizeStoredActiveOrganization, r as getAuthSessionMetadata, u as isBinaryDistribution } from "./auth-session-Bcfr1k3c.js";
10
- import { c as buildRequestAuthHeaders, d as buildOpenMeldRequestContextFromProfile, n as createCliApiClientFoundation, p as deriveAuthBaseUrlFromGatewayUrl, r as fetchSpaceRequestWithTimeout, s as buildOpenMeldRequestContextHeadersWithAuth } from "./api-client-foundation-DhvXlRGR.js";
9
+ import { a as getCurrentAuthOwnerUserId, c as updateAuthSessionActiveOrganization, d as resolveOpenMeldDistribution, i as getAuthSessionState, l as runMacOsNativeKeychainHelperIfRequested, n as clearAuthSession, o as normalizeStoredActiveOrganization, r as getAuthSessionMetadata, u as isBinaryDistribution } from "./auth-session-D4Jml91O.js";
10
+ import { c as buildRequestAuthHeaders, d as buildOpenMeldRequestContextFromProfile, n as createCliApiClientFoundation, p as deriveAuthBaseUrlFromGatewayUrl, r as fetchSpaceRequestWithTimeout, s as buildOpenMeldRequestContextHeadersWithAuth } from "./api-client-foundation-BQgqRvE9.js";
11
11
  import { Command, Option } from "commander";
12
12
  import os, { homedir, hostname, release, tmpdir } from "node:os";
13
13
  import * as z$1 from "zod/v4";
14
+ import { z } from "zod/v4";
14
15
  import { basename, dirname, isAbsolute, join, relative, resolve } from "node:path";
15
16
  import process$1 from "node:process";
16
17
  import pc from "picocolors";
@@ -18,12 +19,14 @@ import { promisify } from "node:util";
18
19
  import { createHash, randomUUID } from "node:crypto";
19
20
  import { access, appendFile, chmod, mkdir, mkdtemp, open, readFile, readdir, realpath, rename, rm, stat, writeFile } from "node:fs/promises";
20
21
  import { execFile, spawn } from "node:child_process";
21
- import { closeSync, constants, openSync, realpathSync } from "node:fs";
22
+ import { closeSync, constants, openSync, readFileSync, realpathSync } from "node:fs";
22
23
  import { setTimeout as setTimeout$1 } from "node:timers/promises";
23
24
  import { cancel, confirm, intro, isCancel, multiselect, note, outro, select, spinner, text } from "@clack/prompts";
24
25
  import { gunzipSync } from "node:zlib";
25
26
  import { ReadStream, WriteStream } from "node:tty";
26
27
  import { performance } from "node:perf_hooks";
28
+ import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
29
+ import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
27
30
  //#region ../../packages/schemas/dist/schemas/agent-view/center-agent.js
28
31
  const centerAgentOrganizationTargetSchema = z$1.strictObject({
29
32
  id: z$1.string().trim().min(1),
@@ -24596,15 +24599,26 @@ async function resolveRequestConfiguration(input) {
24596
24599
  });
24597
24600
  return agentProfileCreationConfigurationSchema.parse({
24598
24601
  ...DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION,
24602
+ agentControllerCollaborationMode: normalizeOptionalText$1(input.agentControllerCollaborationMode) ?? null,
24599
24603
  agentControllerPermissionMode: permissionMode.agentControllerPermissionMode ?? null,
24600
24604
  agentControllerRef: agentControllerRef ?? null,
24601
24605
  authorizeForOrganization: input.authorizeForOrganization !== false,
24602
24606
  defaultProjectId: normalizeOptionalText$1(input.defaultProjectId) ?? null,
24603
24607
  modelId: normalizeOptionalText$1(input.modelId) ?? null,
24608
+ openCodePermission: parseOpenCodePermissionInput(input.openCodePermissionInput),
24604
24609
  reasoningLevel: normalizeOptionalText$1(input.reasoningLevel) ?? null,
24605
24610
  targetComputerId: targetComputerId ?? null
24606
24611
  });
24607
24612
  }
24613
+ function parseOpenCodePermissionInput(value) {
24614
+ const normalized = normalizeOptionalText$1(value);
24615
+ if (!normalized) return null;
24616
+ try {
24617
+ return JSON.parse(normalized);
24618
+ } catch {
24619
+ throw new Error("--open-code-permission must be a valid JSON object.");
24620
+ }
24621
+ }
24608
24622
  async function runProfileCreationRequestList(input = {}) {
24609
24623
  const context = await resolveProfileCreationRequestCommandContext(input);
24610
24624
  if (!context) return;
@@ -26631,16 +26645,30 @@ const WHITESPACE_PATTERN = /\s+/g;
26631
26645
  const DISPATCH_ACTION_CLI_PLACEHOLDER = "<DISPATCH_ACTION_CLI>";
26632
26646
  const SPACE_ACTION_REPLY_TIMING_EVENT = "openmeld.space_action.reply_timing";
26633
26647
  function runSpaceActionReply(input) {
26648
+ const text = resolveReplyMessageText(input);
26649
+ const result = recordDispatchSpaceReply({
26650
+ filePaths: input.filePaths,
26651
+ messagePartCount: input.messageParts.length,
26652
+ referenceTargets: input.referenceTargets,
26653
+ text,
26654
+ wakeTargets: input.wakeTargets
26655
+ });
26656
+ if (result instanceof Promise) return result.then((record) => {
26657
+ emitActionRecorded(record);
26658
+ });
26659
+ emitActionRecorded(result);
26660
+ }
26661
+ function recordDispatchSpaceReply(input) {
26634
26662
  const timing = createSpaceActionReplyTiming();
26635
26663
  timing.emit("command_start", void 0, {
26636
- messagePartCount: input.messageParts.length,
26664
+ messagePartCount: input.messagePartCount ?? 0,
26637
26665
  referenceTargetCount: input.referenceTargets?.length ?? 0,
26638
26666
  wakeTargetCount: input.wakeTargets?.length ?? 0
26639
26667
  });
26640
26668
  const context = readDispatchSpaceActionContextFromEnv();
26641
26669
  timing.emit("context_ready", context);
26642
26670
  assertAllowedAction(context, "post_message");
26643
- const text = normalizeRequiredJoinedText(input.messageParts, "Reply message is required.");
26671
+ const text = normalizeRequiredText(input.text, "Reply message is required.");
26644
26672
  assertNoRemovedCcSpaceAddressingSyntax(text);
26645
26673
  const targetIds = resolveMessageEnvelopeTargetIds({
26646
26674
  context,
@@ -26653,16 +26681,13 @@ function runSpaceActionReply(input) {
26653
26681
  referenceTargetCount: targetIds.referenceTargets.length
26654
26682
  });
26655
26683
  const filePaths = input.filePaths ?? [];
26656
- if (filePaths.length === 0) {
26657
- recordSpaceActionReply({
26658
- context,
26659
- files: [],
26660
- targetIds,
26661
- text,
26662
- timing
26663
- });
26664
- return;
26665
- }
26684
+ if (filePaths.length === 0) return writeSpaceActionReplyRecord({
26685
+ context,
26686
+ files: [],
26687
+ targetIds,
26688
+ text,
26689
+ timing
26690
+ });
26666
26691
  return uploadAndRecordSpaceActionReply({
26667
26692
  context,
26668
26693
  filePaths,
@@ -26671,17 +26696,24 @@ function runSpaceActionReply(input) {
26671
26696
  timing
26672
26697
  });
26673
26698
  }
26699
+ function resolveReplyMessageText(input) {
26700
+ const hasInlineMessage = input.messageParts.length > 0;
26701
+ const messageFilePath = input.messageFilePath?.trim();
26702
+ if (hasInlineMessage && messageFilePath) throw new Error("Choose either a reply message or --message-file, not both.");
26703
+ if (!messageFilePath) return normalizeRequiredJoinedText(input.messageParts, "Reply message is required.");
26704
+ return normalizeRequiredText(readFileSync(messageFilePath === "-" ? 0 : messageFilePath, { encoding: "utf8" }), "Reply message is required.");
26705
+ }
26674
26706
  async function uploadAndRecordSpaceActionReply(input) {
26675
26707
  const files = await uploadSpaceActionReplyFiles({
26676
26708
  context: input.context,
26677
26709
  filePaths: input.filePaths
26678
26710
  });
26679
- recordSpaceActionReply({
26711
+ return writeSpaceActionReplyRecord({
26680
26712
  ...input,
26681
26713
  files
26682
26714
  });
26683
26715
  }
26684
- function recordSpaceActionReply(input) {
26716
+ function writeSpaceActionReplyRecord(input) {
26685
26717
  const record = recordAction({
26686
26718
  action: {
26687
26719
  type: "post_message",
@@ -26698,6 +26730,7 @@ function recordSpaceActionReply(input) {
26698
26730
  });
26699
26731
  input.timing.emit("record_written", input.context, { actionType: record.action.type });
26700
26732
  input.timing.emit("done", input.context, { actionType: record.action.type });
26733
+ return record;
26701
26734
  }
26702
26735
  async function uploadSpaceActionReplyFiles(input) {
26703
26736
  const prepared = await prepareRequestedSpaceSendFiles({ filePaths: input.filePaths });
@@ -26737,22 +26770,31 @@ function runSpaceActionWake(input) {
26737
26770
  });
26738
26771
  }
26739
26772
  function runSpaceActionStatus(input) {
26773
+ emitActionRecorded(recordDispatchSpaceStatus({
26774
+ status: input.status,
26775
+ text: normalizeRequiredJoinedText(input.textParts, "Status text is required.")
26776
+ }));
26777
+ }
26778
+ function recordDispatchSpaceStatus(input) {
26740
26779
  const context = readDispatchSpaceActionContextFromEnv();
26741
26780
  assertAllowedAction(context, "post_status");
26742
- recordAction({
26781
+ return recordAction({
26743
26782
  action: {
26744
26783
  type: "post_status",
26745
26784
  status: normalizeStatus(input.status),
26746
- text: normalizeRequiredJoinedText(input.textParts, "Status text is required.")
26785
+ text: normalizeRequiredText(input.text, "Status text is required.")
26747
26786
  },
26748
26787
  command: "status",
26749
26788
  context
26750
26789
  });
26751
26790
  }
26752
26791
  function runSpaceActionSilent(input) {
26792
+ emitActionRecorded(recordDispatchSpaceSilent(input));
26793
+ }
26794
+ function recordDispatchSpaceSilent(input) {
26753
26795
  const context = readDispatchSpaceActionContextFromEnv();
26754
26796
  assertAllowedAction(context, "stay_silent");
26755
- recordAction({
26797
+ return recordAction({
26756
26798
  action: {
26757
26799
  type: "stay_silent",
26758
26800
  reason: normalizeRequiredText(input.reason, "A silent action requires --reason.")
@@ -26809,9 +26851,10 @@ function formatSpaceActionHelpCommand(action, context) {
26809
26851
  return formatOpenMeldCliCommand(`openmeld space action ${action}`);
26810
26852
  }
26811
26853
  function recordAction(input) {
26812
- const record = writeDispatchSpaceActionRecord(input);
26854
+ return writeDispatchSpaceActionRecord(input);
26855
+ }
26856
+ function emitActionRecorded(record) {
26813
26857
  outLine(`Action recorded: OpenMeld saved this unpublished Space action proposal (${record.action.type}) for the current Wake.`);
26814
- return record;
26815
26858
  }
26816
26859
  function createSpaceActionReplyTiming() {
26817
26860
  const startedAt = performance.now();
@@ -26933,6 +26976,88 @@ function normalizeRequiredText(value, errorMessage) {
26933
26976
  return normalized;
26934
26977
  }
26935
26978
  //#endregion
26979
+ //#region src/space/action-mcp-server.ts
26980
+ const FINAL_STATUS_SCHEMA = z.enum([
26981
+ "done",
26982
+ "blocked",
26983
+ "needs_input",
26984
+ "handoff"
26985
+ ]);
26986
+ function createSpaceActionMcpServer() {
26987
+ const server = new McpServer({
26988
+ name: "openmeld-dispatch-space-action",
26989
+ version: "1.0.0"
26990
+ }, { instructions: "Choose exactly one final OpenMeld Space Action for the current Wake. Use reply for the exact public message, status for a final visible status, or stay_silent when no public message is needed. Private assistant output is not posted to the Space." });
26991
+ server.registerTool("reply", {
26992
+ title: "Reply in the current OpenMeld Space",
26993
+ description: "Record the exact final public reply for the active OpenMeld Wake. Use real newline characters for paragraph breaks. Optionally wake or reference current Space targets by mention label or profile ID.",
26994
+ inputSchema: {
26995
+ message: z.string().min(1),
26996
+ referenceTargets: z.array(z.string().min(1)).optional(),
26997
+ wakeTargets: z.array(z.string().min(1)).optional()
26998
+ },
26999
+ annotations: {
27000
+ destructiveHint: false,
27001
+ idempotentHint: false,
27002
+ openWorldHint: false,
27003
+ readOnlyHint: false
27004
+ }
27005
+ }, async ({ message, referenceTargets, wakeTargets }) => executeSpaceAction(() => recordDispatchSpaceReply({
27006
+ referenceTargets,
27007
+ text: message,
27008
+ wakeTargets
27009
+ })));
27010
+ server.registerTool("status", {
27011
+ title: "Set the final OpenMeld Space status",
27012
+ description: "Record one final visible status for the active OpenMeld Wake. This closes the Wake; do not use it for interim progress.",
27013
+ inputSchema: {
27014
+ status: FINAL_STATUS_SCHEMA,
27015
+ text: z.string().min(1)
27016
+ },
27017
+ annotations: {
27018
+ destructiveHint: false,
27019
+ idempotentHint: false,
27020
+ openWorldHint: false,
27021
+ readOnlyHint: false
27022
+ }
27023
+ }, async ({ status, text }) => executeSpaceAction(() => recordDispatchSpaceStatus({
27024
+ status,
27025
+ text
27026
+ })));
27027
+ server.registerTool("stay_silent", {
27028
+ title: "Stay silent in the current OpenMeld Space",
27029
+ description: "Record that the active OpenMeld Wake intentionally needs no public reply. Use this only after deciding that silence is the correct final outcome.",
27030
+ inputSchema: { reason: z.string().min(1) },
27031
+ annotations: {
27032
+ destructiveHint: false,
27033
+ idempotentHint: false,
27034
+ openWorldHint: false,
27035
+ readOnlyHint: false
27036
+ }
27037
+ }, async ({ reason }) => executeSpaceAction(() => recordDispatchSpaceSilent({ reason })));
27038
+ return server;
27039
+ }
27040
+ async function runSpaceActionMcpServer() {
27041
+ readDispatchSpaceActionContextFromEnv();
27042
+ await createSpaceActionMcpServer().connect(new StdioServerTransport());
27043
+ }
27044
+ async function executeSpaceAction(action) {
27045
+ try {
27046
+ return { content: [{
27047
+ type: "text",
27048
+ text: `Action recorded: OpenMeld saved this unpublished Space action proposal (${(await action()).action.type}) for the current Wake.`
27049
+ }] };
27050
+ } catch (error) {
27051
+ return {
27052
+ content: [{
27053
+ type: "text",
27054
+ text: error instanceof Error ? error.message : String(error)
27055
+ }],
27056
+ isError: true
27057
+ };
27058
+ }
27059
+ }
27060
+ //#endregion
26936
27061
  //#region src/space/add-me-command.ts
26937
27062
  const SPACE_ID_HEX_REGEX = /^[0-9a-f]{64}$/i;
26938
27063
  const SHELL_SAFE_ARG_REGEX = /^[A-Za-z0-9_./:=@%+-]+$/u;
@@ -27365,7 +27490,7 @@ function normalizeOptionalString(value) {
27365
27490
  return normalized.length > 0 ? normalized : null;
27366
27491
  }
27367
27492
  async function runDefaultSpaceAddMeMembership(input) {
27368
- const { runSpaceAddMeMembership } = await import("./add-me-membership-BvvHsAGB.js");
27493
+ const { runSpaceAddMeMembership } = await import("./add-me-membership-DJPXJ1t0.js");
27369
27494
  return await runSpaceAddMeMembership(input);
27370
27495
  }
27371
27496
  //#endregion
@@ -32404,9 +32529,10 @@ registerSpaceFilesCommands(spaceCmd);
32404
32529
  const spaceActionCmd = spaceCmd.command("action").description("Record a dispatch-scoped OpenMeld Space Action.").action(async () => {
32405
32530
  await runSpaceActionHelp();
32406
32531
  });
32407
- spaceActionCmd.command("reply").description("Record a final Space reply for the current dispatch.").argument("<message...>", "Reply message").option("--wake <target>", "Wake another Agent Profile with this reply", collectRepeatedOptionValue, []).option("--reference <target>", "Reference a Human or Agent Profile", collectRepeatedOptionValue, []).option("--file <path>", "Share a local file in this Space reply", collectRepeatedOptionValue, []).action(async (messageParts, opts) => {
32532
+ spaceActionCmd.command("reply").description("Record a final Space reply for the current dispatch.").argument("[message...]", "Reply message").option("--message-file <path>", "Read the UTF-8 reply message from a file; use - for stdin").option("--wake <target>", "Wake another Agent Profile with this reply", collectRepeatedOptionValue, []).option("--reference <target>", "Reference a Human or Agent Profile", collectRepeatedOptionValue, []).option("--file <path>", "Share a local file in this Space reply", collectRepeatedOptionValue, []).action(async (messageParts, opts) => {
32408
32533
  await runSpaceActionReply({
32409
32534
  filePaths: Array.isArray(opts.file) ? opts.file : [],
32535
+ messageFilePath: typeof opts.messageFile === "string" ? opts.messageFile : void 0,
32410
32536
  messageParts: Array.isArray(messageParts) ? messageParts : [],
32411
32537
  wakeTargets: Array.isArray(opts.wake) ? opts.wake : [],
32412
32538
  referenceTargets: Array.isArray(opts.reference) ? opts.reference : []
@@ -33399,7 +33525,7 @@ profileCmd.action(async () => {
33399
33525
  }
33400
33526
  });
33401
33527
  });
33402
- profileCmd.command("create").description("Create an Agent Profile, or an additional Human Profile when enabled.").argument("[profileName]", "OpenMeld profile name").option("--name <profileName>", "OpenMeld profile name").option("--kind <kind>", "Profile kind (agent; human when additional Human Profile creation is enabled)").option("--agent-controller <ref>", "Agent controller for this profile, such as builtin:codex or custom:reviewer").option("--agent-controller-conversation-id <id>", "Private Agent Controller conversation ID for this Agent Profile").option("--model <modelId>", "Model intent for this Agent Profile Binding").option("--reasoning-effort <level>", "Reasoning effort intent for the selected model").option("--agent-controller-permission-mode <policy>", formatAgentControllerPermissionModeHelp()).option("--confirm-dangerous-agent-controller-permission-mode", "Confirm a dangerous Agent Controller Permission Mode without prompting", false).option("--owner <userId>", "Create for a member from `openmeld org directory --view agent`, or self").option("--computer <computerId>", "Exact Organization-visible Computer for a teammate-owned Agent").option("--project <projectId>", "Default Project for the new Agent").option("--session <strategy>", "Session strategy for an owner request: new, resume, or fork", "new").option("--native-session <id>", "Native provider Session ID required for resume or fork").option("--space <spaceId>", "Add the created Agent to this Space").option("--source <source>", "Request source: cli or local-agent", "cli").option("--request-key <key>", "Stable idempotency key for safely retrying an owner request").option("--organization <slugOrId>", "Organization slug or ID; defaults to the current Organization").option("--no-organization-wake-access", "Do not request Organization Wake access for the selected Binding").action(async (profileName, opts) => {
33528
+ profileCmd.command("create").description("Create an Agent Profile, or an additional Human Profile when enabled.").argument("[profileName]", "OpenMeld profile name").option("--name <profileName>", "OpenMeld profile name").option("--kind <kind>", "Profile kind (agent; human when additional Human Profile creation is enabled)").option("--agent-controller <ref>", "Agent controller for this profile, such as builtin:codex or custom:reviewer").option("--agent-controller-conversation-id <id>", "Private Agent Controller conversation ID for this Agent Profile").option("--model <modelId>", "Model intent for this Agent Profile Binding").option("--reasoning-effort <level>", "Reasoning effort intent for the selected model").option("--agent-controller-permission-mode <policy>", formatAgentControllerPermissionModeHelp()).option("--agent-controller-collaboration-mode <mode>", "Collaboration mode for this Agent Controller, such as codex:default or codex:plan").option("--open-code-permission <json>", "OpenCode permission configuration as a JSON object").option("--confirm-dangerous-agent-controller-permission-mode", "Confirm a dangerous Agent Controller Permission Mode without prompting", false).option("--owner <userId>", "Create for a member from `openmeld org directory --view agent`, or self").option("--computer <computerId>", "Exact Organization-visible Computer for a teammate-owned Agent").option("--project <projectId>", "Default Project for the new Agent").option("--session <strategy>", "Session strategy for an owner request: new, resume, or fork", "new").option("--native-session <id>", "Native provider Session ID required for resume or fork").option("--space <spaceId>", "Add the created Agent to this Space").option("--source <source>", "Request source: cli or local-agent", "cli").option("--request-key <key>", "Stable idempotency key for safely retrying an owner request").option("--organization <slugOrId>", "Organization slug or ID; defaults to the current Organization").option("--no-organization-wake-access", "Do not request Organization Wake access for the selected Binding").action(async (profileName, opts) => {
33403
33529
  const outputView = await resolveEffectiveViewForOutput();
33404
33530
  const targetName = (typeof profileName === "string" ? profileName : void 0) ?? opts.name;
33405
33531
  if (outputView === "agent") {
@@ -33411,16 +33537,18 @@ profileCmd.command("create").description("Create an Agent Profile, or an additio
33411
33537
  routeTokens: ["profile", "create"],
33412
33538
  view,
33413
33539
  run: async () => {
33414
- if (typeof opts.owner === "string") {
33540
+ if (typeof opts.owner === "string" || typeof opts.computer === "string" || typeof opts.project === "string" || typeof opts.space === "string" || typeof opts.organization === "string" || typeof opts.agentControllerCollaborationMode === "string" || typeof opts.openCodePermission === "string" || opts.organizationWakeAccess === false) {
33415
33541
  if (typeof opts.kind === "string" && opts.kind.trim().toLowerCase() !== "agent") throw createProfileCreateGuideError("--owner can only create an Agent Profile; pass --kind agent.");
33416
33542
  await runProfileCreationRequestCreate({
33417
33543
  agentController: opts.agentController,
33544
+ agentControllerCollaborationMode: opts.agentControllerCollaborationMode,
33418
33545
  agentControllerPermissionModeInput: opts.agentControllerPermissionMode,
33419
33546
  authorizeForOrganization: opts.organizationWakeAccess,
33420
33547
  confirmDangerousAgentControllerPermissionMode: Boolean(opts.confirmDangerousAgentControllerPermissionMode),
33421
33548
  defaultProjectId: opts.project,
33422
33549
  idempotencyKey: opts.requestKey,
33423
33550
  modelId: opts.model,
33551
+ openCodePermissionInput: opts.openCodePermission,
33424
33552
  nativeSessionId: opts.nativeSession,
33425
33553
  organization: opts.organization,
33426
33554
  profileName: targetName,
@@ -33429,7 +33557,7 @@ profileCmd.command("create").description("Create an Agent Profile, or an additio
33429
33557
  sessionStrategy: opts.session,
33430
33558
  source: opts.source,
33431
33559
  targetComputerId: opts.computer,
33432
- targetOwner: opts.owner,
33560
+ targetOwner: typeof opts.owner === "string" ? opts.owner : "self",
33433
33561
  view
33434
33562
  });
33435
33563
  return;
@@ -33718,9 +33846,16 @@ async function handlePreParseStandaloneCommand(argv) {
33718
33846
  async function main() {
33719
33847
  if (await runMacOsNativeKeychainHelperIfRequested()) return;
33720
33848
  const argv = process.argv.map((arg) => arg === "--h" ? "--help" : arg);
33849
+ if (isDispatchSpaceActionToolServerArgv(argv)) {
33850
+ await runSpaceActionMcpServer();
33851
+ return;
33852
+ }
33721
33853
  if (await delegateToManagedCliIfAuthoritative(argv)) return;
33722
33854
  await runLocalCli(argv);
33723
33855
  }
33856
+ function isDispatchSpaceActionToolServerArgv(argv) {
33857
+ return argv.length === 5 && argv[2] === "space" && argv[3] === "action" && argv[4] === "tool-server";
33858
+ }
33724
33859
  async function runLocalCli(argv) {
33725
33860
  try {
33726
33861
  await ensureSystemLayout();