# Layers in on-call schedules

## What are Layers in on-call schedules?

In Spike.sh's on-call scheduling, 'Layers' add a dynamic dimension to your planning. Each layer encompasses essential elements like members, handoff times, rotations, and slots. The flexibility of adding multiple layers to a single schedule empowers you to customize timings and team involvement with precision.

Layers are meticulously organized in a sequential, ascending order. This design means that in instances of overlapping schedules, the higher layer takes precedence. For example, if Layer 2's timing intersects with that of Layer 1, Layer 2 will be the active layer, overriding Layer 1. Similarly, in a configuration with three layers, Layer 3 would supersede both Layers 1 and 2 in overlapping scenarios.

This layered approach ensures a seamless, well-coordinated on-call schedule, allowing for nuanced control over who is on-call and when..

{% hint style="warning" %}
Every on-call schedule will have at least one layer.
{% endhint %}

### What does overlapping mean?

'Overlapping' in layered scheduling is straightforward: when two layers share common times, the higher layer takes precedence. To illustrate, if Layer 1 and Layer 2 have overlapping schedules, Layer 2 will be the active one, effectively overriding the schedules set in Layer 1.

### Understand layers with an example

Here is a simple on-call schedule with 2 members rotating each day. This means one of the members is on-call every day covering for the entire week.

**All days -** Daily rotation among 2 members

![Just one layer to our schedule](/files/-MVaLydFvSOAlfOmK0L7)

This is how the calendar looks like with just the above layer in our on-call schedule

![Calendar for above on-call schedule with just one layer](/files/QVIRFzgJZGeXFOigTykI)

### Adding the weekend layer to override

Now, this could be too much to handle. How about we give them a break over the weekend and ask other members to help out.

To enable this, we can add another layer with weekly rotation among members who only need to be on-call **from Friday 6 PM to Monday 9 AM**

**Weekdays -** Daily rotation among 2 members\
**Weekends** - One person for the entire weekend rotating weekly

![2 separate layers, one for weekday and another for weekend](/files/-MVaCiykR8XYjII6hi9b)

Members from Layer 1 will be on-call every alternate day, on all weekdays and members from Layer 2 will be on-call for the entire alternate weekend (since weekly rotation has been applied).

This is how the calendar looks with both layers.

![Calendar with 2 layers, one set of members for weekdays and another for weekend](/files/-MVaN4q1zl6LDed2EF12)

### **How did overlapping work here?**

Members from Layer 2 will overlap the scheduled on-call from Friday 6 PM to Monday 9 AM.

{% hint style="info" %}
If the weekend layer was Layer 1 and the weekday layer was Layer 2 then the weekend layer would have never come to effect. **There are no limits on number of layers to be added on a single on-call schedule**
{% endhint %}

You can start experimenting with layers by editing the same schedule as many times as you want.

### FAQs on Layers

* **Can I add a layer temporarily?**
  * Yes, you can. Alternatively, also check out [On-call overrides](https://docs.spike.sh/oncall-schedules/override-an-on-call).
* **How many layers can I add?**
  * There is no limitation. Our recommendation is to avoid adding too many layers. It could get confusing how the schedule works and as a result teams usually hesitate to delete any layer.
* **How many members can be added in one layer?**
  * There is no limit here either.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.spike.sh/oncall-schedules/introduction-to-layers-in-on-call-schedules.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
