> ## Documentation Index
> Fetch the complete documentation index at: https://docs.contactship.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Routing rules

> Order inbound rules by priority and verify conditions, schedules and destinations.

export const Availability = ({lang = 'es', plan, addon, permission, route, status}) => {
  const L = lang === 'en' ? {
    plan: 'Plan',
    addon: 'Add-on',
    permission: 'Permission',
    route: 'Where',
    status: 'Status',
    addonNote: 'enabled on request',
    allPlans: 'All plans',
    beta: 'Beta',
    nuevo: 'New',
    soon: 'Coming soon'
  } : {
    plan: 'Plan',
    addon: 'Add-on',
    permission: 'Permiso',
    route: 'Dónde',
    status: 'Estado',
    addonNote: 'se activa a pedido',
    allPlans: 'Todos los planes',
    beta: 'Beta',
    nuevo: 'Nuevo',
    soon: 'Próximamente'
  };
  const items = [];
  if (plan) items.push([L.plan, plan]);
  if (addon) items.push([L.addon, `${addon} · ${L.addonNote}`]);
  if (permission) items.push([L.permission, permission]);
  if (route) items.push([L.route, route]);
  if (status) items.push([L.status, L[status] || status]);
  return <div style={{
    display: 'flex',
    flexWrap: 'wrap',
    gap: '6px 22px',
    padding: '12px 16px',
    margin: '4px 0 24px',
    border: '1px solid rgba(2, 82, 255, 0.28)',
    borderLeft: '3px solid #0252ff',
    borderRadius: '8px',
    background: 'rgba(2, 82, 255, 0.05)',
    fontSize: '13.5px',
    lineHeight: '1.5'
  }}>
      {items.map(([k, v]) => <div key={k} style={{
    display: 'flex',
    gap: '6px',
    alignItems: 'baseline'
  }}>
          <span style={{
    fontSize: '10.5px',
    fontWeight: 600,
    letterSpacing: '0.07em',
    textTransform: 'uppercase',
    opacity: 0.65
  }}>{k}</span>
          <span style={{
    fontWeight: 500
  }}>{v}</span>
        </div>)}
    </div>;
};

<Availability lang="en" route="Settings → Telephony → Contact Center → Routing rules" permission="contact_center.read" addon="Contact center" />

Rules choose an inbound destination. They run from top to bottom by priority: the first match wins. A broad rule can prevent a more specific rule below it from running.

## Configure a rule

1. Open **Routing rules → New rule**.
2. Choose the trigger and input: phone call, WhatsApp or a call entering a queue.
3. Configure conditions and a time window where applicable.
4. Select an available destination.
5. Review rule order and save.
6. Test inside and outside configured hours.

## Triggers

| Trigger               | Input evaluated                              |
| --------------------- | -------------------------------------------- |
| Phone call            | Configured inbound telephone entry           |
| WhatsApp              | WhatsApp entry supported by the module rules |
| Call entering a queue | Entry into a specific queue                  |

An option does not connect a channel or enable WhatsApp calling by itself. Check the input's requirements before testing.

## Shadowed rules

The app detects rules that may be covered by earlier rules. If a rule does not run, review the conditions and priority of preceding rules.

Place specific rules before a general rule when they should take priority. Use queue fallback to define what happens if the destination does not answer.

## Difference from lead routing

These rules handle contact center entries. Lead routing handles contacts, stages and deadlines. Configuring one does not configure the other.

## Frequently asked questions

<AccordionGroup>
  <Accordion title="Do all matching rules run?">
    No. The first matching rule wins according to priority.
  </Accordion>

  <Accordion title="Why does routing change outside business hours?">
    Review time windows and subsequent or fallback rules. Test both scenarios.
  </Accordion>

  <Accordion title="Does selecting WhatsApp connect my number?">
    No. Channel connection and WhatsApp calling availability are configured separately.
  </Accordion>
</AccordionGroup>

## See also

* [Queues](/en/contact-center/queues-and-skills)
* [Monitoring](/en/contact-center/live-monitoring)
