> For the complete documentation index, see [llms.txt](https://docs.spike.sh/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.spike.sh/spike-api-docs/on-call-overrides.md).

# On-call Overrides

## GET /oncalls/{oncall\_id}/overrides

> Get all overrides

```json
{"openapi":"3.1.0","info":{"title":"Spike API","version":"1.0.0"},"tags":[{"name":"On-call Overrides"}],"servers":[{"url":"https://api.spike.sh","description":"API server"}],"paths":{"/oncalls/{oncall_id}/overrides":{"get":{"summary":"Get all overrides","tags":["On-call Overrides"],"parameters":[{"name":"x-api-key","in":"header","required":true,"schema":{"type":"string"},"description":"Your API key. Find it in your Spike dashboard under Settings > API."},{"name":"oncall_id","in":"path","required":true,"schema":{"type":"string"},"description":"oncall_id parameter"},{"name":"from","in":"query","required":true,"schema":{"type":"string"}},{"name":"to","in":"query","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error message describing the problem"},"error":{"type":"string","description":"Error type or code"}}}}}}
```

## DELETE /on-calls/{oncall\_id}/overrides/{override\_id}/remove

> Delete an override

```json
{"openapi":"3.1.0","info":{"title":"Spike API","version":"1.0.0"},"tags":[{"name":"On-call Overrides"}],"servers":[{"url":"https://api.spike.sh","description":"API server"}],"paths":{"/on-calls/{oncall_id}/overrides/{override_id}/remove":{"delete":{"summary":"Delete an override","tags":["On-call Overrides"],"parameters":[{"name":"x-api-key","in":"header","required":true,"schema":{"type":"string"},"description":"Your API key. Find it in your Spike dashboard under Settings > API."},{"name":"oncall_id","in":"path","required":true,"schema":{"type":"string"},"description":"oncall_id parameter"},{"name":"override_id","in":"path","required":true,"schema":{"type":"string"},"description":"override_id parameter"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error message describing the problem"},"error":{"type":"string","description":"Error type or code"}}}}}}
```

## Add an override

> Add a temporary override to an on-call schedule. Overrides allow you to temporarily assign a different user to cover an on-call shift.\
> \
> All timestamps should be in ISO 8601 format (e.g., \`2025-01-24T00:00:00.000Z\`).<br>

```json
{"openapi":"3.1.0","info":{"title":"Spike API","version":"1.0.0"},"tags":[{"name":"On-call Overrides"}],"servers":[{"url":"https://api.spike.sh","description":"API server"}],"paths":{"/on-calls/{oncall_id}/overrides/add":{"post":{"summary":"Add an override","description":"Add a temporary override to an on-call schedule. Overrides allow you to temporarily assign a different user to cover an on-call shift.\n\nAll timestamps should be in ISO 8601 format (e.g., `2025-01-24T00:00:00.000Z`).\n","tags":["On-call Overrides"],"parameters":[{"name":"x-api-key","in":"header","required":true,"schema":{"type":"string"},"description":"Your API key. Find it in your Spike dashboard under Settings > API."},{"name":"oncall_id","in":"path","required":true,"schema":{"type":"string"},"description":"oncall_id parameter"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"user":{"type":"string"},"start":{"type":"string"},"end":{"type":"string"},"desc":{"type":"string"},"timezone":{"type":"string"}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"Error":{"type":"object","properties":{"message":{"type":"string","description":"Error message describing the problem"},"error":{"type":"string","description":"Error type or code"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.spike.sh/spike-api-docs/on-call-overrides.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
