Orchardcore contact center

From CrestApps/CrestApps.AgentSkills · View interactive version

Orchardcore contact center is an AI agent skill from the GitHub repository CrestApps/CrestApps.AgentSkills. Skill for enabling, configuring, extending and operating the CrestApps Orchard Core Contact Center module that orchestrates work between the Omnichannel CRM and Telephony. Covers the CrestApps.OrchardCore.ContactCenter features (Agents, AgentEntitlements, BusinessHours, Queues, IntervalStatistics, D

How to use this skill

Skill file

Orchard Core Contact Center - Prompt Templates

Build a Contact Center on Orchard Core

You are an Orchard Core expert. Generate accurate feature selections, recipes, configuration, extension code, and operational guidance for the CrestApps Contact Center module set. It turns the Omnichannel CRM into a contact center: the CRM owns the work (contacts, activities, subjects, dispositions), Contact Center owns orchestration (queues, routing, reservations, presence, dialing, interactions, events), and Telephony owns media execution.

Guidelines

Feature Overview

| Feature | Feature ID | Depends on | Notes |

|---|---|---|---|

| Contact Center | CrestApps.OrchardCore.ContactCenter | CrestApps.OrchardCore.Omnichannel.Activities | Interaction lifecycle, durable event log and outbox, baseline permissions, Voice Media library, dialer decision log, admin menu |

| Contact Center Agent Services | CrestApps.OrchardCore.ContactCenter.AgentServices | none | Dependency-only agent profile directory (also used by the messaging workspace) |

| Contact Center Agents | CrestApps.OrchardCore.ContactCenter.Agents | Contact Center, Agent Services, CrestApps.OrchardCore.Users, CrestApps.OrchardCore.Skills | Agent profiles, presence, reason codes, sessions, heartbeat, after-call recovery. Agent skills come from the shared Skills catalog (Skills module) |

| Contact Center Agent Entitlements | CrestApps.OrchardCore.ContactCenter.AgentEntitlements | Agents | Restricts which queues and campaigns an agent may join. Disabled means any agent may join any queue |

| Contact Center Business Hours | CrestApps.OrchardCore.ContactCenter.BusinessHours | CrestApps.OrchardCore.BusinessHours | The open-hours gate (IBusinessHoursService, IBusinessHoursGate) that queues, entry points, the dialer and automated Omnichannel sends use to read Business Hours schedules (edited under Content → Business Hours). It keeps no calendars of its own |

| Contact Center Work Distribution | CrestApps.OrchardCore.ContactCenter.Queues | Agents, Business Hours | Queues, queue groups, skills, reservations, routing strategies |

| Contact Center Interval Statistics | CrestApps.OrchardCore.ContactCenter.IntervalStatistics | Queues | 15-minute queue and agent statistics (IIntervalStatisticsReader), the Queue intervals and Agent intervals report data sets, and Interaction Center → Management → Interval statistics |

| Contact Center Outbound Dialer | CrestApps.OrchardCore.ContactCenter.Dialer | Voice, Queues | Dialer profiles, callbacks, Preview batches, mandatory compliance gate, manual soft-phone screening |

| Contact Center Paced Dialing | CrestApps.OrchardCore.ContactCenter.Dialer.Paced | Dialer | Power, Progressive and Predictive pacing, pacing cycle records, dialer health |

| Provider Webhook Inbox | CrestApps.OrchardCore.ContactCenter.ProviderInbox | none | Dependency-only durable at-least-once webhook inbox, shipped by the CrestApps.OrchardCore.Webhooks module (category Webhooks) |

| Contact Center Voice | CrestApps.OrchardCore.ContactCenter.Voice | Queues, Real-Time, Recording Core, Provider Inbox, CrestApps.OrchardCore.Omnichannel.ChannelEndpoints, CrestApps.OrchardCore.Telephony | Dependency-only Voice Contact Center Call Router, outbound lines, external transfer destinations |

| Contact Center Inbound Entry Points | CrestApps.OrchardCore.ContactCenter.EntryPoints | Queues, Channel Endpoints | Entry points per channel (no voice dependency), IVR menu editor |

| Contact Center Inbound Voice | CrestApps.OrchardCore.ContactCenter.InboundVoice | Voice, Queues, Entry Points | Caller qualification, welcome and closed messages, IVR, voicemail, shared voicemail |

| Contact Center Voice Media | CrestApps.OrchardCore.ContactCenter.Voice.Media | Voice | Opt-in bidirectional media resolution; required for realtime speech-to-speech AI calls |

| Contact Center Recording Governance | CrestApps.OrchardCore.ContactCenter.Recording.Core | Contact Center | Dependency-only recording access governance and audit (voicemail playback) |

| Contact Center Call Recording | CrestApps.OrchardCore.ContactCenter.Recording | Voice, Recording Core | Recording orchestration, disclosure, secure pause, Call recordings page |

| Contact Center Secure Data Capture | CrestApps.OrchardCore.ContactCenter.SecureCapture | Recording, CrestApps.OrchardCore.Telephony.SoftPhone.Core | Hosted tokenized capture of card or identity data |

| Contact Center Supervision & Live Dashboard | CrestApps.OrchardCore.ContactCenter.Supervision | Real-Time, Voice | Live dashboard, monitor, whisper, barge, take over, Free agent |

| Contact Center Real-Time | CrestApps.OrchardCore.ContactCenter.RealTime | Queues, OrchardCore.SignalR | Dependency-only ContactCenterHub and real-time projections |

Activated automatically (no feature ID):

| Capability | Active when |

|---|---|

| Agent Workspace (My workspace) and docked agent bar | Agents + Real-Time + Voice + CrestApps.OrchardCore.Telephony.SoftPhone.Core |

| Contact Center soft-phone projection (Work tab, presence menu) | Voice + Real-Time + Telephony soft phone |

| Provider voice adapter (Telnyx, Asterisk) | Provider module + Contact Center Voice |

| Provider media adapter | Provider module + Voice Media |

| Contact Center reports | Queues + CrestApps.OrchardCore.Reports (Dialer activity and health also needs Paced Dialing) |

| Workflow activities | OrchardCore.Workflows + the capability that owns each task |

| Health checks and probes | OrchardCore.HealthChecks |

| Report Builder data sources | OrchardCore.DataPipelines.Core |

| Staff integration (agents are staff members with the Contact Center agent capability, a Contact Center card on the staff editor, and a person who leaves is signed out of every queue) | Agents + CrestApps.OrchardCore.Staff (see orchardcore-staff) |

Enable via Recipe

Minimal inbound voice contact center with the Agent Workspace and Telnyx:

{
  "steps": [
    {
      "name": "Feature",
      "enable": [
        "CrestApps.OrchardCore.ContactCenter",
        "CrestApps.OrchardCore.ContactCenter.Agents",
        "CrestApps.OrchardCore.ContactCenter.Queues",
        "CrestApps.OrchardCore.ContactCenter.InboundVoice",
        "CrestApps.OrchardCore.Telephony.SoftPhone",
        "CrestApps.OrchardCore.Telnyx"
      ]
    }
  ]
}

Paced outbound with supervision, recording and reports:

{
  "steps": [
    {
      "name": "Feature",
      "enable": [
        "CrestApps.OrchardCore.ContactCenter.Dialer.Paced",
        "CrestApps.OrchardCore.ContactCenter.Supervision",
        "CrestApps.OrchardCore.ContactCenter.Recording",
        "CrestApps.OrchardCore.Telephony.SoftPhone",
        "CrestApps.OrchardCore.Reports",
        "CrestApps.OrchardCore.Telnyx",
        "OrchardCore.Workflows",
        "OrchardCore.HealthChecks"
      ]
    }
  ]
}

The module also ships the harvestable recipe contact-center-asterisk-ga-core.recipe.json (name ContactCenterAsteriskGaCore, Contact Center — Asterisk (GA-Core)), which enables the certified ga-core-asterisk feature set. Feature recipes carry no queues or entry points; add those with the configuration steps in references/configuration-and-recipes.md.

Key Concepts

Layers

Omnichannel CRM   contacts, activities, campaigns, subjects, dispositions, subject actions
Contact Center    queues, reservations, routing, presence, dialer, interactions, events, metrics
Telephony         soft phone, provider resolver, call control, call state lookup
Providers         Telnyx, Asterisk, custom adapters (media, webhooks, provider APIs)

Agents and presence

An AgentProfile links an Orchard user to capacity (MaxConcurrentInteractions, default 1), skills, entitled queues and campaigns, and presence. Agent-set states are Available, RequestBreak, Break, Away, DoNotDisturb, Meeting, Training, AfterHoursUnavailable and Offline; Reserved, Busy and WrapUp are system-managed. Agents sign in from the soft phone's Work tab. Routing only uses an agent whose live session is online with a fresh heartbeat (HeartbeatTimeout, 90 seconds) and spare capacity. Breaks are system-approved: granted at once when idle, otherwise held as RequestBreak until work ends.

Queues, reservations and routing

A queue owns priority, SLA threshold, reservation timeout, unanswered-offer action (Requeue, Voicemail, Reject), required skills with proficiency, Business Hours schedule (BusinessHoursCalendarId holds a schedule id), overflow chain, max wait, queue size, and caller treatment. Routing runs a chain of IActivityRoutingStrategy implementations: required skills, preferred skills, capacity, sticky agent, then the queue's scoring strategy (LongestIdle default, RoundRobin, LeastBusy). A reservation offers one activity to one agent under distributed locks plus database compare-and-set, so work is never offered twice. Every assignment publishes an auditable RoutingDecisionMade event.

Work state

ContactCenterWorkState (one per activity) owns assignment status, reservation, assigned agent and attempt count. The activity's matching columns are a read model reconciled after commit. Mutate through IContactCenterWorkStateService.MutateAsync, and schedule CRM-owned changes through IContactCenterActivityWriter.ScheduleUpdateAsync.

Dialer modes

A dialer profile is an execution policy (mode, provider, pacing, retries, caller ID, compliance), not a source of work. Activities are loaded with the Dialer source, picking both campaign and profile; the campaign acts as the routing queue.

| Mode | Feature | Behavior |

|---|---|---|

| Preview | Dialer | Agent reviews and accepts, then the call is placed |

| Power | Paced Dialing | Up to Calls per agent (max 3) calls per look at the campaign, each with a reserved agent |

| Progressive | Paced Dialing | One call per available agent, bounded at 100 per look |

| Predictive | Paced Dialing | ReservedPerCall (default) throttled by abandonment rate, or OverDial sized from the measured answer rate |

Every attempt passes IDialerEligibilityService (attempts, retry delay, do-not-call, calling window, abandonment cap, national registries) and fails closed. Manual is not a profile mode; soft-phone dials are screened by the Dialer's IOutboundCallScreener.

Paced calls connect to the agent without an Answer click: the agent stays Reserved while the customer rings, the hub snapshot and every AgentPresenceNotification carry DialHoldReservationId, and the soft phone answers only the leg tagged for that dial. A Preview record stays reserved for the profile's PreviewOfferTimeoutSeconds (default 180, 15 to 3600), and the open Complete screen keeps it alive. Dialer loads skip contacts with no number to dial.

Voice routing and entry points

An entry point picks omnichannel addresses (AddressIds) and routes them to a queue, a specific agent (personal line) or an AI voice agent (TargetType Queue, Agent, AIAgent), with priority, business hours, closed action (HoldInQueue, Voicemail, Overflow, Reject), welcome and closed messages, and an optional IVR menu. Inbound calls flow provider webhook → durable inbox → IVoiceContactCenterCallRouter → activity and interaction → queue → reservation → offer → POST Admin/contact-center/voice/offer/accept.

AI voice agent

An entry point with TargetType AIAgent and TargetAIProfileId answers with an automated voice conversation from CrestApps.OrchardCore.Omnichannel.Voice (see orchardcore-omnichannel-voice). With Voice Media enabled and a realtime-capable conversation deployment, the call runs as live speech-to-speech; otherwise it uses the turn-based loop. The Hand Off to Live Agent workflow task (and the model's own transfer tool) seat the caller in a queue.

Recordings and voicemail

Recording is permitted while Call Recording is enabled; ContactCenterRecordingSettings.RecordAllCalls (default on) records every routed call. IRecordingGovernancePolicy fails closed on consent, the recording disclosure captures consent, agents can secure-pause, and erasure honors legal hold. Media lives in the Telephony IRecordingMediaStore, never in Contact Center. Voicemail is greeting, then beep, then record, delivered to an agent inbox or to the queue's shared voicemail box.

Live call topology

Each CallSession carries legs, bridges with append-only membership, consults, monitor sessions and typed relationships. CallTopologyProjector is the only writer; CallSession.ParticipantsAt(utc) answers who was on the call at any instant.

Domain events

Every change is an immutable InteractionEvent published through IContactCenterEventPublisher and dispatched at least once by the outbox to IContactCenterEventHandler implementations, each with a stable HandlerId and a declared ContactCenterHandlerReplaySafety. Failed handlers retry with back-off and dead-letter after ten attempts; a ConcurrencyException in a handler is rolled back, retried and logged as a warning.

Admin Locations

| Menu | Feature |

|---|---|

| Interaction Center → Management → Agent states | Agents |

| Interaction Center → Management → Agent entitlements | Agent Entitlements |

| Content → Business Hours (schedules from the Business Hours module; the old Interaction Center → Management → Business hours page is gone) | Business Hours (CrestApps.OrchardCore.BusinessHours) |

| Interaction Center → Management → Queues, Queue groups | Queues |

| Content → Skills (the old Contact Center skills page redirects there; ManageContactCenterSkills still manages them) | Skills catalog |

| Interaction Center → Management → Interval statistics | Interval Statistics |

| Interaction Center → Management → Dialer Profiles | Dialer |

| Interaction Center → Management → Inbound entry points | Entry Points |

| Interaction Center → Management → Voice Media | Contact Center |

| Interaction Center → My workspace, My voicemail greeting | Agent Workspace glue |

| Interaction Center → Live dashboard (with the Live AI calls panel) | Supervision |

| Interaction Center → Shared voicemail | Inbound Voice |

| Interaction Center → Call recordings | Call Recording |

| Settings → Contact Center (group contactcenter) | Tabs from Voice, Recording, Secure Capture and Channel Endpoints |

| Reports (Executive, Operations, Queue & Routing, Agent Performance, Workforce & Payroll, CRM & Campaigns, Compliance & Audit) | Queues + Reports |

Campaigns, channel endpoints, subject flows and dispositions are Omnichannel screens (see orchardcore-omnichannel-management).

Permissions and Roles

| Permission | Default stereotype | Grants |

|---|---|---|

| ManageContactCenter | Administrator | Implies every manage permission below |

| ManageInteractions, ViewInteractions | Agent and Supervisor get ViewInteractions | Interaction access, generic voice ingress, recording erasure |

| ManageContactCenterAgents, ManageContactCenterQueues, ManageContactCenterQueueGroups, ManageContactCenterSkills, ManageContactCenterDialer, ManageContactCenterVoiceMedia | Administrator | Configuration screens |

| ManageBusinessHoursSchedules (BusinessHoursPermissions, Business Hours module) | Administrator | Content → Business Hours. Replaces the removed ManageContactCenterBusinessHours; the upgrade grants it to roles that held that permission or ManageContactCenter |

| ContactCenterSignIntoQueues | Agent | Sign in, presence, My workspace, My voicemail greeting |

| ContactCenterSecurePauseRecording, ContactCenterInitiateSecureCapture | Agent | Pause recording or start a secure capture on own live interaction |

| MonitorContactCenter | Supervisor | Live dashboard, listen, whisper, barge, message, dependency probe |

| ContactCenterInterveneInCalls | Supervisor | Take over, end, transfer, record, set agent state, Free agent |

| ContactCenterTransferExternally | Supervisor | Transfer to external destinations |

| ViewContactCenterReports | Supervisor | Contact Center reports |

| AccessContactCenterSharedVoicemail, ManageContactCenterSharedVoicemail | Supervisor | Work and manage shared queue voicemail |

| ListenToOwnCallRecordings / ListenToAllCallRecordings, DeleteCallRecordings | Agent / Supervisor, Administrator | Call recordings page (Call Recording feature) |

Supervisors see only the queues and campaigns on their own agent entitlement record; ManageContactCenter sees all. Permissions are declared in ContactCenterPermissions (CrestApps.OrchardCore.ContactCenter.Core).

Key Extension Points

| Contract | Use it to |

|---|---|

| IContactCenterEventHandler | React to domain events (projections, integrations). Declare HandlerId and ReplaySafety |

| IContactCenterRealTimeEventHandler | Mark a cheap, naturally idempotent handler that pushes to a screen; it runs for every event of a change as soon as it commits, before all other handlers |

| IActivityRoutingStrategy | Add a filter or score to candidate agents (Order, ApplyAsync(ActivityRoutingContext)) |

| IEntryPointResolver | Contribute an entry-point source; resolvers are asked in order and the first plan wins |

| IDialerStrategy | Implement a dialing mode |

| INationalDoNotCallRegistry | Add a national DNC registry (see orchardcore-dnc-registry) |

| IContactCenterVoiceProvider plus IContactCenterVoiceCallControlProvider, ...TransferProvider, ...RecordingProvider, ...MonitoringProvider, IContactCenterVoiceMediaProvider | Write a provider adapter. Reference only CrestApps.OrchardCore.ContactCenter.Abstractions |

| IProviderWebhookInboxHandler (namespace CrestApps.OrchardCore.Webhooks, package CrestApps.OrchardCore.Webhooks.Abstractions) | Process durable provider webhook deliveries; declare TechnicalName and a WebhookHandlerReplaySafety |

| IAgentPhoneStatusProvider | Tell the agent bar whether a user has a phone open (HasOpenPhoneAsync; null when the provider cannot tell) |

| IAgentProfileReader, IAgentQueueMembershipReader, services.AddEntryPointChannel(...) | Let a channel module read the agent directory and offer a channel to entry points without referencing Contact Center Core |

| ISecureCaptureTokenSink | Forward captured values to a PCI-DSS vault (required outside Development) |

| IRecordingDisclosureProvider | Supply the disclosure text per call type |

| IVoiceMediaProvisioningService | Resolve playable media for a provider (ResolveAsync) |

| IContactCenterFeatureWorkManager | Gate background work during feature quiesce and drain |

A minimal event handler:

using CrestApps.OrchardCore.ContactCenter;
using CrestApps.OrchardCore.ContactCenter.Core.Models;
using CrestApps.OrchardCore.ContactCenter.Core.Services;
using Microsoft.Extensions.Logging;

public sealed class CallEndedAuditHandler : IContactCenterEventHandler
{
    private readonly ILogger _logger;

    public CallEndedAuditHandler(ILogger<CallEndedAuditHandler> logger)
    {
        _logger = logger;
    }

    // Stable forever: the outbox checkpoints completed handlers by this id.
    public string HandlerId => "MyCompany/CallEndedAudit/v1";

    public ContactCenterHandlerReplaySafety ReplaySafety => ContactCenterHandlerReplaySafety.NaturallyIdempotent;

    public Task HandleAsync(InteractionEvent interactionEvent, CancellationToken cancellationToken = default)
    {
        if (interactionEvent.EventType != ContactCenterConstants.Events.CallEnded)
        {
            return Task.CompletedTask;
        }

        var data = interactionEvent.GetData<CallLifecycleEventData>();

        _logger.LogInformation(
            "Call {InteractionId} ended with cause {HangupCause}.",
            interactionEvent.InteractionId,
            data?.HangupCause);

        return Task.CompletedTask;
    }
}

Register it with services.AddScoped<IContactCenterEventHandler, CallEndedAuditHandler>(); in a startup marked [RequireFeatures("CrestApps.OrchardCore.ContactCenter")]. Registration rejects a blank or duplicate HandlerId and ReplaySafety of Unspecified. More samples are in references/routing-and-dialer.md and references/workflows.md.

Upgrading from 2.x

Contact Center is new in 3.0. Code from 3.0 previews or neighboring modules must apply these changes:

Troubleshooting Pointers

Full diagnostics and runbooks are in references/production-support.md.

References

Related Skills

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.